Skip to main content

Update Order Bump

Sparse-update an order bump. Only the keys you send are changed. amount: null clears the override so checkout uses the offered variant amount. Sending currency returns 422. Unknown keys return 422.

Live writes return 409 when the owner product has has_draft: true. Draft writes require draft_version.

Request

Live:

  • PATCH /order-bumps/{id}

Draft:

  • PATCH /products/{productId}/draft/order-bumps/{id}

Path Parameters

ParameterTypeRequiredDescription
productIdstringDraft onlyOwner product UUID.
idstringYesOrder bump UUID.

Request Body

All fields optional. Draft writes also require draft_version.

ParameterTypeRequiredDescription
product_idstringNoOffered product UUID.
variant_idstringNoOffered one-time variant UUID.
namestringNoMerchant-internal label. null clears it.
titlestringNoCheckout headline. null clears it.
descriptionstringNoCheckout body. null clears it.
amountintegerNoOverride in minor units. null clears it. Minimum 1 when set.
display_typestringNolarge_thumbnail, compact, or countdown.
validity_minutesintegerNoCountdown duration. Required ≥ 1 when display_type is countdown. null clears it.
activebooleanNofalse hides at checkout without deleting.
draft_versionintegerDraft onlyCurrent overlay version. Minimum 1.

Example Request

curl -X PATCH "https://cart.easy.tools/api/v1/order-bumps/4eebbd13-ee35-4d66-bfec-a9988b63ef75" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"active": false
}'

Response

Success Response (200)

Returns the updated Order Bump Object. Draft updates also include draft_version and preview_url.

{
"id": "4eebbd13-ee35-4d66-bfec-a9988b63ef75",
"product_id": "70dbd819-fac2-4dcf-b655-fb925e24410b",
"variant_id": "5272bfcf-4e92-458d-b513-80ca474a16e4",
"name": "Backup recording",
"title": "Add the recording",
"description": "Keep the session afterwards.",
"amount": 4900,
"currency": "usd",
"display_type": "large_thumbnail",
"validity_minutes": null,
"active": false
}

Error Responses

Bad Request (400)

{
"message": "Invalid order bump ID"
}

Not Found Error (404)

{
"message": "Order bump with ID 4eebbd13-ee35-4d66-bfec-a9988b63ef75 not found"
}

Conflict Error (409 — Unpublished Draft)

Live write while has_draft is true:

{
"message": "This product has an unpublished draft. Publish, unpublish, or delete the draft before making live changes."
}

Conflict Error (409 — Stale Draft Version)

Draft write when draft_version does not match:

{
"message": "The draft was edited elsewhere. GET the draft and retry with the current draft_version."
}

Validation Error (422 Unprocessable Entity)

Same field rules as Create Order Bump. Sending currency also returns 422.

{
"message": "The given data was invalid.",
"errors": {
"currency": ["The currency field is not allowed."]
}
}

Unauthorized Error (401)

{
"message": "Unauthenticated."
}

Forbidden Error (403)

{
"message": "You do not have API access to the requested store."
}