Api to use all google cloud vision services, made with TypeScript ❤️!
Explore the docs »
Google offers an incredible api with several services related to images and AI, this is a project that in a simple way brings together its features and makes its use simpler.
You can simply create an account at GCP and upload an image and receive data from it through that backend.
The backend receives your data and the image and returns its data through JSON according to the type of request you requested
This is an example of how you may give instructions on setting up your project locally. To get a local copy up and running follow these simple example steps.
This is an example of how to list things you need to use the software and how to install them.
- npm
npm install npm@latest -g
- yarn
https://classic.yarnpkg.com/en/docs/install/
- Create a GCP account
- Clone the repo
git clone https://github.com/Alifilho/google-cloud-vision-services
- Install NPM packages
yarn
- Run locally
yarn start
Basically there are two options, send the photo directly or in base64 format in a request, the routes are:
- Base64:
/api/base64
- Image:
/api/upload-image
In both you must pass a Header with the name Type, and the values can be:
- TEXT_DETECTION
- FACE_DETECTION
- IMAGE_PROPERTIES
- LABEL_DETECTION
- LANDMARK_DETECTION
- LOGO_DETECTION
- OBJECT_LOCATION
- SAFE_SEARCH_DETECTION
- WEB_DETECTION
And you need to pass the JSON key and email that you got from GCP in the request body.
It will return the values according to the type of the requested request.
Well the project is simple, and another demonstration of GCP in Node, but if interested in, contributions and forks are always amazing. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.
Alisson Oliveira - Linkedin - alissonoliveiram@gmail.com