Surdex Mobile Flight Report API

Tad Hurst

09/24/2020

Used with the Surdex Flight Report Mobile App for iPhone and Android.  This API loads the supporting data from the active projects in the Surdex database, and accepts the Flight Report data entered in the app.

Endpoints:

https:://.../

            GET:  returns this help page (HTML format)

 

https://.../Data

            GET: returns a JSON encoded list of data items, including events, Lines, stations, aircraft, sensors, risers, operators, and pilots.

 

https://.../Report

GET: (future) Could return a set of flight reports to load into a phone or tablet.

POST: takes the reports as recorded on the phone/tablet.  The body must be a JSON encoded list of 4 string, which are in turn JSON encoded list of:

      Report records,

      Line records,

      Message records

      Error Records

Example body:

[

    "[{\"IntDeviceFlightReportKey\":1,\"StrDevice\":\"\",\"StrModel\":\"\",\"IntAircraftId\":44,\"StrAircraftName\":\"Conquest 441 (SDX) N2NQ\",\"StrTailNum\":\"N2NQ\",\"StrSensorName\":\"DMC-148\",\"IntSensorId\":54,\"StrRiserName\":\"72582plate\",\"IntRiserId\":15,\"StrPilotName\":\"Cody Sivcovich\",\"IntPilotId\":1262,\"StrOperatorName\":\"Jason Pohlman\",\"IntOperatorId\":1222,\"StrDepartingAirport\":\"stl\",\"StrArrivingAirport\":\"san\",\"DtLoggingTime\":\"2020-09-21T12:03:28.217112\"},{\"IntDeviceFlightReportKey\":2,\"StrDevice\":\"\",\"StrModel\":\"\",\"IntAircraftId\":44,\"StrAircraftName\":\"Conquest 441 (SDX) N2NQ\",\"StrTailNum\":\"N2NQ\",\"StrSensorName\":\"Galaxy-5060314\",\"IntSensorId\":129,\"StrRiserName\":\"72582plate\",\"IntRiserId\":15,\"StrPilotName\":\"Cody Sivcovich\",\"IntPilotId\":1262,\"StrOperatorName\":\"Jason Pohlman\",\"IntOperatorId\":1222,\"StrDepartingAirport\":\"stl\",\"StrArrivingAirport\":\"san\",\"DtLoggingTime\":\"2020-09-21T15:25:47.891587\"},{\"IntDeviceFlightReportKey\":3,\"StrDevice\":\"\",\"StrModel\":\"\",\"IntAircraftId\":33,\"StrAircraftName\":\"Cessna 402 -ASI Co N2JJ\",\"StrTailNum\":\"N2JJ\",\"StrSensorName\":\"Galaxy-5060314\",\"IntSensorId\":129,\"StrRiserName\":\"441EHriser\",\"IntRiserId\":8,\"StrPilotName\":\"Gary Bryant\",\"IntPilotId\":1175,\"StrOperatorName\":\"Ian Gump\",\"IntOperatorId\":1255,\"StrDepartingAirport\":\"stl\",\"StrArrivingAirport\":\"san\",\"DtLoggingTime\":\"2020-09-21T21:46:38.445226\"}]",

    "[{\"IntLocalFlightReportLinesKey\":2,\"IntDeviceFlightReportKey\":0,\"StrArea\":\"AL_SLI_04_230\",\"lngProjectNumber\":3000505,\"IntLineNumber\":1,\"IntTurbulenceRating\":1,\"IntStartStationNumber\":null,\"IntEndStationNumber\":null,\"DtStartTime\":\"2020-09-21T15:26:49.49437\",\"DtEndTime\":null,\"DtLogTime\":\"2020-09-21T15:26:56.42088\",\"bHasStations\":true},{\"IntLocalFlightReportLinesKey\":3,\"IntDeviceFlightReportKey\":0,\"StrArea\":\"AL_SLI_04_230\",\"lngProjectNumber\":3000505,\"IntLineNumber\":1,\"IntTurbulenceRating\":1,\"IntStartStationNumber\":1,\"IntEndStationNumber\":3,\"DtStartTime\":\"2020-09-21T17:20:07.890467\",\"DtEndTime\":\"2020-09-21T17:20:09.845106\",\"DtLogTime\":\"2020-09-21T17:19:38.510592\",\"bHasStations\":true},{\"IntLocalFlightReportLinesKey\":4,\"IntDeviceFlightReportKey\":0,\"StrArea\":\"AL_SLI_04_230\",\"lngProjectNumber\":3000505,\"IntLineNumber\":1,\"IntTurbulenceRating\":3,\"IntStartStationNumber\":null,\"IntEndStationNumber\":null,\"DtStartTime\":\"2020-09-21T21:47:19.152982\",\"DtEndTime\":\"2020-09-21T21:47:20.599691\",\"DtLogTime\":\"2020-09-21T21:47:23.498268\",\"bHasStations\":true}]",

    "[{\"IntLocalFlightReportMessagesKey\":1,\"IntDeviceFlightReportKey\":0,\"DtTime\":\"2020-09-21T21:47:45.493624\",\"StrText\":\"tad test\",\"StrEvent\":\"General\",\"DtLogTime\":\"2020-09-21T21:48:00.276561\"}]",

    "[]"

]