Deliveries
Update outbound trip details
PATCH
/
delivery
/
{id}
/
outbound
Update outbound trip details
curl --request PATCH \
--url https://{instance}/api/v2/delivery/{id}/outbound \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"name": "<string>",
"truckId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"truck": "<string>",
"trailerType": "<string>",
"isOverDimension": true,
"receiverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"driverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromKind": "<string>",
"fromLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromAddress": "<string>",
"toKind": "<string>",
"toLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"toAddress": "<string>",
"confirmationTemplateId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"plannedStartAt": "2023-11-07T05:31:56Z",
"plannedEndAt": "2023-11-07T05:31:56Z"
}
'const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
truckId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
truck: '<string>',
trailerType: '<string>',
isOverDimension: true,
receiverContactId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
driverContactId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
fromKind: '<string>',
fromLocationId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
fromAddress: '<string>',
toKind: '<string>',
toLocationId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
toAddress: '<string>',
confirmationTemplateId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
plannedStartAt: '2023-11-07T05:31:56Z',
plannedEndAt: '2023-11-07T05:31:56Z'
})
};
fetch('https://{instance}/api/v2/delivery/{id}/outbound', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{instance}/api/v2/delivery/{id}/outbound"
payload = {
"name": "<string>",
"truckId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"truck": "<string>",
"trailerType": "<string>",
"isOverDimension": True,
"receiverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"driverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromKind": "<string>",
"fromLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromAddress": "<string>",
"toKind": "<string>",
"toLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"toAddress": "<string>",
"confirmationTemplateId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"plannedStartAt": "2023-11-07T05:31:56Z",
"plannedEndAt": "2023-11-07T05:31:56Z"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"value": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}Authorizations
Organization-scoped API key. Create one in the BuildingSwell app under Organization settings, API keys.
Path Parameters
Body
application/json
Available options:
own, third_party Response
Successful response.
⌘I
Update outbound trip details
curl --request PATCH \
--url https://{instance}/api/v2/delivery/{id}/outbound \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"name": "<string>",
"truckId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"truck": "<string>",
"trailerType": "<string>",
"isOverDimension": true,
"receiverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"driverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromKind": "<string>",
"fromLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromAddress": "<string>",
"toKind": "<string>",
"toLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"toAddress": "<string>",
"confirmationTemplateId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"plannedStartAt": "2023-11-07T05:31:56Z",
"plannedEndAt": "2023-11-07T05:31:56Z"
}
'const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
truckId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
truck: '<string>',
trailerType: '<string>',
isOverDimension: true,
receiverContactId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
driverContactId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
fromKind: '<string>',
fromLocationId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
fromAddress: '<string>',
toKind: '<string>',
toLocationId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
toAddress: '<string>',
confirmationTemplateId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
plannedStartAt: '2023-11-07T05:31:56Z',
plannedEndAt: '2023-11-07T05:31:56Z'
})
};
fetch('https://{instance}/api/v2/delivery/{id}/outbound', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{instance}/api/v2/delivery/{id}/outbound"
payload = {
"name": "<string>",
"truckId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"truck": "<string>",
"trailerType": "<string>",
"isOverDimension": True,
"receiverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"driverContactId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromKind": "<string>",
"fromLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fromAddress": "<string>",
"toKind": "<string>",
"toLocationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"toAddress": "<string>",
"confirmationTemplateId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"plannedStartAt": "2023-11-07T05:31:56Z",
"plannedEndAt": "2023-11-07T05:31:56Z"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"value": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}