Hey, human!
HTTP/2 200 OK content-type: text/markdown; charset=utf-8 vary: accept, user-agent x-agent: [ai_agent]
Loading the agent response…
Finish a brand file upload
Step 2 of 2. Checks what was stored at the upload address (size, type and the real first bytes, the same rules as the brand editor) and attaches it. A file that fails is removed and answered 422 invalid_file; nothing stored yet is 409 file_not_uploaded. An icon, logo, banner, social image or favicon replaces the current one, and the old file is removed unless the brand still uses it. For logo you may send name, type and usage; for asset send collection_id (or collection_name to start a collection), name and type; for team_photo send member_id (or member_name); for guideline_image send section_id and optionally kind (image, do, dont) and caption. Completing the same file again returns the same answer with already_attached true and changes nothing. The file_id only works for the brand and slot it was made for. Needs brands:files.
What you provide
- Nameoptional
- Typeoptional: For logo: primary, secondary, monochrome, reversed, icon, favicon, square or social media. For asset: the file type, for example image/png
- Usageoptional
- Collection idoptional
- Collection nameoptional
- Member idoptional
- Member nameoptional
- Section idoptional
- Kindoptional
- Captionoptional
Do this with AI
I want to finish a brand file upload. Use the Tarkle API. Read the reference for this operation and follow it exactly: https://project-03b42162.restlessdocs.com/endpoint/completebrandfileupload.md Authenticate with your API key as a Bearer token in the Authorization header. Then make the request for me and tell me what came back.
Paste this into Claude, Cursor, or any AI assistant and it will do it for you.
https://tarkle.com/api/v1/brands/{brand}/files/{file}/completecurl --request POST \
--url https://tarkle.com/api/v1/brands/brand/files/file/complete \
--header 'Authorization: Bearer $API_KEY' \
--header 'Content-Type: application/json' \
--header 'X-Workspace-Key: X-Workspace-Key' \
--data '
{
"name": "name",
"type": "type",
"usage": "digital",
"collection_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"collection_name": "collection_name",
"member_id": "member_id",
"member_name": "member_name",
"section_id": "section_id",
"kind": "image",
"caption": "caption"
}
'Path parameters
brandstringrequiredBrand id (uuid) or slug
filestringrequiredThe file_id from startBrandFileUpload
Query parameters
workspace_keystringThe same key as the X-Workspace-Key header, for clients that cannot set headers. Send one of the two, or both with the same value (different values are 400 conflicting_workspace)
Header parameters
X-Workspace-KeystringrequiredThe 8-character key of the workspace this call acts on; GET /workspaces lists the keys a token can use. A workspace id is refused (400 workspace_key_required)
Idempotency-KeystringMakes a write safe to repeat. Send a random value (a UUID is fine) of up to 255 visible characters. A repeat of the same request gets the first answer again, with the header `Idempotent-Replayed: true`, and does nothing twice. The same key for a different request is 422 `idempotency_key_reused`; the same request while the first one is still running is 409 `idempotency_in_progress`. A 5xx or 429 is not remembered, so retrying it runs the request again. Keys last 24 hours and belong to the account that created the token.
Body
application/jsonnamestringtypestringFor logo: primary, secondary, monochrome, reversed, icon, favicon, square or social media. For asset: the file type, for example image/png
usagestringcollection_idstring · uuidcollection_namestringmember_idstringmember_namestringsection_idstringkindstringcaptionstring