curl --location --request POST 'https://api.stateset.com/api/v1/returns/:id/restock' \
--header 'Content-Type: application/json' \
--header 'Authorization: Token <token>' \
--data-raw '{
"id": "rt_1NXWPnCo6bFb1KQto6C8OWvE",
"warehouse_id": "wh_east_01",
"location_id": "loc_a1_shelf_3",
"condition_code": "new",
"quantity": 1,
"restocking_fee_applied": true
}'
mutation returnRestockMutation {
returnRestock(
id: "${returnId}",
warehouseId: "${warehouseId}",
locationId: "${locationId}",
conditionCode: "${conditionCode}",
quantity: ${quantity},
restockingFeeApplied: ${restockingFeeApplied}
) {
return {
id,
status,
inventory_adjustment_id,
new_inventory_level,
restocked_at
}
userErrors {
field
message
}
}
}
`;
const returns = await stateset.returns.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouse_id: 'wh_east_01',
location_id: 'loc_a1_shelf_3',
condition_code: 'new',
quantity: 1,
restocking_fee_applied: true
});
returns = stateset.returns.restock({
'id': 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
'warehouse_id': 'wh_east_01',
'location_id': 'loc_a1_shelf_3',
'condition_code': 'new',
'quantity': 1,
'restocking_fee_applied': True
})
returns = Stateset::Return.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouse_id: 'wh_east_01',
location_id: 'loc_a1_shelf_3',
condition_code: 'new',
quantity: 1,
restocking_fee_applied: true
})
returns, err := stateset.Returns.restock({
ID: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
WarehouseID: 'wh_east_01',
LocationID: 'loc_a1_shelf_3',
ConditionCode: 'new',
Quantity: 1,
RestockingFeeApplied: true
})
Return returns = stateset.Returns.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouseId: 'wh_east_01',
locationId: 'loc_a1_shelf_3',
conditionCode: 'new',
quantity: 1,
restockingFeeApplied: true
});
$returns = $stateset->returns->restock([
'id' => 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
'warehouse_id' => 'wh_east_01',
'location_id' => 'loc_a1_shelf_3',
'condition_code' => 'new',
'quantity' => 1,
'restocking_fee_applied' => true
]);
var returns = await stateset.Returns.Restock(new {
Id = 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
WarehouseId = 'wh_east_01',
LocationId = 'loc_a1_shelf_3',
ConditionCode = 'new',
Quantity = 1,
RestockingFeeApplied = true
});
{
"id": "rt_1NXWPnCo6bFb1KQto6C8OWvE",
"object": "return",
"restocked": true,
"inventory_adjustment_id": "inv_adj_456",
"new_inventory_level": 150,
"warehouse_id": "wh_east_01",
"location_id": "loc_a1_shelf_3",
"condition_code": "new",
"restocked_at": "2024-01-15T11:00:00Z"
}
Restock Return
This endpoint restocks a returned item back into inventory.
POST
/
api
/
v1
/
returns
/
{id}
/
restock
curl --location --request POST 'https://api.stateset.com/api/v1/returns/:id/restock' \
--header 'Content-Type: application/json' \
--header 'Authorization: Token <token>' \
--data-raw '{
"id": "rt_1NXWPnCo6bFb1KQto6C8OWvE",
"warehouse_id": "wh_east_01",
"location_id": "loc_a1_shelf_3",
"condition_code": "new",
"quantity": 1,
"restocking_fee_applied": true
}'
mutation returnRestockMutation {
returnRestock(
id: "${returnId}",
warehouseId: "${warehouseId}",
locationId: "${locationId}",
conditionCode: "${conditionCode}",
quantity: ${quantity},
restockingFeeApplied: ${restockingFeeApplied}
) {
return {
id,
status,
inventory_adjustment_id,
new_inventory_level,
restocked_at
}
userErrors {
field
message
}
}
}
`;
const returns = await stateset.returns.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouse_id: 'wh_east_01',
location_id: 'loc_a1_shelf_3',
condition_code: 'new',
quantity: 1,
restocking_fee_applied: true
});
returns = stateset.returns.restock({
'id': 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
'warehouse_id': 'wh_east_01',
'location_id': 'loc_a1_shelf_3',
'condition_code': 'new',
'quantity': 1,
'restocking_fee_applied': True
})
returns = Stateset::Return.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouse_id: 'wh_east_01',
location_id: 'loc_a1_shelf_3',
condition_code: 'new',
quantity: 1,
restocking_fee_applied: true
})
returns, err := stateset.Returns.restock({
ID: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
WarehouseID: 'wh_east_01',
LocationID: 'loc_a1_shelf_3',
ConditionCode: 'new',
Quantity: 1,
RestockingFeeApplied: true
})
Return returns = stateset.Returns.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouseId: 'wh_east_01',
locationId: 'loc_a1_shelf_3',
conditionCode: 'new',
quantity: 1,
restockingFeeApplied: true
});
$returns = $stateset->returns->restock([
'id' => 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
'warehouse_id' => 'wh_east_01',
'location_id' => 'loc_a1_shelf_3',
'condition_code' => 'new',
'quantity' => 1,
'restocking_fee_applied' => true
]);
var returns = await stateset.Returns.Restock(new {
Id = 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
WarehouseId = 'wh_east_01',
LocationId = 'loc_a1_shelf_3',
ConditionCode = 'new',
Quantity = 1,
RestockingFeeApplied = true
});
{
"id": "rt_1NXWPnCo6bFb1KQto6C8OWvE",
"object": "return",
"restocked": true,
"inventory_adjustment_id": "inv_adj_456",
"new_inventory_level": 150,
"warehouse_id": "wh_east_01",
"location_id": "loc_a1_shelf_3",
"condition_code": "new",
"restocked_at": "2024-01-15T11:00:00Z"
}
Body
string
The ID provided in the data tab may be used to identify the return
string
The warehouse ID where the item will be restocked
string
The specific location within the warehouse
string
The condition code for inventory classification (e.g., “new”, “refurbished”, “open_box”)
number
The quantity to restock
boolean
Whether a restocking fee was applied to this return
Response
string
The ID provided in the data tab may be used to identify the return
string
The object type
boolean
Indicates whether the item was successfully restocked
string
The ID of the inventory adjustment record
number
The new inventory level after restocking
string
The warehouse where the item was restocked
string
The timestamp when the item was restocked
number
Indicates whether the call was successful. true if successful, false if not.
curl --location --request POST 'https://api.stateset.com/api/v1/returns/:id/restock' \
--header 'Content-Type: application/json' \
--header 'Authorization: Token <token>' \
--data-raw '{
"id": "rt_1NXWPnCo6bFb1KQto6C8OWvE",
"warehouse_id": "wh_east_01",
"location_id": "loc_a1_shelf_3",
"condition_code": "new",
"quantity": 1,
"restocking_fee_applied": true
}'
mutation returnRestockMutation {
returnRestock(
id: "${returnId}",
warehouseId: "${warehouseId}",
locationId: "${locationId}",
conditionCode: "${conditionCode}",
quantity: ${quantity},
restockingFeeApplied: ${restockingFeeApplied}
) {
return {
id,
status,
inventory_adjustment_id,
new_inventory_level,
restocked_at
}
userErrors {
field
message
}
}
}
`;
const returns = await stateset.returns.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouse_id: 'wh_east_01',
location_id: 'loc_a1_shelf_3',
condition_code: 'new',
quantity: 1,
restocking_fee_applied: true
});
returns = stateset.returns.restock({
'id': 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
'warehouse_id': 'wh_east_01',
'location_id': 'loc_a1_shelf_3',
'condition_code': 'new',
'quantity': 1,
'restocking_fee_applied': True
})
returns = Stateset::Return.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouse_id: 'wh_east_01',
location_id: 'loc_a1_shelf_3',
condition_code: 'new',
quantity: 1,
restocking_fee_applied: true
})
returns, err := stateset.Returns.restock({
ID: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
WarehouseID: 'wh_east_01',
LocationID: 'loc_a1_shelf_3',
ConditionCode: 'new',
Quantity: 1,
RestockingFeeApplied: true
})
Return returns = stateset.Returns.restock({
id: 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
warehouseId: 'wh_east_01',
locationId: 'loc_a1_shelf_3',
conditionCode: 'new',
quantity: 1,
restockingFeeApplied: true
});
$returns = $stateset->returns->restock([
'id' => 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
'warehouse_id' => 'wh_east_01',
'location_id' => 'loc_a1_shelf_3',
'condition_code' => 'new',
'quantity' => 1,
'restocking_fee_applied' => true
]);
var returns = await stateset.Returns.Restock(new {
Id = 'rt_1NXWPnCo6bFb1KQto6C8OWvE',
WarehouseId = 'wh_east_01',
LocationId = 'loc_a1_shelf_3',
ConditionCode = 'new',
Quantity = 1,
RestockingFeeApplied = true
});
{
"id": "rt_1NXWPnCo6bFb1KQto6C8OWvE",
"object": "return",
"restocked": true,
"inventory_adjustment_id": "inv_adj_456",
"new_inventory_level": 150,
"warehouse_id": "wh_east_01",
"location_id": "loc_a1_shelf_3",
"condition_code": "new",
"restocked_at": "2024-01-15T11:00:00Z"
}
⌘I