# Calculate the complete virtual sets that are actually available

[All field references](/en/developers/field-reference) · [Articles](/en/developers/fields-group-articles)

`GET /v1/articles/{id}/stock-structure/availability`

One operator and one warehouse, exact free quantities under the published condition rules. Reused SKUs and overlapping rules share the same real quantity. available_sets is point-in-time information, not a reservation and not a simultaneous commitment for several sets.

Required scopes: `"products:read"`, `"inventory:read"`, `"conditions:read"`.

[How to read these tables](/en/developers/field-reference#reading-the-field-tables)

## 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: operator_ref

Required. Authorized operator reference from options.

| Field | Type | Presence | null | Meaning, limits and examples |
| --- | --- | --- | --- | --- |
| $ (whole value) | string | Whole value | Not allowed | format: `"uuid"`. |

### query: warehouse_ref

Required. Warehouse reference of the same operator from options.

| 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 | object | Required when parent is present | Not allowed | Authorized response payload or documented event data. Additional properties are not allowed. |
| data.product_id | string | Required when parent is present | Not allowed | Meykt article ID; not SKU/external ID. format: `"uuid"`. |
| data.variant_id | alternative (anyOf) | Required when parent is present | Allowed by schema | 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. Native Meykt variant ID; null = main article where allowed. format: `"uuid"`. |
| data.variant_id | null | Conditional: anyOf 2/2 | Allowed by schema | anyOf 2/2: At least one alternative must match. Native Meykt variant ID; null = main article where allowed. |
| data.definition_id | string | Required when parent is present | Not allowed | Identifier of the published warehouse manufacturing definition. format: `"uuid"`. |
| data.revision | integer | Required when parent is present | Not allowed | Revision token; reuse unchanged for the next change. exclusiveMinimum: `0`. |
| data.operator_ref | string | Required when parent is present | Not allowed | Opaque reference to the authorized warehouse operator, from the offered options. format: `"uuid"`. |
| data.warehouse_ref | string | Required when parent is present | Not allowed | Opaque warehouse reference associated with the selected operator. format: `"uuid"`. |
| data.observed_at | string | Required when parent is present | Not allowed | Observed at, with time-zone offset. format: `"date-time"`. |
| data.available_sets | string | Required when parent is present | Not allowed | Number of complete sets currently available from all required eligible components. maxLength: `40`. pattern: `"^(0\|[1-9]\\d*)$"`. |
| data.components | array | Required when parent is present | Not allowed | Component quantities/choices for this set, manufacturing or dispatch line. minItems: `1`. maxItems: `100`. |
| data.components[] | object | Every array item | Not allowed | Additional properties are not allowed. |
| data.components[].slot_id | string | Required when parent is present | Not allowed | Stable component slot ID from the selected structure. format: `"uuid"`. |
| data.components[].stock_product_id | string | Required when parent is present | Not allowed | Physical stock article of this product/variant. format: `"uuid"`. |
| data.components[].quantity_per_parent | string | Required when parent is present | Not allowed | Component quantity per parent item, in the component’s unit. pattern: `"^[1-9]\\d{0,8}$"`. |
| data.components[].eligible_free | string | Required when parent is present | Not allowed | Unreserved component quantity that satisfies the configured condition policy. maxLength: `40`. pattern: `"^(0\|[1-9]\\d*)(\\.\\d{1,6})?$"`. |

## Response 401, 403, 404, 409, 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". 409: The same ID already exists with different content. It is never overwritten. 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"`. |
