aviation-stack-sdk
v1.0.0
Published
AviationStack API: A comprehensive aviation data API that provides real-time flight tracking, status information, and access to aviation databases including flights, routes, airports, airlines, aircraft types, and schedules. It enables developers to retri
Readme
Getting Started with Aviationstack
Introduction
Quick Start Guide
Step 1: Your API Access Key
To get started quickly, you need to fork the Aviationstack Postman Collection. Simply click the button below to fork it.
Step 2: Get your API Access Key
- Go to the Aviationstack website and choose the right subscription plan for your particular project.
- Get your personal API Access Key on the Dashboard to authenticate with the API. Keep it safe! You can reset it at any time in your Account Dashboard.
Step 3: Make your first API call
Aviationstack Postman collection contains all the endpoints supported by Aviationstack API.
- Flights
- Routes
- Airports
- Airlines
- Airplanes
- Aircraft Types
- Taxes
- Cities
- Countries
- Flights Schedules
- Flights Future Schedules
Install the Package
Run the following command from your project directory to install the package from npm:
npm install [email protected]For additional package details, see the Npm page for the [email protected] npm.
Test the SDK
To validate the functionality of this SDK, you can execute all tests located in the test directory. This SDK utilizes Jest as both the testing framework and test runner.
To run the tests, navigate to the root directory of the SDK and execute the following command:
npm run testOr you can also run tests with coverage report:
npm run test:coverageInitialize the API Client
Note: Documentation for the client can be found here.
The following parameters are configurable for the API Client:
| Parameter | Type | Description |
| --- | --- | --- |
| environment | Environment | The API environment. Default: Environment.Production |
| timeout | number | Timeout for API calls.Default: 0 |
| httpClientOptions | Partial<HttpClientOptions> | Stable configurable http client options. |
| unstableHttpClientOptions | any | Unstable configurable http client options. |
| customQueryAuthenticationCredentials | CustomQueryAuthenticationCredentials | The credential object for customQueryAuthentication |
The API client can be initialized as follows:
import { Client, Environment } from 'aviation-stack-sdk';
const client = new Client({
customQueryAuthenticationCredentials: {
'access_key': 'access_key'
},
timeout: 0,
environment: Environment.Production,
});Authorization
This API uses the following authentication schemes.
List of APIs
- Aircraft Types
- Flight Schedules
- Flight Future Schedules
- Flights
- Routes
- Airports
- Airlines
- Airplanes
- Taxes
- Cities
- Countries
