face-plusplus-node
Advanced tools
Comparing version 0.0.1 to 0.0.2
{ | ||
"name": "face-plusplus-node", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"description": "Face++ v3 API wrapper for Node.JS", | ||
@@ -17,3 +17,3 @@ "main": "index.js", | ||
"author": "Alperen Yurdakul", | ||
"license": "ISC", | ||
"license": "MIT", | ||
"bugs": { | ||
@@ -20,0 +20,0 @@ "url": "https://github.com/Nycrera/face-plusplus-node/issues" |
# face-plusplus-node | ||
[![NPM Version][npm-image]][npm-url] | ||
[![NPM Downloads][downloads-image]][downloads-url] | ||
# Version: 0.0.1 | ||
[![npm version](https://badge.fury.io/js/face-plusplus-node.svg (https://badge.fury.io/js/face-plusplus-node) | ||
Face++ /v3 [faceplusplus.com](http://faceplusplus.com) API for Node.js | ||
Face++ /v3 [faceplusplus.com](http://faceplusplus.com) API wrapper for Node.js | ||
@@ -12,3 +9,3 @@ ### Installation with npm | ||
### Usage | ||
## Configuration | ||
```js | ||
@@ -18,3 +15,3 @@ var facepp = require('face-plusplus-node'); | ||
### (Required) Set your API Key / Get your API key and secret at [faceplusplus.com](http://faceplusplus.com) | ||
### Set your API Key / Get your API key and secret at [faceplusplus.com](http://faceplusplus.com) (Required) | ||
```js | ||
@@ -24,3 +21,3 @@ facepp.setApiKey('API_KEY'); | ||
### (Required) Set your API Secret | ||
### Set your API Secret(Required) | ||
```js | ||
@@ -63,3 +60,3 @@ facepp.setApiSecret('API_SECRET'); | ||
return_attributes: 'ethnicity,beauty,eyegaze', | ||
image_base64: fs.readFileSync('./image.jpg').toString('base64'); | ||
image_base64: fs.readFileSync('./image.jpg').toString('base64') | ||
} | ||
@@ -72,3 +69,25 @@ }; | ||
### Face Comparison request (pass 2 images from the local file system using base64 encoding) | ||
```js | ||
var facepp = require('face-plus-plus'), | ||
fs = require('fs'); | ||
You can see all possible parameters and ways to pass image and also compare two faces you can see [Face++ Documentation](https://console.faceplusplus.com/documents/5679127) | ||
facepp.setApiKey('API_KEY'); | ||
facepp.setApiSecret('API_SECRET'); | ||
var parameters = { | ||
image_base64_1: fs.readFileSync('./image1.jpg').toString('base64'), | ||
image_base64_2: fs.readFileSync('./image2.jpg').toString('base64'), | ||
} | ||
}; | ||
facepp.post('/compare', parameters, function(err, res) { | ||
console.log(res); | ||
}); | ||
``` | ||
You can see all possible parameters and ways to pass image and also compare two faces you can see [Face++ Documentation](https://console.faceplusplus.com/documents/5679127) | ||
## License | ||
[MIT](LICENSE) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7134
5
89