Infinite Flight Live API

[Updated 12/08/2015]

Guys,

If you have no idea what HTTP Requests, json, xml, sockets, javascript, html are, basically, if you’re not a developer then move along, this topic if not for you

We’re bringing the Live API back!

URL: http://infinite-flight-public-api.cloudapp.net/v1/

Entry points:

  • GetSessionsInfo.aspx
    Use this call to get the current server list. This should be the 1st call you send.
    Parameters: apikey

  • Flights.aspx
    Use this call to get all current flights for specified server
    Parameters: apikey, sessionid, positionsonly [boolean as string]
    Notes: Use the positionsonly if you just want a quick overview of where traffic is

  • FlightDetails.aspx
    Use this call to get flight details
    Parameters: apikey, flightid

  • GetATCFacilities.aspx
    Use this call to get the list of active ATC Facilities for specified server
    Parameters: apikey, sessionid

  • UserDetails.aspx
    Use this call to get information about a user
    Parameters: apikey
    Post Request: a json object containing an array of strings named UserIDs.

  • GetFlightPlans.aspx
    Parameters: apikey, sessionid
    Data Format:

    [DataContract]
    public enum FlightPlanType
    {
    [EnumMember]
    VFR,
    [EnumMember]
    IFR
    }

    [DataContract]
    public class FlightPlanInfo
    {
    [DataMember]
    public Guid EntityID { get; set; } // Pilot ID

     [DataMember]
     public string[] Waypoints { get; set; }
    
     [DataMember]
     public FlightPlanType FlightPlanType { get; set; }
    
     /// <summary>
     /// Filed Altitude in Feet
     /// </summary>
     [DataMember]
     public int Altitude { get; set; }
    
     /// <summary>
     /// Filed Airspeed in KTS
     /// </summary>
     [DataMember]
     public int Speed { get; set; }
    
     [DataMember]
     public string DepartureAirportCode { get; set; }
    
     [DataMember]
     public string DestinationAirportCode { get; set; }
    
     [DataMember]
     public TimeSpan EstimatedTimeEnroute { get; set; }
    
     [DataMember]
     public String Remarks { get; set; }
    
     [DataMember]
     public DateTime DepartureTime { get; set; }
    
     [DataMember]
     public string[] AlternateDestinations { get; set; }
    
     [DataMember]
     public TimeSpan FuelOnBoard { get; set; }
    
     [DataMember]
     public Guid FlightID { get; set; }
    
     [DataMember]
     public DateTime LastUpdate { get; set; }
    

    }

Rules:

  • An API Key is required. Please contact us with your project idea to get an API key.
  • All apps are required to have a timeout feature if the app isn’t being used. We don’t want users to have the app running for hours if no-one is looking.
    So if no action is taken for 15 minutes, have your apps stop downloading new content unless the user presses a button. (FlightRadar24 does this on their site).
  • No permanent storing of data retrieved via the API is permitted. (You cannot keep the data in your own database) If you need additional functionality from the API, please contact us).

Please follow this or your app key will be deactivated. (when we have them in place)

This post will be updated to reflect API changes.

Let me know if you have any feedback!

Laura

45 Likes

I’m sorry, but for the first time in a very long time I have absolutely no idea what you’re talking about. What do we do with Live API?

2 Likes

It’s for developers who want to use the infinite flight data to make apps.

3 Likes

Does this mean that other developers will be able to make apps that show server status, pilot stats, etc…?

I’ve updated the post to help you out, 2nd line ;)

7 Likes

Okay seems cool. I guess that takes a little more knowledge. I’ve messed around with X-code for a few hours but I have no idea how to make apps.

So… are you done with the new app? This has been up for like 10 minutes, and no new update? Quit slacking man… ;)

7 Likes

My laptop is slow to boot.
About that, should I make a separate thread about my watcher app?

1 Like

Haha I’m always eager to learn! I’ve always wanted to know how to program apps. It would be fun to code an app for you guys but I have Zero brains in that field ;)

1 Like

Sure, knock yourself out

1 Like

Ooh…

Add me to your beta when you do ;)

1 Like

If anyone knows how to program for the Apple Watch, here you go!

Here is a picture that someone made of IFFG:
image

5 Likes

What is this JSON you speak of? ;)

Got to continue with my app soon and get it running even nicer than before :smile:
The ATC API seems interesting, I’m thinking favourite users/push notifications for when they come online… :)

1 Like

Yep, let me know if you need more data from the API :smile:

1 Like

One thing I’m interested in:

Querying GetATCFacilities returns objects like below:

{
   "FrequencyID":"27003edf-7d33-9588-e354-acf1681a3b76",
   "Latitude":33.0227432,
   "Longitude":-118.588486,
   "Name":"KNUC",
   "StartTime":"\/Date(1432012924870)\/",
   "Type":1,
   "UserID":"4b3d513a-9508-43a7-add9-cef38e7eafd6",
   "UserName":"Bob Bobberson"
}

I can position this on a map with lat/lng coordinates and name, however, is there any way we could query for the FrequencyID in order to get more info about it? Info such as frequency name, type, grouping, frequency… Cheers :)

1 Like

FrequencyID is a Guid generated from the FrequencyName+Type+FrequencyInteger

For now, you can use this as a ref for the Type item:
Ground = 0
Tower,
Unicom,
Clearance,
Approach,
Departure,
Center,
ATIS,
Aircraft,
Recorded,
Unknown,
Unused

If you want to find out exactly what it is, here’s how I generate the ID from the X-Plane Data:

// For Tower/Ground/Unicom
var fullFrequencyName = frequency.ICAO + frequency.FrequencyType.ToString() + frequency.IntegerFrequency.ToString();

// For Approach/Departire/Center, names are curated… and it’s difficult to post it here…
var fullFrequencyName = frequency.Name + frequency.FrequencyType.ToString() + frequency.IntegerFrequency.ToString();

// Generate the Guid from the frequency name
using (MD5 md5 = MD5.Create())
{
byte[] hash = md5.ComputeHash(Encoding.Default.GetBytes(fullFrequencyName));
return new Guid(hash);
}

5 Likes

I see, thanks! I’ll need to reparse my airport data… may fetch it all directly from the airports repo to have it up to date :smile:

I’ll find a way of parsing these IDs later!

@Swang007 If you are an android user, go here: Infinite Flight Live Tracker for Android

1 Like

By the way, talking about notifications…one thing that would be nice is for controllers to get a notification when lots of airplanes are in an area with no controllers on duty :)

2 Likes