Skip to main content

Shift API (1.0.0)

Download OpenAPI specification:Download

Shift for Business - Booking Api

Supports Token based authentication and OAuth2.0

Booking

Retrieves the collection of Booking resources.

Retrieves the collection of Booking resources.

Authorizations:
tokentoken_deprecated
query Parameters
createdAt[before]
string
createdAt[strictly_before]
string
createdAt[after]
string
createdAt[strictly_after]
string
updatedAt[before]
string
updatedAt[strictly_before]
string
updatedAt[after]
string
updatedAt[strictly_after]
string
bookingId
string
bookingId[]
Array of strings

Responses

Response samples

Content type
[
  • {
    }
]

Creates a Booking resource.

Creates a Booking resource.

Authorizations:
tokentoken_deprecated
Request Body schema:

The new Booking resource

serviceType
required
string
Enum: "P1" "P2" "P3"

The Service Type of the Booking.

Account-write (object) or null

(optional) If not supplied, will use the default account of the authenticated API user

reference
required
string [ 4 .. 40 ] characters

Customer’s reference

required
Array of objects (InventoryItem-write) non-empty
Transfer-write (object) or null

Required if delivery details are not provided. (FastBacks, Returns)
If not supplied, will default to your primary account address and time windows assigned according to your default service plan.

Transfer-write (object) or null

Required if collection details are not provided.
If not supplied, will default to your primary account address and time windows assigned according to your default service plan.

servicePlanId
string or null

(optional) Request the booking be processed under a specific service plan enabled on your account.

isDraft
boolean

false by default.

Responses

Request samples

Content type
{
  • "serviceType": "P1",
  • "account": {
    },
  • "reference": "string",
  • "items": [
    ],
  • "collection": {
    },
  • "delivery": {
    },
  • "servicePlanId": "string",
  • "isDraft": true
}

Response samples

Content type
{}

Retrieves a Booking resource.

Retrieves a Booking resource.

Authorizations:
tokentoken_deprecated
path Parameters
bookingId
required
string

Booking identifier

Responses

Response samples

Content type
{ }

Sets the booking to active

Set the booking to active state.

Authorizations:
tokentoken_deprecated
path Parameters
bookingId
required
string

Booking identifier

Responses

Response samples

Content type
{}

Cancel a Booking

Creates a Booking resource.

Authorizations:
tokentoken_deprecated
path Parameters
bookingId
required
string

Booking identifier

Request Body schema:

The new Booking resource

cancelReason
string or null
Enum: "customer_cancelled" "business_cancelled" null

The reason for cancellation, can only be omitted if otherReason is provided

otherReason
string or null

Alternative reason for cancellation, if none of the above. Can only be omitted if cancelReason is provided

Responses

Request samples

Content type
{
  • "cancelReason": "customer_cancelled",
  • "otherReason": "string"
}

Response samples

Content type
{
  • "bookingId": "string",
  • "success": true
}

Retrieves a Labels from a Booking resource

This endpoint allows you to pass a booking ID through, as well as properties to control what is returned.

Authorizations:
tokentoken_deprecated
path Parameters
bookingId
required
string

Booking identifier

query Parameters
labelType
required
string
Enum: "zpl" "pdf"
Example: labelType=zpl

The type of label returned in the response

Responses

Response samples

Content type
{
  • "bookingId": "string",
  • "labelZpl": [
    ],
  • "labelPdf": "https://s3... ..51241.pdf"
}

Retrieves the detailed tracking history for a booking

Retrieves a Booking resource.

Authorizations:
tokentoken_deprecated
path Parameters
bookingId
required
string

Booking identifier

query Parameters
sortDescending
boolean
Example: sortDescending=true

Ordering of tracking events by the event date. Defaults to ascending.

Responses

Response samples

Content type
{
  • "trackingRecords": [
    ]
}