Comment on page

Get All Flights

This API is used to retrieve all flight logs

API Key

Your API requests are authenticated using API keys. Any request that doesn't include an API key will return an error.
Key

Method

GET : get all the flight

HTTP Request

URL Parameters

Key
Description
searchString :
search by drone_id
startDate / fromDate :
get data between fromdate to todate
offset
fetch records from offsets
limit
fetch limited records

HTTP Response

Response codes explanation:
Code
Details
200
message: "ok" { response shown on right side }
400
request parameters missing
500
internal server error

Code Snippet

Take a look at how you might call this method using our official libraries, or via curl:
curl
JS
Python
curl GET " https://ags.aeromegh.com/Aeromegh/remoteMission/AllFlightsLogs/${droneId}/${fromDate}/${toDate}/${startIndex}/${pageSize}?type=${type} "
-H "Authorization: Bearer <API_key>"
-H "Content-Type: application/json"
-X GET
// require the myapi module and set it up with your API key
var myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer" <API_key>);
myHeaders.append("Cookie", "connect.sid=s%3AiUif6YWkEAACxZWF4clJNfd5xLkslRsg.dWqhvE3CVLHoEJ9wzpp7HlcKEnPfpKGub8nWCF%2BpIsU");
var requestOptions = {
method:"GET',
headers: myHeaders,
redirect :'follow'
};
fetch("https://ags.aeromegh.com/Aeromegh/remoteMission/AllFlightsLogs/%20/1000000000/1692602986154/0/8?type=null", requestOptions)
// Set your API key before making the request
import requests
url = " https://ags.aeromegh.com/Aeromegh/remoteMission/AllFlightsLogs/%20/1000000000/1692602986154/0/8?type=null"
payload = { }
headers = {
'Authorization' : 'Bearer' <API_key>,
'Cookie' : 'connect.sid=s%3AiUif6YWkEAACxZWF4clJNfd5xLkslRsg.dWqhvE3CVLHoEJ9wzpp7HlcKEnPfpKGub8nWCF%2BpIsU'
}
response = requests.request("GET", url, headers=headers, data=payload)

API Response

{
"logs": [
{
"id": "923dbb64-39e5-4751-88ad-4ef3496f4afa",
"project_name": "19_august",
"plan_name": "plan",
"user_id": "edb1bf33-0a01-4362-8474-e54e97873391",
"start_time": "2023-08-19T12:16:09.517
Z",
"end_time": "2023-08-19T12:18:20.335Z",
"drone_id": "P00001DESKTOP-E762V7V",
"streamkey": "u7igwaq1",
"stream_uploaded": true,
"title": null,
"stream_viewer_minutes": "0",
"status": "ended",
"last_activity": "2023-08-19T12:16:09.517Z",
"area_covered": "88",
"distance_covered": "44",
"customer_id": null
},
{
"id": "3603d5b5-6075-443e-9cd8-9abb3f2b987b",
"project_name": "19_august",
"plan_name": "plan",
"user_id": "edb1bf33-0a01-4362-8474-e54e97873391",
"start_time": "2023-08-19T11:55:33.428Z",
"end_time": "2023-08-19T12:09:03.067Z",
"drone_id": "P00001DESKTOP-E762V7V",
"streamkey": "7ojujceo",
"stream_uploaded": true,
"title": null,
"stream_viewer_minutes": "0",
"status": "ended",
"last_activity": "2023-08-19T11:55:33.428Z",
"area_covered": "4025",
"distance_covered": "2013",
"customer_id": null
}
],
"count": "67"
}

Response Parameter Details

  • id: Unique identifier of the log.
  • project_name: Name or title of the project.
  • plan_name: Name or identifier for a specific plan within a project.
  • user_id: Identifier for the user flight.
  • start_time: Timestamp indicating when a flight started.
  • end_time: Timestamp indicating when a flight ended.
  • drone_id: Unique identifier for the drone.
  • stream_key: Unique key associated with the drone's video stream.
  • stream_uploaded: Indicates if the stream has been successfully uploaded.
  • title: Title or label associated with this data.
  • stream_viewer_minutes: Total minutes of streaming viewed.
  • status: Current status of the flight.
  • last_activity: Timestamp of the last recorded activity.
  • area_covered: Area covered by a particular flight.
  • distance_covered: Distance covered by a particular flight.
  • customer_id: Identifier for the customer associated with this data.