Skip to content

Latest commit

 

History

History
53 lines (40 loc) · 1.54 KB

README.md

File metadata and controls

53 lines (40 loc) · 1.54 KB

Google Cloud Vision Kotlin Sample

Open in Cloud Shell

Description

This simple command-line application demonstrates how to invoke the Google Cloud Vision API from Kotlin. The sample calls the Vision API on an input image.

Example:

java -jar build/libs/vision.jar ./resources/doggo.jpg

Quickstart

Setup

Build

  • Clone the repository
git clone https://github.com/GoogleCloudPlatform/kotlin-samples
cd kotlin-samples/vision
  • Build the project with Gradle Wrapper:
# run with "-info" flag to print potential errors
./gradlew build -info

Running the sample!

# Call the Vision API with the default image file in "resources/doggo.jpg"
java -jar build/libs/vision.jar
# Call the Vision API with your own image file
java -jar build/libs/vision.jar path/to/your-image.jpg

Contributing changes

Licensing