GENERAL INFORMATION
Purpose
Use this endpoint to create or update the locations assigned to each style.
How the data is used
Assigned style locations describe which locations carry a style and whether that style is in assortment at those locations. WAIR processes this dataset asynchronously and can use it in location-specific merchandising and replenishment workflows.
Best practices
- Match
styleIdto the style identifiers supplied throughPOST /Items. - Match every
locationIdto an identifier supplied throughPOST /Locations. - Use
fullLoad=trueonly when sending the complete dataset. - For a multi-request full load, keep
moreRecordsAvailable=trueuntil the final request and set it tofalseon the final request. - Include each style and location combination only once per request.
Common pitfalls
- Repeating a location under the same style. Duplicate combinations are rejected.
- Using location codes when your Locations integration uses different location identifiers.
- Marking an incomplete dataset as the final full-load request.
- Sending an empty
assignedStyleLocationsarray. No import is queued for an empty array.
TECHNICAL INFORMATION
Authentication
Bearer token, information on page POST /Token
Headers
| Name | Description | Example |
|---|---|---|
| X-Tenant | Tenant code supplied by WAIR | TENANT |
Query parameters
| Name | Description | Example |
|---|---|---|
| fullLoad | Optional. Defaults to false. Set to true when the requests form a complete replacement dataset. |
false |
| moreRecordsAvailable | Optional. Defaults to true. For a multi-request full load, set to false on the final request. |
true |
For more information, see Integration core principles.
Body example
{
"assignedStyleLocations": [
{
"styleId": "STYLE-001-BLUE",
"locationIds": [
"STORE-014",
"STORE-027"
],
"inAssortment": true
},
{
"styleId": "STYLE-001-BLACK",
"locationIds": [
"STORE-014"
],
"inAssortment": false
}
]
}
Field information
| Field | Context | Mandatory | Type / accepted value |
|---|---|---|---|
| assignedStyleLocations | Style assignments to process. | Yes | array |
| styleId | Identifier of the style. | Yes | string |
| locationIds | Identifiers of the locations assigned to the style. | Yes | array of strings |
| inAssortment | Indicates whether the style is in assortment at the listed locations. Defaults to false when omitted. |
No | boolean |
RESPONSE
Status codes
200 OK— The request was accepted for asynchronous import processing.400 Bad Request— The request body contains duplicate style and location combinations or otherwise fails validation.401 Unauthorized— The bearer token is missing, expired, or invalid.500 Internal Server Error— An unexpected error occurred while accepting the request.
Body example
No response body.