Sign Up

Log In

FaceRect

FREE
By apicloud
Updated 4 months ago
Media
8.9/10
Popularity Score
1512ms
Latency
98%
Success Rate
normanpoh4 years ago
Any curl example for POSTing with image upload?Hello, I'm new to Curl. How do I upload an image and call https://apicloud-facerect.p.mashape.com/process-file.json at the same time in Curl? The following didin't work but it illustrates what I want to do: curl -i -F name=test -F [email protected] --request POST 'https://apicloud-facerect.p.mashape.com/process-file.json' --header "X-Mashape-Authorization: <my code>" --insecure Also, I used the insecure option because otherwise curl keeps complaining with the certificate issue. Thanks for your help!
apicloud4 years ago
Hi there! Thanks for interest in our API! Here is a working cURL sample for you: curl --request POST 'https://apicloud-facerect.p.mashape.com/process-file.json' --header "X-Mashape-Authorization: <your code>" -F "[email protected]" You may also add "-i" or "--include" if you need response headers. "--insecure" shouldn't really be necessary, we didn't experience any problems with the certificate while testing. Hope that helps!
Hi Developer, feel free to post your answer:
Log inSign up

Install SDK for NodeJS

Installing

To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request

unirest.post("https://apicloud-facerect.p.rapidapi.com/process-file.json")
.header("X-RapidAPI-Key", "undefined")
.header("Content-Type", "application/x-www-form-urlencoded")
.send("features=undefined")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication
Sign up for freeto test this endpoint
Join the world’s largest API marketplace with over half a million developers and thousands of APIs.
DiscoverAPIs
Testfrom the browser
Connectusing code snippets
Managefrom one dashboard