Class: Freeports

Freeports

An api adapter over the end points handling public structures via functions in the universe ESI endpoints. You should not usually instantiate this directly as its constructor requires an internal api instance.

This is a function class so instances of Freeports are functions and can be invoked directly, besides accessing its members. Its default function action is equivalent to all.


new Freeports(agent)

Create a new Freeports function using the given agent.

Parameters:
Name Type Description
agent ESIAgent

The ESI agent

Methods


all()

List all public structures. This route is cached for up to 3600 seconds.

This makes an HTTP GET request to /universe/structures/. The route version is v1.

On success, this resolves to list of public structure IDs.

Returns:

A Promise that resolves to the parsed JSON of the response.

Type
Promise.<Array.<Number>>