Skip to main content
POST
/
certifications
/
api
/
v1
/
products
/
{gtin}
/
claims
Assign claim to product
curl --request POST \
  --url https://www.closient.com/certifications/api/v1/products/{gtin}/claims \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "claim_id": "<string>",
  "metadata": {},
  "source": "BRAND_SELF_DECLARED",
  "valid_from": "2023-12-25",
  "expiration_date": "2023-12-25",
  "evidence_url": "",
  "evidence_note": ""
}
'
{
  "id": "<string>",
  "label": "<string>",
  "code": "<string>",
  "category": "DIETARY",
  "source": "BRAND_SELF_DECLARED",
  "metadata": {},
  "valid_from": "2023-12-25",
  "expiration_date": "2023-12-25"
}

Documentation Index

Fetch the complete documentation index at: https://docs.closient.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-API-Key
string
header
required

Path Parameters

gtin
string
required

GTIN-8, GTIN-12, GTIN-13, or GTIN-14 barcode digits (no spaces, no hyphens). Shorter forms are zero-left-padded to GTIN-14 server-side. Returns 404 if no product matches the normalized GTIN.

Required string length: 8 - 14
Pattern: ^\d{8,14}$

Body

application/json

Request body for POST /products/{gtin}/claims.

Creates a new :class:ClaimAssignment linking the GTIN's product to the claim identified by claim_id. Returns 409 Conflict if the assignment already exists.

claim_id
string<shortuuid>
required

UUID of the :class:Claim to assign. Use the id field from GET /claims/{id}.

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$
metadata
Metadata · object

Developer-attached key/value data. Send {} or null to clear. Empty-string values delete that key. Omitted keys are preserved.

source
enum<string>
default:BRAND_SELF_DECLARED

How the claim is asserted. Defaults to BRAND_SELF_DECLARED for brand-supplied data; set to THIRD_PARTY_VERIFIED when an audit trail backs the claim.

Available options:
BRAND_SELF_DECLARED,
THIRD_PARTY_VERIFIED
valid_from
string<date> | null

Start of validity for this claim (ISO 8601). Optional.

expiration_date
string<date> | null

End of validity for this claim (ISO 8601). Optional; null = open-ended.

evidence_url
string
default:""

URL to supporting evidence (third-party certificate scan, lab report, supplier letter). Empty when the source is BRAND_SELF_DECLARED and no evidence exists.

evidence_note
string
default:""

Free-text notes about the evidence. Empty when not provided.

Response

Created

A claim assigned to a specific product.

Mirrors :class:apps.certifications.models.ClaimAssignment. Most fields proxy through to the linked :class:Claim record; source, valid_from, expiration_date, and metadata carry the per-instance state.

Like :class:CertificationAssignmentOut, id and id are the claim's identifiers (not the assignment's), so callers can deep-link to the claim record.

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}$
label
string
required

Display name of the underlying claim (e.g. Non-GMO).

Maximum string length: 100
code
string
required

Stable code of the underlying claim (e.g. NON_GMO).

Maximum string length: 50
category
enum<string>
required

Category of the underlying claim. See :class:ClaimCategoryEnum for the full set of values.

Available options:
DIETARY,
INGREDIENT_ABSENCE,
ALLERGEN_FREE,
PROCESS,
SUSTAINABILITY,
OTHER
source
enum<string>
required

How the claim is asserted. BRAND_SELF_DECLARED means the brand states the claim without third-party verification; THIRD_PARTY_VERIFIED means an independent body has verified it.

Available options:
BRAND_SELF_DECLARED,
THIRD_PARTY_VERIFIED
metadata
Metadata · object

Developer-attached key/value data attached to this object. Up to 50 keys; key max 40 chars, value max 500 chars.

valid_from
string<date> | null

Start of validity for this claim (ISO 8601). null when no start date was recorded — treat as 'valid since unknown date'.

expiration_date
string<date> | null

End of validity for this claim (ISO 8601). null for claims with no scheduled expiry.