EDCE: Elite Dangerous Companion Emulator.

Authors

Status
Active
Required software
Python
Compatible with release
Sources available
License
MIT
Supported languages
English en
Platform
GameApplication Linux GameApplication Mac GameApplication Windows
Elite:Dangerous Application

Share

This is an interface that emulates an iPhone accessing the Elite Dangerous Companion web API, which is normally used by a mobile application developed by Frontier Developments. This experimental code has not been created in association with Frontier Developments and is unsupported by them.

*This was published early 2015 before the API was officially allowed*
Elite Dangerous Companion Emulator (EDCE)

Everything mentioned in this post is a Good Thing™, and I encourage you to read it fully before voicing an opinion.

TL;DR
EDCE is a python script that securely retrieves your commander data from Frontier exactly like your iPhone would if you were using the Elite Dangerous Companion mobile app. It can also optionally post market data from where your commander is docked to EDDN.

Latest release
GitHub
EDCodex

Foreword (2016)
EDCE was meant as a proof-of-concept for other developers to learn how to use the Companion API, and to show FD how incredibly positive third-party apps can be when using the Companion API. As such this is why it’s not fully fleshed out comparatively to the other great tools out there.

With that in mind anyone else that wishes to become a collaborator to continue tweaking it, or turn it into a proper library for others to use, please do not hesitate to contact me.

*Begin historical documents*

Why?
Community developers have wanted access to game data since the earliest Alpha and Beta releases in order to produce cool tools that enhance the gaming experience for many commanders.

Initially, data was mined directly from the client, and this caused difficulties for Frontier: not only were there exploits, but it caused stability issues with the clients that strained their support capabilities. Frontier then obfuscated the client executable code and indicated to community developers that direct access to game data from the client would no longer be supported.

The first requests for an API (Application Programming Interface) where then made to Frontier for allowing game information to be extracted and processed by third-party tools. Frontier responded that it was an interesting idea, and that they would consider it in the future due to their limited resources.

Community developers have nevertheless continued to develop many incredible tools, using very difficult and unreliable techniques such as OCR (Optical Character Recognition) to access game information, to the great appreciation of commanders.

A thread was started by Frontier in January to collect ideas for an external API, which ran for 32 pages. However, to date, there are no definite plans by Frontier to develop this API in the near future. It is understood that their limited resources are fully dedicated to continue making a great game.

In the meantime Frontier released the Elite Dangerous Companion app for iPhones. This app uses SSL (Secure Sockets Layer) to retrieve commander data from a Frontier website using a Web-based API. All you need is the app and your Frontier store credentials, and you have access to your commander data.

Other developers and myself have contacted Frontier to see if they would allow community developers to use the Web API to extract game data for tool development. The response was that they do not have the resources to provide support for this approach, and that they would rather look at a real API when they will be able to.

Hence, in good faith, I am releasing the approach to access the Web API, with the undestanding that Frontier will not provide support for it. Hopefully, Frontier will tolerate its use by developers and commanders as long as it does not induce any extra effort on their part, affect the operation of their servers, and does not otherwise compromise their game.

