{"openapi":"3.1.1","info":{"title":"Cognis Public API — Collections and landing slugs","version":"1.0.0","description":"Collection CRUD, collection images/products, product landing slugs (PDP URLs). Authenticate with `Authorization: Bearer cogn_…`. Base: https://api.cognissuite.com/api/v1. Max 30 operations for ChatGPT Custom GPT Actions."},"servers":[{"url":"https://api.cognissuite.com/api/v1","description":"Production"},{"url":"http://localhost:3013/api/v1","description":"Local"}],"tags":[{"name":"Commerce Collections","description":"Commerce Collections API"},{"name":"Product","description":"Product API"}],"paths":{"/org/{orgId}/ecom/collections/{collectionId}":{"delete":{"operationId":"delete","summary":"Delete","description":"Public API endpoint: ecomCollection.delete\n\n**Required scopes:** `org:ecom:collections:delete`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:delete"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"ok":true},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}},"get":{"operationId":"getById","summary":"Get By Id","description":"Public API endpoint: ecomCollection.getById\n\n**Required scopes:** `org:ecom:collections:read`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:read"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"id":"ecoll-1","orgId":"1","parentId":null,"name":"Spring","slug":"spring","shortDescription":"Spring season collection","llmDetails":"Use for seasonal merchandising cues.","brandIds":[],"createdBy":null,"createdAt":"2025-01-01T19:42:28.687Z","updatedAt":"2025-01-02T10:15:00.000Z"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}},"patch":{"operationId":"patch","summary":"Patch","description":"Public API endpoint: ecomCollection.patch\n\n**Required scopes:** `org:ecom:collections:write`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"id":"ecoll-1","orgId":"1","parentId":null,"name":"Spring","slug":"spring","shortDescription":"Spring season collection","llmDetails":"Use for seasonal merchandising cues.","brandIds":[],"createdBy":null,"createdAt":"2025-01-01T19:42:28.687Z","updatedAt":"2025-01-02T10:15:00.000Z"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":255},"parentId":{"type":"string","nullable":true},"slug":{"anyOf":[{"type":"string","maxLength":255,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$"},{"enum":["null"],"nullable":true}]},"shortDescription":{"type":"string","nullable":true},"llmDetails":{"type":"string","nullable":true},"brandIds":{"type":"array","items":{"type":"string"}}},"additionalProperties":false}}}}}},"/org/{orgId}/ecom/collections/{collectionId}/images/{imageId}":{"delete":{"operationId":"deleteImage","summary":"Delete Image","description":"Public API endpoint: ecomCollection.deleteImage\n\n**Required scopes:** `org:ecom:collections:write`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}},{"name":"imageId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"ok":true},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}},"patch":{"operationId":"patchImage","summary":"Patch Image","description":"Public API endpoint: ecomCollection.patchImage\n\n**Required scopes:** `org:ecom:collections:write`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}},{"name":"imageId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"id":"eci-1","collectionId":"ecoll-1","fileUploadId":"fu-1","brandId":null,"lang":null,"sortOrder":0,"filename":"hero.jpg","contentType":"image/jpeg","sizeBytes":12000,"publicCdnUrl":null,"createdAt":"2025-01-01T19:42:28.687Z","updatedAt":"2025-01-01T19:42:28.687Z"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"brandId":{"type":"string","nullable":true},"lang":{"type":"string","enum":["en","sv","no","da","fi","de","it","nl","pl","pt","es","fr"],"nullable":true},"sortOrder":{"type":"integer","minimum":0}},"additionalProperties":false}}}}}},"/org/{orgId}/ecom/collections/{collectionId}/products/{productId}":{"delete":{"operationId":"deleteProduct","summary":"Delete Product","description":"Public API endpoint: ecomCollection.deleteProduct\n\n**Required scopes:** `org:ecom:collections:write`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}},{"name":"productId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"ok":true},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}}},"/org/{orgId}/ecom/collections":{"get":{"operationId":"list","summary":"List","description":"Public API endpoint: ecomCollection.list\n\n**Required scopes:** `org:ecom:collections:read`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:read"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":10}},{"name":"search","in":"query","required":false,"schema":{"type":"string"}},{"name":"fromDate","in":"query","required":false,"schema":{"type":"string"}},{"name":"toDate","in":"query","required":false,"schema":{"type":"string"}},{"name":"dateBy","in":"query","required":false,"schema":{"type":"string","default":"createdAt"}},{"name":"sort","in":"query","required":false,"schema":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","enum":["id","orgId","parentId","name","slug","shortDescription","llmDetails","createdAt","updatedAt"]},"order":{"type":"string","enum":["asc","desc"],"default":"desc"}},"required":["field"],"additionalProperties":false},"default":[{"field":"id","order":"desc"}]}},{"name":"fields","in":"query","required":false,"schema":{"type":"array","items":{"type":"string","enum":["id","orgId","parentId","name","slug","shortDescription","llmDetails","brandIds","createdBy","createdAt","updatedAt"]},"default":["id"]}},{"name":"filters","in":"query","required":false,"schema":{"type":"object","properties":{"type":{"type":"string","enum":["group"]},"op":{"type":"string","enum":["and","or"]},"children":{"type":"array","items":{"anyOf":[{},{"type":"object","properties":{"type":{"type":"string","enum":["rule"]},"field":{"type":"string","enum":["id","orgId","parentId","name","slug","shortDescription","llmDetails","brandIds","createdBy","createdAt","updatedAt"]},"operator":{"type":"string","enum":["eq","neq","in","not_in","is_set","is_not_set","gt","gte","lt","lte","between","contains","not_contains","starts_with","ends_with"]},"value":{}},"required":["type","field","operator"],"additionalProperties":false}]},"minItems":1}},"required":["type","op","children"],"additionalProperties":false}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"array","items":{"type":"object"}},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":[{"id":"ecoll-1","orgId":"1","parentId":null,"name":"Spring","slug":"spring","shortDescription":"Spring season collection","llmDetails":"Use for seasonal merchandising cues.","brandIds":[],"createdBy":null,"createdAt":"2025-01-01T19:42:28.687Z","updatedAt":"2025-01-02T10:15:00.000Z"}],"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}},"post":{"operationId":"create","summary":"Create","description":"Public API endpoint: ecomCollection.create\n\n**Required scopes:** `org:ecom:collections:create`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:create"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"id":"ecoll-1","orgId":"1","parentId":null,"name":"Spring","slug":"spring","shortDescription":"Spring season collection","llmDetails":"Use for seasonal merchandising cues.","brandIds":[],"createdBy":null,"createdAt":"2025-01-01T19:42:28.687Z","updatedAt":"2025-01-02T10:15:00.000Z"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":255},"parentId":{"type":"string","nullable":true},"slug":{"anyOf":[{"type":"string","maxLength":255,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$"},{"enum":["null"],"nullable":true}]},"shortDescription":{"type":"string","nullable":true},"llmDetails":{"type":"string","nullable":true},"brandIds":{"type":"array","items":{"type":"string"}}},"required":["name"],"additionalProperties":false}}}}}},"/org/{orgId}/ecom/collections/{collectionId}/images":{"get":{"operationId":"listImages","summary":"List Images","description":"Public API endpoint: ecomCollection.listImages\n\n**Required scopes:** `org:ecom:collections:read`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:read"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"array","items":{"type":"object"}},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":[{"id":"eci-1","collectionId":"ecoll-1","fileUploadId":"fu-1","brandId":null,"lang":null,"sortOrder":0,"filename":"hero.jpg","contentType":"image/jpeg","sizeBytes":12000,"publicCdnUrl":null,"createdAt":"2025-01-01T19:42:28.687Z","updatedAt":"2025-01-01T19:42:28.687Z"}],"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}},"post":{"operationId":"postImage","summary":"Post Image","description":"Public API endpoint: ecomCollection.postImage\n\n**Required scopes:** `org:ecom:collections:write`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"id":"eci-1","collectionId":"ecoll-1","fileUploadId":"fu-1","brandId":null,"lang":null,"sortOrder":0,"filename":"hero.jpg","contentType":"image/jpeg","sizeBytes":12000,"publicCdnUrl":null,"createdAt":"2025-01-01T19:42:28.687Z","updatedAt":"2025-01-01T19:42:28.687Z"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"fileUploadId":{"type":"string"},"brandId":{"type":"string","nullable":true},"lang":{"type":"string","enum":["en","sv","no","da","fi","de","it","nl","pl","pt","es","fr"],"nullable":true},"sortOrder":{"type":"integer","minimum":0}},"required":["fileUploadId"],"additionalProperties":false}}}}}},"/org/{orgId}/ecom/collections/{collectionId}/products":{"get":{"operationId":"listProducts","summary":"List Products","description":"Public API endpoint: ecomCollection.listProducts\n\n**Required scopes:** `org:ecom:collections:read`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:read"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"array","items":{"type":"object"}},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":[{"collectionId":"ecoll-1","productId":"prod-1","name":"Example product","brandId":"10","brandName":"Acme","sortOrder":0,"createdAt":"2025-01-01T19:42:28.687Z"}],"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}},"post":{"operationId":"postProduct","summary":"Post Product","description":"Public API endpoint: ecomCollection.postProduct\n\n**Required scopes:** `org:ecom:collections:write`","tags":["Commerce Collections"],"x-scopes":["org:ecom:collections:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"orgId","in":"path","required":true,"schema":{"type":"string","description":"Organization ID (prefix: org_)"}},{"name":"collectionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"collectionId":"ecoll-1","productId":"prod-1","name":"Example product","brandId":"10","brandName":"Acme","sortOrder":0,"createdAt":"2025-01-01T19:42:28.687Z"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"productId":{"type":"string","minLength":1}},"required":["productId"],"additionalProperties":false}}}}}},"/products/{productId}":{"get":{"operationId":"getProductById","summary":"Get Product By Id","description":"Get product details by passing the product id\n\n**Required scopes:** `product:read`","tags":["Product"],"x-scopes":["product:read"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"productId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"id":"p_123","name":"Example Product","description":"Example Product Description","slug":"example-product","createdAt":"2026-08-20T08:48:53.949Z","updatedAt":"2026-08-20T08:48:53.949Z","brandId":"b_123","orgId":"o_123","integrationType":"shopify","externalId":"gid://shopify/Product/123","externalHandle":"example-product"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}},"put":{"operationId":"putProductById","summary":"Put Product By Id","description":"Public API endpoint: product.putProductById\n\n**Required scopes:** `product:write`","tags":["Product"],"x-scopes":["product:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"productId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}},"example":{"success":true,"data":{"id":"p_123","name":"Example Product","slug":"example-product","createdAt":"2026-08-20T08:48:53.949Z","updatedAt":"2026-08-20T08:48:53.949Z","brandId":"b_123","orgId":"o_123","integrationType":"shopify","externalId":"gid://shopify/Product/123","externalHandle":"example-product"},"message":"Success","traceId":"req_abc123"}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":255},"slug":{"anyOf":[{"type":"string","maxLength":255,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$"},{"enum":["null"],"nullable":true}]}},"additionalProperties":false}}}}}},"/products/{productId}/landing-slugs":{"post":{"operationId":"addProductLandingSlug","summary":"Add Product Landing Slug","description":"Public API endpoint: product.addProductLandingSlug\n\n**Required scopes:** `product:write`","tags":["Product"],"x-scopes":["product:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"productId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"slug":{"type":"string","minLength":1,"maxLength":255,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$"},"setAsPrimary":{"type":"boolean"}},"required":["slug"],"additionalProperties":false}}}}},"get":{"operationId":"listProductLandingSlugs","summary":"List Product Landing Slugs","description":"Public API endpoint: product.listProductLandingSlugs\n\n**Required scopes:** `product:read`","tags":["Product"],"x-scopes":["product:read"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"productId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}}}},"/products/{productId}/landing-slugs/{landingSlugId}/retire":{"post":{"operationId":"retireProductLandingSlug","summary":"Retire Product Landing Slug","description":"Public API endpoint: product.retireProductLandingSlug\n\n**Required scopes:** `product:write`","tags":["Product"],"x-scopes":["product:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"productId","in":"path","required":true,"schema":{"type":"string"}},{"name":"landingSlugId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{},"additionalProperties":false}}}}}},"/products/{productId}/landing-slugs/{landingSlugId}/set-primary":{"post":{"operationId":"setPrimaryProductLandingSlug","summary":"Set Primary Product Landing Slug","description":"Public API endpoint: product.setPrimaryProductLandingSlug\n\n**Required scopes:** `product:write`","tags":["Product"],"x-scopes":["product:write"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"productId","in":"path","required":true,"schema":{"type":"string"}},{"name":"landingSlugId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"type":"boolean","enum":[true]},"data":{"type":"object","additionalProperties":true},"message":{"type":"string"},"traceId":{"type":"string"},"meta":{"type":"object","properties":{"pagination":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"},"totalItems":{"type":"integer"}}}}}}}}}},"400":{"description":"Bad request — validation error or invalid payload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Invalid data","errors":[{"code":400,"message":"Invalid data"}],"traceId":"req_xxx"}}}},"401":{"description":"Unauthorized — invalid or missing API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unauthorized","errors":[{"code":401,"message":"Unauthorized"}],"traceId":"req_xxx"}}}},"403":{"description":"Forbidden — insufficient permissions or api_allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Forbidden","errors":[{"code":403,"message":"Forbidden"}],"traceId":"req_xxx"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Not found","errors":[{"code":404,"message":"Not found"}],"traceId":"req_xxx"}}}},"409":{"description":"Conflict — e.g. unique violation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Conflict","errors":[{"code":409,"message":"Conflict"}],"traceId":"req_xxx"}}}},"422":{"description":"Unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too many requests — rate limited","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Rate limit exceeded","errors":[],"traceId":"req_xxx"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"success":false,"message":"Unexpected error","errors":[{"code":500,"message":"Unexpected error"}],"traceId":"req_xxx"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{},"additionalProperties":false}}}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"API Key","description":"API key (prefix: cogn_) from Account → Developer"}},"schemas":{"ErrorResponse":{"type":"object","required":["success","message","errors"],"properties":{"success":{"type":"boolean","enum":[false]},"message":{"type":"string","description":"Human-readable error message"},"errors":{"type":"array","items":{"type":"object","required":["code","message"],"properties":{"code":{"type":"number","description":"Error code"},"message":{"type":"string"},"details":{"type":"object"}}}},"traceId":{"type":"string","description":"Request ID for tracing"},"params":{"type":"object","description":"Validation params for interpolation"},"readableMessage":{"type":"string","description":"Human-readable validation message"}}}}},"security":[{"bearerAuth":[]}]}