Skip to main content
POST
Upload product document

Authorizations

X-API-Key
string
header
required

Path Parameters

organization_id
string<shortuuid>
required

UUID of the organization that owns the product.

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$
gtin
string
required

GTIN-8/12/13/14 of the target product. Normalized to GTIN-14 by zero-padding before lookup.

Pattern: ^\d{8,14}$

Body

multipart/form-data
file
file
required

PDF document to upload.

title
string
default:""

Caption for the document. Empty string when not specified.

Maximum string length: 255
description
string
default:""

Free-text description of the document. Empty string when not specified.

Response

201 - application/json

Created

A single PDF document attached to a product.

id
string<shortuuid>
required

URL-safe 22-character shortuuid encoding of the row's UUID primary key. Stable across the row's lifetime; suitable for sharing in URLs, log lines, and external SDK clients. Accepted on input as either the shortuuid form or the canonical UUID form (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$
title
string
required

Caption entered for the document. Empty string when not set.

Maximum string length: 255
Example:

"Safety Data Sheet"

description
string
required

Free-text description of the document. Empty string when not set.

display_title
string
required

Best available title: the entered title, else the PDF's embedded title, else the filename.

Example:

"Safety Data Sheet"

created
string<date-time>
required

ISO-8601 UTC timestamp of when the document was uploaded.

file_url
string<uri>

Absolute URL of the stored PDF. Null only when the underlying file is missing.

Example:

"https://cdn.closient.com/products/00012345678905/sds.pdf"

page_count
integer | null

Number of pages, extracted asynchronously after upload. Null until the PDF-processing task has run.

Required range: x >= 0
file_size_bytes
integer | null

Size of the stored file in bytes. Null when not yet computed.

Required range: x >= 0
thumbnail_url
string<uri>

URL of the first-page thumbnail, generated asynchronously. Empty string / null until processing has run.