AirHub API
  1. Route
AirHub API
  • Introduction
  • Authorization
    • Overview
    • Get Oauth Token
      POST
  • Advisories
    • Advisory
      POST
    • Get Advisories BBox
      GET
    • Get Advisories GeoJSON
      POST
  • Briefing
    • Overview
    • B4UFLY
      • What Is B4UFLY
      • The API Basics
      • Location vs Area
      • v1
        • B4UFLY Briefing by Area v1
        • B4UFLY Briefing by Location v1
      • v2
        • What's New in v2
        • B4UFLY Briefing by Area v2
        • B4UFLY Briefing by Location v2
  • LAANC SDSP
    • Overview
    • ASL Operations
      • List Operations
      • Create Operation
      • Get Operation
      • Delete Operation
      • Update Operation
    • LAANC Operations
      • Get Operation
      • Delete Operation
      • Create Operation
      • Update Operation
    • LAANC Authorizations
      • Rescinded and Invalid Operations
      • Submit Authorization
      • Get Authorization
      • Cancel Authorization
      • Cancel Invalid Authorization
      • Close Authorization
      • Acknowledge Rescinded Authorization
    • Operation v2
      POST
    • Create Ephemeral Operations
      POST
  • Risk
    • Get Hazard
      POST
    • Get Hazard Ground Type
      POST
    • Get Hazard Ground Risk
      POST
  • Aviation
    • Aviation
      POST
  • Surface
    • Suitability
      POST
    • Classification Surface
      POST
    • Surface v2 GeoJSON
      POST
    • Surface v2 Hexbin
      POST
  • Route
    • Route v2
      POST
  • Check
    • Check Airspace
    • Get Status
  • Elevation - NEW
    • Elevation
  • Map Vector Tiles - NEW
    • Overview
    • Styled Tiles
    • Vector Tile
  1. Route

Route v2

Sandbox
https://airhub-api-sandbox.airspacelink.com
Sandbox
https://airhub-api-sandbox.airspacelink.com
POST
/v2/route
Last modified:2024-05-17 17:31:19
Scope: route:create
Returns a GeoJSON LineString representing a route between two or more waypoints, optimized for the modeled risk of your operation. There are 3 methods to generating a route. Each route request must include one of the three methods described:
1.
Pre-Generated Surface: Pre-create a classification surface and pass with the surface parameter. The surface must enclose all the waypoints or the route will be unsolvable.
2.
Risk Model Definition with Area of Interest: Create a risk model definition and pass with the layers parameter. Include the operational area to be evaulated using the geometry parmeter. The geometry must enclose all waypoints or the route will be unsolvable.
3.
Risk Model Definition: Create a risk model defintion and pass with the layers param. The API will infer the operational boundary using a buffer of the input waypoints.

Request

Header Params
Content-Type
enum<string> 
required
Allowed value:
application/json;charset=UTF-8
Example:
application/json;charset=UTF-8
Authorization
string 
required
Authorization bearer accessToken generated in Authorization step
Example:
{{access-token}}
Body Params application/json
resolution
integer 
required
Hex grid resolution.
waypoints
object 
required
A multipoint identifying origin and destination(s) to route sequentially.
coordinates
array [array] 
required
type
string 
required
surface
object 
optional
(Option 1) Risk surface.
8a288c74dd1ffff
integer 
required
layers
array [object {2}] 
optional
(Options 2 & 3) Array of layer objects. Valid length of 1-5.
code
string 
required
fields
array[string]
required
geometry
object 
optional
(Option 2) A polygon to pass that connects all the waypoints passed to use for creating a risk surface. If you passed in a surface, this will be ignored. If you don't pass a surface or geometry, the server will pick the geometry to generate the surface for you
type
string 
required
coordinates
array [array] 
required
Example
{
  "resolution": 9,
  "layers": [
    {
      "code": "nsufr_ft"
    },
    {
      "code": "nsufr_pt"
    },
    {
      "code": "tfr"
    },
    {
      "code": "sua"
    }
  ],
  "waypoints": {
    "type": "MultiPoint",
    "coordinates": [
      [
        -83.237915,
        42.316416
      ],
      [
        -83.205643,
        42.304991
      ]
    ]
  }
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://airhub-api-sandbox.airspacelink.com/v2/route' \
--header 'Authorization: ' \
--header 'Content-Type: application/json;charset=UTF-8' \
--data-raw '{
    "resolution": 9,
    "layers": [
        {
            "code": "nsufr_ft"
        },
        {
            "code": "nsufr_pt"
        },
        {
            "code": "tfr"
        },
        {
            "code": "sua"
        }
    ],
    "waypoints": {
        "type": "MultiPoint",
        "coordinates": [
            [
                -83.237915,
                42.316416
            ],
            [
                -83.205643,
                42.304991
            ]
        ]
    }
}'

Responses

🟢200Happy path desc
application/json
Body
data
object 
required
corridor
array[string]
required
network
object 
required
path
object 
required
message
string 
required
statusCode
integer 
required
Example
{
  "data": {
    "corridor": [
      "8a288c758037fff",
      "8a288c75811ffff",
      "8a288c2b24effff"
    ],
    "network": {
      "coordinates": [
        [
          [
            -118.802633639131,
            45.6458480563089
          ],
          [
            -118.807281209253,
            45.6466533063531
          ]
        ],
        [
          [
            -118.802633639131,
            45.6458480563089
          ],
          [
            -118.806148391677,
            45.6458671344001
          ]
        ],
        [
          [
            -118.802633639131,
            45.6458480563089
          ],
          [
            -118.805422182588,
            45.6463312319668
          ]
        ]
      ],
      "type": "MultiLineString"
    },
    "path": {
      "coordinates": [
        [
          -118.685607263462,
          45.6649712310512
        ],
        [
          -118.687640419679,
          45.6618603236282
        ],
        [
          -118.688367745235,
          45.6613969233936
        ],
        [
          -118.704736454367,
          45.657756124899
        ]
      ],
      "type": "LineString"
    }
  },
  "message": "success",
  "statusCode": 200
}
🔴500Internal error
Previous
Surface v2 Hexbin
Next
Check Airspace
Built with