Create an order (spends credits)
create_orderSpends 1 credit per complete UK record against a live machine quote from quote_order, and queues the order. It needs the quote_id and an idempotency_key to reuse on any retry, so a retry never charges twice; a flag set by a model is never consent. Where the host supports elicitation the user confirms the spend in a form or on mydatahub.emailmovers.com; otherwise an agent key must cover it within its per-order cap and monthly budget. If neither applies nothing is charged: the result is a confirmation-required error with an approval_url to give the user, so keep the quote_id; a short balance returns a top_up_url. Call get_order until the status is ready, then fetch_order_records. Lawful basis is UK GDPR Article 6(1)(f) legitimate interests; email audiences include corporate subscribers only by default (PECR), so sole traders and ordinary partnerships are left out unless the toggle is changed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | ||
| delivery | No | api (fetch records), csv (signed download) and google_sheets. Default api. | |
| quote_id | Yes | A live machine quote from quote_order. Without one nothing is charged. | |
| idempotency_key | Yes | Any unique string, such as a V4 UUID. Reuse it when retrying the same order so it is never charged twice; a different order needs a new key. | |
| confirmation_token | No | The token the approval page on mydatahub.emailmovers.com returns once the signed-in person approves. It is bound to that person (their sub), this spend (the machine quote_id, or the enrichment or push) and an expiry no later than the quote's, and it is redeemable once. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Format: an order id: ord_ followed by a 26 character ULID in upper case Crockford base32, such as ord_01JB4N9S3W2X6Y7Z8A1B2C3D4E. | |
| name | No | ||
| test | No | A test mode order (a test key, or anyone in a demo organisation): no credits were charged, the records are invented and no licence is granted. Absent on a live order. | |
| status | Yes | queued, building, verifying, ready; failed if processing failed; cancelled (only while queued). | |
| failure | No | ||
| licence | Yes | ||
| records | Yes | ||
| cost_gbp | Yes | The charge in GBP excluding VAT at your plan's rate. | |
| count_id | Yes | The count the machine quote was priced from. | |
| delivery | No | ||
| quote_id | Yes | The machine quote the order settled. | |
| ready_at | No | ||
| buyer_kit | No | ||
| field_set | No | ||
| created_at | No | ||
| receipt_url | No | A path on https://mydatahub.emailmovers.com starting /v1/. Resolve it against the origin (RFC 3986), not by appending it to the server URL. | |
| records_url | Yes | A path on https://mydatahub.emailmovers.com starting /v1/. Resolve it against the origin (RFC 3986), not by appending it to the server URL. | |
| confirmed_by | Yes | ||
| download_url | No | 302 to a single-use signed URL that lives 5 minutes. | |
| verification | No | The real-time check at delivery, such as 4,102 checked, 4,071 passed. | |
| credits_charged | Yes | Credits, to one decimal place: whole at 1 credit a record, fractional only where a rule is (0.1 company-only, 1.8 outright, both proposed). | |
| dataset_version | No | The immutable weekly build a count is bound to, such as 2026-W39. The last 52 stay queryable. | |
| credits_remaining | Yes | The balance right after this order was charged. | |
| validation_report | No | Present once the order is ready. | |
| licence_expires_at | Yes | When the licence ends; null for outright ownership. |