GET
/
allocations
/
{allocationId}
curl --request GET \
  --url https://api.fabric.inc/v3/allocations/{allocationId} \
  --header 'Authorization: Bearer <token>' \
  --header 'x-fabric-channel-id: <x-fabric-channel-id>' \
  --header 'x-fabric-tenant-id: <x-fabric-tenant-id>'
{
  "allocationId": "62ff5c0bec0aed3c86202c32",
  "version": 2,
  "allocationRequestId": "62ff5c0bec0aed3c86202c32",
  "parentAllocationId": "62ff5c0bec0aed3c86202c32",
  "notifiedToPPSAt": "2022-08-01T18:03:28.483971941Z",
  "createdAt": "2022-08-01T18:03:28.483971941Z",
  "updatedAt": "2022-08-01T20:03:28.483971941Z",
  "currency": "USD",
  "type": "ALLOCATED",
  "previousAllocatedLocationNums": [
    "410"
  ],
  "itemsType": "WEB_SHIP",
  "orderSubType": "ANDROID",
  "shippedAt": "2022-08-01T20:03:28.483971941Z",
  "shipmentType": "SHIP_TO_ADDRESS",
  "shipmentMethod": "Parcel Post Delivery",
  "shipToId": "98ff5c0bec0aed3c86202c32",
  "statusCode": "ALLOCATED",
  "allocationNumber": 13000004,
  "locationNumber": "1234B",
  "locationType": "DC",
  "shipToAddress": {
    "name": {
      "firstName": "Alex",
      "middleName": "E",
      "lastName": "Doe"
    },
    "email": "test@example.com",
    "phone": {
      "number": "123-456-7890",
      "type": "MOBILE"
    },
    "addressLine1": "123 Main St.",
    "addressLine2": "Suite 100",
    "addressLine3": "Seventh floor",
    "addressLine4": "Attention: Pat E. Kake",
    "city": "Seattle",
    "region": "WA",
    "postalCode": "98121",
    "countryCode": "US",
    "type": "Home",
    "latitude": 47.6205,
    "longitude": -122.3493
  },
  "recipients": [
    {
      "name": {
        "firstName": "Alex",
        "middleName": "E",
        "lastName": "Doe"
      },
      "email": "test@example.com",
      "phone": {
        "number": "123-456-7890",
        "type": "MOBILE"
      },
      "pickupType": "PRIMARY"
    }
  ],
  "items": [
    {
      "orderLineId": "134fqfaa532qrf",
      "itemId": 100064,
      "sku": "123k4h123k",
      "orderId": "62f3982438bcab1951be0a19",
      "orderNumber": "123k4h123k",
      "orderedAt": "2022-08-01T18:03:28.483971941Z",
      "estimatedDeliveryDate": "2022-08-01T18:03:28.483971941Z",
      "quantity": 3,
      "allocationLineNumber": 3,
      "parentAllocationLineNumber": 3,
      "reallocationRequestId": "123k4h123k",
      "uom": "EA",
      "shippedQuantity": 1,
      "scratchQuantity": 1,
      "scratchedReasonCode": "Out of stock",
      "reshipReasonCode": "Stock refilled",
      "reallocationReasonCode": "Reallocating due to unavailability of location number",
      "channelId": "4a35cc1b-4e15-46df-96c9-38a697d88dfe",
      "weight": 5.5,
      "cost": 150.6,
      "price": 50.2,
      "itemStatus": "PARTIALLY_ALLOCATED"
    }
  ],
  "auditLogs": [
    {
      "lineItemId": "b03b72dc-78d8-4ea4-90fc-2fe6a1fe6569",
      "auditId": "a05b72dc-78d8-4ea4-90fc-2fe6a1fe1111",
      "auditType": "CANCEL",
      "employeeId": "6227",
      "auditedAt": "2023-03-12T09:24:54.804Z",
      "source": "POS",
      "reasonCode": "Scratched item",
      "subReasonCode": "Scratched item",
      "policyCode": "POS",
      "note": "Note",
      "lineItemNumber": 1,
      "sku": "SKU0023",
      "quantity": 1,
      "amount": 2.4,
      "paymentToken": {
        "token": "pi_34tr6787rt",
        "paymentType": "VISA"
      },
      "updatedFields": [
        {
          "fieldName": "UOM",
          "fieldOriginalValue": "PK"
        }
      ],
      "isSuccess": true,
      "attributes": {
        "key": "value"
      }
    }
  ]
}

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

