Endpoints : Supplier management#

The following sections will describe each endpoints providing at least one example.

Create a new supplier#

Path

POST /api/supplier

Input parameters

Table 1 - Description of the input parameters in the “create new supplier” endpoint#

Field

Mandatory

Type

Description

Example

externalId

Y

string[255]

Identifier of the supplier

f27a4b3d-24c4

country

Y

string[2]

Supplier country code (ISO 3166-1 alpha-2)

IT

bookingEngine

Y/N*

integer

Booking engine id (*Mandatory if RBAC role is AMADEUS_CATALOG_MANAGEMENT else will be autofilled with existing booking engine)

channel

N

string[32]

Identifies the channel through which the supplier uploads the content for our application (could be ALENTOUR or DISCOVER)

ALENTOUR

name

N

string[255]

Supplier name

Kayak-Evasion

endpoint

N

string[255]

Supplier Endpoint

http://supplier.com/api

logo

N

string[255]

Logo of the supplier

http://cdn.com/logo.jpg

supplierContact/website

N

string[512]

Website of the supplier

www.kayka-evasion.com

supplierContact/email

N

string[255]

Contact email of the supplier

contact@kayakevasion.com

supplierContact/telephone

N

string[255]

Phone number of the supplier

+33245670921

supplierContact/address

N

string[255]

Adress of the supplier

3 place Aristide Briand 44000 Nantes, France

geoLocation/latitude

N

float

Latitude of the supplier address

29.976

geoLocation/longitude

N

float

Longitude of the supplier address

31.1313

geoLocation/geoHash

N

string

public domain geocode system encodes a geographic location into a short string of letters and digits (it encodes a geographic location into a short string of letters and digits)

u09wh9nfs998797

onlineBookable

N/A

boolean

autogenerated

true

Output

Status code

Code

Description

201

Created

400

Bad request

400

Missing Booking Engine

401

Unauthorized

403

Forbidden

500

Internal server error

Retrieve supplier information#

Path

GET /api/supplier/{supplierId}

Input parameters

Table 2 - Description of the input parameters in the “retrive supplier information” endpoint#

Field

Mandatory

Type

Description

Example

supplierId

Y

integer

provided by API when the supplier has been created

1176483

Output

Response Body Example
{
"id": 7986141,
"name": "SCOPE_01-supplier-01 - 1662105596",
"externalId": "SCOPE_01-supplier-01-1662104859",
"creationDate": "2022-09-02T07:47:38.762+00:00",
"updateDate": "2022-09-02T07:59:56.246+00:00",
"endpoint": "www.SCOPE_01.com",
"logo": "https://estaticos.muyinteresante.es/media/cache/1000x_thumb/uploads/images/gallery/5b1f82135bafe8e0fbeffd4f/corgi-con-palo.jpg",
"supplierContact": {
    "website": "www.SCOPE_01-supplier-01.com",
    "email": "SCOPE_01-supplier-01@mailinator.com",
    "telephone": "+3402020202",
    "address": "27-21 Bd du Parc Impérial, Nice, France"
},
"geoLocation": {
    "latitude": 43.703651,
    "longitude": 7.252747,
    "geoHash": "spv0t6wf4"
},
"country": "FR",
"bookingEngine": "SCOPE_01",
"onlineBookable": true
}

Status code

Code

Description

200

Ok

400

Bad request (non numeric supplier id)

401

Unauthorized

403

Forbidden

404

Non existing supplier

500

Internal server error

Update supplier#

Path

POST /api/supplier/{supplierId}

Input parameters

Table 3 - Description of the input parameters in the “update supplier” endpoint#

Field

Mandatory

Type

Description

Example

supplierId

Y

integer

provided by API when the supplier has been created

1176483

externalId

Y

string[255]

Identifier of the supplier

f27a4b3d-24c4

country

Y

string[2]

Supplier country code (ISO 3166-1 alpha-2)

IT

bookingEngine

Y/N*

integer

Booking engine id (*Mandatory if RBAC role is AMADEUS_CATALOG_MANAGEMENT else will be autofilled with existing booking engine)

channel

N

string

Identifies the channel through which the supplier uploads the content for our application

ALENTOUR

name

N

string

Supplier name

Kayak-Evasion

endpoint

N

string[255]

Supplier Endpoint

http://supplier.com/api

logo

N

string[255]

Logo of the supplier

http://cdn.com/logo.jpg

supplierContact/website

N

string[512]

Website of the supplier

