Bookings

Creates a booking based on a previously requested offer.

Changed on
post/bookings

Request

  • Base URL
    https://s3p-osdm.cloud.sqills.com
  • Auth
    OAuth 2
    Client credentials
    Token URLhttps://login.microsoftonline.com/tbd

Headers

Requestorstring

The requestor header contains detailed information about who is calling the API. It can include information such as channel, organization, sales unit or workstation id and be used to configure e.g. the fare range provided to the caller. The content of the string is part of a bilateral contract by the two parties and not standardized by OSDM. It is recommend to encrypt the information transferred.

Accept-Languagestring

Describes the set of natural languages that are preferred for localized text in the response to the request (see RFC9110). Supporting English (en) is a must.

traceparentstring

The traceparent header describes the position of the incoming request in its trace graph in a portable, fixed-length format. Its design focuses on fast parsing. Every tracing tool MUST properly set traceparent even when it only relies on vendor-specific information in tracestate (see W3C Trace Context).

tracestatestring

The tracestate extends traceparent with vendor-specific data represented by a set of name/value pairs. Storing information in tracestate is optional (see W3C Trace Context).

Idempotency-Keystring uuid

The HTTP Idempotency request header field can be used to carry idempotency key in order to make non-idempotent HTTP methods such as POST or PATCH fault-tolerant. Servers should keep the idempotency key for as long as the result of the underlying operation is valid. Idempotency keys should be globally unique.

x-accept-namespacestring

The x-accept-namespace HTTP header indicates the URN namespace that the client prefers. The provider uses content-negotiation to apply the corresponding namespace(s) where applicable.

Request body

requestedFulfillmentTypestring

DEPRECATED — will be removed in 4.0.0. Instead, express the fulfillment type where the document is produced: on POST/PATCH /bookings/{bookingId}/fulfillments, or as a query parameter on GET /fulfillments/{fulfillmentId}.

preferredFulfillmentMediastring

DEPRECATED — will be removed in 4.0.0. Instead, express the preferred media where the document is produced: on POST/PATCH /bookings/{bookingId}/fulfillments, or as a query parameter on GET /fulfillments/{fulfillmentId}.

embedBookingResponseContent2[]

Influences whether referenced resources are returned in full or as references only.

externalRefstring nullable

Example request

{
  "passengerSpecifications": [
    {
      "externalRef": "TK-id-12345",
      "detail": {
        "lastName": "Diaz Lopez",
        "firstFamilyName": "Diaz",
        "secondFamilyName": "Lopez",
        "address": {
          "id": "urn:uic:stn:8500000",
          "geoPosition": {
            "longitude": 8.54021,
            "latitude": 47.37818
          },
          "modes": [
            {
              "name": "rail",
              "shortName": "S"
            }
          ],
          "_links": [
            {
              "rel": "self",
              "type": "application/json"
            }
          ],
          "name": "Oude Trambaan 7, 2265CA Leidschendam, Nederland",
          "code": "NL:1916200000022621",
          "countryName": "The Netherlands",
          "countryCode": "DE",
          "postCode": "2265CA",
          "city": "Leidschendam",
          "topographicPlaceName": "Leidschendam",
          "street": "Oude Trambaan"
        },
        "postalAddress": {
          "countryName": "The Netherlands",
          "countryCode": "DE",
          "postCode": "2265CA",
          "city": "Leidschendam",
          "street": "Oude Trambaan"
        },
        "contact": {
          "postalAddress": {
            "countryName": "The Netherlands",
            "countryCode": "DE",
            "postCode": "2265CA",
            "city": "Leidschendam",
            "street": "Oude Trambaan"
          }
        },
        "taxId": "CZ1234567890"
      },
      "transportableDetails": {
        "car": {
          "contactDetail": {
            "postalAddress": {
              "countryName": "The Netherlands",
              "countryCode": "DE",
              "postCode": "2265CA",
              "city": "Leidschendam",
              "street": "Oude Trambaan"
            }
          }
        },
        "motorCycle": {
          "contactDetail": {
            "postalAddress": {
              "countryName": "The Netherlands",
              "countryCode": "DE",
              "postCode": "2265CA",
              "city": "Leidschendam",
              "street": "Oude Trambaan"
            }
          }
        },
        "trailer": {
          "contactDetail": {
            "postalAddress": {
              "countryName": "The Netherlands",
              "countryCode": "DE",
              "postCode": "2265CA",
              "city": "Leidschendam",
              "street": "Oude Trambaan"
            }
          }
        }
      }
    }
  ],
  "purchaser": {
    "detail": {
      "lastName": "Diaz Lopez",
      "firstFamilyName": "Diaz",
      "secondFamilyName": "Lopez",
      "address": {
        "id": "urn:uic:stn:8500000",
        "geoPosition": {
          "longitude": 8.54021,
          "latitude": 47.37818
        },
        "modes": [
          {
            "name": "rail",
            "shortName": "S"
          }
        ],
        "_links": [
          {
            "rel": "self",
            "type": "application/json"
          }
        ],
        "name": "Oude Trambaan 7, 2265CA Leidschendam, Nederland",
        "code": "NL:1916200000022621",
        "countryName": "The Netherlands",
        "countryCode": "DE",
        "postCode": "2265CA",
        "city": "Leidschendam",
        "topographicPlaceName": "Leidschendam",
        "street": "Oude Trambaan"
      },
      "postalAddress": {
        "countryName": "The Netherlands",
        "countryCode": "DE",
        "postCode": "2265CA",
        "city": "Leidschendam",
        "street": "Oude Trambaan"
      },
      "contact": {
        "postalAddress": {
          "countryName": "The Netherlands",
          "countryCode": "DE",
          "postCode": "2265CA",
          "city": "Leidschendam",
          "street": "Oude Trambaan"
        }
      },
      "taxId": "CZ1234567890"
    },
    "companyDetails": {
      "legalAddress": {
        "id": "urn:uic:stn:8500000",
        "geoPosition": {
          "longitude": 8.54021,
          "latitude": 47.37818
        },
        "modes": [
          {
            "name": "rail",
            "shortName": "S"
          }
        ],
        "_links": [
          {
            "rel": "self",
            "type": "application/json"
          }
        ],
        "name": "Oude Trambaan 7, 2265CA Leidschendam, Nederland",
        "code": "NL:1916200000022621",
        "countryName": "The Netherlands",
        "countryCode": "DE",
        "postCode": "2265CA",
        "city": "Leidschendam",
        "topographicPlaceName": "Leidschendam",
        "street": "Oude Trambaan"
      },
      "legalPostalAddress": {
        "countryName": "The Netherlands",
        "countryCode": "DE",
        "postCode": "2265CA",
        "city": "Leidschendam",
        "street": "Oude Trambaan"
      },
      "contact": {
        "postalAddress": {
          "countryName": "The Netherlands",
          "countryCode": "DE",
          "postCode": "2265CA",
          "city": "Leidschendam",
          "street": "Oude Trambaan"
        }
      }
    }
  },
  "promotionCodes": [
    {
      "code": "SPRING_DISCOUNT"
    }
  ]
}

Response

booking pre-booked

Changes