x-fabric-tenant-id
string
required

Merchant's 24-character tenant ID

x-fabric-channel-id
string
required

Sales channel ID

x-fabric-request-id
string

Unique request ID

Path Parameters

allocationId
string
required

24-character system-generated allocation ID

Response

200 - application/json
allocationId
string
required

24-character system-generated allocation ID

version
integer
required

Allocation document version. The version number is incremented each time the allocation document undergoes an update. Update to an allocation document happens automatically when the status changes from one state to another based on the statusCode.

allocationRequestId
string
required

Merchant-specified unique ID. If omitted, this is generated by fabric’s sequence generator using Configuration service.

parentAllocationId
string

Allocation ID that is generated while creating the allocation for the first time. Initially this will be the same as allocationRequestId. If there is a reallocation, the parentAllocationId will be assigned the same value as the initial allocationRequestId, and will serve as a means of monitoring all subsequent child allocations.

notifiedToPPSAt
string

fabric system-generated time when allocation service sent event notification to package tracking service.

createdAt
string
required

System-generated time of allocation record creation

updatedAt
string

System-generated time when allocation record was last modified

currency
string

Currency

type
enum<string>

Allocation type<br />ALLOCATED: Order is allocated for fulfillment<br />SCRATCHED: Order is canceled during allocation due to unavailability of inventory<br />RETURNED: Allocation created for the return items

Available options:
ALLOCATED,
SCRATCHED,
RETURNED
previousAllocatedLocationNums
string[]

In case of reallocation, it keeps track of previously allocated location numbers.

itemsType
string

This is an inherited attribute from Orders that pertains to item types such as WEB_SHIP, WEB_PICKUP, WEB_SDD INTERNATIONAL, POS, POS_SHIP, and POS_PICKUP.

orderSubType
string

During allocation creation, this attribute is inherited from fabric Orders and includes subtypes such as IOS, ANDROID, INTERNATIONAL, among others.

shippedAt
string

Time of order shipment, generated by allocation service when shipment service calls allocation after shipment is created.

shipmentType
string

This attribute is inherited from order.shipInfo during allocation creation.<br />Acceptable value: SHIP_TO_ADDRESS, CUSTOMER_PICKUP, PICKUP, SDD, SHIP_TO_STORE

shipmentMethod
string

Shipping method. This attribute is inherited from order.shipInfo during allocation creation.

shipToId
string

System-generated UUID associated with shipInfo, generated from CnC service. Note: An order can have multiple ship-to (delivery) locations and items going to the same location have one shipToId.

statusCode
enum<string>

Allocation status

Available options:
ALLOCATED,
PENDING_DROP,
PENDING_PICK,
SHIPPED,
PARTIALLY_SHIPPED,
REALLOCATED,
CANCELLED,
PARTIALLY_CANCELLED
allocationNumber
integer

Merchant-specified unique number assigned to each allocation. If omitted, is this generated by fabric’s sequence generator using Configuration service

locationNumber
string
required

Inventory location number to identify ship-from location or Buy Online Pickup from Store (BOPIS) location. This must be the locationNumber stored in the fabric Location service.

locationType
string

Inventory location type such as, DC or Store from where the order is picked up

shipToAddress
object

Address details

recipients
object[]

Recipient details like name, email address, and phone number

items
object[]

List of items to be shipped

auditLogs
object[]

Change history details