IDs and Keys
LCE resources can expose system identifiers and business identifiers. Use the identifier explicitly supported by an operation, preserve its type and keep it within the correct tenant and environment context.
Identifier types
System ID
Many entity identifiers, such as productId, orderId and languageId, are represented as 32-bit integers in the current schemas.
Business identifier
Some resources also expose codes, keys, SKUs or reference numbers used by external systems and business workflows.
Context identifier
Tenant, application, user and session identifiers establish the context in which a request is evaluated.
Choose the identifier supported by the endpoint
| Identifier | Use it when | Avoid |
|---|---|---|
resourceId | The service returned the ID and the operation accepts that field. | Deriving IDs, reusing an ID from another environment or treating an ID as globally unique. |
code or key | The resource has a stable business identifier and the operation provides a matching field. | Assuming every endpoint supports lookup by code or key. |
sku | The Inventory or catalog operation explicitly accepts an SKU value. | Using product or variant display names as an SKU substitute. |
tenantId | The request model requires tenant context. | Copying a production tenant ID into a non-production request. |
threadId | You need the request tracking field supported by the model. | Treating it as a resource ID or an idempotency key. |
Filter by IDs or codes
Query models commonly use plural arrays when several identifiers can be supplied:
{
"tenantId": 1,
"productIds": [1201, 1202],
"codes": ["SKU-GROUP-001", "SKU-GROUP-002"],
"pageIndex": 0,
"pageSize": 20
}
Use only the fields defined by the chosen query schema. If both ID and code filters are supplied, do not assume how they are combined unless the endpoint documentation defines that behavior.
Integration practices
- Store service-returned IDs rather than reconstructing them.
- Preserve the original string form and casing of codes, keys and SKUs.
- Do not use localized names or labels as persistent identifiers.
- Keep environment-specific identifier mappings separate.
- Validate identifier type before sending a request; do not send an empty string where an integer is expected.
- For cross-system mapping, retain both the LCE ID and the external system reference.