WebAPI:Galaxies

From Starsonata Wiki
(Difference between revisions)
Jump to: navigation, search
 
(One intermediate revision by one user not shown)
Line 1: Line 1:
 
This returns a list of all [[Galaxy|galaxies]] in the game that have been discovered or otherwise marked as public knowledge.
 
This returns a list of all [[Galaxy|galaxies]] in the game that have been discovered or otherwise marked as public knowledge.
 +
 +
==Parameters==
 +
<code>https://www.starsonata.com/webapi/galaxies/v1</code>
 +
 +
No parameters.
  
 
==Response==
 
==Response==

Latest revision as of 18:04, 9 November 2019

This returns a list of all galaxies in the game that have been discovered or otherwise marked as public knowledge.

Contents

Parameters

https://www.starsonata.com/webapi/galaxies/v1

No parameters.

Response

Returns an array galaxies with members keyed by their galaxy ID. Each galaxy has the following attributes.

  • ID - The galaxy ID. This is unique per galaxy in a universe.
  • name - The galaxy name.
  • lastUpdate - The last time the galaxy was updated in the api.
  • x - The x coordinate for the map.
  • y - The y coordinate for the map.
  • links - An array of galaxy IDs that this galaxy has wormholes leading to.
  • layer - The layer of the map that this galaxy resides in.
  • df - The df of the map that this galaxy resides in. This is on a slightly different scale and is 1/10th of the value you normally see in-game.
  • special - true if the galaxy is marked as "special".
  • anchor - true if the galaxy is marked as an anchor. This means that the map should render it in its own layer as well as layers of galaxies that it is linked to.
  • owningTeamID - The team ID of a Userteam that owns the galaxy. Use the teams api to get more details on the team.
  • owningTeam - The name of an ai team that owns the galaxy. Mutually exclusive with owningTeamID.
  • protected - true if the galaxy is protected by the team that owns it.
  • aibases - The number of aibases in the galaxy.
  • userbases - The number of userbasesin the galaxy.
  • mapable - false if the galaxy is not rendered on the normal map

The above values are trimmed if they are an empty string or false, with the exception of mapable which is trimmed if it is true.

Example

See Also

Development