Read the published stock structure of an article
All field references · Articles
GET /v1/articles/{id}/stock-structure
The current or an explicitly chosen immutable version. null means no publication is available. Component factors and condition rules belong to this version; they are not stock of their own.
Required scopes: "products:read".
#Parameters
#path: id
Required. Your own commercial article.
| Field | Type | Presence | null | Meaning, limits and examples |
|---|---|---|---|---|
| $ (whole value) | string | Whole value | Not allowed | format: "uuid". |
#query: variant_id
Optional. Your own variant; if omitted, the main article applies.
| Field | Type | Presence | null | Meaning, limits and examples |
|---|---|---|---|---|
| $ (whole value) | string | Whole value | Not allowed | format: "uuid". |
#query: definition_id
Optional. Optional historical definition of your own.
| Field | Type | Presence | null | Meaning, limits and examples |
|---|---|---|---|---|
| $ (whole value) | string | Whole value | Not allowed | format: "uuid". |
#Request body
No request body is defined for this operation.
#Response 200
200: Success
Content type: application/json
| Field | Type | Presence | null | Meaning, limits and examples |
|---|---|---|---|---|
| $ (whole value) | object | Whole value | Not allowed | Additional properties are not allowed. |
| data | alternative (anyOf) | Required when parent is present | Allowed by schema | Authorized response payload or documented event data. |
| data | object | Conditional: anyOf 1/2 | Not allowed | anyOf 1/2: At least one alternative must match. Authorized response payload or documented event data. Additional properties are not allowed. |
| data.product_id | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Meykt article ID; not SKU/external ID. format: "uuid". |
| data.variant_id | alternative (anyOf) | Required when parent is present | Allowed by schema | anyOf 1/2: At least one alternative must match. Native Meykt variant ID; null = main article where allowed. |
| data.variant_id | string | Conditional: anyOf 1/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Native Meykt variant ID; null = main article where allowed. format: "uuid". |
| data.variant_id | null | Conditional: anyOf 2/2 | Allowed by schema | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Native Meykt variant ID; null = main article where allowed. |
| data.stock_product_id | alternative (anyOf) | Required when parent is present | Allowed by schema | anyOf 1/2: At least one alternative must match. Physical stock article of this product/variant. |
| data.stock_product_id | string | Conditional: anyOf 1/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Physical stock article of this product/variant. format: "uuid". |
| data.stock_product_id | null | Conditional: anyOf 2/2 | Allowed by schema | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Physical stock article of this product/variant. |
| data.variant_revision | alternative (anyOf) | Required when parent is present | Allowed by schema | anyOf 1/2: At least one alternative must match. Current revision of the variant binding; retain it when changing that binding. |
| data.variant_revision | string | Conditional: anyOf 1/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Current revision of the variant binding; retain it when changing that binding. format: "date-time". |
| data.variant_revision | null | Conditional: anyOf 2/2 | Allowed by schema | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Current revision of the variant binding; retain it when changing that binding. |
| data.definition_id | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Identifier of the published warehouse manufacturing definition. format: "uuid". |
| data.structure_version_id | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Exact saved recipe version whose warehouse behavior is being configured. format: "uuid". |
| data.revision | integer | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Revision token; reuse unchanged for the next change. exclusiveMinimum: 0. |
| data.mode | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Mode; follow its required fields. enum: ["virtual_set","physical_kit","production_bom"]. |
| data.output_condition_policy | alternative (anyOf) | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Condition policy for finished goods from this warehouse definition. |
| data.output_condition_policy | object | Conditional: anyOf 1/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Applies to kind = "certified_released". Condition policy for finished goods from this warehouse definition. Additional properties are not allowed. |
| data.output_condition_policy.kind | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Applies to kind = "certified_released". Kind selects required fields. const: "certified_released". |
| data.output_condition_policy | object | Conditional: anyOf 2/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". Condition policy for finished goods from this warehouse definition. Additional properties are not allowed. |
| data.output_condition_policy.kind | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". Kind selects required fields. const: "selected". |
| data.output_condition_policy.condition_refs | array | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". Distinct immutable condition references selected from the current catalog. minItems: 1. maxItems: 100. |
| data.output_condition_policy.condition_refs[] | string | Every array item | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". format: "uuid". |
| data.created_at | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Created at, with time-zone offset. format: "date-time". |
| data.components | array | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Component quantities/choices for this set, manufacturing or dispatch line. minItems: 1. maxItems: 100. |
| data.components[] | object | Every array item | Not allowed | anyOf 1/2: At least one alternative must match. Additional properties are not allowed. |
| data.components[].id | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Stable entry identifier. format: "uuid". |
| data.components[].slot_id | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Stable component slot ID from the selected structure. format: "uuid". |
| data.components[].product_id | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Meykt article ID; not SKU/external ID. format: "uuid". |
| data.components[].variant_id | alternative (anyOf) | Required when parent is present | Allowed by schema | anyOf 1/2: At least one alternative must match. Native Meykt variant ID; null = main article where allowed. |
| data.components[].variant_id | string | Conditional: anyOf 1/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Native Meykt variant ID; null = main article where allowed. format: "uuid". |
| data.components[].variant_id | null | Conditional: anyOf 2/2 | Allowed by schema | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Native Meykt variant ID; null = main article where allowed. |
| data.components[].stock_product_id | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Physical stock article of this product/variant. format: "uuid". |
| data.components[].unit | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Exact offered unit; no implicit carton, weight or dimension conversion. const: "piece". |
| data.components[].quantity_per_parent | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Component quantity per parent item, in the component’s unit. pattern: "^[1-9]\\d{0,8}$". |
| data.components[].condition_policy | alternative (anyOf) | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match. Policy selecting which stock conditions are eligible for this component. |
| data.components[].condition_policy | object | Conditional: anyOf 1/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Applies to kind = "certified_released". Policy selecting which stock conditions are eligible for this component. Additional properties are not allowed. |
| data.components[].condition_policy.kind | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 1/2: At least one alternative must match. Applies to kind = "certified_released". Kind selects required fields. const: "certified_released". |
| data.components[].condition_policy | object | Conditional: anyOf 2/2 | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". Policy selecting which stock conditions are eligible for this component. Additional properties are not allowed. |
| data.components[].condition_policy.kind | string | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". Kind selects required fields. const: "selected". |
| data.components[].condition_policy.condition_refs | array | Required when parent is present | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". Distinct immutable condition references selected from the current catalog. minItems: 1. maxItems: 100. |
| data.components[].condition_policy.condition_refs[] | string | Every array item | Not allowed | anyOf 1/2: At least one alternative must match.; anyOf 2/2: At least one alternative must match. Applies to kind = "selected". format: "uuid". |
| data | null | Conditional: anyOf 2/2 | Allowed by schema | anyOf 2/2: At least one alternative must match. Authorized response payload or documented event data. |
#Response 401, 403, 404, 422, 429, 500, 503
401: The key is missing, unknown, revoked or expired. 403: The key lacks a required scope, or the operation requires a live key. 404: Not found. Also applies to IDs that belong to another organization — we deliberately do not distinguish between "does not exist" and "does not belong to you". 422: Content validation failed. The response lists all affected locations at once. 429: A rate limit was reached and the request did not run. Wait for Retry-After, then repeat it unchanged. X-RateLimit-Scope names the limit: key (120 requests per minute), organization (300 per minute across all keys), write (1,000 at once, refilling at 60 per minute) or list (300 unfiltered list pages at once, refilling at 10 per minute). 500: Unexpected error on our side. 503: Temporarily unavailable. Repeat the same request with the same business identity.
Content type: application/json
| Field | Type | Presence | null | Meaning, limits and examples |
|---|---|---|---|---|
| $ (whole value) | object | Whole value | Not allowed | — |
| error | object | Required when parent is present | Not allowed | Machine-readable error code; use it to select the documented recovery path. |
| error.code | string | Required when parent is present | Not allowed | Machine-readable, permanently stable error code. Program against it, not against message. |
| error.message | string | Required when parent is present | Not allowed | Explanation for humans. May change at any time. |
| error.field | string | Optional | Not allowed | Affected location in the request, if it can be determined. |
| error.doc_url | string | Required when parent is present | Not allowed | Documentation link explaining this API error. format: "uri". |
Machine-readable version of this page: https://www.meykt.com/developers/fields-read-stock-structure.md