Update order bump on event
Updates how an order bump is offered on the specified event. Only the fields provided change; showHideLogic is replaced whole. The product's own copy and price are edited on the product. An archived event must be unarchived first.
/v1/events/:pageId/order-bumps/:productIdAuthorization
api_key_auth API key authentication. Use "Bearer YOUR_API_KEY" format.
In: header
Path Parameters
The ID of the checkout page or event.
^[0-9a-fA-F]{24}$
The ID of the product offered as an order bump on the page.
^[0-9a-fA-F]{24}$
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
- enabledboolean
Whether the order bump is offered. A disabled order bump stays on the page but is not shown.
- preselectedboolean
Whether the order bump is ticked when the page loads.
- hiddenboolean
Hide the order bump unless the page URL reveals it with
?show_order_bumps=and the product price reference. Rule that shows the order bump only for some selections. Sent whole: it replaces the stored rule.
- allowQuantityboolean
Let the customer pick a quantity. Off, the order bump is bought once.
- shortenDescriptionboolean
Clamp a long description behind a Show more toggle.
Returns
Order bump updated successfully
- productIdstring
ID of the product offered as an order bump.
- addedAtstring, nullable
ISO 8601 timestamp when the order bump was added to this page.
- enabledboolean
Whether the order bump is offered.
- preselectedboolean
Whether it is ticked when the page loads.
- hiddenboolean
Whether it is hidden unless the page URL reveals it with
?show_order_bumps=. Rule that shows the order bump only for some selections.
- allowQuantityboolean
Whether the customer can pick a quantity.
- shortenDescriptionboolean
Whether a long description is clamped behind a Show more toggle.
Summary of the product. Read the full product with get_product.
The price the order bump is offered at. Null when it is unavailable, including when its price is disabled.
- unavailableReasonstring, nullable
Why the order bump cannot be offered on this page right now (e.g. a currency mismatch or a deleted product), or null when it can. An unavailable order bump stays on the page until removed.
- usedOnPageCountnumber
How many of your pages offer this product as an order bump.
- hasPurchasesboolean
Whether the product has been bought. A bought product cannot be deleted.
- productIdstring
Bad request - invalid input, or the event is archived
- statusstring
Indicates the request failed.
error - typestring
Machine-readable error category.
- messagestring
Human-readable error message.
Optional validation details for invalid requests.
Unauthorized - Missing or invalid API key
- statusstring
Indicates the request failed.
error - typestring
Machine-readable error category.
- messagestring
Human-readable error message.
Optional validation details for invalid requests.
Forbidden - Insufficient permissions or validation error
- statusstring
Indicates the request failed.
error - typestring
Machine-readable error category.
- messagestring
Human-readable error message.
Optional validation details for invalid requests.
event or order bump not found
- statusstring
Indicates the request failed.
error - typestring
Machine-readable error category.
- messagestring
Human-readable error message.
Optional validation details for invalid requests.
Rate Limit Exceeded - Please try again later.
- messagestring
Human-readable error message.
Internal server error
- statusstring
Indicates the request failed.
error - typestring
Machine-readable error category.
- messagestring
Human-readable error message.
Optional validation details for invalid requests.
import { createCheckoutPageClient } from '@checkoutpage/sdk';const checkoutpage = createCheckoutPageClient({ apiKey: process.env.CHECKOUTPAGE_API_KEY!,});const response = await checkoutpage.events.orderBumps.update('65f4a1c2e4a9f3d2b1c0a9e8', '65f4a1c2e4a9f3d2b1c0a9e8', {});{
"data": {
"productId": "string",
"addedAt": "string",
"enabled": true,
"preselected": true,
"hidden": true,
"showHideLogic": {
"enabled": true,
"subject": "price",
"comparison": "is",
"priceIds": [
"string"
],
"ticketTypeIds": [
"string"
],
"orderBumpProductIds": [
"string"
]
},
"allowQuantity": true,
"shortenDescription": true,
"product": {
"id": "string",
"title": "string",
"currency": "string",
"imageUrl": "string"
},
"price": {
"amount": 0,
"currency": "string",
"billingType": "one_time",
"interval": "string",
"intervalCount": 0
},
"unavailableReason": "string",
"usedOnPageCount": 0,
"hasPurchases": true
}
}{
"status": "error",
"type": "error",
"message": "This event is archived. Unarchive it to change its add-ons."
}{
"status": "error",
"type": "error",
"message": "Missing or invalid API key"
}{
"status": "error",
"type": "error",
"message": "Insufficient permissions requires: BOOKINGS_WRITE"
}{
"status": "error",
"type": "error",
"message": "This product is not an add-on on this page."
}{
"message": "API key rate limit exceeded. Please try again later."
}{
"status": "error",
"type": "error",
"message": "Internal server error"
}