OpenAPI Specification
openapi: 3.0.0
info:
title: Aloft API V1 Accounts Flight Sessions API
contact:
email: support@aloft.ai
version: 1.0.0
description: Accounts
tags:
- name: Flight Sessions
description: Flight Sessions
paths:
/v1/account/{account_id}/flight-sessions:
get:
tags:
- Flight Sessions
summary: Get all flight sessions
description: Get all flight sessions
operationId: a76103f0ab054c53018f9fd76bda4ec0
parameters:
- name: account_id
in: path
required: true
schema:
$ref: '#components/schemas/account_id'
- name: status[]
in: query
description: A list of flight session statuses
required: false
schema:
type: array
items:
description: status
type: string
enum:
- pre_flight
- flying
- post_flight
- complete
- canceled
- name: origin_system[]
in: query
description: System the flight session originated from
required: false
schema:
type: array
items:
type: string
enum:
- ac
- import
- third_party_app
- classic
- public_api
- unknown
- name: origin_method[]
in: query
description: Method the flights were flown with.
required: false
schema:
type: array
items:
description: status
type: string
enum:
- autel
- bulk
- dji
- import
- manual
- skydio
- name: origin_env[]
in: query
description: Environment the flight was flown on
required: false
schema:
type: array
items:
description: status
type: string
enum:
- android
- ios
- unknown
- web
- name: starts_at_before
in: query
description: The starts_at_before date must be greater than the starts_at date.
required: false
schema:
type: integer
- name: starts_at_after
in: query
description: The starts_at_after date must be less than the starts_at date.
required: false
schema:
type: integer
- name: open
in: query
description: Returns only open flight sessions if true.
required: false
schema:
type: boolean
- name: user_id
in: query
required: false
schema:
type: integer
- name: mission_uuid
in: query
required: false
schema:
type: string
- name: workflow_id
in: query
required: false
schema:
type: integer
- name: appends[]
in: query
description: array of model names
schema:
type: array
items:
description: A list of models to attach
type: string
enum:
- mission
- user
- workflow_executions
- workflow
- flights
- flights.address
- flights.import_id
- name: order_by
in: query
description: The field to order the data by.
required: false
schema:
type: string
enum:
- provider
- ended_at
- starts_at
- name: order
in: query
required: false
schema:
$ref: '#components/schemas/order_direction'
- name: page
in: query
required: false
schema:
type: integer
- name: page_length
in: query
required: false
schema:
type: integer
responses:
'403':
description: Access Denied
'401':
description: Unauthorized
'200':
description: Successful operation
content:
application/json: {}
application/csv: {}
post:
tags:
- Flight Sessions
summary: Create a flight session.
description: Create a flight session
operationId: 5b263ae71ecf28516006d50aa11f03ed
parameters:
- name: account_id
in: path
required: true
schema:
$ref: '#components/schemas/account_id'
- name: appends[]
in: query
description: array of model names
schema:
type: array
items:
description: A list of models to attach
type: string
enum:
- mission
- user
- workflow
- flights
requestBody:
content:
application/json:
schema:
$ref: '#components/schemas/flight_session_create'
responses:
'403':
description: Access Denied
'401':
description: Unauthorized
'200':
description: Successful operation
/v1/account/{account_id}/flight-sessions/{flight_session_uuid}:
get:
tags:
- Flight Sessions
summary: Get a flight session
description: Get a flight session
operationId: 551a2d453115887701136e17a7de3276
parameters:
- name: account_id
in: path
required: true
schema:
$ref: '#components/schemas/account_id'
- name: flight_session_uuid
in: path
description: Flight session uuid.
required: true
schema:
type: string
- name: appends[]
in: query
description: array of model names
schema:
type: array
items:
description: A list of models to attach
type: string
enum:
- flights
- flights.address
- flights.import_id
- mission
- user
- workflow
- workflow.workflow_steps
- workflow.workflow_steps.workflow_step_id
- workflow_executions
responses:
'403':
description: Access Denied
'401':
description: Unauthorized
'200':
description: Successful operation
content:
application/json: {}
application/csv: {}
delete:
tags:
- Flight Sessions
summary: Delete a flight session
description: Delete a flight session
operationId: ce0632380fc35507e40595a704cb6985
parameters:
- name: account_id
in: path
required: true
schema:
$ref: '#components/schemas/account_id'
- name: flight_session_uuid
in: path
description: flight session Id.
required: true
schema:
type: string
responses:
'403':
description: Access Denied
'401':
description: Unauthorized
'204':
description: Successful operation
/v1/account/{account_id}/flight-sessions/{flight_session_uuid}/flights:
post:
tags:
- Flight Sessions
summary: Create a flight on a flight session.
description: Create a flight on a flight session
operationId: e97a32823796bf731c8e80c73ac094d8
parameters:
- name: account_id
in: path
required: true
schema:
$ref: '#components/schemas/account_id'
- name: flight_session_uuid
in: path
description: flight session Id.
required: true
schema:
type: string
- name: appends[]
in: query
description: array of model names
schema:
type: array
items:
description: A list of models to attach
type: string
enum:
- flights
- flights.address
- flights.import_id
- mission
- user
- workflow
- workflow_executions
requestBody:
content:
multipart/form-data:
schema:
schema: flight_session_create_flight
properties:
file:
description: flight log
type: string
format: binary
flight_uuid:
description: uuid for the flight
type: string
type:
description: Type of flight log provided
type: string
enum:
- aloft-v1
- dji
type: object
responses:
'403':
description: Access Denied
'401':
description: Unauthorized
'201':
description: Successful operation
/v1/account/{account_id}/flight-sessions/{flight_session_uuid}/media:
post:
tags:
- Flight Sessions
summary: Import media on flight
description: Import media for a flight on a flight session
operationId: 5d38fd715b392ddb30c8029770da27b2
parameters:
- name: account_id
in: path
required: true
schema:
$ref: '#components/schemas/account_id'
- name: flight_session_uuid
in: path
description: flight session Id.
required: true
schema:
type: string
requestBody:
content:
multipart/form-data:
schema:
schema: flight_session_import_flight_media
required:
- media_uuid
- flight_uuid
- file
properties:
flight_uuid:
description: uuid for the flight
type: string
media_uuid:
description: uuid for the flight media
type: string
file:
description: flight media file for flight
type: file
format: binary
type: object
responses:
'403':
description: Access Denied
'401':
description: Unauthorized
'201':
description: Successful operation
/v1/account/{account_id}/flight-session-events:
post:
tags:
- Flight Sessions
summary: Create a flight event.
description: Create a flight event
operationId: 0a0dad4002e1671dda896ae36ab6c4f2
parameters:
- name: account_id
in: path
required: true
schema:
$ref: '#components/schemas/account_id'
- name: appends[]
in: query
description: array of model names
schema:
type: array
items:
description: A list of models to attach
type: string
enum:
- account
- flight_session
- user
requestBody:
content:
application/json:
schema:
$ref: '#components/schemas/flight_session_event'
responses:
'403':
description: Access Denied
'401':
description: Unauthorized
'200':
description: Successful operation
components:
securitySchemes:
Aloft Token:
type: http
name: Aloft Token
in: header
scheme: bearer