---
title: "Request all the KongAir routes"
url: "https://devportal.jilson.dev/apis/kong-air-ap-is-1-0-0/versions/7a8b8282-7fdc-432a-a618-88582e8fb712/operations/get-routes"
---

> Full API specification: https://devportal.jilson.dev/apis/kong-air-ap-is-1-0-0/versions/7a8b8282-7fdc-432a-a618-88582e8fb712.md

# Request all the KongAir routes

`GET` `/routes`

Operation ID: `get-routes`

Returns all the routes KongAir is currently registered to fly.\nA Route is a pairing between origin and destination airport codes.

## Query parameters

- `origin` (array, optional) - Filter routes by origin airport code. To filter by multiple origin airports, provide an array of airport codes (e.g., `origin=LHR&origin=JFK`).

## Responses

- `200` - Successful response with the registered Routes

## OpenAPI definition

```yaml
openapi: 3.1.0
info:
  title: KongAir APIs
  version: 1.0.0
servers:
  - url: https://api.kongair.dev
    description: KongAir API Dev
paths:
  /routes:
    get:
      summary: Request all the KongAir routes
      description: Returns all the routes KongAir is currently registered to fly.\nA
        Route is a pairing between origin and destination airport codes.
      operationId: get-routes
      tags:
        - Routes
      parameters:
        - name: origin
          in: query
          description: Filter routes by origin airport code.  To filter by multiple origin
            airports, provide an array of airport codes (e.g.,
            `origin=LHR&origin=JFK`).
          required: false
          style: form
          schema:
            type: array
            items:
              type: string
      responses:
        "200":
          description: Successful response with the registered Routes
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/Route"
              examples:
                lhr-sfo:
                  value:
                    - id: LHR-SFO
                      origin: LHR
                      destination: SFO
                      avg_duration: 660
security:
  - ApiKeyAuth: []
  - BearerAuth: []
components:
  schemas:
    Route:
      type: object
      properties:
        id:
          type: string
        origin:
          type: string
        destination:
          type: string
        avg_duration:
          type: integer
      required:
        - id
        - origin
        - destination
        - avg_duration
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
```
