Order API
Write CallUpdateOrders4
Push new or updated orders for Bubblehouse to process.
| Kind | Write API call |
|---|---|
| Method | POST |
| URL | https://app.bubblehouse.com/api/v2023061/<shop>/UpdateOrders4 |
| Authentication | Shop Token |
Bubblehouse rejects malformed request content before order processing. An HTTP 400 invalid_content response means that no orders in the request were processed; correct the request and retry the entire batch. Once decoding succeeds, per-order errors such as bad_data do not stop valid sibling orders.
When one or more orders fail during processing, the response keeps the first failure's HTTP status, error ID, and message. extra.failed_order_count reports the total failures, and extra.failed_orders lists up to 100 failures with each zero-based index, external_id truncated to 256 bytes, and error. Retry the corrected failed orders. Resending the whole batch is also safe because order updates are idempotent, but already successful orders will be processed again.
For a 5xx response, retry the listed failures when extra.failed_orders is present; otherwise retry the entire batch. Retry the entire batch after a network error because the processing outcome is unknown. Other processing may be delayed, and some errors might only be visible via error emails later. Use debug mode to receive additional errors immediately during development.
There is no separate deletion call, but you can delete orders by updating them with "deleted": true flag. For safety reasons, deletion is not normally enabled on ordinary API keys, talk to support if you want it. In most cases, though, you should rather use "status": "canceled".
The optional location field is resolved against the Location set for the order's venue. Structurally malformed location JSON fails request decoding with HTTP 400 invalid_content. An unusable Location identity does not fail the order: a new order is saved without a Location, and an update keeps the stored Location.
Input
-
A list of orders to process.
-
debugboolean optionalTrue to make it easier to debug this call
Normally, we do not guarantee that updates are processed synchronously. We might do that, or we might return success from this function immediately and queue processing until a later time. Passing
"debug": trueensures that processing is immediate and synchronous, and will also fail the call on any warnings, making it easier to diagnose problems.Please ensure to never enable debug mode in production, or even during high-volume testing.
Output
A successful response has no meaningful properties and only contains an ok property always set to true:
{"ok": true}
Specific Errors
| Status | Error | Reason & Examples |
|---|---|---|
| 400 | bad_data |
Global Errors
| Status | Error | Reason & Examples |
|---|---|---|
| 401 | invalid_token |
The provided authentication token is invalid or has expired. |
| 429 | rate_limit_exceeded |
Your usage is over the rate limit. Ensure that you're not making duplicate calls, and contact our team for a rate limit increase. |
| 400 | obsolete_global_api_version |
The global API version you are trying to use is no longer supported. |
| 400 | invalid_global_api_version |
The global API version you are trying to use has never existed. |
| 400 | inaccessible_global_api_version |
The global API version you are trying to use is not enabled on your account. |