Skip to content
duxt
Upcoming version
You're browsing the documentation for an upcoming version. Its documentation and features are subject to change.

Run a batch

post
/batches

runBatch

Takes a list of instructions and applies them in order. This endpoint needs no authentication, which is why it takes nothing destructive.

Authorisation

This endpoint needs no authentication.

Request body Required

application/json

object
  • instructions*Requiredarray<any>min items 1max items 50

    Each item

    anyInstruction

    Exactly one of

    • objectRelabelInstruction
      • op*Requiredany
      • consignmentId*Requiredstring
      • reference*Requiredstring
    • objectRetagInstruction
      • op*Requiredany
      • consignmentId*Requiredstring
      • tags*Requiredarray<string>

        Each item

        string

    Told apart by op

json
{
  "instructions": [
    {
      "op": "relabel",
      "consignmentId": "00000000-0000-4000-8000-000000000000",
      "reference": "string"
    }
  ]
}

Responses

200
What each instruction did.

application/json

array<any>

Each item

any

Exactly one of

  • object
    • doneboolean
  • objectProblem
    • title*RequiredstringA short, human-readable summary.
    • status*Requiredintegermin 400max 599
    • detailstring | null
json
[
  {
    "done": true
  }
]

Send a request

This body cannot be drawn as a form: edit it as JSON.

The request is sent by your browser, straight to that server.

curl 'https://api.example.org/v3/consignments?limit=20&cursor=string&status=%5B%0A++%22booked%22%0A%5D&session=string' \
  -H 'Authorization: Bearer demo-token' \
  -H 'X-Request-Id: 00000000-0000-4000-8000-000000000000'