Authentication

To start with our API's the first step is to get a valid token by authorizing yourself.

Retrieve Token - Authenticate endpoint basically authenticates the enduser [OTA] and issue standard JWT Token on successful authentication. 

This API has to be called with valid travel agent credentials (Username and Password).

By passing JWT Token in header you can do further API communication in a secured manner from availability search to Payment. 

URL: https://devapi.flydubai.com/res/v3/authenticate

Method: POST

Headers:

      • Content-Type                    : application/x-www-form-urlencoded

Body:

      • client_id                            : <XXXXXXXXXXXXXXX>
      • client_secret                     : <XXXXXXXXXXXXXXX>
      • grant_type                        : password
      • username                         : <TA_USER_NAME>
      • password                          : <TA_PASSWORD>
      • scope                                : res

Response:

{
    "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYXBpcmlzaGkiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9naXZlbm5hbWUiOiJURVNUIFJJU0hJIiwiY2xpZW50SVAiOiIxMC4xLjEzMy45MiIsInJlc0NoYW5uZWxJRCI6IjIiLCJpc0FwdENsbnQiOiJGYWxzZSIsIm5iZiI6MTU1NDk2NDUzOCwiZXhwIjoxNTU0OTY3NTM4LCJpc3MiOiJmbHlkdWJhaS5jb20iLCJhdWQiOiJTUExFTkRJRF9GWl9VIn0.d3vVs9DV46PnhwPPh5wh41FFtcAXQiVeW_pp1Z6jiLY",
    "token_type": "bearer",
    "expires_in": 2999,
    "refresh_token": "dd15d291b011487fb4378cc451305d30",
    "audience": "XXXXXXX",
    "displayName": "XXXX XXXX",
    "userId": "XXXXXX",
    "rolesandpermission": "",
    "resChannelID": "2",
    "airports": "",
    "isAptClnt": "False",
    "scope": "",
    ".issued": "Thu, 11 Apr 2019 06:35:38 GMT",
    ".expires": "Thu, 11 Apr 2019 07:25:38 GMT"
}