What is in the data?
The same data as in the app. Commanders using this script do not have any more of an "advantage" over others than those using the Companion app. It just allows to access the data in a way to allow it to be stored and manipulated (e.g. commander's log for systems visited, etc.)

The data has a wealth of information about your commander that you can explore by viewing the logged data, namely:
 

  • Location
  • Ranks
  • Reputations
  • Credits
  • Systems visited
  • Full game stats (trade, combat, exploration, ...)
  • Current ship and loadout
  • Other ships and their locations
  • Last system visited and faction
  • Last station at which docked and faction
  • Last station market data and outfitting item availability
  • ..and more

Prerequisites
  • Runs on Windows, Linux and Mac OSX
  • Python 3.3+
  • You may need to install some modules if the script complains. Example, if "requests" is missing, run "pip3 install requests"
  • If you wish to obtain the source code, use git and use the command "git clone https://github.com/Andargor/edce-client.git"

 

Obtaining
Latest release

EDCE is open source and available on Github.

Installation

  • Unzip in any directory
  • Requirements:
  • - Python 3.3 or higher
  • - Python requests library: pip3 install requests
  • Run client-setup.py (use python3 client-setup.py on Linux and Mac)
  • Enter your Frontier store credentials (NOTE: The password is stored unencrypted in the edce.ini file. You can leave the password blank, however this means you will need to run the client in interactive mode and you will be prompted to enter the password every time)

Usage
EDCE is a really basic script that fetches your data, and optionally posts to EDDN. It needs to be manually executed every time you wish to fetch data.

There is a lot of information in the data, and community developers are free to write more sophisticated clients that uses this code. For example, if someone can figure out a way to determine when a commander is docked, then this can be automatically run at that time.
 
  • Run edce_client.py (use python3 edce_client on Linux and Mac)
  • The first time it is run, a verification code will be sent by Frontier to your account email. Enter it when prompted
  • If you have left either your Frontier store username or password empty, you will be prompted to enter it
  • The script will fetch your commander data, dump it to "last.json", and store it compressed in the "logs" directory. The data is in JSON format, which is machine-readable and marginally human readable. It is compressed (7-zip can read it)
  • Optionally, if you have enabled it, and if your commander is docked, it will post the current station market data to EDDN. No private information is sent.
  • You need to run the program manually every time you wish to fetch data (and post to EDDN)

Security
  • Protect your edce.ini file as it contains your Frontier store credentials in unencrypted form if you have not left them blank during setup
  • Your store credentials are transmitted in the same way the iPhone app does, using secure requests directly to Frontier, without any intermediaries. This communication is not logged.
  • This script has been developed as open source so that you may verify how your store credentials are handled

Other Notes
  • Avoid querying the Elite Dangerous Companion site too often in order to avoid overloading it. As a rule, try not to query more than once every 2-3 minutes.
  • By default, there is a 120 second delay imposed between queries.
  • The web API sometimes lags actual game state by several seconds. For example, you might dock, but only be able to post market data to EDDN after a few seconds until the web API catches up.
  • You can modify the code as you wish, the edce subdirectory contains the core module to access the Elite Dangerous Companion web API

 

Admin. On the 5th of January 2016, Zac Antonaci - Head of Community Management of FD - created a post in the "Open Letter to Frontier Developments" thread where he wrote that usage of the iPhone companion app api is LEGAL. Source. Hence the usage of tools which use this api like EDMC, EDAPI and EDCE is LEGAL.

 


Links

History

  • Jan 23, 2016 (wolverine2710) Complete overhaul of the entry. Basically the full description is now the OP text from the FD thread.
  • Jan 23, 2016 (wolverine2710) Added "admin" comment that FD declared (20160105) usage of the iPhone companion app api and tools which use it is LEGAL.
  • Jan 23, 2016 (wolverine2710) Added the new FD forum thread in the links section.
  • View more ...
  • Jan 23, 2016 (wolverine2710) Clarified that the reddit thread is archived.
  • Sep 29, 2015 (wolverine2710) Cleaned full desc. a bit. EDCE github pointed to EDAPI github: corrected.
  • Sep 29, 2015 (wolverine2710) Removed thread url+name: EDAPI: Elite Dangerous API Tool. With Trade Dangerous support. Pointed to EDAPI and NOT EDCE. Added thread url+name: EDCE: Elite Dangerous Companion Emulator
  • Aug 28, 2015 (wolverine2710) Tough call. Decided to remove category API. Not needed to make it show up in EDDN.
  • Aug 28, 2015 (wolverine2710) Added "Use an existing API": EDDN
  • Aug 28, 2015 (wolverine2710) Added category: API. This way it shows up as a tool sending data to EDDN.
  • Aug 4, 2015 (wolverine2710) Set platform: Windows, Mac, Linux. Set required software: Python
  • Jun 7, 2015 (wolverine2710) First revision

API used by this tool