Orders
Pause or resume one of your orders
Needs the orders:write scope. About scopes
Only where the account lets you pause your own orders.
keyheader
AuthorizationBearer <traki_buyer_…>id*stringFormat
uuidapplication/json- body
action*stringValue in
"pause""resume"reason?stringLength
length <= 300ifVersion?stringThe version the change is based on; refused with 409 when the order moved on.
Match
^\d{1,16}$Success
application/json- response
id*stringFormat
uuidcode*stringstatus*stringtest*booleancampaign*tier*shelf*stringstates*array<string>quantity*integerRange
-9007199254740991 <= value <= 9007199254740991filled*integerRange
-9007199254740991 <= value <= 9007199254740991owed*integerRange
-9007199254740991 <= value <= 9007199254740991replacements*integerRange
-9007199254740991 <= value <= 9007199254740991dailyCap*|nullpacePerHour*integerRange
-9007199254740991 <= value <= 9007199254740991deliveryDays*|nullcurrency*stringprice*stringtotal*stringcash*stringcredit*stringdiscount*stringpaymentMethod*string|nullpaidAt*string|nullpausedAt*string|nullpauseReason*string|nullholdReason*string|nullcancelReason*string|nullcompletedAt*string|nullexpectedCompletionAt*string|nulllastDeliveryAt*string|nullrefunded*origin*stringcreatedAt*stringupdatedAt*stringversion*stringcurl -X POST 'https://api.traki.io/v1/buyer/orders/497f6eca-6276-4993-bfeb-53cbbbba6f08/actions' \ -H "Authorization: Bearer $TRAKI_KEY" \ -H 'Content-Type: application/json' \ -H 'Idempotency-Key: a-unique-id-for-this-change' \ -d '{ "action": "pause"}'Example Response
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "code": "string", "status": "string", "test": true, "campaign": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string" }, "tier": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string" }, "shelf": "string", "states": [ "string" ], "quantity": -9007199254740991, "filled": -9007199254740991, "owed": -9007199254740991, "replacements": -9007199254740991, "dailyCap": -9007199254740991, "pacePerHour": -9007199254740991, "deliveryDays": -9007199254740991, "currency": "string", "price": "string", "total": "string", "cash": "string", "credit": "string", "discount": "string", "paymentMethod": "string", "paidAt": "string", "pausedAt": "string", "pauseReason": "string", "holdReason": "string", "cancelReason": "string", "completedAt": "string", "expectedCompletionAt": "string", "lastDeliveryAt": "string", "refunded": { "leads": -9007199254740991, "cash": "string", "credit": "string", "at": "string" }, "origin": "string", "createdAt": "string", "updatedAt": "string", "version": "string"}The leads delivered on one of your orders, newest first GET
The full lead records come from `GET /leads`; these name which order each filled.
Change an open order’s states, daily cap or run length POST
Applied at once, or sent to the account for approval, as your access to orders allows. The quantity does not change here: more leads is a new order.