Discussion Documentation?

I'm a bit new so I apologize if I just haven't found the proper links yet, but i'm struggling to find documentation for the API. I found the Journal Manual that's linked in the sticky here. But I can't seem to find any manuals or documentation for the API. (meaning, what's the URL? how do i get access? what are the available endpoints, etc)

I'm also a little confused, is the Companion API and edcd API the same thing? Do they just get their data from player submissions or do they get their data from a ED API of some sort? If so, am I allowed to access that ED API? (and again, docs?)

I link tinkering and developing scripts etc and would love to review the docs to see if any ideas pop up for fun things to do as companions for when i'm out there bussing VIP's back and forth...

Thanks for any help or clarification.
 
I'm also interested in finding this out, I'd like to get a feel for it so I can hopefully contribute to existing projects a bit.
 
The Companion API is not something that's supposed to be used by 3rd party applications, and as such it's not documented and can change at any time. It's been reverse engineered for some applications. The only "API" for data exfiltration that has official support is the journal.
 
Frontier have said that, although this isn't an "official" service, we are OK to use it providing we don't spam it with requests. Due to this however, it sometimes doesn't get updated after a major patch as a priority, but generally Frontier are pretty good at keeping it working. They do occasionally change the structure of the JSON responses, but that's usually to accommodate changes in the game or improve the API.

It's not documented, but it's not too difficult to figure out how it works if you're familiar with writing code that queries a web API - it's pretty standard stuff. Essentially, you're just making an HTTP call to a specific URL and getting a JSON object full of data back from it. I just downloaded one of the community applications available on here and ran it though Fiddler to see what it was doing, then coded something to do the same thing in my chosen language.

The root URL for the API is https://companion.orerve.net

Here's a high-level overview of the process you need to create in order to login and request data:-

1. Request /user/login with your normal ED credentials in the body of the request. If login is successful, you will get an email sent to the associated address with a confirmation code, otherwise it will throw you back to /user/login.
2. Request /user/confirm with the confirmation code in the body of the request to confirm and login. If you track the cookies correctly and store them for future requests to the API, you should not have to go through the login process each time, you can just re-query the endpoints below directly using the stored cookies as your authentication.

Here are the endpoints you can query for data (as far as I know so far anyway!):-

/profile - Returns commander data, including all of your ships and their fittings (always.)
/market - Returns station commodity data (when docked only.)
/shipyard - Returns shipyard and outfitting data (when docked only.)

As I mentioned earlier, the responses for each endpoint are JSON formatted, so you can easily load the response into an object and parse through it to extract each piece of data iteratively and do stuff with it. The only issue I had was managing and storing the cookies that you need to keep re-authenticating without having to do the whole login/confirmation code process each time, but that's what I get for writing my ED assistant in VBA I guess ;)
 
Last edited:
Thank you RoadRunner. That's extremely helpful, even though it's a lot more limited than I was hoping for.

No problem :)

I agree it seems a bit limited at first glance, but it's only one part of what we have to develop around for extracting data from the game. The API was originally intended to be used by Frontier's companion mobile app to download data, which I think has now been discontinued. The fact that the API is still running at all, let alone being constantly updated, is a testament to the community's tenacity in developing applications that use it and FD's commitment to promoting development around their game.

Relying solely on the API for gathering in game data isn't really enough to produce a useful companion application as it's only there to provide bulk dumps of large amounts of regularly changing data, like commodity prices and such. To get a fuller picture, you should also look into monitoring the netlog files in the game folder and the journal files too. Combining all these data sources together, you can extract:-

1. From the netlog file - Your current precise location, including the local system name, LY coordinates of the system, in system coordinates of your ship, and the body number of the closest celestial object.
2. From the journal files - Full information for just about any dynamic in-game action you perform with your ship (including, but not limited to, entering and exiting super-cruise/FSD, buying/selling to/from the markets, scanning objects/nav beacons, requesting docking permission, etc.) The journal can be very handy, so I'd recommend digesting the manual for it fully.
3. From the API - Up to the minute data on the prices and availability of just about every commodity, module, and ship from each station you visit.

