Update Swag Global Inventory
Allows business admin users to update the inventory quantity for an existing swag item configured with global inventory.
Authentication Note: This is a Dashboard API endpoint. It uses a business admin API key (not a mobile guest access token) and does not require client or x-pch-digest headers.
Prerequisites and Permissions:
- The Save points for swag redemption feature must be enabled for the business. Contact your Punchh representative to update this Punchh platform configuration.
- The business admin must have Dashboard API access and the required Inventory and Redeemable/Swag Management permissions to create, edit, and delete redeemables, swag items, and inventory items.
Note: Do not pass both location_id and tag_id in the same request. If neither is passed, the inventory is updated globally.
See Get Swags, Get Swag Shipping Details, Get User's Save Points for Swag Settings and Balance, Update User's Save Points for Swag Settings, Fetch Available User's Swag, Fetch Swag Locations, and Redeem Swag.
Headers
- Type: stringAuthorizationrequired
Bearer token for admin authorization, who is making a call on behalf of the customer. Send the API key in the following format: "Authorization: Bearer BUSINESS_ADMIN_KEY_GOES_HERE".
- Type: stringAcceptrequired
Advertises which content types the client is able to understand
- Type: stringContent
- Type requiredSet this header to application/json.
Body
- Type: integerinventory
_qty min:0max:999999requiredThe new inventory quantity to assign.
- Type: integerswag
_id requiredThe unique identifier of the swag item.
- Type: integerlocation
_id ID of a participating store location. Optional. Must belong to the current business. Mutually exclusive with
tag_id. - Type: integertag
_id ID of a participating location group or tag. Optional. Must belong to the current business and be active. Mutually exclusive with
location_id.
Responses
- application/json
- application/json
- application/json
- application/json
- application/json
- application/json
curl https://SERVER_NAME_GOES_HERE.punchh.com/api2/dashboard/inventory_items/global \
--request PATCH \
--header 'Authorization: Bearer BUSINESS_ADMIN_KEY_GOES_HERE' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"swag_id": 513663,
"inventory_qty": 33
}'
{
"swag_id": 513741,
"message": "Inventory updated successfully"
}