www.kayka-evasion.com

supplierContact/email

N

string[255]

Contact email of the supplier

contact@kayakevasion.com

supplierContact/telephone

N

string[255]

Phone number of the supplier

+33245670921

supplierContact/address

N

string[255]

Adress of the supplier

3 place Aristide Briand 44000 Nantes, France

geoLocation/latitude

N

float

Latitude of the supplier address

29.976

geoLocation/longitude

N

float

Longitude of the supplier address

31.1313

geoLocation/geoHash

N

string

public domain geocode system encodes a geographic location into a short string of letters and digits (it encodes a geographic location into a short string of letters and digits)

u09wh9nfs998797

onlineBookable

N/A

boolean

autogenerated

true


Output

Response Body Example
{
"id": 7986141,
"name": "SCOPE_01-supplier-01 - 1662124676",
"externalId": "SCOPE_01-supplier-01-1662104859",
"creationDate": "2022-09-02T07:47:38.762+00:00",
"updateDate": "2022-09-02T13:17:56.285+00:00",
"endpoint": "www.SCOPE_01.com",
"logo": "https://estaticos.muyinteresante.es/media/cache/1000x_thumb/uploads/images/gallery/5b1f82135bafe8e0fbeffd4f/corgi-con-palo.jpg",
"supplierContact": {
    "website": "www.SCOPE_01-supplier-01.com",
    "email": "SCOPE_01-supplier-01@mailinator.com",
    "telephone": "+3402020202",
    "address": "27-21 Bd du Parc Impérial, Nice, France"
},
"geoLocation": {
    "latitude": 43.703651,
    "longitude": 7.252747,
    "geoHash": "spv0t6wf4"
},
"country": "FR",
"bookingEngine": "SCOPE_01",
"onlineBookable": true
}

Status code

Code

Description

200

Ok

400

Missing Booking Engine

401

Unauthorized

403

Forbidden

404

Non existing supplier

500

Internal server error

Delete supplier#

Path

DELETE /api/supplier/{supplierId}

Input parameters

Table 4 - Description of the input parameters in the “delete supplier” endpoint#

Field

Mandatory

Type

Description

Example

supplierId

Y

integer

provided by API when the supplier has been created

1176483

Status code

Code

Description

200

Ok

400

Bad request (non numeric supplier id)

401

Unauthorized

403

Forbidden

404

Non existing supplier

500

Internal server error

Note

Note: Delete a supplier is a definitive action that cannot be cancelled. If a supplier has been deleted by mistake, it will need to be created again.


Retrieve suppliers information for your booking engine#

This endpoint allows to retrieve the list of your suppliers (not including the deleted ones)

Path

GET /api/suppliers

Input parameters

Table 5 - Description of the input parameters in the “retrive supplier information” endpoint#

Field

Mandatory

Type

Description

Example

bookingEngineName

Y

string[255]

Booking engine name

TIQETS

pageNumber

N

integer

Page number for pagination

1 (default)

resultsPerPage

N

integer

Number of results per page

100 (default)

Output

Response Body Example
{
"pageNumber": 2,
"totalResults": 4393,
"resultsPerPage": 50,
"items": [
    {
        "id": 120368,
        "name": "Belfry of Lille",
        "externalId": "8eb556ca-7dac-4213-baaf-52ccc24fea95",
        "bookingEngine": "HOLIBOB",
        "onlineBookable": true
    },
    {
        "id": 157377,
        "name": "Montserrat Cable Car Station",
        "externalId": "4c765e1e-7877-4f84-a0f2-2b40681de032",
        "channel": "DISCOVER",
        "creationDate": "2022-02-04T11:26:38.268+00:00",
        "updateDate": "2022-04-29T04:50:11.258+00:00",
        "country": "FR",
        "bookingEngine": "HOLIBOB",
        "onlineBookable": true
    },
    {
        "id": 120553,
        "name": "Versailles - Musement",
        "externalId": "fa328c5b-857f-44b1-98d9-10dc5fb78f5d",
        "bookingEngine": "HOLIBOB",
        "onlineBookable": true
    }
]
"SHORTEDNED EXAMPLE": "[...]"
}

Status code

Code

Description

200

Successful retrieval of suppliers

400

Scope not found in privileges / User calling the request does not have the right privileges

400

User is requesting a wrong booking engine

400

Non existent booking engine

400

Account does not exist

400

Account is not setup with booking engine

401

Unauthorized

403

Forbidden

500

Internal server error