They may not seem like much individually, but when combined, all this data can easily give you the ability to work out so many useful things:-

- Automatically populate a database with all data around a star, planet, or moon, including all its parameters, atmosphere, mineral content (if landable,) etc. You can even do this with no input from the user; just setup a routine to monitor the netlog and journal files for certain JSON entries and fly about collecting boat loads of data automatically!
- Where to make the most profit from trading based on commodity availability and margins.
- Work out how far away/apart things are and thus and how many jumps a navigation path will take (essentially you could pretty much write a whole a navigation computer if you wanted.)
- Locate the nearest sources of minerals, station services, ships, modules, etc.
- Design and test ship fittings and load outs.
- Upload and share the data you have personally captured in game to the wider community by connecting your application to the EDDB, thus providing a fuller experience for everyone who plays.

Tie all this together in a single application and, once you start cross-referencing the different sources of data and building up different ways to query the results, it can provide a very powerful game assistant.

I would highly recommend downloading some of the community developed applications on here and having a play with them if you want to see what's really possible though. Some of the stuff that's been achieved with the above combinations of data is quite remarkable, and far beyond what I've managed to achieve with a little archaic programming knowledge from back in the day and a copy of Access :)
 
Yea, i have since downloaded EDDI and have highly modified a number of the actions to give me a better fit for what I'm looking for. But one challenge I have really been trying to solve, is that I have no view into my currently plotted course (outside of the next hop from the nav panel). I really wish I could get a view into a multi-hop route so i can scan the mission and passenger boards to find paralleling routes/destinations.

I have looked a bit at both the journal and the net logs (though that's mostly been when troubleshooting connectivity issues... :( ) and i haven't seen anything for route planning/reporting. Have you seen any mods/sites that might get me a little closer there?
 
I'm not 100% sure what you're trying to achieve here as I've not looked at EDDI (I thought that was for voice commands,) but it sounds like you're wanting to see what missions are available in remote locations? This isn't possible as the mission boards are not static, which is why there is no mission information in the journal other than the ones you've actually accepted or completed - that's when they become "real" missions. You can't undock from a station and then re-dock and expect the boards to still be the same. Hell, I've even come out of the mission board to free up some cargo space in commodities, then gone back to it and it's changed completely in just a few seconds of being on a different screen!

You can build a route planner from the available information in the netlog and journal files, but you have to fly around and gather the coordinate data for the systems and stations yourself first, then write a routine to plan the routes from A to B in your application. There are a few route planner websites available online already, or you can just call EDDB's API if you want to avoid collecting the data yourself by parsing your game files. There are also locally installable community applications, like Trade Computer MKII, that do similar things. I use my application primarily to find the best trade routes, or decide which commodities to buy fill the remainder of my cargo hold when running missions, to get that extra bit of profit on top of the mission reward. It's also very useful for finding things in relation to where I am like engineering materials, specific station services, ships, modules, etc.

It's worth mentioning that ED is mostly a game where you have to be in (or have been in) a location to get detailed data for it - FD intentionally only provide limited information for things remotely so you have to fly there in person to collect the data in the first instance.
 
Last edited:
EDDI can work with that voice commands app (i forget the name), but i'm only using EDDI for it's EDSM integration and journal/API text to speech features. I have it call out system details during jumps, reads out planetary scan details when exploring, and provides me with fuel status if my scoop falls short of a full tank, etc.

And there's a slight misunderstanding of what i've been trying to solve with missions. I get that you can't see remote missions, that's not what i'm looking for. I'll step through it in a use-case;

A passenger has a sight seeing mission.
I pick up that mission and plot a course to the target system.
Before I leave that station (this is where the confusion was):
I would like to see my plotted course as a list of systems
I would like to then review the other passenger jobs and mission board to see if any of their destinations are along my plotted course.
Assuming i have picked up another mission with a destination along the way to my sight seeing destination,
while at that intermediary station, repeat the above, looking for passenger/mission destinations along my primary plotted route.

i'm just looking for a means to be more efficient at making full use of my journey on longer missions. (thanks for the continued replies)
 
Top Bottom