Skip to content

Simple application example, using Node Js and API Amazon Rekognition. Index new faces, delete faces and the main functionality facial recognition using photo.

License

Notifications You must be signed in to change notification settings

TeknofileNet/aws-rekognition-with-node-js

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aws-rekognition-with-node-js

Simple application example, using Node Js and API Amazon Rekognition. Index new faces, delete faces and the main functionality facial recognition using photo detect.

Getting Started

To start, you must have an AWS account, it is necessary to create collection and perform calls to API rekognition.

Prerequisites

Install Node JS and AWS CLI in your enviroment.

Installing

The first step, create Collection in your terminal using the folow command

Make sure AWS CLI is configured with your keys

aws rekognition create-collection --collection-id <your collection name>

Clone this repo

git clone https://github.com/wanderaraujo/aws-rekognition-with-node-js.git

Run command to install resources

npm i

In file aws-config.js on folder /resource/config, put the collectionName and region that you create your collection

module.exports.collectionName = "PUT YOUR COLLECTION NAME HERE";
module.exports.region = "PUT YOUR REGION COLLECTION HERE";

And finally run command to start example

npm start or node server

The application running at port 3000

Calling the methods

Using Postman

  • POST /detect-face
POST /detect-face HTTP/1.1
Host: localhost:3000
Content-Type: application/x-www-form-urlencoded
Cache-Control: no-cache

photo=<source with image base 64>
  • POST /index-new-face
POST /index-new-face HTTP/1.1
Host: localhost:3000
Content-Type: application/x-www-form-urlencoded
Cache-Control: no-cache
photo=<source with image base 64>&id_user=<id of user in your data base>
  • POST /delete-face
POST /delete-face HTTP/1.1
Host: localhost:3000
Content-Type: application/x-www-form-urlencoded
Cache-Control: no-cache

face_id= <string with face id to delete>

Put param photo whitout "image/png;base64,"

Built With

Authors

License

This project is licensed under the GNU License - see the LICENSE.md file for details

About

Simple application example, using Node Js and API Amazon Rekognition. Index new faces, delete faces and the main functionality facial recognition using photo.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%