From ef2b329e076be9a6e979b9ac8d515326ee0cf9b1 Mon Sep 17 00:00:00 2001 From: Natalie Rose Date: Tue, 18 Aug 2026 21:06:22 +1000 Subject: [PATCH] Updates after fixing the largest issues in the api spec --- README.md | 167 +- lib/__utils__/validate-schema.ts | 21 +- lib/core/endpoint.ts | 2 +- lib/core/server.ts | 6 +- lib/core/util.test.ts | 3 + lib/core/util.ts | 4 +- lib/endpoints/body.test.ts | 7 +- lib/endpoints/body.ts | 2 - lib/endpoints/buildings/archaeology.test.ts | 2 +- lib/endpoints/buildings/entertainment.test.ts | 2 +- lib/endpoints/buildings/essentia-vein.test.ts | 2 +- lib/endpoints/buildings/essentia-vein.ts | 3 +- .../buildings/mercenaries-guild.test.ts | 7 +- lib/endpoints/buildings/observatory.test.ts | 8 +- lib/endpoints/buildings/park.test.ts | 5 +- lib/endpoints/buildings/trade.test.ts | 12 +- lib/endpoints/buildings/transporter.test.ts | 2 +- lib/endpoints/captcha.ts | 6 +- lib/endpoints/empire.test.ts | 41 +- lib/endpoints/empire.ts | 50 +- lib/endpoints/inbox.test.ts | 10 +- lib/endpoints/map.test.ts | 7 +- lib/endpoints/stats.test.ts | 88 +- lib/endpoints/stats.ts | 37 +- lib/lacuna.ts | 2 +- lib/types/building.ts | 8 +- lib/types/captcha.ts | 6 - lib/types/empire.ts | 15 +- lib/types/essentia-vein.ts | 12 +- lib/types/schema.ts | 2073 ++++++++++++++--- lib/types/stats.ts | 157 +- lib/types/trade.ts | 2 +- package-lock.json | 14 +- package.json | 2 +- 34 files changed, 2236 insertions(+), 549 deletions(-) diff --git a/README.md b/README.md index e4af1d2..0ed2595 100644 --- a/README.md +++ b/README.md @@ -8,123 +8,76 @@ This client's types are generated from `@tlecommunity/api-spec` (OpenAPI spec for the `/v2` Rails API) via `openapi-typescript` (`npm run generate:types` → `lib/types/schema.ts`). Where the spec conflicts with this client's existing, tested behavior, the tested behavior wins. Differences found so far, for -whoever owns the spec/backend: - -1. **`@tlecommunity/api-spec`'s own `package.json` is broken.** `main` points - to `./spec.json`, but the package only ships `./build/spec.json`. Codegen - here references the `build/` path directly. -2. **`/v2/empire/login` requires `empire_name`, not `name`**, and has no - `browser` field at all. The client keeps its public `LoginParams.name` / - `.browser` for backwards compatibility, mapping `name` → `empire_name` on - the wire and dropping `browser` entirely. -3. **Numeric ids are typed as `string` in every request body schema** - (`building_id`, `body_id`, `ship_id`, `spy_ids`, etc.), but the server - accepts (and this client sends) `number`. Kept as `number` throughout. -4. **Session-authenticated `/v2/...` endpoints currently reject every - session**, tried every way the spec documents: `Authorization: Token -` header, `session_id` in the body, both together, and with both a - freshly `/v2`-issued session and a legacy-issued one — all return - `{"error":{"code":1006,"message":"Session expired."}}`. The identical - call against the legacy (non-`/v2`) endpoint succeeds. Only - unauthenticated `/v2` endpoints (e.g. `login`, `captcha/fetch`) currently - work. This blocks real usage of any authenticated `/v2` endpoint until - fixed server-side — the client is built against `/v2` regardless, per - direction from the backend owner. -5. **No `stats`/`credits` module exists anywhere in the spec** (checked all - 1,157 paths across 139 modules). `stats.credits()` falls back to the - legacy JSON-RPC transport since there's no `/v2` equivalent. -6. **`/v2/body/get_status` takes no request body at all** — it returns - status for the session's current body, not a body picked by id. Its - OpenAPI description ("Returns information about the current state of the - empire") also looks copy-pasted from `empire/get_status`. The client - keeps `GetStatusParams.body_id` as a public param for compatibility but - doesn't send it on the wire. -7. **`empire.set_boost(type, weeks)` doesn't exist in `/v2`.** It's been - split into one method per boost type: `boost_food`, `boost_water`, - `boost_energy`, `boost_ore`, `boost_happiness`, `boost_building`, - `boost_spy_training`, `boost_storage`. The client keeps its existing - `setBoost({type, weeks})` signature and calls `boost_${type}` internally. -8. **`/v2/captcha/solve` fields are `captcha_guid`/`captcha_solution`**, not - `guid`/`solution` as the existing hand-written type has them. Mapped - internally; public param names unchanged. -9. **`/v2/essentiavein/drain`'s field is `building_id`** (snake_case), not - the existing hand-written type's `buildingId`. Mapped internally. -10. **`building.demolish`'s response has no `building` field** — only - `status`. The previous hand-written `DemolishResponse` incorrectly - claimed a `building` field; corrected to `{}`. -11. **`shipyard.buildShip`'s previous hand-written params didn't match any - real wire shape** (`building_ids: number[]`, `auto_select` — neither - exists on the wire). The real `/v2/shipyard/build_ship` takes - `{building_id, type, quantity}` (singular id, no `auto_select`); - corrected. `build_ships` (plural, batch build across shipyards) is a - separate method with a nested `options` object, and its response is - `{status}` only (no build-queue detail). -12. **There is no generic `/v2/building/*` path** — every building type has - its own module slug (`apple`, `shipyard`, `planetarycommand`, ...). - `planetarycommand` previously reused the bare generic `Building` class - even though it has 3 extra methods (`view_plans`, - `view_incoming_supply_chains`, `subsidize_pod_cooldown`) the generic - class doesn't have; it now gets its own subclass. -13. **Every building module shares 7 base methods** (`build`, `upgrade`, - `downgrade`, `demolish`, `repair`, `get_stats_for_level`, `view`), but - the previous hand-written `Building` base class only had 4 of them - (missing `build`, `repair`, `get_stats_for_level`) — added. - -Entries #14 onward were found while writing schema-validated tests for every -read-only method (see `lib/__utils__/validate-schema.ts`) that assert live -responses against the spec, rather than just spot-checking a couple of -fields. Most of these are handled automatically by that validator (spec-wide, -not per-endpoint) rather than one-off client code changes, since they're -systemic issues with how the spec describes the wire format: - -14. **`/v2/empire/get_status`'s response schema declares `required: ['empire', -'body']` but only defines `properties: {server, empire}`** — `body` is - required-but-undefined in the spec itself. -15. **Boolean-flag fields are typed `boolean` in the spec but the server - sends the IntBool convention (`0`/`1`)** used pervasively elsewhere in - this same API (e.g. `shipyard/get_buildable`'s `buildable.*.can`). -16. **`reason` fields hold either a `[code, message]` pair or the literal - number `0` for "no reason", but the spec inconsistently types them** - (`array` for `building.upgrade.reason`/`buildable.*.reason`, `string` - for `building.downgrade.reason`) - neither declared type matches both - real shapes. -17. **Fields of any shape — arrays, objects, and plain strings — are sent as - `null` instead of `[]`/`{}`/`""` when empty/absent** — a common Rails-ism - the spec never marks as nullable anywhere (e.g. `building.pending_build`, - `building.work`, `spaceport/get_fleet_for`'s `ships`, - `alliance/view_profile`'s `profile.description`). -18. **`/v2/mercenariesguild/get_spies`'s response never includes the - spec-required `cargo_space_used_each` field.** -19. **`/v2/observatory/get_probed_stars`'s star items are missing the - spec-required `z` coordinate, and some nested `bodies` entries are - missing the spec-required `water` field** — on essentially every array - item, which is why `expectMatchesApiSchema`'s `allowedErrors` supports - array-index-normalized `instancePath`s (e.g. `/stars/*`) rather than - requiring one entry per array index. -20. **`/v2/map/get_star_map`'s star items omit the spec-required `bodies` - field entirely** (rather than sending `[]`) when a star has no bodies. -21. **`/v2/map/view_laws` sends each law's description under a misspelled - key, `descripition` (sic), instead of the spec's `description`.** -22. **`/v2/park/view`'s `party` object is missing the spec-required - `seconds_remaining` and `happiness` fields** — only `can_throw` is ever - sent. -23. **`/v2/trade/view_waste_chains` sends the singular key `waste_chain`, - not the plural `waste_chains`** the spec (and this client's - `ViewWasteChainsResponse` type) declare. -24. **Several `/v2` endpoints documented in the spec return error 1002 - ("Method ... is not recognized by the v2 API's argument map")** — the +whoever owns the spec/backend. Everything below was re-verified against both +the spec and the live server as of `@tlecommunity/api-spec` 1.1.0; entries +resolved by that release (and the accompanying backend work) have been +removed. + +1. **Numeric ids are typed as `string` in every request body schema** + (`building_id`, `body_id`, `ship_id`, `spy_ids`, etc. - 1,208 of them), + but the server accepts (and this client sends) `number`. Kept as `number` + throughout. +2. **There is no generic `/v2/building/*` path** — every building type has + its own module slug (`apple`, `shipyard`, `planetarycommand`, ...), so the + generic `Building` class is only ever constructed with a concrete slug. + `planetarycommand` gets its own subclass because it has 3 methods the + generic class doesn't (`view_plans`, `view_incoming_supply_chains`, + `subsidize_pod_cooldown`). +3. **`shipyard/get_buildable`'s `buildable.*.can` is typed `boolean`** but + the server sends the IntBool convention (`0`/`1`) used pervasively + elsewhere in this same API - including, since 1.1.0, `building.can` and + `park.can_throw`. +4. **`reason` fields hold either a `[code, message]` pair, the empty string, + or the literal number `0` for "no reason", but the spec inconsistently + types them** (`array` for `building.upgrade.reason`/`buildable.*.reason`, + `string` for `building.downgrade.reason`) - neither declared type matches + every real shape. +5. **Fields of any shape — arrays, objects, and plain strings — are sent as + `null` instead of `[]`/`{}`/`""` when empty/absent** — a common Rails-ism + the spec marks as nullable in exactly one place + (`stats/empire_rank`'s `alliance_id`/`alliance_name`), and even there the + server sends a number rather than the declared `["string", "null"]`. +6. **The `buildings_list` component wraps the id-keyed building map in a + second `buildings` level.** It's `{buildings: {: {...}}}` but is + `$ref`'d _as_ the `buildings` property in 628 places, so the spec asks for + `result.buildings.buildings` where the server sends `result.buildings`. + Affects `body/get_buildings` and every `build`/`upgrade`/`downgrade`/ + `demolish`/`repair` response. New in 1.1.0. +7. **`/v2/map/get_star_map`'s star items omit the spec-required `bodies` + field entirely** (rather than sending `[]`) when a star has no bodies. +8. **`/v2/empire/boost_*` responses are the full `{boosts}` map**, exactly + like `view_boosts`, not the `{food_boost}`/`{ore_boost}`/... single-field + shape the spec declares for each. +9. **`/v2/stats/alliance_rank` errors on its own default sort.** Called with + no `sort_by` the server raises `Can't locate object method "influence +desc,population desc" via package Lacuna::DB::Result::Log::Alliance`; + every explicit `sort_by` value works. The spec documents `sort_by` as + optional, so this client's `AllianceRankParams` requires it. +10. **`building.demolish`'s response is documented but unverified.** The spec + says `{status, buildings}`; nothing here demolishes a building to check, + so `DemolishResponse` mirrors the spec on trust. +11. **Several `/v2` endpoints documented in the spec return error 1002** + ("Method ... is not recognized by the v2 API's argument map") — the backend migration off legacy Perl hasn't wired these routes up yet: `archaeology/get_ores_available_for_processing`, `trade/view_market`, `transporter/view_market`, and every `inbox/*` method (`view_inbox`, `view_archived`, `view_trashed`, `view_sent`, `view_unread`). Expected current backend state per CLAUDE.md, not a client bug - tests skip the - schema check (rather than fail) when this error is returned. -25. **`/v2/entertainment/get_lottery_voting_options` triggers a captcha + schema check (rather than fail) on that specific code, so they'll fail + once the route lands. +12. **`/v2/entertainment/get_lottery_voting_options` triggers a captcha challenge (error 1016).** The client surfaces the challenge to subscribers (see "Error handling" below) along with a retry callback, but it ships no captcha solver, so the test still skips rather than fails. +Most of #1, #3, #4 and #5 are handled automatically by the schema validator +behind the tests (`lib/__utils__/validate-schema.ts`) rather than by one-off +client code, since they're systemic issues with how the spec describes the +wire format. The rest are allowlisted per-call via `expectMatchesApiSchema`'s +fourth argument, which fails the test if an allowlisted error _stops_ +occurring — so a fix upstream surfaces here rather than going unnoticed. + # Error handling Calls never throw. Every endpoint method resolves to a `ServerResponse`: diff --git a/lib/__utils__/validate-schema.ts b/lib/__utils__/validate-schema.ts index cf269cc..ede176e 100644 --- a/lib/__utils__/validate-schema.ts +++ b/lib/__utils__/validate-schema.ts @@ -1,6 +1,14 @@ import Ajv2020, { ValidateFunction } from 'ajv/dist/2020'; import spec from '@tlecommunity/api-spec/build/spec.json'; +/** Applies the same widening as relaxKnownDivergences to a list of types. */ +function widenTypeList(types: string[]) { + const widened = new Set(types); + if (widened.has('string') || widened.has('boolean')) widened.add('number'); + if (widened.has('string') || widened.has('array') || widened.has('object')) widened.add('null'); + return [...widened]; +} + /** * Widens the compiled spec, spec-wide, to tolerate a handful of systemic, * already-observed divergences between what @tlecommunity/api-spec declares @@ -32,6 +40,11 @@ import spec from '@tlecommunity/api-spec/build/spec.json'; * spec doesn't mark as nullable anywhere. Every `"type": "array"`, * `"type": "object"`, or `"type": "string"` node is widened to also * accept `null`. + * + * The same widening applies to nodes that already declare a *list* of types + * (the spec's one nullable field, `stats/empire_rank`'s `alliance_id`, is + * `["string", "null"]` and arrives as a number), so a type list containing + * `"string"` or `"boolean"` picks up `"number"` too. */ function relaxKnownDivergences(node: unknown, key?: string): unknown { if (Array.isArray(node)) return node.map((n) => relaxKnownDivergences(n)); @@ -48,6 +61,7 @@ function relaxKnownDivergences(node: unknown, key?: string): unknown { else if (next.type === 'boolean') next.type = ['boolean', 'number']; else if (next.type === 'array') next.type = ['array', 'null']; else if (next.type === 'object') next.type = ['object', 'null']; + else if (Array.isArray(next.type)) next.type = widenTypeList(next.type as string[]); return next; } @@ -58,10 +72,9 @@ function relaxKnownDivergences(node: unknown, key?: string): unknown { const relaxedSpec = relaxKnownDivergences(structuredClone(spec)); const ajv = new Ajv2020({ - // The spec has real bugs (e.g. empire/get_status's `required: ['body']` - // with no matching `body` in `properties`) - strict mode would throw at - // *compile* time instead of surfacing them as an ordinary, allowlistable - // validation error. + // The spec has real bugs (e.g. the `buildings_list` component's extra + // wrapping `buildings` level) - strict mode would throw at *compile* time + // instead of surfacing them as an ordinary, allowlistable validation error. strict: false, allErrors: true, }); diff --git a/lib/core/endpoint.ts b/lib/core/endpoint.ts index a574ec2..c302fe0 100644 --- a/lib/core/endpoint.ts +++ b/lib/core/endpoint.ts @@ -12,7 +12,7 @@ abstract class Endpoint { return this.lacuna.server.call({ module: this.url, method, params, addSession: false }); } - /** For RPC methods with no /v2 equivalent in the spec. See Server#callLegacy. */ + /** For RPC methods with no working /v2 equivalent. See Server#callLegacy. */ callLegacyWithSession(method: string, params: any) { return this.lacuna.server.callLegacy({ module: this.url, method, params, addSession: true }); } diff --git a/lib/core/server.ts b/lib/core/server.ts index 77b5ad8..297ce2b 100644 --- a/lib/core/server.ts +++ b/lib/core/server.ts @@ -95,8 +95,10 @@ class Server { } /** - * Fallback for RPC methods with no /v2 equivalent in the spec (e.g. - * stats.credits). Hits the legacy non-/v2 JSON-RPC endpoint directly. + * Fallback for RPC methods with no working /v2 equivalent. Hits the legacy + * non-/v2 JSON-RPC endpoint directly. No endpoint in this library uses it + * any more - it's kept as an escape hatch for the /v2 methods the backend + * migration hasn't wired up yet (see README "Spec Discrepancies"). */ async callLegacy(options: ServerRequest, attempt = 0): Promise> { this.lacuna.log.info('Calling (legacy)', `${options.module}/${options.method}`, options.params); diff --git a/lib/core/util.test.ts b/lib/core/util.test.ts index 1cf405e..093c4e3 100644 --- a/lib/core/util.test.ts +++ b/lib/core/util.test.ts @@ -86,6 +86,9 @@ test('util.fixNumbers', () => { expect(util.fixNumbers({ foo: [{ bar: '1.1.1' }] })).toStrictEqual({ foo: [{ bar: '1.1.1' }] }); expect(util.fixNumbers(1)).toBe(1); expect(util.fixNumbers('ok')).toBe('ok'); + // A top-level array stays an array (stats/credits returns one). + expect(util.fixNumbers([{ bar: '100' }])).toStrictEqual([{ bar: 100 }]); + expect(util.fixNumbers(['100', 'ok'])).toStrictEqual([100, 'ok']); }); test('util.ensureTrailingSlash', () => { diff --git a/lib/core/util.ts b/lib/core/util.ts index bd56143..287ee9c 100644 --- a/lib/core/util.ts +++ b/lib/core/util.ts @@ -162,7 +162,9 @@ const handleObj = function (obj: any): any { export const fixNumbers = function (data: any): any { if (_.isNumber(data) || _.isString(data)) return data; - return _.mapValues(data, handleObj); + // handleObj rather than _.mapValues: mapValues turns a top-level array + // (stats/credits is one) into an object keyed by its indices. + return handleObj(data); }; export const ensureTrailingSlash = (url: string) => (url.slice(-1) === '/' ? url : `${url}/`); diff --git a/lib/endpoints/body.test.ts b/lib/endpoints/body.test.ts index 0397894..791e2ea 100644 --- a/lib/endpoints/body.test.ts +++ b/lib/endpoints/body.test.ts @@ -15,7 +15,12 @@ beforeAll(async () => { test('getBuildings', async () => { const { result } = await lacuna.body.getBuildings({ body_id: empire.home_planet_id }); expect(result?.buildings).toBeDefined(); - expectMatchesApiSchema('body', 'get_buildings', result); + // Spec bug: the `buildings_list` component wraps the id-keyed map in a + // second `buildings` level, so the spec asks for `result.buildings.buildings` + // where the server sends `result.buildings`. See README "Spec Discrepancies". + expectMatchesApiSchema('body', 'get_buildings', result, [ + { keyword: 'required', instancePath: '/buildings' }, + ]); }); test('rearrangeBuildings', async () => { diff --git a/lib/endpoints/body.ts b/lib/endpoints/body.ts index ac1e039..98b65d5 100644 --- a/lib/endpoints/body.ts +++ b/lib/endpoints/body.ts @@ -17,8 +17,6 @@ class Body extends Endpoint { } getStatus(params: B.GetStatusParams) { - // /v2/body/get_status takes no request params on the wire (returns status - // for the session's current body) - see README "Spec Discrepancies". return this.callWithSession('get_status', params); } diff --git a/lib/endpoints/buildings/archaeology.test.ts b/lib/endpoints/buildings/archaeology.test.ts index 92cf811..ac0d114 100644 --- a/lib/endpoints/buildings/archaeology.test.ts +++ b/lib/endpoints/buildings/archaeology.test.ts @@ -62,7 +62,7 @@ test('getOresAvailableForProcessing', async () => { building_id: buildingId, }); - if (error) { + if (error?.code === 1002) { // Live server currently returns 1002 "Method ... is not recognized by // the v2 API's argument map" for this call, even though it's documented // in @tlecommunity/api-spec - the backend migration hasn't wired this diff --git a/lib/endpoints/buildings/entertainment.test.ts b/lib/endpoints/buildings/entertainment.test.ts index 37ba978..738678a 100644 --- a/lib/endpoints/buildings/entertainment.test.ts +++ b/lib/endpoints/buildings/entertainment.test.ts @@ -50,7 +50,7 @@ test('getLotteryVotingOptions', async () => { building_id: buildingId, }); - if (error) { + if (error?.code === 1016) { // The live server responds to this call by requesting a captcha (code // 1016). The client surfaces that to subscribers via Lacuna#onResponse // with a retry callback, but ships no captcha solver, so nothing here diff --git a/lib/endpoints/buildings/essentia-vein.test.ts b/lib/endpoints/buildings/essentia-vein.test.ts index a2826eb..af720f4 100644 --- a/lib/endpoints/buildings/essentia-vein.test.ts +++ b/lib/endpoints/buildings/essentia-vein.test.ts @@ -43,7 +43,7 @@ test('getStatsForLevel', async () => { }); test('drain', async () => { - const { error } = await lacuna.essentiaVein.drain({ buildingId: 123456789, times: 123456789 }); + const { error } = await lacuna.essentiaVein.drain({ building_id: 123456789, times: 123456789 }); expect(error).toBeDefined(); expect(error?.code).toEqual(expect.any(Number)); diff --git a/lib/endpoints/buildings/essentia-vein.ts b/lib/endpoints/buildings/essentia-vein.ts index 729b910..e8cf658 100644 --- a/lib/endpoints/buildings/essentia-vein.ts +++ b/lib/endpoints/buildings/essentia-vein.ts @@ -8,8 +8,7 @@ class EssentiaVein extends Building { } drain(params: EV.DrainParams) { - const body: EV.DrainRequestBody = { building_id: params.buildingId, times: params.times }; - return this.callWithSession('drain', body); + return this.callWithSession('drain', params); } } diff --git a/lib/endpoints/buildings/mercenaries-guild.test.ts b/lib/endpoints/buildings/mercenaries-guild.test.ts index d9cdc4c..0f150bf 100644 --- a/lib/endpoints/buildings/mercenaries-guild.test.ts +++ b/lib/endpoints/buildings/mercenaries-guild.test.ts @@ -52,12 +52,7 @@ test('getSpies', async () => { const { result } = await lacuna.mercenariesGuild.getSpies({ building_id: buildingId }); expect(result?.spies).toBeDefined(); - // Spec bug: live server never sends `cargo_space_used_each` on this - // response even though the spec marks it required. See README "Spec - // Discrepancies" #18. - expectMatchesApiSchema('mercenariesguild', 'get_spies', result, [ - { keyword: 'required', instancePath: '' }, - ]); + expectMatchesApiSchema('mercenariesguild', 'get_spies', result); }); test('viewMarket', async () => { diff --git a/lib/endpoints/buildings/observatory.test.ts b/lib/endpoints/buildings/observatory.test.ts index 482c01f..9d33b33 100644 --- a/lib/endpoints/buildings/observatory.test.ts +++ b/lib/endpoints/buildings/observatory.test.ts @@ -49,13 +49,7 @@ test('getProbedStars', async () => { const { result } = await lacuna.observatory.getProbedStars({ building_id: buildingId }); expect(result?.stars).toBeDefined(); - // Spec bugs: every star item is missing the spec-required `z` coordinate, - // and some nested `bodies` entries (asteroids/gas giants) are missing the - // spec-required `water` field. See README "Spec Discrepancies" #19. - expectMatchesApiSchema('observatory', 'get_probed_stars', result, [ - { keyword: 'required', instancePath: '/stars/*' }, - { keyword: 'required', instancePath: '/stars/*/bodies/*' }, - ]); + expectMatchesApiSchema('observatory', 'get_probed_stars', result); }); // abandonProbe / abandonAllProbes mutate probe state (they release a probed diff --git a/lib/endpoints/buildings/park.test.ts b/lib/endpoints/buildings/park.test.ts index f80a48b..898c6b5 100644 --- a/lib/endpoints/buildings/park.test.ts +++ b/lib/endpoints/buildings/park.test.ts @@ -22,10 +22,7 @@ test('view', async () => { expect(result?.building).toBeDefined(); expect(result?.building.name).toBe('Park'); - // Spec bug: the live response's `party` object only has `can_throw` - it's - // missing the spec-required `seconds_remaining` and `happiness` fields. - // See README "Spec Discrepancies" #22. - expectMatchesApiSchema('park', 'view', result, [{ keyword: 'required', instancePath: '/party' }]); + expectMatchesApiSchema('park', 'view', result); }); test('getStatsForLevel', async () => { diff --git a/lib/endpoints/buildings/trade.test.ts b/lib/endpoints/buildings/trade.test.ts index b4524f9..6c54184 100644 --- a/lib/endpoints/buildings/trade.test.ts +++ b/lib/endpoints/buildings/trade.test.ts @@ -54,7 +54,7 @@ test('viewMarket', async () => { // client bug). See README "Spec Discrepancies" #24. const { result, error } = await lacuna.trade.viewMarket({ building_id: buildingId }); - if (error) { + if (error?.code === 1002) { console.warn( 'Skipping schema check: trade/view_market is not yet implemented by the live server', error @@ -158,14 +158,8 @@ test('viewWasteChains', async () => { const { result } = await lacuna.trade.viewWasteChains({ building_id: buildingId }); - // Spec bug: the live server sends the singular key `waste_chain`, not the - // plural `waste_chains` the spec (and this client's - // ViewWasteChainsResponse type) declares - so the typed `waste_chains` - // field is always undefined here. See README "Spec Discrepancies" #23. - expect((result as unknown as { waste_chain: unknown })?.waste_chain).toBeDefined(); - expectMatchesApiSchema('trade', 'view_waste_chains', result, [ - { keyword: 'required', instancePath: '' }, - ]); + expect(result?.waste_chain).toBeDefined(); + expectMatchesApiSchema('trade', 'view_waste_chains', result); }); test('getPrisoners', async () => { diff --git a/lib/endpoints/buildings/transporter.test.ts b/lib/endpoints/buildings/transporter.test.ts index c0f4687..d1b89af 100644 --- a/lib/endpoints/buildings/transporter.test.ts +++ b/lib/endpoints/buildings/transporter.test.ts @@ -102,7 +102,7 @@ test('viewMarket', async () => { // client bug). See README "Spec Discrepancies" #24. const { result, error } = await lacuna.transporter.viewMarket({ building_id: buildingId }); - if (error) { + if (error?.code === 1002) { console.warn( 'Skipping schema check: transporter/view_market is not yet implemented by the live server', error diff --git a/lib/endpoints/captcha.ts b/lib/endpoints/captcha.ts index 5449911..53cc425 100644 --- a/lib/endpoints/captcha.ts +++ b/lib/endpoints/captcha.ts @@ -17,11 +17,7 @@ class Captcha extends Endpoint { } solve(params: C.SolveParams) { - const body: C.SolveRequestBody = { - captcha_guid: params.guid, - captcha_solution: params.solution, - }; - return this.callWithSession('solve', body); + return this.callWithSession('solve', params); } } diff --git a/lib/endpoints/empire.test.ts b/lib/endpoints/empire.test.ts index 192931a..a7f73b7 100644 --- a/lib/endpoints/empire.test.ts +++ b/lib/endpoints/empire.test.ts @@ -6,7 +6,7 @@ test('login with errors', async () => { const lacuna = new Lacuna(); const { error } = await lacuna.empire.login({ - name: 'non-existant-empire', + empire_name: 'non-existant-empire', password: 'incorrect-password', browser: 'todo', api_key: 'anonymous', @@ -20,7 +20,7 @@ test('login with errors', async () => { test('login', async () => { const lacuna = new Lacuna(); const { result } = await lacuna.empire.login({ - name: 'nataliethistime', + empire_name: 'nataliethistime', password: '1234qwer', browser: 'todo', api_key: 'anonymous', @@ -63,22 +63,31 @@ test('getStatus', async () => { expect(result?.empire).toBeDefined(); expect(result?.server).toBeDefined(); expect(result?.empire.name).toBe('nataliethistime'); - // Spec bug: /v2/empire/get_status's response schema lists `required: - // ['empire', 'body']` but only defines `properties: {server, empire}` - - // `body` is required-but-undefined in the spec itself. See README "Spec - // Discrepancies" #14. - expectMatchesApiSchema('empire', 'get_status', result, [ - { keyword: 'required', instancePath: '' }, - ]); + expectMatchesApiSchema('empire', 'get_status', result); }); -test('setBoost', async () => { - const lacuna = await getLacuna(); - - const { error } = await lacuna.empire.setBoost({ type: 'invalidtype', weeks: -0 }); - - expect(error).toBeDefined(); - expect(error?.code).toEqual(expect.any(Number)); +// Every boost costs 5 essentia per week bought, so these deliberately call +// without a session rather than actually buying anything. The server checks +// its argument map *before* the session, so a "session expired" (1006) - and +// not a "method not recognized" (1002) - is what proves the method name is +// one the server actually serves. +describe.each([ + ['boostFood'], + ['boostWater'], + ['boostEnergy'], + ['boostOre'], + ['boostHappiness'], + ['boostBuilding'], + ['boostSpyTraining'], + ['boostStorage'], +] as const)('%s', (method) => { + test('is a method the server recognises', async () => { + const lacuna = new Lacuna(); + + const { error } = await lacuna.empire[method]({ weeks: 1 }); + + expect(error?.code).toBe(1006); + }); }); test('fetchCaptcha', async () => { diff --git a/lib/endpoints/empire.ts b/lib/endpoints/empire.ts index ecdb60d..6e4f623 100644 --- a/lib/endpoints/empire.ts +++ b/lib/endpoints/empire.ts @@ -25,27 +25,47 @@ class Empire extends Endpoint { } login(params: E.LoginParams) { - // `browser` has no wire equivalent under /v2/empire/login - see README - // "Spec Discrepancies". Kept as a public param for backwards compatibility. - const body: E.LoginRequestBody = { - empire_name: params.name, - password: params.password, - api_key: params.api_key, - }; - return this.callWithoutSession('login', body); + return this.callWithoutSession('login', params); } logout() { return this.callWithSession('logout', {}); } - setBoost(params: E.BoostParams) { - // v2 splits the legacy single `set_boost(type, weeks)` method into one - // method per boost type (`boost_food`, `boost_ore`, ...) - see README - // "Spec Discrepancies". - return this.callWithSession(`boost_${params.type}`, { - weeks: params.weeks, - }); + // There is no single `set_boost(type, weeks)` method - the API has one method + // per boost type. Each costs 5 essentia per week bought, and each responds + // with the whole boost map, exactly like `view_boosts`. + + boostFood(params: E.BoostParams = {}) { + return this.callWithSession('boost_food', params); + } + + boostWater(params: E.BoostParams = {}) { + return this.callWithSession('boost_water', params); + } + + boostEnergy(params: E.BoostParams = {}) { + return this.callWithSession('boost_energy', params); + } + + boostOre(params: E.BoostParams = {}) { + return this.callWithSession('boost_ore', params); + } + + boostHappiness(params: E.BoostParams = {}) { + return this.callWithSession('boost_happiness', params); + } + + boostBuilding(params: E.BoostParams = {}) { + return this.callWithSession('boost_building', params); + } + + boostSpyTraining(params: E.BoostParams = {}) { + return this.callWithSession('boost_spy_training', params); + } + + boostStorage(params: E.BoostParams = {}) { + return this.callWithSession('boost_storage', params); } } diff --git a/lib/endpoints/inbox.test.ts b/lib/endpoints/inbox.test.ts index cebe3f0..37c13de 100644 --- a/lib/endpoints/inbox.test.ts +++ b/lib/endpoints/inbox.test.ts @@ -20,7 +20,7 @@ beforeAll(async () => { test('viewInbox', async () => { const { result, error } = await lacuna.inbox.viewInbox({}); - if (error) { + if (error?.code === 1002) { console.warn('Skipping schema check: inbox/view_inbox errored on the live server', error); return; } @@ -33,7 +33,7 @@ test('viewInbox', async () => { test('viewArchived', async () => { const { result, error } = await lacuna.inbox.viewArchived({}); - if (error) { + if (error?.code === 1002) { console.warn('Skipping schema check: inbox/view_archived errored on the live server', error); return; } @@ -46,7 +46,7 @@ test('viewArchived', async () => { test('viewTrashed', async () => { const { result, error } = await lacuna.inbox.viewTrashed({}); - if (error) { + if (error?.code === 1002) { console.warn('Skipping schema check: inbox/view_trashed errored on the live server', error); return; } @@ -59,7 +59,7 @@ test('viewTrashed', async () => { test('viewSent', async () => { const { result, error } = await lacuna.inbox.viewSent({}); - if (error) { + if (error?.code === 1002) { console.warn('Skipping schema check: inbox/view_sent errored on the live server', error); return; } @@ -72,7 +72,7 @@ test('viewSent', async () => { test('viewUnread', async () => { const { result, error } = await lacuna.inbox.viewUnread({}); - if (error) { + if (error?.code === 1002) { console.warn('Skipping schema check: inbox/view_unread errored on the live server', error); return; } diff --git a/lib/endpoints/map.test.ts b/lib/endpoints/map.test.ts index 042939a..375d850 100644 --- a/lib/endpoints/map.test.ts +++ b/lib/endpoints/map.test.ts @@ -110,10 +110,5 @@ test('viewLaws', async () => { const { result } = await lacuna.map.viewLaws({ star_id: star.id }); expect(result?.laws).toBeDefined(); - // Spec bug: the live server sends each law's description under a - // misspelled key, `descripition` (sic), instead of the spec-required - // `description`. See README "Spec Discrepancies" #21. - expectMatchesApiSchema('map', 'view_laws', result, [ - { keyword: 'required', instancePath: '/laws/*' }, - ]); + expectMatchesApiSchema('map', 'view_laws', result); }); diff --git a/lib/endpoints/stats.test.ts b/lib/endpoints/stats.test.ts index c8f122b..54d769a 100644 --- a/lib/endpoints/stats.test.ts +++ b/lib/endpoints/stats.test.ts @@ -1,4 +1,5 @@ import { getLacuna } from '../__utils__/get-lacuna'; +import { expectMatchesApiSchema } from '../__utils__/validate-schema'; test('credits', async () => { const lacuna = await getLacuna(); @@ -6,5 +7,90 @@ test('credits', async () => { const { result } = await lacuna.stats.credits(); expect(result).toBeDefined(); - expect(result!['0']['Game Design']).toStrictEqual(['JT Smith', 'Jamie Vrbsky']); + expect(result![0]['Game Design']).toStrictEqual(['JT Smith', 'Jamie Vrbsky']); + expectMatchesApiSchema('stats', 'credits', result); +}); + +test('empireRank', async () => { + const lacuna = await getLacuna(); + + const { result } = await lacuna.stats.empireRank(); + + expect(result?.empires.length).toBeGreaterThan(0); + expect(result?.total_empires).toEqual(expect.any(Number)); + expect(result?.page_number).toEqual(expect.any(Number)); + expectMatchesApiSchema('stats', 'empire_rank', result); +}); + +test('findEmpireRank', async () => { + const lacuna = await getLacuna(); + + const { result } = await lacuna.stats.findEmpireRank({ + sort_by: 'empire_size_rank', + empire_name: 'nataliethistime', + }); + + expect(result?.empires[0].empire_name).toBe('nataliethistime'); + expectMatchesApiSchema('stats', 'find_empire_rank', result); +}); + +test('allianceRank', async () => { + const lacuna = await getLacuna(); + + // `sort_by` is optional per the spec, but the server's own default sort + // errors out - see README "Spec Discrepancies". + const { result } = await lacuna.stats.allianceRank({ sort_by: 'average_empire_size_rank' }); + + expect(result?.alliances.length).toBeGreaterThan(0); + expect(result?.total_alliances).toEqual(expect.any(Number)); + expectMatchesApiSchema('stats', 'alliance_rank', result); +}); + +test('allianceRank with the default sort', async () => { + const lacuna = await getLacuna(); + + const { error } = await lacuna.stats.allianceRank({} as never); + + // Documents the server-side bug the test above works around: with no + // `sort_by` the ranking blows up inside Lacuna::RPC::Stats. + expect(error).toBeDefined(); +}); + +test('findAllianceRank', async () => { + const lacuna = await getLacuna(); + + const { result } = await lacuna.stats.findAllianceRank({ + sort_by: 'average_empire_size_rank', + alliance_name: 'Sluts United', + }); + + expect(result?.alliances[0].alliance_name).toBe('Sluts United'); + expectMatchesApiSchema('stats', 'find_alliance_rank', result); +}); + +test('colonyRank', async () => { + const lacuna = await getLacuna(); + + const { result } = await lacuna.stats.colonyRank(); + + expect(result?.colonies.length).toBeGreaterThan(0); + expectMatchesApiSchema('stats', 'colony_rank', result); +}); + +test('spyRank', async () => { + const lacuna = await getLacuna(); + + const { result } = await lacuna.stats.spyRank(); + + expect(result?.spies.length).toBeGreaterThan(0); + expectMatchesApiSchema('stats', 'spy_rank', result); +}); + +test('weeklyMedalWinners', async () => { + const lacuna = await getLacuna(); + + const { result } = await lacuna.stats.weeklyMedalWinners(); + + expect(result?.winners.length).toBeGreaterThan(0); + expectMatchesApiSchema('stats', 'weekly_medal_winners', result); }); diff --git a/lib/endpoints/stats.ts b/lib/endpoints/stats.ts index 9c2304e..50d1aaa 100644 --- a/lib/endpoints/stats.ts +++ b/lib/endpoints/stats.ts @@ -2,7 +2,7 @@ import Lacuna from '../lacuna'; import Endpoint from '../core/endpoint'; import * as S from '../types/stats'; -class Empire extends Endpoint { +class Stats extends Endpoint { lacuna: Lacuna; url: string; @@ -12,10 +12,37 @@ class Empire extends Endpoint { this.url = url; } - credits() { - // No /v2/stats module exists in the spec - see README "Spec Discrepancies". - return this.callLegacyWithSession('credits', []); + credits(params: S.CreditsParams = {}) { + return this.callWithSession('credits', params); + } + + empireRank(params: S.EmpireRankParams = {}) { + return this.callWithSession('empire_rank', params); + } + + findEmpireRank(params: S.FindEmpireRankParams) { + return this.callWithSession('find_empire_rank', params); + } + + allianceRank(params: S.AllianceRankParams) { + return this.callWithSession('alliance_rank', params); + } + + findAllianceRank(params: S.FindAllianceRankParams) { + return this.callWithSession('find_alliance_rank', params); + } + + colonyRank(params: S.ColonyRankParams = {}) { + return this.callWithSession('colony_rank', params); + } + + spyRank(params: S.SpyRankParams = {}) { + return this.callWithSession('spy_rank', params); + } + + weeklyMedalWinners(params: S.WeeklyMedalWinnersParams = {}) { + return this.callWithSession('weekly_medal_winners', params); } } -export default Empire; +export default Stats; diff --git a/lib/lacuna.ts b/lib/lacuna.ts index 37cb997..03b45d4 100644 --- a/lib/lacuna.ts +++ b/lib/lacuna.ts @@ -213,7 +213,7 @@ class Lacuna { async authenticate(name: string, password: string) { const { result, error } = await this.empire.login({ - name, + empire_name: name, password, api_key: this.config.apiKey, browser: this.config.fingerprintToken, diff --git a/lib/types/building.ts b/lib/types/building.ts index fba2d90..ab36b56 100644 --- a/lib/types/building.ts +++ b/lib/types/building.ts @@ -1,3 +1,4 @@ +import { BuildingSummary } from './body'; import { ServerDate } from '.'; export interface Building { @@ -109,7 +110,12 @@ export interface DemolishParams { building_id: number; } -export interface DemolishResponse {} +export interface DemolishResponse { + /** Untested - no test demolishes a building. Shape per @tlecommunity/api-spec. */ + buildings: { + [index: string]: BuildingSummary; + }; +} export interface BuildParams { body_id: number; diff --git a/lib/types/captcha.ts b/lib/types/captcha.ts index 9e18eee..513bf32 100644 --- a/lib/types/captcha.ts +++ b/lib/types/captcha.ts @@ -10,10 +10,4 @@ export interface SolveParams { solution: string; } -/** Wire shape for POST /v2/captcha/solve - see README "Spec Discrepancies". */ -export interface SolveRequestBody { - captcha_guid: string; - captcha_solution: string; -} - export interface SolveResponse {} diff --git a/lib/types/empire.ts b/lib/types/empire.ts index 3c4fd78..beff1e4 100644 --- a/lib/types/empire.ts +++ b/lib/types/empire.ts @@ -31,7 +31,7 @@ export interface ViewBoostsResult { } export interface BoostParams { - type: string; + /** The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; } @@ -50,20 +50,11 @@ export interface FetchCaptchaResponse { } export interface LoginParams { - name: string; - password: string; - api_key: string; - browser: string; -} - -/** - * Wire shape for POST /v2/empire/login - field is `empire_name` not `name`, - * and there is no `browser` field at all. See README "Spec Discrepancies". - */ -export interface LoginRequestBody { empire_name: string; password: string; api_key: string; + /** Optional client identifier recorded against the session. */ + browser?: string; } export interface LoginResponse { diff --git a/lib/types/essentia-vein.ts b/lib/types/essentia-vein.ts index 20325fa..402b710 100644 --- a/lib/types/essentia-vein.ts +++ b/lib/types/essentia-vein.ts @@ -1,14 +1,12 @@ import { Building } from './building'; export interface DrainParams { - buildingId: number; - times: number; -} - -/** Wire shape for POST /v2/essentiavein/drain - field is `building_id`, not `buildingId`. */ -export interface DrainRequestBody { building_id: number; - times: number; + /** + * Number of 30-day periods to drain in a single call. Each period instantly + * provides 30 essentia instead of 4/day over 30 days. Defaults to 1. + */ + times?: number; } export interface DrainResponse { diff --git a/lib/types/schema.ts b/lib/types/schema.ts index 9b33535..f72eee3 100644 --- a/lib/types/schema.ts +++ b/lib/types/schema.ts @@ -54,6 +54,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -123,6 +124,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -184,6 +186,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -244,6 +247,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -305,6 +309,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -520,6 +525,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -589,6 +595,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -650,6 +657,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -710,6 +718,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -771,6 +780,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1128,6 +1138,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1197,6 +1208,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1258,6 +1270,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1318,6 +1331,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1379,6 +1393,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1594,6 +1609,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1663,6 +1679,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1724,6 +1741,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1784,6 +1802,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -1845,6 +1864,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -2060,6 +2080,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -2129,6 +2150,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -2190,6 +2212,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -2250,6 +2273,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -2311,6 +2335,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3130,6 +3155,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3199,6 +3225,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3260,6 +3287,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3320,6 +3348,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3381,6 +3410,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3596,6 +3626,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3665,6 +3696,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3726,6 +3758,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3786,6 +3819,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -3847,6 +3881,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4062,6 +4097,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4131,6 +4167,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4192,6 +4229,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4252,6 +4290,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4313,6 +4352,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4528,6 +4568,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4597,6 +4638,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4658,6 +4700,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4718,6 +4761,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4779,6 +4823,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -4994,6 +5039,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5063,6 +5109,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5124,6 +5171,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5184,6 +5232,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5245,6 +5294,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5460,6 +5510,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5529,6 +5580,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5590,6 +5642,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5650,6 +5703,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -5711,6 +5765,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -6206,7 +6261,13 @@ export interface paths { path?: never; cookie?: never; }; - requestBody?: never; + requestBody?: { + content: { + 'application/json': { + body_id: string; + }; + }; + }; responses: { /** @description Returns information about the current state of the empire. */ 200: { @@ -6276,28 +6337,7 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - /** @description Keyed by building id. */ - buildings: { - [key: string]: { - name: string; - x: number; - y: number; - url: string; - level: number; - image: string; - efficiency: number; - pending_build?: { - seconds_remaining: number; - start: string; - end: string; - }; - work?: { - seconds_remaining: number; - start: string; - end: string; - }; - }; - }; + buildings: components['schemas']['buildings_list']; body: { surface_image: string; }; @@ -6362,28 +6402,7 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - /** @description Keyed by building id. */ - buildings: { - [key: string]: { - name: string; - x: number; - y: number; - url: string; - level: number; - image: string; - efficiency: number; - pending_build?: { - seconds_remaining: number; - start: string; - end: string; - }; - work?: { - seconds_remaining: number; - start: string; - end: string; - }; - }; - }; + buildings: components['schemas']['buildings_list']; body: { surface_image: string; }; @@ -6942,6 +6961,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7011,6 +7031,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7072,6 +7093,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7132,6 +7154,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7193,6 +7216,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7408,6 +7432,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7477,6 +7502,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7538,6 +7564,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7598,6 +7625,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7659,6 +7687,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7874,6 +7903,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -7943,6 +7973,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8004,6 +8035,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8064,6 +8096,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8125,6 +8158,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8423,9 +8457,9 @@ export interface paths { content: { 'application/json': { /** @description Must match the guid from fetch. */ - captcha_guid: string; + guid: string; /** @description The user's typed solution. */ - captcha_solution: string; + solution: string; }; }; }; @@ -8511,6 +8545,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8580,6 +8615,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8641,6 +8677,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8701,6 +8738,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8762,6 +8800,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -8977,6 +9016,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9046,6 +9086,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9107,6 +9148,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9167,6 +9209,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9228,6 +9271,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9443,6 +9487,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9512,6 +9557,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9573,6 +9619,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9633,6 +9680,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9694,6 +9742,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9909,6 +9958,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -9978,6 +10028,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10039,6 +10090,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10099,6 +10151,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10160,6 +10213,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10375,6 +10429,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10444,6 +10499,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10505,6 +10561,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10565,6 +10622,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10626,6 +10684,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10841,6 +10900,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10910,6 +10970,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -10971,6 +11032,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11031,6 +11093,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11092,6 +11155,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11307,6 +11371,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11376,6 +11441,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11437,6 +11503,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11497,6 +11564,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11558,6 +11626,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11773,6 +11842,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11842,6 +11912,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11903,6 +11974,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -11963,6 +12035,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12024,6 +12097,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12239,6 +12313,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12308,6 +12383,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12369,6 +12445,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12429,6 +12506,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12490,6 +12568,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12774,6 +12853,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12843,6 +12923,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12904,6 +12985,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -12964,6 +13046,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13025,6 +13108,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13240,6 +13324,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13309,6 +13394,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13370,6 +13456,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13430,6 +13517,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13491,6 +13579,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13706,6 +13795,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13775,6 +13865,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13836,6 +13927,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13896,6 +13988,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -13957,6 +14050,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14172,6 +14266,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14241,6 +14336,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14302,6 +14398,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14362,6 +14459,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14423,6 +14521,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14638,6 +14737,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14707,6 +14807,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14768,6 +14869,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14828,6 +14930,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -14889,6 +14992,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -15317,6 +15421,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -15386,6 +15491,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -15447,6 +15553,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -15507,6 +15614,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -15568,6 +15676,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -16004,6 +16113,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -16073,6 +16183,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -16134,6 +16245,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -16194,6 +16306,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -16255,6 +16368,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -17598,12 +17712,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The name of the empire to search for. */ name: string; }; }; }; responses: { - /** @description Returns a 1 if the name is available, or a throws an exception if it is not. */ + /** @description Returns a 1 if the name is available, or throws an exception if it is not. Throws 1000. */ 200: { headers: { [name: string]: unknown; @@ -17652,7 +17767,7 @@ export interface paths { }; requestBody?: never; responses: { - /** @description Ends a session. Returns 1. */ + /** @description Ends a session. Returns 1. Throws 1006. */ 200: { headers: { [name: string]: unknown; @@ -17702,14 +17817,22 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The name of the empire. */ empire_name: string; - password: Record; + /** + * Format: password + * @description The password to authenticate to the empire. + */ + password: string; + /** @description Your client's unique API key, identifying it from all other clients. See ApiKeys for details. */ api_key: string; + /** @description Optional client identifier recorded against the session. Not part of the original API documentation. */ + browser?: string; }; }; }; responses: { - /** @description Returns a session ID with empire and server status */ + /** @description Confirms the password matches the empire and returns a session id alongside the empire and server status. A session survives up to 2 hours of inactivity, so there is no need to log in again while an existing session is still valid. Throws 1004 and 1005. */ 200: { headers: { [name: string]: unknown; @@ -17816,18 +17939,29 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The name of the empire to create. */ name: string; - password: string; - password1: string; + /** @description The password to log in to the empire. Must be between 6 and 30 characters. Required unless you have a valid facebook_uid and facebook_token, and still recommended even when authenticating through Facebook. */ + password?: string; + /** @description Retyping the password again. This must match password to succeed. Required whenever password is supplied. */ + password1?: string; + /** @description Must match the guid field returned by the fetch_captcha method. */ captcha_guid: string; + /** @description The text typed in by the user as the solution of the captcha. */ captcha_solution: string; + /** @description The user's email address. Not required, but used for system vital functions like password recovery. */ email?: string; + /** @description A Facebook user id passed in through Lacuna's Facebook integration system. Optional, but required alongside facebook_token. */ + facebook_uid?: string; + /** @description A Facebook access token passed in through Lacuna's Facebook integration system. Optional, but required alongside facebook_uid. */ + facebook_token?: string; + /** @description A 36 character code that was sent to the user by a friend. Usable only once, it ensures that their friend gets a home planet in relatively close proximity to their own. */ invite_code?: string; }; }; }; responses: { - /** @description Creates a new empire and then returns an empire_id. */ + /** @description Creates a new empire and returns its empire_id. The empire is not playable yet — either call update_species and then found, or skip the species step and call found directly. Throws 1000, 1001, 1002, and 1014. On a 1014 the error data carries fresh captcha information that must be used for the next attempt, since a captcha cannot be used more than once. */ 200: { headers: { [name: string]: unknown; @@ -17876,14 +18010,17 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The empire to found. */ empire_id: string; + /** @description Your client's unique API key, identifying it from all other clients. See ApiKeys for details. */ api_key: string; + /** @description Deprecated here. Pass invite_code to the create method instead. */ invite_code?: string; }; }; }; responses: { - /** @description Set up an empire on it's new home world. Once this method is called, the species can no longer be modified. */ + /** @description Sets up an empire on its new home world. Once this method is called, the species can no longer be modified. The returned welcome_message_id identifies an inbox message that starts the tutorial, so the user can be prompted to read it right away. */ 200: { headers: { [name: string]: unknown; @@ -17921,7 +18058,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/empire/get_friend_invite_url': { + '/v2/empire/get_invite_friend_url': { parameters: { query?: never; header?: never; @@ -17995,13 +18132,15 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The email address of your friend, or a comma separated string of email addresses. */ email: string; + /** @description An optional message the user can type to invite their friend. Defaults to "I'm having a great time with this new game called Lacuna Expanse. Come play with me." The empire name, friend code, and server URI are appended to whatever is sent. */ custom_message?: string; }; }; }; responses: { - /** @description Send an invitation code to a friend so that they can start in the same zone as your empire. */ + /** @description Sends an invitation code to a friend so that they can start in the same zone as your empire. Each not_sent entry pairs the address with the [code, message] reason it could not be invited. */ 200: { headers: { [name: string]: unknown; @@ -18060,7 +18199,7 @@ export interface paths { }; requestBody?: never; responses: { - /** @description Returns information about the current state of the empire. */ + /** @description Returns information about the current state of the empire. You should probably never call this directly — it is a wasted call, since the same data comes back in the status block of every relevant request. Throws 1002. */ 200: { headers: { [name: string]: unknown; @@ -18070,7 +18209,7 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - server?: components['schemas']['server_status']; + server: components['schemas']['server_status']; empire: components['schemas']['empire_status']; }; }; @@ -18124,7 +18263,18 @@ export interface paths { profile: { description: string; status_message: string; - medals: unknown; + /** @description Keyed by medal id. */ + medals: { + [key: string]: { + name: string; + image: string; + /** Format: date-time */ + date: string; + /** @enum {integer} */ + public: 1 | 0; + times_earned: number; + }; + }; city: string; country: string; notes: string; @@ -18205,50 +18355,102 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The properties to be edited. Set one or all of them — only those set will be updated. */ profile: { + /** @description A description of the empire. Limited to 1024 characters and cannot contain < or >. */ description?: string; + /** @description A message to indicate what you're doing, how you're feeling, or other status indicator. Limited to 100 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ status_message?: string; + /** @description The ids of the medals the user wishes to display in the public profile. */ public_medals?: number[]; + /** @description The city in which the player resides. Limited to 100 characters and cannot contain @, &, <, >, or ;. */ city?: string; + /** @description The country in which the player resides. Limited to 100 characters and cannot contain @, &, <, >, or ;. */ country?: string; + /** @description A text blob where the user can write down whatever they want to store in their account. Limited to 1024 characters and cannot contain @, &, <, >, or ;. */ notes?: string; + /** @description The username this player uses on Skype. Limited to 100 characters and cannot contain @, &, <, >, or ;. */ skype?: string; + /** @description The real name or online identity of this player. Limited to 100 characters and cannot contain @, &, <, >, or ;. */ player_name?: string; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages about unhappy citizens. WARNING: these messages are there for your own protection — turn them off at your own risk. + * @enum {integer} + */ skip_happiness_warnings?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages about a lack of resources to keep buildings running. WARNING: these messages are there for your own protection — turn them off at your own risk. + * @enum {integer} + */ skip_resource_warnings?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages about excess waste causing pollution. WARNING: these messages are there for your own protection — turn them off at your own risk. + * @enum {integer} + */ skip_pollution_warnings?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages about the medals they've earned. + * @enum {integer} + */ skip_medal_messages?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop messages being posted to their Facebook wall. + * @enum {integer} + */ skip_facebook_wall_posts?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages when excavators find nothing. + * @enum {integer} + */ skip_found_nothing?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages when excavators find resources. + * @enum {integer} + */ skip_excavator_resources?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages when excavators find glyphs. + * @enum {integer} + */ skip_excavator_glyph?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages when excavators find plans. + * @enum {integer} + */ skip_excavator_plan?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving spy recovery messages ("I'm ready to work. What do you need from me?"). + * @enum {integer} + */ skip_spy_recovery?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages when a probe is detected. + * @enum {integer} + */ skip_probe_detected?: 1 | 0; - /** @enum {integer} */ + /** + * @description Defaults to 0. Set to 1 to stop receiving messages about attacks. + * @enum {integer} + */ skip_attack_messages?: 1 | 0; - /** @enum {integer} */ + /** + * @description Controls the display of incoming ships (own, allied, foreign) on the map display. Defaults to 0, which shows them. Set to 1 to hide them, which can improve browser responsiveness. + * @enum {integer} + */ skip_incoming_ships?: 1 | 0; - /** Format: email */ + /** + * Format: email + * @description An email address that can be used for system functions like password recovery. Must either resemble an email address or be empty. + */ email?: string; + /** @description A password that can be safely given to account sitters and alliance members. Must be between 6 and 30 characters. */ sitter_password?: string; }; }; }; }; responses: { - /** @description Edits properties of an empire. Returns the view_profile method. See also the view_profile and view_public_profile methods. */ + /** @description Edits properties of an empire. Returns the same payload as view_profile. Only the properties present in the request are updated. See also the view_profile and view_public_profile methods. Throws 1005 and 1009. */ 200: { headers: { [name: string]: unknown; @@ -18261,7 +18463,18 @@ export interface paths { profile: { description: string; status_message: string; - medals: unknown; + /** @description Keyed by medal id. */ + medals: { + [key: string]: { + name: string; + image: string; + /** Format: date-time */ + date: string; + /** @enum {integer} */ + public: 1 | 0; + times_earned: number; + }; + }; city: string; country: string; notes: string; @@ -18342,12 +18555,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The id of the empire for which you'd like to retrieve the public profile. */ empire_id: number; }; }; }; responses: { - /** @description Provides a list of data that is publicly known about this empire */ + /** @description Provides a list of the data that's publicly known about this empire. Throws 1002. */ 200: { headers: { [name: string]: unknown; @@ -18360,12 +18574,16 @@ export interface paths { profile: { city: string; description: string; + /** @description Keyed by medal id. */ medals: { - '{medal_id}'?: { - date: string; - times_earned: number; + [key: string]: { name: string; image: string; + /** Format: date-time */ + date: string; + /** @enum {integer} */ + public: 1 | 0; + times_earned: number; }; }; player_name: string; @@ -18468,14 +18686,17 @@ export interface paths { requestBody?: { content: { 'application/json': { - empire_id: number; - empire_name: string; - email: string; + /** @description The unique id of the empire to recover. Choose one of empire_id, empire_name, or email. */ + empire_id?: number; + /** @description The full name of the empire. Choose one of empire_id, empire_name, or email. */ + empire_name?: string; + /** @description The email address associated with an empire. Choose one of empire_id, empire_name, or email. */ + email?: string; }; }; }; responses: { - /** @description Starts a password recovery process by sending an email with a recovery key. */ + /** @description Starts a password recovery process by sending an email with a recovery key. Identify the empire by exactly one of empire_id, empire_name, or email. */ 200: { headers: { [name: string]: unknown; @@ -18527,9 +18748,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description A key that was emailed to the user via the send_password_reset_message method. */ reset_key: number; + /** @description The password to log in to the empire. Must be between 6 and 30 characters. */ password1: string; + /** @description Retyping the password again. This must match password1 to succeed. */ password2: string; + /** @description Your client's unique API key, identifying it from all other clients. See ApiKeys for details. */ api_key: string; }; }; @@ -18591,7 +18816,9 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The password to log in to the empire. Must be between 6 and 30 characters. */ password1: string; + /** @description Retyping the password again. This must match password1 to succeed. */ password2: string; }; }; @@ -18652,6 +18879,7 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The name you're searching for. Case insensitive, and partial names work fine. Must be at least 3 characters. */ name: string; }; }; @@ -18716,6 +18944,7 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description A message to indicate what you're doing, how you're feeling, or other status indicator. Limited to 100 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ message: string; }; }; @@ -18775,7 +19004,7 @@ export interface paths { }; requestBody?: never; responses: { - /** @description Shows the dates boosts have expired or will expire */ + /** @description Shows the dates at which boosts have expired or will expire. Boosts are subsidies applied to various resources using essentia. */ 200: { headers: { [name: string]: unknown; @@ -18848,12 +19077,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { - /** @description Spends 5 essentia, and boosts storage (all 5 types) on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. */ + /** @description Spends 5 essentia, and boosts storage (all 5 types) on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -18910,11 +19140,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { + /** @description Spends 5 essentia, and boosts food production on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -18971,11 +19203,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { + /** @description Spends 5 essentia, and boosts water production on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -19032,11 +19266,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { + /** @description Spends 5 essentia, and boosts energy production on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -19093,11 +19329,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { + /** @description Spends 5 essentia, and boosts ore production on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -19154,11 +19392,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { + /** @description Spends 5 essentia, and boosts happiness production on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -19215,11 +19455,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { + /** @description Spends 5 essentia, and boosts build queues on all planets for 7 days. If a boost is already underway, calling again will add 7 more days. It will not boost builds already under way, only new builds added to a build queue. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -19276,11 +19518,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description Optional. The number of 7 day boost periods to buy at once, at 5 essentia each. Defaults to 1. */ weeks?: number; }; }; }; responses: { + /** @description Spends 5 essentia, and boosts spy training speed on all planets by 50% for 7 days. If a boost is already underway, calling again will add 7 more days. Unlike the other boosts, this one also boosts spies already in specialist training. Throws 1011. */ 200: { headers: { [name: string]: unknown; @@ -19390,7 +19634,7 @@ export interface paths { }; requestBody?: never; responses: { - /** @description Disables the self distruction countdown. */ + /** @description Disables the self destruction countdown. */ 200: { headers: { [name: string]: unknown; @@ -19445,6 +19689,7 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description A 36 character string that was sent to the user via email. */ code: string; }; }; @@ -19506,29 +19751,46 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The id of the empire you wish to update a species for. */ empire_id: string; + /** @description The species definition. Every field except name and description is an integer, and those integers must add up to exactly 45. */ params: { + /** @description The name of the species. Limited to 30 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ name: string; + /** @description The species description. Limited to 1024 characters and cannot contain < or >. */ description: string; + /** @description The closest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be less than or equal to max_orbit. */ min_orbit: number; + /** @description The furthest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be greater than or equal to min_orbit. */ max_orbit: number; + /** @description 7 is best. Determines advantages in manufactured goods, such as ships. */ manufacturing_affinity: number; + /** @description 7 is best. Determines advantages in spying. */ deception_affinity: number; + /** @description 7 is best. Determines advantages in upgrading buildings. */ research_affinity: number; + /** @description 7 is best. Determines advantages in the speed of building. */ management_affinity: number; + /** @description 7 is best. Determines advantages in food production. */ farming_affinity: number; + /** @description 7 is best. Determines advantages in mineral production. */ mining_affinity: number; + /** @description 7 is best. Determines advantages in energy, propulsion, and other technologies. */ science_affinity: number; + /** @description 7 is best. Determines advantages in waste and water management. */ environmental_affinity: number; + /** @description 7 is best. Determines advantages in managing population happiness. */ political_affinity: number; + /** @description 7 is best. Determines advantages in freight handling. */ trade_affinity: number; + /** @description 7 is best. Determines advantages in colonization. */ growth_affinity: number; }; }; }; }; responses: { - /** @description Updates the species definition for an empire that hasn't been founded yet. Returns 1. */ + /** @description Updates the empire's species and returns 1. Can only be called after create and before found; calling it outside that window throws an exception. Use redefine_species for an empire that has already been founded, and see get_species_templates for ready-made starting points. Throws 1000, 1002, 1005, 1007, 1008, 1009, and 1010 — the error data names the field that needs adjusting whenever the problem can be attributed to a single field. */ 200: { headers: { [name: string]: unknown; @@ -19577,7 +19839,7 @@ export interface paths { }; requestBody?: never; responses: { - /** @description Returns the limits that apply if the empire wants to redefine its species. */ + /** @description Returns the extra limits placed upon an empire that wants to redefine its species, including the essentia cost, the settable orbit range, the minimum growth affinity, and whether a redefinition is currently allowed at all. */ 200: { headers: { [name: string]: unknown; @@ -19639,28 +19901,44 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The species definition, same as the params of update_species. Every field except name and description is an integer, and those integers must add up to exactly 45. */ params: { + /** @description The name of the species. Limited to 30 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ name: string; + /** @description The species description. Limited to 1024 characters and cannot contain < or >. */ description: string; + /** @description The closest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be less than or equal to max_orbit. */ min_orbit: number; + /** @description The furthest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be greater than or equal to min_orbit. */ max_orbit: number; + /** @description 7 is best. Determines advantages in manufactured goods, such as ships. */ manufacturing_affinity: number; + /** @description 7 is best. Determines advantages in spying. */ deception_affinity: number; + /** @description 7 is best. Determines advantages in upgrading buildings. */ research_affinity: number; + /** @description 7 is best. Determines advantages in the speed of building. */ management_affinity: number; + /** @description 7 is best. Determines advantages in food production. */ farming_affinity: number; + /** @description 7 is best. Determines advantages in mineral production. */ mining_affinity: number; + /** @description 7 is best. Determines advantages in energy, propulsion, and other technologies. */ science_affinity: number; + /** @description 7 is best. Determines advantages in waste and water management. */ environmental_affinity: number; + /** @description 7 is best. Determines advantages in managing population happiness. */ political_affinity: number; + /** @description 7 is best. Determines advantages in freight handling. */ trade_affinity: number; + /** @description 7 is best. Determines advantages in colonization. */ growth_affinity: number; }; }; }; }; responses: { - /** @description Redefines the species of an already-founded empire. */ + /** @description Spends essentia to redefine the empire's species affinities, name, and description. Only usable after the empire has been founded — use update_species during empire creation instead. See also redefine_species_limits. WARNING: once this is done it cannot be redone for 1 month, so make sure the user is aware and prompt them appropriately before submitting. */ 200: { headers: { [name: string]: unknown; @@ -19714,7 +19992,7 @@ export interface paths { }; requestBody?: never; responses: { - /** @description Returns the empire's original species attributes. */ + /** @description Returns the stats associated with the empire's species as it was originally created. An empire can only view its own species stats through this method. */ 200: { headers: { [name: string]: unknown; @@ -19725,20 +20003,35 @@ export interface paths { jsonrpc?: string; result?: { species: { + /** @description The name of the species. Limited to 30 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ name: string; + /** @description The species description. Limited to 1024 characters and cannot contain < or >. */ description: string; + /** @description The closest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be less than or equal to max_orbit. */ min_orbit: number; + /** @description The furthest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be greater than or equal to min_orbit. */ max_orbit: number; + /** @description 7 is best. Determines advantages in manufactured goods, such as ships. */ manufacturing_affinity: number; + /** @description 7 is best. Determines advantages in spying. */ deception_affinity: number; + /** @description 7 is best. Determines advantages in upgrading buildings. */ research_affinity: number; + /** @description 7 is best. Determines advantages in the speed of building. */ management_affinity: number; + /** @description 7 is best. Determines advantages in food production. */ farming_affinity: number; + /** @description 7 is best. Determines advantages in mineral production. */ mining_affinity: number; + /** @description 7 is best. Determines advantages in energy, propulsion, and other technologies. */ science_affinity: number; + /** @description 7 is best. Determines advantages in waste and water management. */ environmental_affinity: number; + /** @description 7 is best. Determines advantages in managing population happiness. */ political_affinity: number; + /** @description 7 is best. Determines advantages in freight handling. */ trade_affinity: number; + /** @description 7 is best. Determines advantages in colonization. */ growth_affinity: number; }; status: { @@ -19785,7 +20078,7 @@ export interface paths { }; requestBody?: never; responses: { - /** @description Returns the list of pre-defined species templates available when founding an empire. */ + /** @description Returns the list of species templates that can be used to help the user populate the form for update_species. */ 200: { headers: { [name: string]: unknown; @@ -19795,20 +20088,35 @@ export interface paths { id?: number; jsonrpc?: string; result?: { + /** @description The name of the species. Limited to 30 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ name: string; + /** @description The species description. Limited to 1024 characters and cannot contain < or >. */ description: string; + /** @description The closest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be less than or equal to max_orbit. */ min_orbit: number; + /** @description The furthest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be greater than or equal to min_orbit. */ max_orbit: number; + /** @description 7 is best. Determines advantages in manufactured goods, such as ships. */ manufacturing_affinity: number; + /** @description 7 is best. Determines advantages in spying. */ deception_affinity: number; + /** @description 7 is best. Determines advantages in upgrading buildings. */ research_affinity: number; + /** @description 7 is best. Determines advantages in the speed of building. */ management_affinity: number; + /** @description 7 is best. Determines advantages in food production. */ farming_affinity: number; + /** @description 7 is best. Determines advantages in mineral production. */ mining_affinity: number; + /** @description 7 is best. Determines advantages in energy, propulsion, and other technologies. */ science_affinity: number; + /** @description 7 is best. Determines advantages in waste and water management. */ environmental_affinity: number; + /** @description 7 is best. Determines advantages in managing population happiness. */ political_affinity: number; + /** @description 7 is best. Determines advantages in freight handling. */ trade_affinity: number; + /** @description 7 is best. Determines advantages in colonization. */ growth_affinity: number; }[]; }; @@ -19910,18 +20218,27 @@ export interface paths { requestBody?: { content: { 'application/json': { - /** @enum {integer} */ + /** + * @description If true, all allies are automatically selected. + * @enum {integer} + */ allied?: 1 | 0; + /** @description The name of another alliance, all of whom are automatically selected. */ alliance?: string; + /** @description The id of another alliance, all of whom are automatically selected. */ alliance_id?: string; + /** @description The ids and/or names of specific empires being authorized. */ empires?: string[]; - /** @enum {integer} */ + /** + * @description A quick way of selecting all currently-authorized empires in order to extend their authorization period. + * @enum {integer} + */ revalidate_all?: 1 | 0; }; }; }; responses: { - /** @description Authorizes one or more empires (or an alliance) to sit for this empire. */ + /** @description Authorizes other empires to babysit this account. Each authorization is created if needed and granted for the full server-defined period. Returns the same list as view_authorized_sitters, plus any ids that were rejected. */ 200: { headers: { [name: string]: unknown; @@ -19984,12 +20301,13 @@ export interface paths { requestBody?: { content: { 'application/json': { + /** @description The ids (not names) of specific empires being removed. */ empires: string[]; }; }; }; responses: { - /** @description Removes sitting authorization from one or more empires. */ + /** @description Removes sitters from being permitted to sit this account. */ 200: { headers: { [name: string]: unknown; @@ -20075,6 +20393,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20144,6 +20463,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20205,6 +20525,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20265,6 +20586,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20326,6 +20648,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20603,6 +20926,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20672,6 +20996,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20733,6 +21058,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20793,6 +21119,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -20854,6 +21181,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21195,6 +21523,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21264,6 +21593,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21325,6 +21655,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21385,6 +21716,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21446,6 +21778,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21661,6 +21994,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21730,6 +22064,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21791,6 +22126,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21851,6 +22187,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -21912,6 +22249,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22191,6 +22529,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22260,6 +22599,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22321,6 +22661,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22381,6 +22722,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22442,6 +22784,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22657,6 +23000,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22726,6 +23070,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22787,6 +23132,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22847,6 +23193,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -22908,6 +23255,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23123,6 +23471,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23192,6 +23541,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23253,6 +23603,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23313,6 +23664,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23374,6 +23726,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23656,6 +24009,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23725,6 +24079,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23786,6 +24141,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23846,6 +24202,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -23907,6 +24264,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24122,6 +24480,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24191,6 +24550,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24252,6 +24612,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24312,6 +24673,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24373,6 +24735,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24588,6 +24951,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24657,6 +25021,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24718,6 +25083,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24778,6 +25144,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -24839,6 +25206,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25054,6 +25422,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25123,6 +25492,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25184,6 +25554,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25244,6 +25615,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25305,6 +25677,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25516,20 +25889,35 @@ export interface paths { name: string; }; species: { + /** @description The name of the species. Limited to 30 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ name: string; + /** @description The species description. Limited to 1024 characters and cannot contain < or >. */ description: string; + /** @description The closest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be less than or equal to max_orbit. */ min_orbit: number; + /** @description The furthest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be greater than or equal to min_orbit. */ max_orbit: number; + /** @description 7 is best. Determines advantages in manufactured goods, such as ships. */ manufacturing_affinity: number; + /** @description 7 is best. Determines advantages in spying. */ deception_affinity: number; + /** @description 7 is best. Determines advantages in upgrading buildings. */ research_affinity: number; + /** @description 7 is best. Determines advantages in the speed of building. */ management_affinity: number; + /** @description 7 is best. Determines advantages in food production. */ farming_affinity: number; + /** @description 7 is best. Determines advantages in mineral production. */ mining_affinity: number; + /** @description 7 is best. Determines advantages in energy, propulsion, and other technologies. */ science_affinity: number; + /** @description 7 is best. Determines advantages in waste and water management. */ environmental_affinity: number; + /** @description 7 is best. Determines advantages in managing population happiness. */ political_affinity: number; + /** @description 7 is best. Determines advantages in freight handling. */ trade_affinity: number; + /** @description 7 is best. Determines advantages in colonization. */ growth_affinity: number; }; /** @description Names of the species attributes this prisoner's traits can be grafted onto. */ @@ -25612,20 +26000,35 @@ export interface paths { name: string; }; species: { + /** @description The name of the species. Limited to 30 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ name: string; + /** @description The species description. Limited to 1024 characters and cannot contain < or >. */ description: string; + /** @description The closest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be less than or equal to max_orbit. */ min_orbit: number; + /** @description The furthest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be greater than or equal to min_orbit. */ max_orbit: number; + /** @description 7 is best. Determines advantages in manufactured goods, such as ships. */ manufacturing_affinity: number; + /** @description 7 is best. Determines advantages in spying. */ deception_affinity: number; + /** @description 7 is best. Determines advantages in upgrading buildings. */ research_affinity: number; + /** @description 7 is best. Determines advantages in the speed of building. */ management_affinity: number; + /** @description 7 is best. Determines advantages in food production. */ farming_affinity: number; + /** @description 7 is best. Determines advantages in mineral production. */ mining_affinity: number; + /** @description 7 is best. Determines advantages in energy, propulsion, and other technologies. */ science_affinity: number; + /** @description 7 is best. Determines advantages in waste and water management. */ environmental_affinity: number; + /** @description 7 is best. Determines advantages in managing population happiness. */ political_affinity: number; + /** @description 7 is best. Determines advantages in freight handling. */ trade_affinity: number; + /** @description 7 is best. Determines advantages in colonization. */ growth_affinity: number; }; /** @description Names of the species attributes this prisoner's traits can be grafted onto. */ @@ -25784,6 +26187,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25853,6 +26257,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25914,6 +26319,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -25974,6 +26380,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26035,6 +26442,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26250,6 +26658,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26319,6 +26728,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26380,6 +26790,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26440,6 +26851,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26501,6 +26913,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26716,6 +27129,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26785,6 +27199,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26846,6 +27261,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26906,6 +27322,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -26967,6 +27384,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27182,6 +27600,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27251,6 +27670,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27312,6 +27732,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27372,6 +27793,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27433,6 +27855,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27648,6 +28071,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27717,6 +28141,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27778,6 +28203,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27838,6 +28264,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -27899,6 +28326,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28114,6 +28542,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28183,6 +28612,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28244,6 +28674,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28304,6 +28735,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28365,6 +28797,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28580,6 +29013,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28649,6 +29083,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28710,6 +29145,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28770,6 +29206,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -28831,6 +29268,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -30056,6 +30494,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -30125,6 +30564,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -30186,6 +30626,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -30246,6 +30687,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -30307,6 +30749,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31251,6 +31694,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31320,6 +31764,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31381,6 +31826,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31441,6 +31887,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31502,6 +31949,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31723,6 +32171,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31792,6 +32241,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31853,6 +32303,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31913,6 +32364,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -31974,6 +32426,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32189,6 +32642,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32258,6 +32712,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32319,6 +32774,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32379,6 +32835,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32440,6 +32897,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32655,6 +33113,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32724,6 +33183,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32785,6 +33245,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32845,6 +33306,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -32906,6 +33368,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33121,6 +33584,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33190,6 +33654,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33251,6 +33716,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33311,6 +33777,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33372,6 +33839,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33587,6 +34055,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33656,6 +34125,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33717,6 +34187,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33777,6 +34248,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -33838,6 +34310,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34053,6 +34526,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34122,6 +34596,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34183,6 +34658,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34243,6 +34719,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34304,6 +34781,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34519,6 +34997,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34588,6 +35067,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34649,6 +35129,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34709,6 +35190,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34770,6 +35252,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -34985,6 +35468,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35054,6 +35538,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35115,6 +35600,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35175,6 +35661,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35236,6 +35723,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35451,6 +35939,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35520,6 +36009,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35581,6 +36071,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35641,6 +36132,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35702,6 +36194,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -35904,20 +36397,35 @@ export interface paths { jsonrpc?: string; result?: { species: { + /** @description The name of the species. Limited to 30 characters, cannot be blank, and cannot contain @, &, <, >, or ;. */ name: string; + /** @description The species description. Limited to 1024 characters and cannot contain < or >. */ description: string; + /** @description The closest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be less than or equal to max_orbit. */ min_orbit: number; + /** @description The furthest orbit this species can inhabit, where 1 is nearest the star. Every orbit from min_orbit to max_orbit inclusive costs a point. Must be greater than or equal to min_orbit. */ max_orbit: number; + /** @description 7 is best. Determines advantages in manufactured goods, such as ships. */ manufacturing_affinity: number; + /** @description 7 is best. Determines advantages in spying. */ deception_affinity: number; + /** @description 7 is best. Determines advantages in upgrading buildings. */ research_affinity: number; + /** @description 7 is best. Determines advantages in the speed of building. */ management_affinity: number; + /** @description 7 is best. Determines advantages in food production. */ farming_affinity: number; + /** @description 7 is best. Determines advantages in mineral production. */ mining_affinity: number; + /** @description 7 is best. Determines advantages in energy, propulsion, and other technologies. */ science_affinity: number; + /** @description 7 is best. Determines advantages in waste and water management. */ environmental_affinity: number; + /** @description 7 is best. Determines advantages in managing population happiness. */ political_affinity: number; + /** @description 7 is best. Determines advantages in freight handling. */ trade_affinity: number; + /** @description 7 is best. Determines advantages in colonization. */ growth_affinity: number; }; status: { @@ -35996,6 +36504,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36065,6 +36574,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36126,6 +36636,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36186,6 +36697,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36247,6 +36759,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36462,6 +36975,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36531,6 +37045,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36592,6 +37107,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36652,6 +37168,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36713,6 +37230,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36928,6 +37446,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -36997,6 +37516,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37058,6 +37578,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37118,6 +37639,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37179,6 +37701,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37394,6 +37917,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37463,6 +37987,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37524,6 +38049,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37584,6 +38110,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -37645,6 +38172,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -38458,7 +38986,7 @@ export interface paths { laws: { id: string; name: string; - description: string; + descripition: string; date_enacted: string; }[]; }; @@ -38532,6 +39060,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -38601,6 +39130,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -38662,6 +39192,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -38722,6 +39253,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -38783,6 +39315,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -38998,6 +39531,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39067,6 +39601,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39128,6 +39663,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39188,6 +39724,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39249,6 +39786,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39469,6 +40007,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39538,6 +40077,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39599,6 +40139,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39659,6 +40200,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39720,6 +40262,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -39991,7 +40534,6 @@ export interface paths { name: string; level: number; }[]; - cargo_space_used_each: number; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; @@ -40480,6 +41022,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -40549,6 +41092,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -40610,6 +41154,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -40670,6 +41215,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -40731,6 +41277,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -40946,6 +41493,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41015,6 +41563,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41076,6 +41625,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41136,6 +41686,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41197,6 +41748,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41412,6 +41964,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41481,6 +42034,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41542,6 +42096,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41602,6 +42157,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -41663,6 +42219,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -42281,6 +42838,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -42350,6 +42908,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -42411,6 +42970,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -42471,6 +43031,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -42532,6 +43093,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -42940,6 +43502,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43009,6 +43572,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43070,6 +43634,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43130,6 +43695,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43191,6 +43757,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43406,6 +43973,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43475,6 +44043,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43536,6 +44105,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43596,6 +44166,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43657,6 +44228,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43872,6 +44444,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -43941,6 +44514,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44002,6 +44576,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44062,6 +44637,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44123,6 +44699,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44476,6 +45053,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44545,6 +45123,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44606,6 +45185,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44666,6 +45246,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44727,6 +45308,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -44934,8 +45516,26 @@ export interface paths { name: string; x: number; y: number; - z: number; - bodies: components['schemas']['body_status'][]; + bodies: { + id: number; + x: number; + y: number; + star_id: number; + star_name: string; + orbit: number; + type: string; + name: string; + image: string; + size: number; + notes: string; + zone: string; + station?: { + id: number; + x: number; + y: number; + name: string; + }; + }[]; }[]; star_count: number; max_probes: number; @@ -45207,6 +45807,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -45276,6 +45877,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -45337,6 +45939,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -45397,6 +46000,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -45458,6 +46062,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -45818,6 +46423,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -45887,6 +46493,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -45948,6 +46555,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46008,6 +46616,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46069,6 +46678,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46284,6 +46894,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46353,6 +46964,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46414,6 +47026,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46474,6 +47087,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46535,6 +47149,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46817,6 +47432,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46886,6 +47502,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -46947,6 +47564,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47007,6 +47625,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47068,6 +47687,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47283,6 +47903,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47352,6 +47973,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47413,6 +48035,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47473,6 +48096,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47534,6 +48158,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47749,6 +48374,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47818,6 +48444,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47879,6 +48506,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -47939,6 +48567,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -48000,6 +48629,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -48215,6 +48845,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -48284,6 +48915,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -48345,6 +48977,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -48405,6 +49038,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -48466,6 +49100,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -48611,10 +49246,10 @@ export interface paths { body?: components['schemas']['body_status']; }; party?: { - seconds_remaining: number; - happiness: number; + seconds_remaining?: number; + happiness?: number; /** @enum {integer} */ - can_throw: 1 | 0; + can_throw?: 1 | 0; }; }; }; @@ -48678,10 +49313,10 @@ export interface paths { body?: components['schemas']['body_status']; }; party: { - seconds_remaining: number; - happiness: number; + seconds_remaining?: number; + happiness?: number; /** @enum {integer} */ - can_throw: 1 | 0; + can_throw?: 1 | 0; }; }; }; @@ -48745,10 +49380,10 @@ export interface paths { body?: components['schemas']['body_status']; }; party: { - seconds_remaining: number; - happiness: number; + seconds_remaining?: number; + happiness?: number; /** @enum {integer} */ - can_throw: 1 | 0; + can_throw?: 1 | 0; }; }; }; @@ -51004,6 +51639,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51073,6 +51709,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51134,6 +51771,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51194,6 +51832,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51255,6 +51894,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51470,6 +52110,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51539,6 +52180,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51600,6 +52242,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51660,6 +52303,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51721,6 +52365,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -51936,6 +52581,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -52005,6 +52651,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -52066,6 +52713,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -52126,6 +52774,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -52187,6 +52836,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53180,6 +53830,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53249,6 +53900,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53310,6 +53962,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53370,6 +54023,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53431,6 +54085,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53651,6 +54306,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53720,6 +54376,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53781,6 +54438,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53841,6 +54499,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -53902,6 +54561,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54117,6 +54777,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54186,6 +54847,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54247,6 +54909,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54307,6 +54970,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54368,6 +55032,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54583,6 +55248,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54652,6 +55318,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54713,6 +55380,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54773,6 +55441,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -54834,6 +55503,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55049,6 +55719,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55118,6 +55789,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55179,6 +55851,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55239,6 +55912,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55300,6 +55974,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55515,6 +56190,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55584,6 +56260,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55645,6 +56322,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55705,6 +56383,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55766,6 +56445,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -55981,6 +56661,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56050,6 +56731,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56111,6 +56793,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56171,6 +56854,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56232,6 +56916,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56447,6 +57132,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56516,6 +57202,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56577,6 +57264,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56637,6 +57325,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56698,6 +57387,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56913,6 +57603,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -56982,6 +57673,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57043,6 +57735,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57103,6 +57796,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57164,6 +57858,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57639,6 +58334,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57708,6 +58404,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57769,6 +58466,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57829,6 +58527,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -57890,6 +58589,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -58105,6 +58805,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -58174,6 +58875,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -58235,6 +58937,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -58295,6 +58998,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -58356,6 +59060,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59006,6 +59711,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59075,6 +59781,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59136,6 +59843,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59196,6 +59904,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59257,6 +59966,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59472,6 +60182,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59541,6 +60252,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59602,6 +60314,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59662,6 +60375,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59723,6 +60437,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -59938,6 +60653,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60007,6 +60723,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60068,6 +60785,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60128,6 +60846,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60189,6 +60908,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60404,6 +61124,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60473,6 +61194,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60534,6 +61256,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60594,6 +61317,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -60655,6 +61379,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -63079,6 +63804,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -63148,6 +63874,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -63209,6 +63936,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -63254,7 +63982,630 @@ export interface paths { }; }; responses: { - /** @description Instantly destroys a building. */ + /** @description Instantly destroys a building. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + buildings: components['schemas']['buildings_list']; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/spacestationlab/repair': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + }; + }; + }; + responses: { + /** @description Restores a building's efficiency to 100%, then returns the building's view. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + building: components['schemas']['building']; + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + buildings: components['schemas']['buildings_list']; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/spacestationlab/get_stats_for_level': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + level: number; + }; + }; + }; + responses: { + /** @description Returns the projected stats of a building at a given level. The building must already exist, since where it exists and who owns it affects the stats. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + building: { + id: string; + name: string; + image: string; + level: number; + food_hour?: number; + food_capacity?: number; + energy_hour?: number; + energy_capacity?: number; + ore_hour?: number; + ore_capacity?: number; + water_hour?: number; + water_capacity?: number; + waste_hour?: number; + waste_capacity?: number; + happiness_hour?: number; + upgrade?: { + cost: components['schemas']['building_cost']; + production: components['schemas']['building_production']; + image: string; + }; + }; + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/spacestationlab/view': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + }; + }; + }; + responses: { + /** @description Retrieves the properties of the building. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + building: components['schemas']['building']; + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + make_plan?: { + types?: { + type?: string; + name?: string; + image?: string; + url?: string; + }[]; + level_costs?: { + level?: number; + food?: number; + ore?: number; + water?: number; + energy?: number; + waste?: number; + time?: number; + }[]; + subsidy_cost?: number; + /** @description Only present if a plan is currently being made. */ + making?: string; + }; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/spacestationlab/make_plan': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + /** @description Key from view's make_plan > types, e.g. 'ibs'. */ + type: string; + level: number; + }; + }; + }; + responses: { + /** @description Starts the plan creation process. Returns the building view. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + building: components['schemas']['building']; + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + make_plan?: { + types?: { + type?: string; + name?: string; + image?: string; + url?: string; + }[]; + level_costs?: { + level?: number; + food?: number; + ore?: number; + water?: number; + energy?: number; + waste?: number; + time?: number; + }[]; + subsidy_cost?: number; + /** @description Only present if a plan is currently being made. */ + making?: string; + }; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/spacestationlab/subsidize_plan': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + }; + }; + }; + responses: { + /** @description Spends essentia equal to view's subsidy_cost to complete the current plan immediately. Returns the building view. Throws 1011. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + building: components['schemas']['building']; + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + make_plan?: { + types?: { + type?: string; + name?: string; + image?: string; + url?: string; + }[]; + level_costs?: { + level?: number; + food?: number; + ore?: number; + water?: number; + energy?: number; + waste?: number; + time?: number; + }[]; + subsidy_cost?: number; + /** @description Only present if a plan is currently being made. */ + making?: string; + }; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/stationcommand/view': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + }; + }; + }; + responses: { + /** @description Retrieves the properties of this module, plus the station's own planet data. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + building: { + id: string; + name: string; + image: string; + level: number; + x: number; + y: number; + efficiency: number; + }; + /** @description The amount of happiness required to settle your next colony. */ + next_colony_cost: number; + planet: { + id?: string; + x?: number; + y?: number; + star_id?: string; + orbit?: number; + type?: string; + name?: string; + image?: string; + size?: number; + water?: number; + ore?: { + [key: string]: number; + }; + building_count?: number; + population?: number; + happiness?: number; + happiness_hour?: number; + food_stored?: number; + food_capacity?: number; + food_hour?: number; + energy_stored?: number; + energy_capacity?: number; + energy_hour?: number; + ore_hour?: number; + ore_capacity?: number; + ore_stored?: number; + waste_hour?: number; + waste_stored?: number; + waste_capacity?: number; + water_stored?: number; + water_hour?: number; + water_capacity?: number; + }; + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/stationcommand/view_plans': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + }; + }; + }; + responses: { + /** @description Returns a list of all the plans this empire has collected. */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': { + id?: number; + jsonrpc?: string; + result?: { + plans: { + name: string; + level: number; + /** @description If level is 1 and this is present, the building will be built up to 1 plus this value when complete. */ + extra_build_level?: number; + }[]; + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; + }; + }; + }; + }; + }; + /** @description RPC Error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + 'application/json': components['schemas']['rpc_error']; + }; + }; + }; + }; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + '/v2/stationcommand/view_incoming_supply_chains': { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + get?: never; + put?: never; + post: { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: { + content: { + 'application/json': { + building_id: string; + }; + }; + }; + responses: { + /** @description Returns a list of all incoming supply chains feeding this planet. */ 200: { headers: { [name: string]: unknown; @@ -63264,6 +64615,21 @@ export interface paths { id?: number; jsonrpc?: string; result?: { + supply_chains: { + id?: string; + from_body?: { + id?: string; + name?: string; + x?: number; + y?: number; + image?: string; + }; + resource_hour?: number; + resource_type?: string; + percent_transferred?: number; + /** @enum {integer} */ + stalled?: 1 | 0; + }[]; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; @@ -63290,7 +64656,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/spacestationlab/repair': { + '/v2/stats/credits': { parameters: { query?: never; header?: never; @@ -63306,15 +64672,9 @@ export interface paths { path?: never; cookie?: never; }; - requestBody?: { - content: { - 'application/json': { - building_id: string; - }; - }; - }; + requestBody?: never; responses: { - /** @description Restores a building's efficiency to 100%, then returns the building's view. */ + /** @description Retrieves the list of game credits. Each entry names a single contribution category and the people who worked on it. */ 200: { headers: { [name: string]: unknown; @@ -63324,13 +64684,8 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - building: components['schemas']['building']; - status: { - server: components['schemas']['server_status']; - empire?: components['schemas']['empire_status']; - body?: components['schemas']['body_status']; - }; - }; + [key: string]: string[]; + }[]; }; }; }; @@ -63351,7 +64706,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/spacestationlab/get_stats_for_level': { + '/v2/stats/alliance_rank': { parameters: { query?: never; header?: never; @@ -63370,13 +64725,22 @@ export interface paths { requestBody?: { content: { 'application/json': { - building_id: string; - level: number; + /** + * @description Optional. Defaults to average_empire_size_rank. + * @enum {string} + */ + sort_by?: + | 'average_empire_size_rank' + | 'offense_success_rate_rank' + | 'defense_success_rate_rank' + | 'dirtiest_rank'; + /** @description Optional. 25 records per page. Defaults to the page containing the current user's own rank. */ + page_number?: number; }; }; }; responses: { - /** @description Returns the projected stats of a building at a given level. The building must already exist, since where it exists and who owns it affects the stats. */ + /** @description Returns a sorted list of alliances ranked by various statistics. */ 200: { headers: { [name: string]: unknown; @@ -63386,28 +64750,23 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - building: { - id: string; - name: string; - image: string; - level: number; - food_hour?: number; - food_capacity?: number; - energy_hour?: number; - energy_capacity?: number; - ore_hour?: number; - ore_capacity?: number; - water_hour?: number; - water_capacity?: number; - waste_hour?: number; - waste_capacity?: number; - happiness_hour?: number; - upgrade?: { - cost: components['schemas']['building_cost']; - production: components['schemas']['building_production']; - image: string; - }; - }; + alliances: { + alliance_id: string; + alliance_name: string; + member_count: number; + space_station_count: number; + influence: number; + colony_count: number; + population: number; + average_empire_size: number; + building_count: number; + average_building_level: number; + offense_success_rate: number; + defense_success_rate: number; + dirtiest: number; + }[]; + total_alliances: number; + page_number: number; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; @@ -63434,7 +64793,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/spacestationlab/view': { + '/v2/stats/find_alliance_rank': { parameters: { query?: never; header?: never; @@ -63453,12 +64812,22 @@ export interface paths { requestBody?: { content: { 'application/json': { - building_id: string; + /** + * @description Determines which ranking the returned page numbers refer to. + * @enum {string} + */ + sort_by: + | 'average_empire_size_rank' + | 'offense_success_rate_rank' + | 'defense_success_rate_rank' + | 'dirtiest_rank'; + /** @description Full or partial name. Must be at least 3 characters. */ + alliance_name: string; }; }; }; responses: { - /** @description Retrieves the properties of the building. */ + /** @description Searches for a particular alliance within the alliance rankings, returning the page of the alliance_rank listing each match appears on. */ 200: { headers: { [name: string]: unknown; @@ -63468,32 +64837,16 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - building: components['schemas']['building']; + alliances: { + alliance_id: string; + alliance_name: string; + page_number: number; + }[]; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; - make_plan?: { - types?: { - type?: string; - name?: string; - image?: string; - url?: string; - }[]; - level_costs?: { - level?: number; - food?: number; - ore?: number; - water?: number; - energy?: number; - waste?: number; - time?: number; - }[]; - subsidy_cost?: number; - /** @description Only present if a plan is currently being made. */ - making?: string; - }; }; }; }; @@ -63515,7 +64868,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/spacestationlab/make_plan': { + '/v2/stats/empire_rank': { parameters: { query?: never; header?: never; @@ -63534,15 +64887,22 @@ export interface paths { requestBody?: { content: { 'application/json': { - building_id: string; - /** @description Key from view's make_plan > types, e.g. 'ibs'. */ - type: string; - level: number; + /** + * @description Optional. Defaults to empire_size_rank. + * @enum {string} + */ + sort_by?: + | 'empire_size_rank' + | 'offense_success_rate_rank' + | 'defense_success_rate_rank' + | 'dirtiest_rank'; + /** @description Optional. 25 records per page. Defaults to the page containing the current user's own rank. */ + page_number?: number; }; }; }; responses: { - /** @description Starts the plan creation process. Returns the building view. */ + /** @description Returns a sorted list of empires ranked by various statistics. */ 200: { headers: { [name: string]: unknown; @@ -63552,32 +64912,27 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - building: components['schemas']['building']; + empires: { + empire_id: string; + empire_name: string; + alliance_id: string | null; + alliance_name: string | null; + colony_count: number; + population: number; + empire_size: number; + building_count: number; + average_building_level: number; + offense_success_rate: number; + defense_success_rate: number; + dirtiest: number; + }[]; + total_empires: number; + page_number: number; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; - make_plan?: { - types?: { - type?: string; - name?: string; - image?: string; - url?: string; - }[]; - level_costs?: { - level?: number; - food?: number; - ore?: number; - water?: number; - energy?: number; - waste?: number; - time?: number; - }[]; - subsidy_cost?: number; - /** @description Only present if a plan is currently being made. */ - making?: string; - }; }; }; }; @@ -63599,7 +64954,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/spacestationlab/subsidize_plan': { + '/v2/stats/find_empire_rank': { parameters: { query?: never; header?: never; @@ -63618,12 +64973,22 @@ export interface paths { requestBody?: { content: { 'application/json': { - building_id: string; + /** + * @description Determines which ranking the returned page numbers refer to. + * @enum {string} + */ + sort_by: + | 'empire_size_rank' + | 'offense_success_rate_rank' + | 'defense_success_rate_rank' + | 'dirtiest_rank'; + /** @description Full or partial name. Must be at least 3 characters. */ + empire_name: string; }; }; }; responses: { - /** @description Spends essentia equal to view's subsidy_cost to complete the current plan immediately. Returns the building view. Throws 1011. */ + /** @description Searches for a particular empire within the empire rankings, returning the page of the empire_rank listing each match appears on. */ 200: { headers: { [name: string]: unknown; @@ -63633,32 +64998,16 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - building: components['schemas']['building']; + empires: { + empire_id: string; + empire_name: string; + page_number: number; + }[]; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; - make_plan?: { - types?: { - type?: string; - name?: string; - image?: string; - url?: string; - }[]; - level_costs?: { - level?: number; - food?: number; - ore?: number; - water?: number; - energy?: number; - waste?: number; - time?: number; - }[]; - subsidy_cost?: number; - /** @description Only present if a plan is currently being made. */ - making?: string; - }; }; }; }; @@ -63680,7 +65029,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/stationcommand/view': { + '/v2/stats/colony_rank': { parameters: { query?: never; header?: never; @@ -63699,12 +65048,16 @@ export interface paths { requestBody?: { content: { 'application/json': { - building_id: string; + /** + * @description Optional. Defaults to population_rank. + * @enum {string} + */ + sort_by?: 'population_rank'; }; }; }; responses: { - /** @description Retrieves the properties of this module, plus the station's own planet data. */ + /** @description Returns a sorted list of planets ranked by various statistics. */ 200: { headers: { [name: string]: unknown; @@ -63714,51 +65067,16 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - building: { - id: string; - name: string; - image: string; - level: number; - x: number; - y: number; - efficiency: number; - }; - /** @description The amount of happiness required to settle your next colony. */ - next_colony_cost: number; - planet: { - id?: string; - x?: number; - y?: number; - star_id?: string; - orbit?: number; - type?: string; - name?: string; - image?: string; - size?: number; - water?: number; - ore?: { - [key: string]: number; - }; - building_count?: number; - population?: number; - happiness?: number; - happiness_hour?: number; - food_stored?: number; - food_capacity?: number; - food_hour?: number; - energy_stored?: number; - energy_capacity?: number; - energy_hour?: number; - ore_hour?: number; - ore_capacity?: number; - ore_stored?: number; - waste_hour?: number; - waste_stored?: number; - waste_capacity?: number; - water_stored?: number; - water_hour?: number; - water_capacity?: number; - }; + colonies: { + empire_id: string; + empire_name: string; + planet_id: string; + planet_name: string; + population: number; + building_count: number; + average_building_level: number; + highest_building_level: number; + }[]; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; @@ -63785,7 +65103,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/stationcommand/view_plans': { + '/v2/stats/spy_rank': { parameters: { query?: never; header?: never; @@ -63804,12 +65122,16 @@ export interface paths { requestBody?: { content: { 'application/json': { - building_id: string; + /** + * @description Optional. Defaults to level_rank. + * @enum {string} + */ + sort_by?: 'level_rank' | 'success_rate_rank' | 'dirtiest_rank'; }; }; }; responses: { - /** @description Returns a list of all the plans this empire has collected. */ + /** @description Returns a sorted list of the top spies ranked by various statistics. */ 200: { headers: { [name: string]: unknown; @@ -63819,11 +65141,15 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - plans: { - name: string; + spies: { + empire_id: string; + empire_name: string; + spy_id: string; + spy_name: string; + age: number; level: number; - /** @description If level is 1 and this is present, the building will be built up to 1 plus this value when complete. */ - extra_build_level?: number; + success_rate: number; + dirtiest: number; }[]; status: { server: components['schemas']['server_status']; @@ -63851,7 +65177,7 @@ export interface paths { patch?: never; trace?: never; }; - '/v2/stationcommand/view_incoming_supply_chains': { + '/v2/stats/weekly_medal_winners': { parameters: { query?: never; header?: never; @@ -63867,15 +65193,9 @@ export interface paths { path?: never; cookie?: never; }; - requestBody?: { - content: { - 'application/json': { - building_id: string; - }; - }; - }; + requestBody?: never; responses: { - /** @description Returns a list of all incoming supply chains feeding this planet. */ + /** @description Returns the list of empires who won this week's weekly medals. */ 200: { headers: { [name: string]: unknown; @@ -63885,20 +65205,12 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - supply_chains: { - id?: string; - from_body?: { - id?: string; - name?: string; - x?: number; - y?: number; - image?: string; - }; - resource_hour?: number; - resource_type?: string; - percent_transferred?: number; - /** @enum {integer} */ - stalled?: 1 | 0; + winners: { + empire_id: string; + empire_name: string; + medal_name: string; + medal_image: string; + times_earned: number; }[]; status: { server: components['schemas']['server_status']; @@ -63976,6 +65288,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64045,6 +65358,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64106,6 +65420,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64166,6 +65481,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64227,6 +65543,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64442,6 +65759,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64511,6 +65829,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64572,6 +65891,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64632,6 +65952,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -64693,6 +66014,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65243,6 +66565,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65312,6 +66635,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65373,6 +66697,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65433,6 +66758,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65494,6 +66820,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65709,6 +67036,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65778,6 +67106,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65839,6 +67168,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65899,6 +67229,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -65960,6 +67291,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66175,6 +67507,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66244,6 +67577,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66305,6 +67639,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66365,6 +67700,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66426,6 +67762,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66777,6 +68114,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66846,6 +68184,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66907,6 +68246,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -66967,6 +68307,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67028,6 +68369,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67243,6 +68585,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67312,6 +68655,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67373,6 +68717,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67433,6 +68778,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67494,6 +68840,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67709,6 +69056,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67778,6 +69126,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67839,6 +69188,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67899,6 +69249,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -67960,6 +69311,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68392,6 +69744,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68461,6 +69814,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68522,6 +69876,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68582,6 +69937,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68643,6 +69999,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68863,6 +70220,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68932,6 +70290,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -68993,6 +70352,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -69053,6 +70413,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -69114,6 +70475,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -69396,6 +70758,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -69465,6 +70828,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -69526,6 +70890,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -69586,6 +70951,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -69647,6 +71013,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -71028,7 +72395,7 @@ export interface paths { id?: number; jsonrpc?: string; result?: { - waste_chains: { + waste_chain: { id?: string; waste_hour?: number; percent_transferred?: number; @@ -71550,6 +72917,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -71619,6 +72987,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -71680,6 +73049,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -71740,6 +73110,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -71801,6 +73172,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -72916,6 +74288,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -72985,6 +74358,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73046,6 +74420,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73106,6 +74481,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73167,6 +74543,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73382,6 +74759,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73451,6 +74829,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73512,6 +74891,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73572,6 +74952,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73633,6 +75014,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73917,6 +75299,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -73986,6 +75369,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74047,6 +75431,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74107,6 +75492,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74168,6 +75554,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74383,6 +75770,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74452,6 +75840,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74513,6 +75902,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74573,6 +75963,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74634,6 +76025,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74849,6 +76241,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74918,6 +76311,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -74979,6 +76373,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -75039,6 +76434,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -75100,6 +76496,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -75484,6 +76881,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -75553,6 +76951,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -75614,6 +77013,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -75674,6 +77074,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -75735,6 +77136,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76119,6 +77521,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76188,6 +77591,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76249,6 +77653,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76309,6 +77714,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76370,6 +77776,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76585,6 +77992,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76654,6 +78062,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76715,6 +78124,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76775,6 +78185,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -76836,6 +78247,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77051,6 +78463,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77120,6 +78533,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77181,6 +78595,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77241,6 +78656,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77302,6 +78718,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77517,6 +78934,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77586,6 +79004,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77647,6 +79066,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77707,6 +79127,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77768,6 +79189,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -77983,6 +79405,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78052,6 +79475,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78113,6 +79537,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78173,6 +79598,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78234,6 +79660,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78449,6 +79876,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78518,6 +79946,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78579,6 +80008,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78639,6 +80069,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78700,6 +80131,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -78977,6 +80409,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -79046,6 +80479,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -79107,6 +80541,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -79167,6 +80602,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -79228,6 +80664,7 @@ export interface paths { empire?: components['schemas']['empire_status']; body?: components['schemas']['body_status']; }; + buildings: components['schemas']['buildings_list']; }; }; }; @@ -79493,6 +80930,30 @@ export interface components { ore: number; time: number; }; + buildings_list: { + /** @description Keyed by building id. */ + buildings: { + [key: string]: { + name: string; + x: number; + y: number; + url: string; + level: number; + image: string; + efficiency: number; + pending_build?: { + seconds_remaining: number; + start: string; + end: string; + }; + work?: { + seconds_remaining: number; + start: string; + end: string; + }; + }; + }; + }; building_production: { food_hour: number; food_capacity: number; diff --git a/lib/types/stats.ts b/lib/types/stats.ts index b04ba30..34f5a14 100644 --- a/lib/types/stats.ts +++ b/lib/types/stats.ts @@ -1,7 +1,156 @@ -export interface StatsCreditsParams {} +import { components } from './schema'; -export interface CreditsResult { - [index: number]: { - [index: string]: string[]; +interface StatusBlock { + status: { + server: components['schemas']['server_status']; + empire?: components['schemas']['empire_status']; + body?: components['schemas']['body_status']; }; } + +export interface CreditsParams {} + +/** One entry per contribution category, e.g. "Game Design" or "Play Testers". */ +export type CreditsResult = Array<{ + [category: string]: string[]; +}>; + +export type EmpireRankSort = + 'empire_size_rank' | 'offense_success_rate_rank' | 'defense_success_rate_rank' | 'dirtiest_rank'; + +export type AllianceRankSort = + | 'average_empire_size_rank' + | 'offense_success_rate_rank' + | 'defense_success_rate_rank' + | 'dirtiest_rank'; + +export interface EmpireRankParams { + sort_by?: EmpireRankSort; + /** 25 records per page. Defaults to the page holding the current empire's own rank. */ + page_number?: number; +} + +export interface EmpireRankResult extends StatusBlock { + empires: Array<{ + empire_id: number; + empire_name: string; + alliance_id: number | null; + alliance_name: string | null; + colony_count: number; + population: number; + empire_size: number; + building_count: number; + average_building_level: number; + offense_success_rate: number; + defense_success_rate: number; + dirtiest: number; + }>; + total_empires: number; + page_number: number; +} + +export interface AllianceRankParams { + /** + * The server errors on its own default sort, so pass one explicitly - see + * README "Spec Discrepancies". + */ + sort_by: AllianceRankSort; + /** 25 records per page. Defaults to the page holding the current empire's own rank. */ + page_number?: number; +} + +export interface AllianceRankResult extends StatusBlock { + alliances: Array<{ + alliance_id: number; + alliance_name: string; + member_count: number; + space_station_count: number; + influence: number; + colony_count: number; + population: number; + average_empire_size: number; + building_count: number; + average_building_level: number; + offense_success_rate: number; + defense_success_rate: number; + dirtiest: number; + }>; + total_alliances: number; + page_number: number; +} + +export interface FindEmpireRankParams { + /** Determines which ranking the returned page numbers refer to. */ + sort_by: EmpireRankSort; + /** Full or partial name. Must be at least 3 characters. */ + empire_name: string; +} + +export interface FindEmpireRankResult extends StatusBlock { + empires: Array<{ + empire_id: number; + empire_name: string; + page_number: number; + }>; +} + +export interface FindAllianceRankParams { + /** Determines which ranking the returned page numbers refer to. */ + sort_by: AllianceRankSort; + /** Full or partial name. Must be at least 3 characters. */ + alliance_name: string; +} + +export interface FindAllianceRankResult extends StatusBlock { + alliances: Array<{ + alliance_id: number; + alliance_name: string; + page_number: number; + }>; +} + +export interface ColonyRankParams { + sort_by?: 'population_rank'; +} + +export interface ColonyRankResult extends StatusBlock { + colonies: Array<{ + empire_id: number; + empire_name: string; + planet_id: number; + planet_name: string; + population: number; + building_count: number; + average_building_level: number; + highest_building_level: number; + }>; +} + +export interface SpyRankParams { + sort_by?: 'level_rank' | 'success_rate_rank' | 'dirtiest_rank'; +} + +export interface SpyRankResult extends StatusBlock { + spies: Array<{ + empire_id: number; + empire_name: string; + spy_id: number; + spy_name: string; + age: number; + level: number; + success_rate: number; + dirtiest: number; + }>; +} + +export interface WeeklyMedalWinnersParams {} + +export interface WeeklyMedalWinnersResult extends StatusBlock { + winners: Array<{ + empire_id: number; + empire_name: string; + medal_name: string; + medal_image: string; + times_earned: number; + }>; +} diff --git a/lib/types/trade.ts b/lib/types/trade.ts index 05613a2..e74d6a1 100644 --- a/lib/types/trade.ts +++ b/lib/types/trade.ts @@ -306,7 +306,7 @@ export interface ViewWasteChainsParams { } export interface ViewWasteChainsResponse { - waste_chains: Array<{ id?: string; waste_hour?: number; percent_transferred?: number }>; + waste_chain: Array<{ id?: string; waste_hour?: number; percent_transferred?: number }>; status: { server: components['schemas']['server_status']; empire?: components['schemas']['empire_status']; diff --git a/package-lock.json b/package-lock.json index 1174ed2..9997284 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,7 +15,7 @@ "openapi-fetch": "^0.17.0" }, "devDependencies": { - "@tlecommunity/api-spec": "^1.0.1", + "@tlecommunity/api-spec": "^1.1.0", "@types/jest": "^30.0.0", "ajv": "^8.20.0", "jest": "^30.4.2", @@ -1557,9 +1557,9 @@ } }, "node_modules/@tlecommunity/api-spec": { - "version": "1.0.1", - "resolved": "https://gitea.allosaurus-chromatic.ts.net/api/packages/tlecommunity/npm/%40tlecommunity%2Fapi-spec/-/1.0.1/api-spec-1.0.1.tgz", - "integrity": "sha512-W9JcffP8ORwtbCTEHUqGoD/pgX5LhES56AU6uIORm4GIOaVvDc3GLrok1DhKo2BMIjQxF1cQutZZ8A1kbiq88g==", + "version": "1.1.0", + "resolved": "https://gitea.allosaurus-chromatic.ts.net/api/packages/tlecommunity/npm/%40tlecommunity%2Fapi-spec/-/1.1.0/api-spec-1.1.0.tgz", + "integrity": "sha512-fefhEmn7V0tw8F4u7zMXZRWrepT25EwlwYSoeel5/rL2jKceOJumyvtjNe8L635p/THENhKXy4CprTfmRJrXTw==", "dev": true, "license": "MIT" }, @@ -7154,9 +7154,9 @@ } }, "@tlecommunity/api-spec": { - "version": "1.0.1", - "resolved": "https://gitea.allosaurus-chromatic.ts.net/api/packages/tlecommunity/npm/%40tlecommunity%2Fapi-spec/-/1.0.1/api-spec-1.0.1.tgz", - "integrity": "sha512-W9JcffP8ORwtbCTEHUqGoD/pgX5LhES56AU6uIORm4GIOaVvDc3GLrok1DhKo2BMIjQxF1cQutZZ8A1kbiq88g==", + "version": "1.1.0", + "resolved": "https://gitea.allosaurus-chromatic.ts.net/api/packages/tlecommunity/npm/%40tlecommunity%2Fapi-spec/-/1.1.0/api-spec-1.1.0.tgz", + "integrity": "sha512-fefhEmn7V0tw8F4u7zMXZRWrepT25EwlwYSoeel5/rL2jKceOJumyvtjNe8L635p/THENhKXy4CprTfmRJrXTw==", "dev": true }, "@tybys/wasm-util": { diff --git a/package.json b/package.json index ebf2435..1a7424d 100644 --- a/package.json +++ b/package.json @@ -31,7 +31,7 @@ "author": "Natalie Rose ", "license": "MIT", "devDependencies": { - "@tlecommunity/api-spec": "^1.0.1", + "@tlecommunity/api-spec": "^1.1.0", "@types/jest": "^30.0.0", "ajv": "^8.20.0", "jest": "^30.4.2", -- 2.51.2