Getting Started with Avianis API

Getting Started with Avianis API

Introduction to the Avianis API

The Avianis API provides access to Avianis data and services, enabling integration with various aviation operations.


This API supports Basic Authentication as well as Bearer Token (JWT) Authentication for enhanced security and access control.

Authentication Types

  1. Basic Authentication: Use your username and password to access basic API features.
  2. Bearer Token (JWT) Authentication: Provides an additional layer of security. This requires obtaining an access token via OAuth.

Getting Started with Bearer Token Authentication

To use Bearer Token authentication, you must first request an access token from the Avianis OAuth server. Once you have the token, include it in your API requests to authenticate.

Step 1: Request an Access Token

To obtain an access token, make a POST request to the following endpoint:

Method: POST
Headers: Content-Type: application/x-www-form-urlencoded
Body Parameters:
  • grant_type: client_credentials
  • client_id: <Username> (Replace with your username)
  • client_secret: <Password> (Replace with your password)
  • client_authentication: header
CURL Request (Can be imported into POSTMAN)
curl --location 'https://api.avianis.io/oauth/token' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode 'client_id=<username>' \
--data-urlencode 'client_secret=<password>' \
--data-urlencode 'client_authentication=header'
---------------------------------------------------------------------------- 

Step 2: Use the Access Token in API Requests

After receiving the access token, include it in the header of your API requests for authentication.

Example of Headers:

Authorization: Bearer <access_token>

Example of an API Request:

GET https://api.avianis.io/your-endpoint Authorization: Bearer <access_token>