Consistent_identitiesUpload_target

Step 1) Uploading a target image

POST
/api/consistent_identities/upload_target

The uploaded target image expires after 24 hours.

import requestsapi_url = "https://api.piktid.com/api"access_token = "your_access_token"target_path = "path_to_image"options = {"flag_hair": True,}with open(target_path, "rb") as target:response = requests.post(api_url + "/consistent_identities/upload_target",headers={"Authorization": "Bearer " + access_token},data={"options": json.dumps(options)},files={"file": target},).json()image_id = response.get("image_id")print("Created image ID: ", image_id)

Authorization

token_auth_2
headerAuthorizationBearer <token>

Request Body

multipart/form-data
  1. body
file?unknown
url?string
options?string

Response Body

Success

application/json
  1. response
image_id?string
faces?array<string>
coordinates_list?array<string>
thumbnails?array<string>
blurred_faces_list?array<string>
face_description_list?array<string>
curl -X POST "https://example.com/api/consistent_identities/upload_target"
{  "image_id": "string",  "faces": [    "string"  ],  "coordinates_list": [    "string"  ],  "thumbnails": [    "string"  ],  "blurred_faces_list": [    "string"  ],  "face_description_list": [    "string"  ]}