Create fleet
POST
/api/v1/fleets/
const url = 'https://app.ayna.com/api/v1/fleets/';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"example","description":"example","base_location":"example","base_latitude":1,"base_longitude":1,"max_altitude_agl":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://app.ayna.com/api/v1/fleets/ \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "example", "description": "example", "base_location": "example", "base_latitude": 1, "base_longitude": 1, "max_altitude_agl": 1 }'Create a new fleet.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
FleetCreateRequest
object
Example generated
{ "name": "example", "description": "example", "base_location": "example", "base_latitude": 1, "base_longitude": 1, "max_altitude_agl": 1}Responses
Section titled “Responses”Created
Media typeapplication/json
Response
object
key
additional properties
any
Example generated
{}