updateBookingTasks
Mutation
Adds new tasks and deletes existing tasks of a valid booking. The new booking tasks will be passed through the booking engine in order to evaluate their viability based on the time requested and location conditions.
Signature
Section titled “Signature”mutation { updateBookingTasks( organisationId: UUID! bookingId: ID! addTasks: [TaskInput!]! deleteTasks: [ID!]! time: Timestamp! areaId: UUID headerLoads: [LoadQuantityInput!] ): Void}Arguments
Section titled “Arguments”| Argument | Type | Default | Description |
|---|---|---|---|
organisationId* | UUID! | — | — |
bookingId* | ID! | — | — |
addTasks* | [TaskInput!]! | — | — |
deleteTasks* | [ID!]! | — | — |
time* | Timestamp! | — | — |
areaId | UUID | — | — |
headerLoads | [LoadQuantityInput!] | — | An array of inputs containing the updated header loads for this booking |
Return type
Section titled “Return type”Void (Void)
Example
Section titled “Example”mutation UpdateBookingTasks($organisationId: UUID!, $bookingId: ID!, $addTasks: [TaskInput!]!, $deleteTasks: [ID!]!, $time: Timestamp!, $areaId: UUID, $headerLoads: [LoadQuantityInput!]) { updateBookingTasks(organisationId: $organisationId, bookingId: $bookingId, addTasks: $addTasks, deleteTasks: $deleteTasks, time: $time, areaId: $areaId, headerLoads: $headerLoads)}curl -X POST https://my.mobiledock.com/api/v1/graphql \ -H "Authorization: Bearer YOUR_TOKEN" \ -H "Content-Type: application/json" \ -d '{ "query": "mutation UpdateBookingTasks($organisationId: UUID!, $bookingId: ID!, $addTasks: [TaskInput!]!, $deleteTasks: [ID!]!, $time: Timestamp!, $areaId: UUID, $headerLoads: [LoadQuantityInput!]) { updateBookingTasks(organisationId: $organisationId, bookingId: $bookingId, addTasks: $addTasks, deleteTasks: $deleteTasks, time: $time, areaId: $areaId, headerLoads: $headerLoads) }", "variables": { "organisationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890", "bookingId": "MDB-26-XXXX-XXXX", "addTasks": [ {} ], "deleteTasks": [ "MDB-26-XXXX-XXXX" ], "time": "2026-04-01T09:00:00Z" } }'const response = await fetch('https://my.mobiledock.com/api/v1/graphql', { method: 'POST', headers: { 'Authorization': 'Bearer YOUR_TOKEN', 'Content-Type': 'application/json', }, body: JSON.stringify({ query: ` mutation UpdateBookingTasks($organisationId: UUID!, $bookingId: ID!, $addTasks: [TaskInput!]!, $deleteTasks: [ID!]!, $time: Timestamp!, $areaId: UUID, $headerLoads: [LoadQuantityInput!]) { updateBookingTasks(organisationId: $organisationId, bookingId: $bookingId, addTasks: $addTasks, deleteTasks: $deleteTasks, time: $time, areaId: $areaId, headerLoads: $headerLoads) } `, variables: { "organisationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890", "bookingId": "MDB-26-XXXX-XXXX", "addTasks": [ {} ], "deleteTasks": [ "MDB-26-XXXX-XXXX" ], "time": "2026-04-01T09:00:00Z" }, }),});
const data = await response.json();