commercetools / commercetools/commercetools-api-reference
Format of InventoryEntryCreated message doesn't match the spec
- Dominant language
- RAML
- Stars
- 66
- Forks
- 33
- PR merge metrics
- No merged PRs in 30d
Description
According the the spec and [docs](https://docs.commercetools.com/api/projects/messages#inventoryentry-created) the `inventoryEntry` field of the `InventoryEntryCreated` message should contain an [InventoryEntry](https://docs.commercetools.com/api/projects/inventory#inventoryentry).
The messages API instead returns the following structure (didn't check the format in subscriptions yet):
```json
{
"id": "00000000-0000-0000-0000-000000000000",
"version": 1,
"versionModifiedAt": "2022-11-17T13:59:00.080Z",
"sequenceNumber": 1,
"resource": {
"typeId": "inventory-entry",
"id": "11111111-1111-1111-1111-111111111111"
},
"resourceVersion": 1,
"resourceUserProvidedIdentifiers": {
"sku": "my-sku"
},
"type": "InventoryEntryCreated",
"inventoryEntry": {
"type": "InventoryEntryCreated",
"inventoryEntryId": "11111111-1111-1111-1111-111111111111",
"sku": "my-sku",
"supplyChannel": {
"typeId": "channel",
"id": "22222222-2222-2222-2222-222222222222"
},
"quantityOnStock": 123,
"restockableInDays": 2,
"messageId": {
"id": "00000000-0000-0000-0000-000000000000",
"sequenceNumber": 1
}
},
"createdAt": "2022-11-17T13:59:00.080Z",
"lastModifiedAt": "2022-11-17T13:59:00.080Z",
"lastModifiedBy": {
"isPlatformClient": false,
"clientId": "client-id"
},
"createdBy": {
"isPlatformClient": false,
"clientId": "client-id"
}
}
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.