curl --request POST 'https://core.getfaceage.com/api/v1/quiz/upload-img/{business_id}' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer your_secret_key' \
--form 'image=@"/path/to/image.png"'
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => 'https://core.getfaceage.com/api/v1/quiz/upload-img/{business_id}',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS => ['image' => new CURLFILE('/path/to/image.png')],
CURLOPT_HTTPHEADER => [
'Accept: application/json',
'Authorization: Bearer your_secret_key',
],
]);
$response = curl_exec($curl);
curl_close($curl);
echo $response;
storage/quiz/12567/670a4919b99087.png
{
"message": "Unauthenticated."
}
Skin analyze quiz
Upload quiz image
Upload an image to use in a quiz.
POST
/
quiz
/
upload-img
/
{business_id}
curl --request POST 'https://core.getfaceage.com/api/v1/quiz/upload-img/{business_id}' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer your_secret_key' \
--form 'image=@"/path/to/image.png"'
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => 'https://core.getfaceage.com/api/v1/quiz/upload-img/{business_id}',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS => ['image' => new CURLFILE('/path/to/image.png')],
CURLOPT_HTTPHEADER => [
'Accept: application/json',
'Authorization: Bearer your_secret_key',
],
]);
$response = curl_exec($curl);
curl_close($curl);
echo $response;
storage/quiz/12567/670a4919b99087.png
{
"message": "Unauthenticated."
}
Uploads an image for a quiz and returns its storage path.
Path parameters
integer
required
ID of the business.
Body
file
required
Image file. Supported types:
png, jpeg, jpg, ico. Send as multipart/form-data.Response
Returns the storage path of the uploaded image as plain text.curl --request POST 'https://core.getfaceage.com/api/v1/quiz/upload-img/{business_id}' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer your_secret_key' \
--form 'image=@"/path/to/image.png"'
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => 'https://core.getfaceage.com/api/v1/quiz/upload-img/{business_id}',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS => ['image' => new CURLFILE('/path/to/image.png')],
CURLOPT_HTTPHEADER => [
'Accept: application/json',
'Authorization: Bearer your_secret_key',
],
]);
$response = curl_exec($curl);
curl_close($curl);
echo $response;
storage/quiz/12567/670a4919b99087.png
{
"message": "Unauthenticated."
}