API Guides

Ready-to-use client libraries for popular programming languages.

API Center Menu

Assign Item to Inventory (from an Order)

Request Type: 

POST

API Endpoint:

<url>/api/orders/:order_id/line_items/:line_item_id/assign_to_inventory 

Mandatory Headers Properties:

  • Authorization (type: string): the valid access token from the authentication.ย 

Mandatory Query parameters:

  • order_id (type: string): The order number that contains the item to be moved to the inventory.
  • line_item_id (type: string): The line item that will get moved from the Order into the Inventory.

Optional Parameter:

You can pass the item condition when moved from the Order into the inventory. 

Item Conditions:

BOXED: 1

OPEN: 2

USED: 3

DEFECTIVE: 4

REPACK: 5

Sample Request:

{

    "options": {

       "condition": 3

    }

}

Response:

The created Inventory item including location and tracking information. 

{

    "status": "ok",

    "data": [

        {

            "damage_report": {

                "geolocation": {

                    "coords": {},

                    "timestamp": "2021-03-08T12:38:01.139Z"

                }

            },

            "freight_info": {

                "vendor_info": {

                    "address": {

                        "address1": "78 Canal St",

                        "address2": "",

                        "city": "New York",

                        "state": "NY",

                        "zip": "10023"

                    },

                    "first_name": null,

                    "last_name": null,

                    "phone": "888-756-3940",

                    "email": "adouglas@testing.com",

                    "receiving_hours": null,

                    "vendor_id": "59b6b08157bf22ae15611e35",

                    "location_id": "59b6b08157bf22ae15611e36",

                    "send_labels": true,

                    "company": "adouglas"

                },

                "is_fob": true,

                "consolidation_stop": null,

                "total_cost": 0,

                "weight": 0,

                "trip_id": null,

                "fsc": 0,

                "pro_number": null,

                "ack": null,

                "verified": false,

                "validations": [],

                "paid": false,

                "paid_date": null,

                "rate_type": null,

                "rate": 0,

                "is_minimum": false,

                "scheduled_pickup_date": null,

                "manifest_id": null,

                "carrier_pickup_status": 0

            },

            "packaging": {

                "required": null,

                "type": null

            },

            "weight": 11,

            "cube": 11,

            "retail_value": 11,

            "status": 4,

            "packages": 1,

            "quantity": 1,

            "vendor": "adouglas",

            "vendor_id": "59b6b08157bf22ae15611e35",

            "in_warehouse": "58d1e4582bdebd0f0025de72",

            "properties": [],

            "ref_order_number": null,

            "serial_number": null,

            "require_pre_inspection": false,

            "failure_details": {

                "reason_id": null,

                "reason_description": null

            },

            "has_free_storage": false,

            "commodity_type": 0,

            "insurance_coverage": 0,

            "dimensions": null,

            "locations": [

                {

                    "geolocation": {

                        "coords": {},

                        "timestamp": "2021-03-08T16:33:01.959Z"

                    },

                    "region_id": null,

                    "location_id": "5fd0f0f4a5cf51c7b025fe16",

                    "is_actual": true,

                    "date": "2021-03-08T16:33:01.959Z",

                    "_id": "604651bd8cd2ed8396fbdea5",

                    "user": "531114ba4231c0d02f3a2163"

                },

      

            ]

            },

            "tracking": [

                {

                    "geolocation": {

                        "coords": {},

                        "timestamp": "2021-03-08T12:39:17.645Z"

                    },

                    "event_type_id": 163,

                    "reference_record": null,

                    "date": "2021-03-08T12:39:17.645Z",

                    "_id": "60461af531c937d47e678606",

                    "description": "Inventory item created item id: I3908",

                    "user": "531114ba4231c0d02f3a2163"

                },

                {

                    "geolocation": {

                        "coords": {},

                        "timestamp": "2021-03-08T16:33:01.949Z"

                    },

                    "event_type_id": 5,

                    "reference_record": null,

                    "date": "2021-03-08T16:33:01.949Z",

                    "_id": "604651bd8cd2ed8396fbdea4",

                    "description": "item received",

                    "user": "531114ba4231c0d02f3a2163"

                },

            ],

            "resource_url": [],

            "sku": "TEST456",

            "name": "TEST456",

            "item_id": "I3908",

            "order_id": "22200019620",

            "category": null,

            "designated_region": "54d1005de00b63c74dc428f0",

            "source_app_id": "haim-local",

            "retailer_id": "58c889b67dcce40f000f08a1",

            "created_at": "2021-03-25T11:41:11.159Z",

            "received_at": "2021-03-25T11:41:11.159Z",

            "condition": 3

        }

    ]

}