diff --git a/models/Faction.json b/models/Faction.json new file mode 100644 index 0000000..ae066d3 --- /dev/null +++ b/models/Faction.json @@ -0,0 +1,63 @@ +{ + "description": "", + "type": "object", + "x-examples": { + "example-1": { + "symbol": "COMMERCE_REPUBLIC", + "name": "Commerce Repubic", + "description": "", + "headquarters": "X1-OE-PM", + "traits": [ + "BUREAUCRATIC", + "CAPITALISTIC", + "GUILD", + "ESTABLISHED" + ] + } + }, + "examples": [ + { + "symbol": "COMMERCE_REPUBLIC", + "name": "Commerce Repubic", + "description": "The Commerce Republic takes capital from top tier worlds and invests it into new systems with high potential for growth.", + "headquarters": "X1-OE-PM", + "traits": [ + "BUREAUCRATIC", + "CAPITALISTIC", + "GUILD", + "ESTABLISHED" + ] + } + ], + "properties": { + "symbol": { + "type": "string", + "minLength": 1 + }, + "name": { + "type": "string", + "minLength": 1 + }, + "description": { + "type": "string", + "minLength": 1 + }, + "headquarters": { + "type": "string", + "minLength": 1 + }, + "traits": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "symbol", + "name", + "description", + "headquarters", + "traits" + ] +} \ No newline at end of file diff --git a/models/Faction.yaml b/models/Faction.yaml deleted file mode 100644 index 9fbb1ab..0000000 --- a/models/Faction.yaml +++ /dev/null @@ -1,46 +0,0 @@ -description: '' -type: object -x-examples: - example-1: - symbol: COMMERCE_REPUBLIC - name: Commerce Repubic - description: The Commerce Republic takes capital from top tier worlds and invests it into new systems with high potential for growth. - headquarters: X1-OE-PM - traits: - - BUREAUCRATIC - - CAPITALISTIC - - GUILD - - ESTABLISHED -examples: - - symbol: COMMERCE_REPUBLIC - name: Commerce Repubic - description: The Commerce Republic takes capital from top tier worlds and invests it into new systems with high potential for growth. - headquarters: X1-OE-PM - traits: - - BUREAUCRATIC - - CAPITALISTIC - - GUILD - - ESTABLISHED -properties: - symbol: - type: string - minLength: 1 - name: - type: string - minLength: 1 - description: - type: string - minLength: 1 - headquarters: - type: string - minLength: 1 - traits: - type: array - items: - type: string -required: - - symbol - - name - - description - - headquarters - - traits diff --git a/models/Jump.json b/models/Jump.json new file mode 100644 index 0000000..792d59d --- /dev/null +++ b/models/Jump.json @@ -0,0 +1,30 @@ +{ + "description": "", + "type": "object", + "properties": { + "shipSymbol": { + "type": "string", + "minLength": 1 + }, + "destination": { + "type": "string", + "minLength": 1 + } + }, + "required": [ + "shipSymbol", + "destination" + ], + "x-examples": { + "example-1": { + "shipSymbol": "1D7FDA-1", + "destination": "00E0B1" + } + }, + "examples": [ + { + "shipSymbol": "1D7FDA-1", + "destination": "00E0B1" + } + ] +} \ No newline at end of file diff --git a/models/Jump.yaml b/models/Jump.yaml deleted file mode 100644 index 9d9c957..0000000 --- a/models/Jump.yaml +++ /dev/null @@ -1,19 +0,0 @@ -description: '' -type: object -properties: - shipSymbol: - type: string - minLength: 1 - destination: - type: string - minLength: 1 -required: - - shipSymbol - - destination -x-examples: - example-1: - shipSymbol: 1D7FDA-1 - destination: 00E0B1 -examples: - - shipSymbol: 1D7FDA-1 - destination: 00E0B1 diff --git a/models/Market.json b/models/Market.json new file mode 100644 index 0000000..2730266 --- /dev/null +++ b/models/Market.json @@ -0,0 +1,38 @@ +{ + "description": "", + "type": "object", + "properties": { + "symbol": { + "type": "string", + "description": "The symbol of the market. The symbol is the same as the waypoint where the market is located." + }, + "exports": { + "type": "array", + "description": "The list of goods that are exported from this market.", + "items": { + "type": "string" + } + }, + "imports": { + "type": "array", + "description": "The list of goods that are sought as imports in this market.", + "items": { + "type": "string" + } + }, + "transactions": { + "type": "array", + "description": "The list of recent transactions at this market.", + "items": { + "$ref": "./MarketTransaction.json" + } + }, + "tradeGoods": { + "type": "array", + "description": "The list of goods that are traded at this market.", + "items": { + "$ref": "./MarketTradeGood.json" + } + } + } +} \ No newline at end of file diff --git a/models/MarketTrade.yaml b/models/MarketTrade.yaml deleted file mode 100644 index 1f7eadc..0000000 --- a/models/MarketTrade.yaml +++ /dev/null @@ -1,18 +0,0 @@ -description: "" -type: object -properties: - waypointSymbol: - type: string - minLength: 1 - tradeSymbol: - type: string - minLength: 1 - price: - type: integer - tariff: - type: integer -required: - - waypointSymbol - - tradeSymbol - - price - - tariff diff --git a/models/MarketTradeGood.json b/models/MarketTradeGood.json new file mode 100644 index 0000000..4519f05 --- /dev/null +++ b/models/MarketTradeGood.json @@ -0,0 +1,33 @@ +{ + "type": "object", + "properties": { + "symbol": { + "type": "string", + "description": "The symbol of the trade good." + }, + "tradeVolume": { + "type": "integer", + "description": "The average volume flowing through the market for this type of good.", + "minimum": 1 + }, + "supply": { + "type": "string", + "description": "A rough estimate of the total supply of this good in this marketplace.", + "enum": [ + "HIGH", + "AVERAGE", + "LOW" + ] + }, + "purchasePrice": { + "type": "integer", + "description": "The price at which this good is sold.", + "minimum": 0 + }, + "sellPrice": { + "type": "integer", + "description": "The price at which this good is bought.", + "minimum": 0 + } + } +} \ No newline at end of file diff --git a/models/MarketTransaction.json b/models/MarketTransaction.json new file mode 100644 index 0000000..b076537 --- /dev/null +++ b/models/MarketTransaction.json @@ -0,0 +1,36 @@ +{ + "type": "object", + "properties": { + "symbol": { + "type": "string", + "description": "The symbol of the trade good." + }, + "type": { + "type": "string", + "description": "The type of transaction.", + "enum": [ + "PURCHASE", + "SELL" + ] + }, + "units": { + "type": "integer", + "description": "The number of units of the transaction.", + "minimum": 1 + }, + "pricePerUnit": { + "type": "integer", + "description": "The price per unit of the transaction.", + "minimum": 1 + }, + "shipSymbol": { + "type": "string", + "description": "The symbol of the ship that made the transaction." + }, + "timestamp": { + "type": "string", + "format": "date-time", + "description": "The timestamp of the transaction." + } + } +} \ No newline at end of file diff --git a/models/Ship.json b/models/Ship.json index 2b7175e..7693032 100644 --- a/models/Ship.json +++ b/models/Ship.json @@ -26,8 +26,8 @@ "reactor": { "$ref": "./ShipReactor.json" }, - "thrusters": { - "$ref": "./ShipThrusters.json" + "engine": { + "$ref": "./ShipEngine.json" }, "modules": { "type": "array", diff --git a/models/ShipCargo.json b/models/ShipCargo.json index 93fca08..bdc27f9 100644 --- a/models/ShipCargo.json +++ b/models/ShipCargo.json @@ -3,42 +3,17 @@ "properties": { "capacity": { "type": "integer", + "description": "The max number of items that can be stored in the cargo hold.", "minimum": 0 }, "inventory": { "type": "array", + "description": "The items currently in the cargo hold.", "items": { - "type": "object", - "properties": { - "symbol": { - "type": "string", - "examples": [ - "ORE_COPPER", - "MICROPROCESSORS", - "FOOD" - ] - }, - "name": { - "type": "string", - "examples": [ - "Copper Ore", - "Microprocessors", - "Food" - ] - }, - "units": { - "type": "integer", - "minimum": 1 - } - }, - "required": [ - "symbol", - "name", - "units" - ] + "$ref": "./ShipCargoItem.json" }, "required": [ - "size", + "capacity", "inventory" ] } diff --git a/models/ShipCargoItem.json b/models/ShipCargoItem.json new file mode 100644 index 0000000..3fc82bf --- /dev/null +++ b/models/ShipCargoItem.json @@ -0,0 +1,31 @@ +{ + "type": "object", + "description": "The type of cargo item and the number of units.", + "properties": { + "symbol": { + "type": "string", + "examples": [ + "ORE_COPPER", + "MICROPROCESSORS", + "FOOD" + ] + }, + "name": { + "type": "string", + "examples": [ + "Copper Ore", + "Microprocessors", + "Food" + ] + }, + "units": { + "type": "integer", + "minimum": 1 + } + }, + "required": [ + "symbol", + "name", + "units" + ] +} \ No newline at end of file diff --git a/models/ShipThrusters.json b/models/ShipEngine.json similarity index 86% rename from models/ShipThrusters.json rename to models/ShipEngine.json index 6cf169a..c480fda 100644 --- a/models/ShipThrusters.json +++ b/models/ShipEngine.json @@ -1,6 +1,6 @@ { "type": "object", - "description": "The thrusters determine how quickly a ship travels between waypoints.", + "description": "The engine determines how quickly a ship travels between waypoints.", "properties": { "symbol": { "type": "string", diff --git a/models/Shipyard.json b/models/Shipyard.json new file mode 100644 index 0000000..f99ac83 --- /dev/null +++ b/models/Shipyard.json @@ -0,0 +1,18 @@ +{ + "description": "", + "type": "object", + "properties": { + "symbol": { + "type": "string", + "description": "The symbol of the shipyard. The symbol is the same as the waypoint where the shipyard is located.", + "minLength": 1 + }, + "ships": { + "type": "array", + "description": "The ships that are currently available for purchase at the shipyard.", + "items": { + "$ref": "./ShipyardShip.json" + } + } + } +} \ No newline at end of file diff --git a/models/Shipyard.yaml b/models/Shipyard.yaml deleted file mode 100644 index e0568f2..0000000 --- a/models/Shipyard.yaml +++ /dev/null @@ -1,19 +0,0 @@ -description: '' -type: object -properties: - symbol: - type: string - minLength: 1 - faction: - type: string - minLength: 1 -required: - - symbol - - faction -x-examples: - example-1: - symbol: X1-OE-PM - faction: COMMERCE_REPUBLIC -examples: - - symbol: X1-OE-PM - faction: COMMERCE_REPUBLIC diff --git a/models/ShipyardListing.yaml b/models/ShipyardListing.yaml deleted file mode 100644 index 63ed2fb..0000000 --- a/models/ShipyardListing.yaml +++ /dev/null @@ -1,66 +0,0 @@ -description: "" -type: object -x-examples: - example-1: - id: cl0nahta90000aq0jonm1nprl - waypoint: X1-OE-PM - price: 58191 - role: EXCAVATOR - frame: FRAME_DRONE - reactor: REACTOR_SOLAR_I - engine: ENGINE_SOLAR_PROPULSION - modules: - - MODULE_CARGO_HOLD - mounts: - - MOUNT_MINING_LASER_I -examples: - - id: cl0nahta90000aq0jonm1nprl - waypoint: X1-OE-PM - price: 58191 - role: EXCAVATOR - frame: FRAME_DRONE - reactor: REACTOR_SOLAR_I - engine: ENGINE_SOLAR_PROPULSION - modules: - - MODULE_CARGO_HOLD - mounts: - - MOUNT_MINING_LASER_I -properties: - id: - type: string - minLength: 1 - waypoint: - type: string - minLength: 1 - price: - type: integer - role: - type: string - minLength: 1 - frame: - type: string - minLength: 1 - reactor: - type: string - minLength: 1 - engine: - type: string - minLength: 1 - modules: - type: array - items: - type: string - mounts: - type: array - items: - type: string -required: - - id - - waypoint - - price - - role - - frame - - reactor - - engine - - modules - - mounts diff --git a/models/ShipyardShip.json b/models/ShipyardShip.json new file mode 100644 index 0000000..2533e1b --- /dev/null +++ b/models/ShipyardShip.json @@ -0,0 +1,34 @@ +{ + "description": "", + "type": "object", + "properties": { + "symbol": { + "type": "string", + "minLength": 1 + }, + "price": { + "type": "integer" + }, + "frame": { + "$ref": "./ShipFrame.json" + }, + "reactor": { + "$ref": "./ShipReactor.json" + }, + "engine": { + "$ref": "./ShipEngine.json" + }, + "modules": { + "type": "array", + "items": { + "$ref": "./ShipModule.json" + } + }, + "mounts": { + "type": "array", + "items": { + "$ref": "./ShipMount.json" + } + } + } +} \ No newline at end of file diff --git a/models/Waypoint.json b/models/Waypoint.json new file mode 100644 index 0000000..619bd59 --- /dev/null +++ b/models/Waypoint.json @@ -0,0 +1,56 @@ +{ + "description": "A waypoint is a location that ships can travel to such as a Planet, Moon or Space Station.", + "type": "object", + "properties": { + "symbol": { + "type": "string", + "minLength": 1 + }, + "type": { + "$ref": "./WaypointType.json" + }, + "systemSymbol": { + "type": "string", + "minLength": 1 + }, + "x": { + "type": "integer" + }, + "y": { + "type": "integer" + }, + "orbitals": { + "type": "array", + "items": { + "$ref": "./WaypointOrbital.json" + } + }, + "factions": { + "type": "array", + "description": "The factions that are active on the waypoint.", + "items": { + "$ref": "./WaypointFaction.json" + } + }, + "traits": { + "type": "array", + "description": "The traits of the waypoint.", + "items": { + "$ref": "./WaypointTrait.json" + } + }, + "chart": { + "$ref": "./WaypointChart.json" + } + }, + "required": [ + "symbol", + "type", + "systemSymbol", + "x", + "y", + "orbitals", + "factions", + "traits" + ] +} \ No newline at end of file diff --git a/models/Waypoint.yaml b/models/Waypoint.yaml deleted file mode 100644 index b9e963a..0000000 --- a/models/Waypoint.yaml +++ /dev/null @@ -1,89 +0,0 @@ -description: "" -type: object -x-examples: - example-1: - system: X1-OE - symbol: X1-OE-PM - type: PLANET - x: 10 - "y": 5 - orbitals: - - X1-OE-PM01 - faction: COMMERCE_REPUBLIC - features: - - MARKETPLACE - - SHIPYARD - traits: - - OVERCROWDED - - HIGH_TECH - - BUREAUCRATIC - - TRADING_HUB - - TEMPERATE - charted: true - chartedBy: null -examples: - - system: X1-OE - symbol: X1-OE-PM - type: PLANET - x: 10 - "y": 5 - orbitals: - - X1-OE-PM01 - faction: COMMERCE_REPUBLIC - features: - - MARKETPLACE - - SHIPYARD - traits: - - OVERCROWDED - - HIGH_TECH - - BUREAUCRATIC - - TRADING_HUB - - TEMPERATE - charted: true - chartedBy: null -properties: - system: - type: string - minLength: 1 - symbol: - type: string - minLength: 1 - type: - type: string - minLength: 1 - x: - type: integer - "y": - type: integer - orbitals: - type: array - items: - type: string - faction: - type: string - minLength: 1 - features: - type: array - items: - type: string - traits: - type: array - items: - type: string - charted: - type: boolean - chartedBy: - type: - - string - - "null" -required: - - system - - symbol - - type - - x - - "y" - - orbitals - - faction - - features - - traits - - charted diff --git a/models/WaypointChart.json b/models/WaypointChart.json new file mode 100644 index 0000000..6eead76 --- /dev/null +++ b/models/WaypointChart.json @@ -0,0 +1,13 @@ +{ + "type": "object", + "description": "The chart of the waypoint, which makes the waypoint visible to other agents.", + "properties": { + "submittedBy": { + "type": "string" + }, + "submittedOn": { + "type": "string", + "format": "date-time" + } + } +} \ No newline at end of file diff --git a/models/WaypointFaction.json b/models/WaypointFaction.json new file mode 100644 index 0000000..33b0b8b --- /dev/null +++ b/models/WaypointFaction.json @@ -0,0 +1,9 @@ +{ + "type": "object", + "properties": { + "symbol": { + "type": "string", + "minLength": 1 + } + } +} \ No newline at end of file diff --git a/models/WaypointOrbital.json b/models/WaypointOrbital.json new file mode 100644 index 0000000..7ef5bda --- /dev/null +++ b/models/WaypointOrbital.json @@ -0,0 +1,10 @@ +{ + "type": "object", + "description": "An orbital is another waypoint that orbits a parent waypoint.", + "properties": { + "symbol": { + "type": "string", + "minLength": 1 + } + } +} \ No newline at end of file diff --git a/models/WaypointTrait.json b/models/WaypointTrait.json new file mode 100644 index 0000000..5ed26e4 --- /dev/null +++ b/models/WaypointTrait.json @@ -0,0 +1,72 @@ +{ + "type": "object", + "properties": { + "symbol": { + "type": "string", + "description": "The unique identifier of the trait.", + "enum": [ + "UNCHARTED", + "OUTPOST", + "SCATTERED_SETTLEMENTS", + "SPRAWLING_CITIES", + "MEGA_STRUCTURES", + "OVERCROWDED", + "HIGH_TECH", + "CORRUPT", + "BUREAUCRATIC", + "TRADING_HUB", + "INDUSTRIAL", + "BLACK_MARKET", + "RESEARCH_FACILITY", + "MILITARY_BASE", + "SURVEILLANCE_OUTPOST", + "EXPLORATION_OUTPOST", + "MINERAL_DEPOSITS", + "COMMON_METAL_DEPOSITS", + "PRECIOUS_METAL_DEPOSITS", + "RARE_METAL_DEPOSITS", + "METHANE_POOLS", + "ICE_CRYSTALS", + "EXPLOSIVE_GASES", + "VIBRANT_AURORAS", + "SALT_FLATS", + "CANYONS", + "PERPETUAL_DAYLIGHT", + "PERPETUAL_OVERCAST", + "DRY_SEABEDS", + "MAGMA_SEAS", + "SUPERVOLCANOES", + "ASH_CLOUDS", + "VAST_RUINS", + "MUTATED_FLORA", + "DIVERSE_LIFE", + "SCARCE_LIFE", + "FOSSILS", + "WEAK_GRAVITY", + "STRONG_GRAVITY", + "CRUSHING_GRAVITY", + "TOXIC_ATMOSPHERE", + "CORROSIVE_ATMOSPHERE", + "BREATHABLE_ATMOSPHERE", + "COMM_RELAY_I", + "JOVIAN", + "ROCKY", + "VOLCANIC", + "FROZEN", + "SWAMP", + "BARREN", + "TEMPERATE", + "JUNGLE", + "OCEAN" + ] + }, + "name": { + "type": "string", + "description": "The name of the trait." + }, + "description": { + "type": "string", + "description": "A description of the trait." + } + } +} \ No newline at end of file diff --git a/models/WaypointType.json b/models/WaypointType.json new file mode 100644 index 0000000..4d4c37f --- /dev/null +++ b/models/WaypointType.json @@ -0,0 +1,14 @@ +{ + "type": "string", + "description": "The type of waypoint.", + "enum": [ + "PLANET", + "GAS_GIANT", + "MOON", + "ORBITAL_STATION", + "JUMP_GATE", + "ASTEROID_FIELD", + "DEBRIS_FIELD", + "GRAVITY_WELL" + ] +} \ No newline at end of file diff --git a/reference/SpaceTraders.json b/reference/SpaceTraders.json index 00314ca..34a97ac 100644 --- a/reference/SpaceTraders.json +++ b/reference/SpaceTraders.json @@ -2,8 +2,8 @@ "openapi": "3.1.0", "info": { "title": "SpaceTraders API", - "version": "2.1.0", - "summary": "SpaceTraders is a unique multiplayer game built on a free Web API.", + "version": "2.0.0-rc.2", + "summary": "[Alpha] SpaceTraders is a multiplayer sci-fi strategy game where you acquire and manage a fleet of ships.", "contact": { "name": "Joel Brubaker", "email": "joel@spacetraders.io" @@ -12,16 +12,16 @@ "name": "No Permission", "url": "https://choosealicense.com/no-permission/" }, - "description": "SpaceTraders is a multiplayer sci-fi strategy game where you acquire and manage a fleet of ships across a growing and dynamic universe.\n\nSimilar to games such as Eve Online, you work with or against other players to establish trade routes, chart new systems, mine precious ores, patrol for pirates, spy on factions, and discover hidden treasures.\n\nBut what makes SpaceTraders unique is that the game is entirely accessible through open and well-documented API endpoints. In fact, SpaceTraders doesn't have a first-class client to play the game - if you want to take it for a spin, you should try one of our community-created web clients, or use the API documentation to see how you might play a game through an API.\n\nIf this sounds fun and interesting to you, please drop into our Discord and get to know the community. We are actively working on new clients, new ideas and sharing tips for how to play the game.\n\n\n```json http\n{\n \"method\": \"GET\",\n \"url\": \"https://v2-0-0.alpha.spacetraders.io\",\n}\n```" + "description": "SpaceTraders is a multiplayer sci-fi strategy game where you acquire and manage a fleet of ships across a growing and dynamic universe.\n\nSimilar to games such as Eve Online, you work with or against other players to establish trade routes, chart new systems, mine precious ores, patrol for pirates, spy on factions, and discover hidden treasures.\n\nSpaceTraders as a game is unique in that it is entirely accessible through open and well-documented API endpoints.\n\nIf this sounds fun and interesting to you, please drop into our Discord and get to know the community. We are actively working on new clients, new ideas and sharing tips for how to play the game.\n\n\n```json http\n{\n \"method\": \"GET\",\n \"url\": \"https://v2-0-0.alpha.spacetraders.io\",\n}\n```" }, "servers": [ { - "url": "https://v2-1-0.spacetraders.io", - "description": "v2.1.0" + "url": "https://api-server-2-0-0-rc-2-vxxwq5xqdq-uc.a.run.app", + "description": "v2.0.0-rc.2" } ], "paths": { - "/agents": { + "/register": { "post": { "summary": "Register New Agent", "tags": [ @@ -39,13 +39,14 @@ "type": "object", "properties": { "token": { - "type": "string" + "type": "string", + "description": "A Bearer token for accessing secured API endpoints." }, "agent": { "$ref": "../models/Agent.yaml" }, "faction": { - "$ref": "../models/Faction.yaml" + "$ref": "../models/Faction.json" }, "contract": { "$ref": "../models/Contract.yaml" @@ -61,7 +62,7 @@ } } }, - "operationId": "post-agents", + "operationId": "post-register", "description": "Creates a new agent and ties it to a temporary Account. Use `COMMERCE_REPUBLIC` as your starting faction if you don't know any other factions to choose from.\n\nThe agent symbol is a 4-8 character string that will represent your agent. This symbol will prefix the symbol of every ship you own. Agent symbols will be cast to all uppercase characters.\n\nA new agent will be granted an authorization token, a contract with their starting faction, a command ship with a jump drive, and one hundred thousand credits.\n\n> #### Keep your token safe and secure\n>\n> Save your token during the alpha phase. There is no way to regenerate this token without starting a new agent. In the future you will be able to generate and manage your tokens from the SpaceTraders website.\n\nYou can accept your contract using the `/my/contracts/{contractId}/accept` endpoint. You will want to navigate your command ship to a nearby asteroid field waypoint, and execute the `/my/ships/{shipSymbol}/accept` endpoint to mine various types of ores and minerals.\n\nReturn to the contract destination and execute the `/my/ships/{shipSymbol}/deliver` endpoint to deposit goods into the contract.\n\nWhen your contract is fulfilled, you can call `/my/contracts/{contractId}/fulfill` to retrieve payment.", "requestBody": { "content": { @@ -133,6 +134,398 @@ "description": "Fetch your agent's details." } }, + "/my/ships": { + "get": { + "summary": "List Ships", + "tags": [ + "ships" + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "description": "", + "type": "object", + "x-examples": { + "example-1": { + "data": [ + { + "symbol": "653298-1", + "crew": null, + "officers": null, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "653298", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + }, + { + "symbol": "653298-2", + "crew": null, + "officers": null, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "653298", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + }, + { + "symbol": "653298-3", + "crew": null, + "officers": null, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "653298", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + }, + { + "symbol": "653298-4", + "crew": null, + "officers": null, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "653298", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + }, + { + "symbol": "653298-5", + "crew": null, + "officers": null, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "653298", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + }, + { + "symbol": "653298-6", + "crew": null, + "officers": null, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "653298", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + } + ], + "meta": { + "total": 6, + "page": 1, + "limit": 20 + } + } + }, + "properties": { + "data": { + "type": "array", + "uniqueItems": true, + "minItems": 1, + "items": { + "$ref": "../models/Ship.json" + } + }, + "meta": { + "$ref": "../models/Meta.yaml" + } + }, + "required": [ + "data", + "meta" + ] + } + } + } + } + }, + "operationId": "get-my-ships", + "description": "Retrieve all of your ships.", + "security": [ + { + "AgentToken": [] + } + ] + }, + "post": { + "summary": "Purchase Ship", + "tags": [ + "shipyards" + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "description": "", + "type": "object", + "x-examples": { + "example-1": { + "data": { + "symbol": "4F4D44-1", + "crew": null, + "officers": null, + "fuel": 100, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "4F4D44", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + } + } + }, + "properties": { + "data": { + "type": "object", + "properties": { + "ship": { + "$ref": "../models/Ship.json" + }, + "credits": { + "type": "integer" + } + } + } + }, + "required": [ + "data" + ] + } + } + } + } + }, + "operationId": "post-my-ships", + "security": [ + { + "AgentToken": [] + } + ], + "description": "Purchase a ship", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The id of the shipyard listing you want to purchase." + } + } + } + } + } + } + } + }, + "/my/ships/{shipSymbol}": { + "parameters": [ + { + "schema": { + "type": "string" + }, + "name": "shipSymbol", + "in": "path", + "required": true + } + ], + "get": { + "summary": "View Ship", + "tags": [ + "ships" + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "description": "", + "type": "object", + "x-examples": { + "example-1": { + "data": { + "symbol": "653298-1", + "crew": null, + "officers": null, + "frame": "FRAME_DRONE", + "reactor": "REACTOR_SOLAR_I", + "engine": "ENGINE_SOLAR_PROPULSION", + "modules": [ + "MODULE_CARGO_HOLD" + ], + "mounts": [ + "MOUNT_MINING_LASER_I" + ], + "registration": { + "factionSymbol": "COMMERCE_REPUBLIC", + "agentSymbol": "653298", + "fee": 100, + "role": "EXCAVATOR" + }, + "integrity": { + "frame": 1, + "reactor": 1, + "engine": 1 + }, + "status": "DOCKED", + "location": "X1-OE-PM", + "cargo": [] + } + } + }, + "properties": { + "data": { + "$ref": "../models/Ship.json" + } + }, + "required": [ + "data" + ] + } + } + } + } + }, + "operationId": "get-my-ships-shipSymbol", + "description": "Retrieve the details of your ship.", + "security": [ + { + "AgentToken": [] + } + ] + } + }, "/my/ships/{shipSymbol}/chart": { "post": { "summary": "Chart Waypoint", @@ -277,246 +670,6 @@ "description": "Deliver cargo on a given contract." } }, - "/my/ships/{shipSymbol}/nav/transit": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "shipSymbol", - "in": "path", - "required": true, - "description": "The ship symbol" - } - ], - "post": { - "summary": "Navigate Ship", - "tags": [ - "navigation" - ], - "responses": { - "201": { - "description": "The successful transit information including the route details and changes to ship fuel, supplies, and crew wages paid. The route includes the expected time of arrival.", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": { - "shipSymbol": "3AE434-1", - "departure": "X1-OE-PM", - "destination": "X1-OE-A005", - "durationRemaining": 2159, - "arrivedAt": null - } - } - }, - "properties": { - "data": { - "type": "object", - "properties": { - "route": { - "$ref": "../models/ShipNavRoute.json" - }, - "shipFuel": { - "$ref": "../models/ShipFuel.json" - } - } - } - }, - "required": [ - "data" - ] - }, - "examples": { - "Success": { - "value": { - "data": { - "fuelCost": 38, - "navigation": { - "shipSymbol": "BA03F2-1", - "departure": "X1-OE-PM", - "destination": "X1-OE-A005", - "durationRemaining": 2279, - "arrivedAt": null - } - } - } - } - } - } - } - } - }, - "operationId": "post-my-ships-shipSymbol-navigate", - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "waypointSymbol": { - "type": "string", - "description": "The target destination." - } - }, - "required": [ - "waypointSymbol" - ] - } - } - }, - "description": "" - }, - "security": [ - { - "AgentToken": [] - } - ], - "description": "Navigate to a target destination. The destination must be located within the same system as the ship. Navigating will consume the necessary fuel and supplies from the ship's manifest, and will pay out crew wages from the agent's account.\n\nThe returned response will detail the route information including the expected time of arrival. Most ship actions are unavailable until the ship has arrived at it's destination.\n\nFor faster-than-light travel between systems, see the ship's jump action." - } - }, - "/my/ships/{shipSymbol}/nav/dock": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "shipSymbol", - "in": "path", - "required": true, - "description": "The symbol of the ship" - } - ], - "post": { - "summary": "Dock Ship", - "tags": [ - "navigation" - ], - "responses": { - "200": { - "description": "The ship has successfully docked at it's current location.", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": { - "status": "DOCKED" - } - } - }, - "properties": { - "data": { - "type": "object", - "required": [ - "status" - ], - "properties": { - "status": { - "$ref": "../models/ShipNavStatus.json" - } - } - } - }, - "required": [ - "data" - ] - }, - "examples": { - "Success": { - "value": { - "data": { - "status": "DOCKED" - } - } - } - } - } - } - } - }, - "operationId": "post-my-ships-shipSymbol-dock", - "security": [ - { - "AgentToken": [] - } - ], - "description": "Attempt to dock your ship at it's current location. Docking will only succeed if the waypoint is a dockable location, and your ship is capable of docking at the time of the request.\n\nThe endpoint is idempotent - successive calls will succeed even if the ship is already docked." - } - }, - "/my/ships/{shipSymbol}/nav/orbit": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "shipSymbol", - "in": "path", - "required": true, - "description": "The symbol of the ship" - } - ], - "post": { - "summary": "Orbit Ship", - "responses": { - "200": { - "description": "The ship has successfully moved into orbit at it's current location.", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": { - "status": "ORBIT" - } - } - }, - "properties": { - "data": { - "type": "object", - "properties": { - "status": { - "$ref": "../models/ShipNavStatus.json" - } - } - } - }, - "required": [ - "data" - ] - }, - "examples": { - "Success": { - "value": { - "data": { - "status": "IN_ORBIT" - } - } - } - } - } - } - } - }, - "operationId": "post-my-ships-shipSymbol-orbit", - "security": [ - { - "AgentToken": [] - } - ], - "description": "Attempt to move your ship into orbit at it's current location. The request will only succeed if your ship is capable of moving into orbit at the time of the request.\n\nThe endpoint is idempotent - successive calls will succeed even if the ship is already in orbit.", - "tags": [ - "navigation" - ] - } - }, "/my/ships/{shipSymbol}/jettison": { "parameters": [ { @@ -1683,7 +1836,7 @@ "$ref": "../models/Cooldown.yaml" }, "waypoint": { - "$ref": "../models/Waypoint.yaml" + "$ref": "../models/Waypoint.json" } } } @@ -1790,7 +1943,7 @@ ] } }, - "/my/ships/{shipSymbol}": { + "/my/ships/{shipSymbol}/navigate": { "parameters": [ { "schema": { @@ -1798,57 +1951,34 @@ }, "name": "shipSymbol", "in": "path", - "required": true + "required": true, + "description": "The ship symbol" } ], - "get": { - "summary": "View Ship", + "post": { + "summary": "Navigate Ship", "tags": [ - "ships" + "navigation" ], "responses": { - "200": { - "description": "OK", + "201": { + "description": "The successful transit information including the route details and changes to ship fuel, supplies, and crew wages paid. The route includes the expected time of arrival.", "content": { "application/json": { "schema": { "description": "", "type": "object", - "x-examples": { - "example-1": { - "data": { - "symbol": "653298-1", - "crew": null, - "officers": null, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "653298", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] - } - } - }, "properties": { "data": { - "$ref": "../models/Ship.json" + "type": "object", + "properties": { + "route": { + "$ref": "../models/ShipNav.json" + }, + "shipFuel": { + "$ref": "../models/ShipFuel.json" + } + } } }, "required": [ @@ -1859,246 +1989,54 @@ } } }, - "operationId": "get-my-ships-shipSymbol", - "description": "Retrieve the details of your ship.", - "security": [ - { - "AgentToken": [] - } - ] - } - }, - "/my/ships": { - "get": { - "summary": "List Ships", - "tags": [ - "ships" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": [ - { - "symbol": "653298-1", - "crew": null, - "officers": null, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "653298", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] - }, - { - "symbol": "653298-2", - "crew": null, - "officers": null, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "653298", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] - }, - { - "symbol": "653298-3", - "crew": null, - "officers": null, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "653298", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] - }, - { - "symbol": "653298-4", - "crew": null, - "officers": null, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "653298", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] - }, - { - "symbol": "653298-5", - "crew": null, - "officers": null, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "653298", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] - }, - { - "symbol": "653298-6", - "crew": null, - "officers": null, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "653298", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] - } - ], - "meta": { - "total": 6, - "page": 1, - "limit": 20 - } - } - }, - "properties": { - "data": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/Ship.json" - } - }, - "meta": { - "$ref": "../models/Meta.yaml" - } - }, - "required": [ - "data", - "meta" - ] - } + "operationId": "post-my-ships-shipSymbol-navigate", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "waypointSymbol": { + "type": "string", + "description": "The target destination." + } + }, + "required": [ + "waypointSymbol" + ] } } - } + }, + "description": "" }, - "operationId": "get-my-ships", - "description": "Retrieve all of your ships.", "security": [ { "AgentToken": [] } - ] - }, + ], + "description": "Navigate to a target destination. The destination must be located within the same system as the ship. Navigating will consume the necessary fuel and supplies from the ship's manifest, and will pay out crew wages from the agent's account.\n\nThe returned response will detail the route information including the expected time of arrival. Most ship actions are unavailable until the ship has arrived at it's destination.\n\nFor faster-than-light travel between systems, see the ship's jump action." + } + }, + "/my/ships/{shipSymbol}/dock": { + "parameters": [ + { + "schema": { + "type": "string" + }, + "name": "shipSymbol", + "in": "path", + "required": true, + "description": "The symbol of the ship" + } + ], "post": { - "summary": "Purchase Ship", + "summary": "Dock Ship", "tags": [ - "shipyards" + "navigation" ], "responses": { "200": { - "description": "OK", + "description": "The ship has successfully docked at it's current location.", "content": { "application/json": { "schema": { @@ -2107,33 +2045,75 @@ "x-examples": { "example-1": { "data": { - "symbol": "4F4D44-1", - "crew": null, - "officers": null, - "fuel": 100, - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ], - "registration": { - "factionSymbol": "COMMERCE_REPUBLIC", - "agentSymbol": "4F4D44", - "fee": 100, - "role": "EXCAVATOR" - }, - "integrity": { - "frame": 1, - "reactor": 1, - "engine": 1 - }, - "status": "DOCKED", - "location": "X1-OE-PM", - "cargo": [] + "status": "DOCKED" + } + } + }, + "properties": { + "data": { + "type": "object", + "required": [ + "status" + ], + "properties": { + "status": { + "$ref": "../models/ShipNavStatus.json" + } + } + } + }, + "required": [ + "data" + ] + }, + "examples": { + "Success": { + "value": { + "data": { + "status": "DOCKED" + } + } + } + } + } + } + } + }, + "operationId": "post-my-ships-shipSymbol-dock", + "security": [ + { + "AgentToken": [] + } + ], + "description": "Attempt to dock your ship at it's current location. Docking will only succeed if the waypoint is a dockable location, and your ship is capable of docking at the time of the request.\n\nThe endpoint is idempotent - successive calls will succeed even if the ship is already docked." + } + }, + "/my/ships/{shipSymbol}/orbit": { + "parameters": [ + { + "schema": { + "type": "string" + }, + "name": "shipSymbol", + "in": "path", + "required": true, + "description": "The symbol of the ship" + } + ], + "post": { + "summary": "Orbit Ship", + "responses": { + "200": { + "description": "The ship has successfully moved into orbit at it's current location.", + "content": { + "application/json": { + "schema": { + "description": "", + "type": "object", + "x-examples": { + "example-1": { + "data": { + "status": "ORBIT" } } }, @@ -2141,11 +2121,8 @@ "data": { "type": "object", "properties": { - "ship": { - "$ref": "../models/Ship.json" - }, - "credits": { - "type": "integer" + "status": { + "$ref": "../models/ShipNavStatus.json" } } } @@ -2153,33 +2130,56 @@ "required": [ "data" ] - } - } - } - } - }, - "operationId": "post-my-ships", - "security": [ - { - "AgentToken": [] - } - ], - "description": "Purchase a ship", - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "id": { - "type": "string", - "description": "The id of the shipyard listing you want to purchase." + }, + "examples": { + "Success": { + "value": { + "data": { + "status": "IN_ORBIT" + } + } } } } } } + }, + "operationId": "post-my-ships-shipSymbol-orbit", + "security": [ + { + "AgentToken": [] + } + ], + "description": "Attempt to move your ship into orbit at it's current location. The request will only succeed if your ship is capable of moving into orbit at the time of the request.\n\nThe endpoint is idempotent - successive calls will succeed even if the ship is already in orbit.", + "tags": [ + "navigation" + ] + } + }, + "/my/ships/{shipSymbol}/negotiate": { + "parameters": [ + { + "schema": { + "type": "string" + }, + "name": "shipSymbol", + "in": "path", + "required": true, + "description": "The symbol of the ship" } + ], + "post": { + "summary": "Negotiate with a waypoint", + "operationId": "post-my-ships-negotiate", + "security": [ + { + "AgentToken": [] + } + ], + "description": "Attempt to negotiate with the faction at a waypoint. The request will only succeed if the waypoint is a negotiable location, and your ship is capable of negotiating using an envoy.", + "tags": [ + "ships" + ] } }, "/my/contracts": { @@ -2648,625 +2648,6 @@ ] } }, - "/systems/{systemSymbol}/shipyards": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "systemSymbol", - "in": "path", - "required": true, - "description": "the system symbol" - } - ], - "get": { - "summary": "List Shipyards", - "tags": [ - "shipyards" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": [ - { - "symbol": "X1-OE-PM", - "faction": "COMMERCE_REPUBLIC" - } - ], - "meta": { - "total": 1, - "page": 1, - "limit": 20 - } - } - }, - "properties": { - "data": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/Shipyard.yaml" - } - }, - "meta": { - "$ref": "../models/Meta.yaml" - } - }, - "required": [ - "data", - "meta" - ] - } - } - } - } - }, - "operationId": "get-systems-systemSymbol-shipyards", - "security": [ - { - "AgentToken": [] - } - ], - "description": "Returns a list of all shipyards in a system." - } - }, - "/systems/{systemSymbol}/shipyards/{waypointSymbol}": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "systemSymbol", - "in": "path", - "required": true, - "description": "The system symbol" - }, - { - "schema": { - "type": "string" - }, - "name": "waypointSymbol", - "in": "path", - "required": true, - "description": "The waypoint symbol" - } - ], - "get": { - "summary": "Shipyard Details", - "tags": [ - "shipyards" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "data": { - "$ref": "../models/Shipyard.yaml" - } - } - } - } - } - } - }, - "operationId": "get-systems-systemSymbol-shipyards-waypointSymbol", - "security": [ - { - "AgentToken": [] - } - ] - } - }, - "/systems/{systemSymbol}/shipyards/{waypointSymbol}/ships": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "systemSymbol", - "in": "path", - "required": true, - "description": "The system symbol" - }, - { - "schema": { - "type": "string" - }, - "name": "waypointSymbol", - "in": "path", - "required": true, - "description": "The waypoint symbol" - } - ], - "get": { - "summary": "Shipyard Listings", - "tags": [ - "shipyards" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": [ - { - "id": "cl0nahta90000aq0jonm1nprl", - "waypoint": "X1-OE-PM", - "price": 58191, - "role": "EXCAVATOR", - "frame": "FRAME_DRONE", - "reactor": "REACTOR_SOLAR_I", - "engine": "ENGINE_SOLAR_PROPULSION", - "modules": [ - "MODULE_CARGO_HOLD" - ], - "mounts": [ - "MOUNT_MINING_LASER_I" - ] - } - ], - "meta": { - "total": 1, - "page": 1, - "limit": 20 - } - } - }, - "properties": { - "data": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/ShipyardListing.yaml" - } - }, - "meta": { - "$ref": "../models/Meta.yaml" - } - }, - "required": [ - "data", - "meta" - ] - }, - "examples": {} - } - } - } - }, - "operationId": "get-systems-systemSymbol-shipyards-waypointSymbol-ships", - "security": [ - { - "AgentToken": [] - } - ] - } - }, - "/trade/{tradeSymbol}/imports": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "tradeSymbol", - "in": "path", - "required": true, - "description": "The trade symbol" - } - ], - "get": { - "summary": "Trade Imports", - "tags": [ - "markets" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "properties": { - "data": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/MarketTrade.yaml" - } - }, - "meta": { - "$ref": "../models/Meta.yaml" - } - }, - "required": [ - "data", - "meta" - ] - }, - "examples": {} - } - } - } - }, - "operationId": "get-trade-tradeSymbol-imports", - "security": [ - { - "AgentToken": [] - } - ] - } - }, - "/trade/{tradeSymbol}/exports": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "tradeSymbol", - "in": "path", - "required": true, - "description": "The trade symbol" - } - ], - "get": { - "summary": "Trade Exports", - "tags": [ - "markets" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "properties": { - "data": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/MarketTrade.yaml" - } - }, - "meta": { - "$ref": "../models/Meta.yaml" - } - }, - "required": [ - "data", - "meta" - ] - }, - "examples": {} - } - } - } - }, - "operationId": "get-trade-tradeSymbol-exports", - "security": [ - { - "AgentToken": [] - } - ] - } - }, - "/trade/{tradeSymbol}/exchange": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "tradeSymbol", - "in": "path", - "required": true, - "description": "The trade symbol" - } - ], - "get": { - "summary": "Trade Exchanges", - "tags": [ - "markets" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "properties": { - "data": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/MarketTrade.yaml" - } - }, - "meta": { - "$ref": "../models/Meta.yaml" - } - }, - "required": [ - "data", - "meta" - ] - }, - "examples": {} - } - } - } - }, - "operationId": "get-trade-tradeSymbol-exchange", - "security": [ - { - "AgentToken": [] - } - ] - } - }, - "/systems/{systemSymbol}/markets": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "systemSymbol", - "in": "path", - "required": true, - "description": "The system symbol" - } - ], - "get": { - "summary": "List Markets", - "tags": [ - "markets" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": { - "exports": [ - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "MICROPROCESSORS", - "price": 834, - "tariff": 0 - } - ], - "imports": [ - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "SILICON", - "price": 144, - "tariff": 0 - }, - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "QUARTZ", - "price": 286, - "tariff": 0 - } - ], - "exchange": [] - } - } - }, - "properties": { - "data": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "data" - ] - }, - "examples": { - "Success": { - "value": { - "data": [ - "X1-AK3-88760F" - ], - "meta": { - "total": 1, - "page": 1, - "limit": 20 - } - } - } - } - } - } - } - }, - "operationId": "get-systems-systemSymbol-markets", - "description": "Retrieve a list of all charted markets in the given system. Markets are only available if the waypoint is charted and contains a communications relay.\n\nTo install a communications relay at a market, look at the `my/ships/{shipSymbol}/deploy` endpoint.", - "security": [ - { - "AgentToken": [] - } - ] - } - }, - "/systems/{systemSymbol}/markets/{waypointSymbol}": { - "parameters": [ - { - "schema": { - "type": "string" - }, - "name": "systemSymbol", - "in": "path", - "required": true, - "description": "The system symbol" - }, - { - "schema": { - "type": "string" - }, - "name": "waypointSymbol", - "in": "path", - "required": true, - "description": "The waypoint symbol" - } - ], - "get": { - "summary": "View Market", - "tags": [ - "markets" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "", - "type": "object", - "x-examples": { - "example-1": { - "data": { - "exports": [ - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "MICROPROCESSORS", - "price": 834, - "tariff": 0 - } - ], - "imports": [ - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "SILICON", - "price": 144, - "tariff": 0 - }, - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "QUARTZ", - "price": 286, - "tariff": 0 - } - ], - "exchange": [] - } - } - }, - "properties": { - "data": { - "type": "object", - "required": [ - "exports", - "imports", - "exchange" - ], - "properties": { - "exports": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/MarketTrade.yaml" - } - }, - "imports": { - "type": "array", - "uniqueItems": true, - "minItems": 1, - "items": { - "$ref": "../models/MarketTrade.yaml" - } - }, - "exchange": { - "type": "array", - "items": { - "$ref": "../models/MarketTrade.yaml" - } - } - } - } - }, - "required": [ - "data" - ] - }, - "examples": { - "Success": { - "value": { - "data": { - "exports": [ - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "MICROPROCESSORS", - "price": 834, - "tariff": 0 - } - ], - "imports": [ - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "SILICON", - "price": 144, - "tariff": 0 - }, - { - "waypointSymbol": "X1-OE-PM", - "tradeSymbol": "QUARTZ", - "price": 286, - "tariff": 0 - } - ], - "exchange": [] - } - } - } - } - } - } - } - }, - "operationId": "get-systems-systemSymbol-markets-waypointSymbol", - "description": "Retrieve imports, exports and exchange data from a marketplace. Imports can be sold, exports can be purchased, and exchange trades can be purchased or sold.\n\nMarket data is only available if you have a ship at the location, or the location is charted and has a communications relay deployed.\n\nSee `/my/ships/{shipSymbol}/deploy` for deploying relays at a location.", - "security": [ - { - "AgentToken": [] - } - ] - } - }, "/systems/{systemSymbol}/waypoints": { "parameters": [ { @@ -3378,7 +2759,7 @@ "uniqueItems": true, "minItems": 1, "items": { - "$ref": "../models/Waypoint.yaml" + "$ref": "../models/Waypoint.json" } }, "meta": { @@ -3389,88 +2770,6 @@ "data", "meta" ] - }, - "examples": { - "Success": { - "value": { - "data": [ - { - "system": "X1-OE", - "symbol": "X1-OE-PM", - "type": "PLANET", - "x": 10, - "y": 5, - "orbitals": [ - "X1-OE-PM01" - ], - "faction": "COMMERCE_REPUBLIC", - "features": [ - "MARKETPLACE", - "SHIPYARD" - ], - "traits": [ - "OVERCROWDED", - "HIGH_TECH", - "BUREAUCRATIC", - "TRADING_HUB", - "TEMPERATE" - ], - "charted": true, - "chartedBy": null - }, - { - "system": "X1-OE", - "symbol": "X1-OE-PM01", - "type": "MOON", - "x": 10, - "y": 5, - "orbitals": [], - "faction": "COMMERCE_REPUBLIC", - "features": [ - "MARKETPLACE" - ], - "traits": [ - "WEAK_GRAVITY" - ], - "charted": true, - "chartedBy": null - }, - { - "system": "X1-OE", - "symbol": "X1-OE-A005", - "type": "ASTEROID_FIELD", - "x": -1, - "y": -29, - "orbitals": [], - "faction": "MINERS_COLLECTIVE", - "features": [], - "traits": [ - "COMMON_METAL_DEPOSITS" - ], - "charted": true, - "chartedBy": null - }, - { - "system": "X1-OE", - "symbol": "X1-OE-25X", - "type": "JUMP_GATE", - "x": -38, - "y": 47, - "orbitals": [], - "faction": "SPACERS_GUILD", - "features": [], - "traits": [], - "charted": true, - "chartedBy": null - } - ], - "meta": { - "total": 4, - "page": 1, - "limit": 20 - } - } - } } } } @@ -3605,7 +2904,7 @@ "uniqueItems": true, "minItems": 1, "items": { - "$ref": "../models/Waypoint.yaml" + "$ref": "../models/Waypoint.json" } }, "meta": { @@ -3616,88 +2915,6 @@ "data", "meta" ] - }, - "examples": { - "Success": { - "value": { - "data": [ - { - "system": "X1-OE", - "symbol": "X1-OE-PM", - "type": "PLANET", - "x": 10, - "y": 5, - "orbitals": [ - "X1-OE-PM01" - ], - "faction": "COMMERCE_REPUBLIC", - "features": [ - "MARKETPLACE", - "SHIPYARD" - ], - "traits": [ - "OVERCROWDED", - "HIGH_TECH", - "BUREAUCRATIC", - "TRADING_HUB", - "TEMPERATE" - ], - "charted": true, - "chartedBy": null - }, - { - "system": "X1-OE", - "symbol": "X1-OE-PM01", - "type": "MOON", - "x": 10, - "y": 5, - "orbitals": [], - "faction": "COMMERCE_REPUBLIC", - "features": [ - "MARKETPLACE" - ], - "traits": [ - "WEAK_GRAVITY" - ], - "charted": true, - "chartedBy": null - }, - { - "system": "X1-OE", - "symbol": "X1-OE-A005", - "type": "ASTEROID_FIELD", - "x": -1, - "y": -29, - "orbitals": [], - "faction": "MINERS_COLLECTIVE", - "features": [], - "traits": [ - "COMMON_METAL_DEPOSITS" - ], - "charted": true, - "chartedBy": null - }, - { - "system": "X1-OE", - "symbol": "X1-OE-25X", - "type": "JUMP_GATE", - "x": -38, - "y": 47, - "orbitals": [], - "faction": "SPACERS_GUILD", - "features": [], - "traits": [], - "charted": true, - "chartedBy": null - } - ], - "meta": { - "total": 4, - "page": 1, - "limit": 20 - } - } - } } } } @@ -3711,9 +2928,165 @@ ], "description": "View the details of a waypoint." } + }, + "/systems/{systemSymbol}/waypoints/{waypointSymbol}/shipyard": { + "parameters": [ + { + "schema": { + "type": "string" + }, + "name": "systemSymbol", + "in": "path", + "required": true, + "description": "The system symbol" + }, + { + "schema": { + "type": "string" + }, + "name": "waypointSymbol", + "in": "path", + "required": true, + "description": "The waypoint symbol" + } + ], + "get": { + "summary": "Get Shipyard", + "tags": [ + "shipyards" + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "description": "", + "type": "object", + "properties": { + "data": { + "type": "array", + "uniqueItems": true, + "minItems": 1, + "items": { + "$ref": "../models/Shipyard.json" + } + }, + "meta": { + "$ref": "../models/Meta.yaml" + } + }, + "required": [ + "data", + "meta" + ] + }, + "examples": {} + } + } + } + }, + "operationId": "get-systems-systemSymbol-shipyards-waypointSymbol-ships", + "security": [ + { + "AgentToken": [] + } + ] + } + }, + "/systems/{systemSymbol}/waypoints/{waypointSymbol}/market": { + "parameters": [ + { + "schema": { + "type": "string" + }, + "name": "systemSymbol", + "in": "path", + "required": true, + "description": "The system symbol" + }, + { + "schema": { + "type": "string" + }, + "name": "waypointSymbol", + "in": "path", + "required": true, + "description": "The waypoint symbol" + } + ], + "get": { + "summary": "View Market", + "tags": [ + "markets" + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "description": "", + "type": "object", + "properties": { + "data": { + "$ref": "../models/Market.json" + } + }, + "required": [ + "data" + ] + } + } + } + } + }, + "operationId": "get-system-waypoint-market", + "description": "Retrieve imports, exports and exchange data from a marketplace. Imports can be sold, exports can be purchased, and exchange trades can be purchased or sold.\n\nMarket data is only available if you have a ship at the location, or the location is charted and has a communications relay deployed.\n\nSee `/my/ships/{shipSymbol}/deploy` for deploying relays at a location.", + "security": [ + { + "AgentToken": [] + } + ] + } + }, + "/factions": { + "get": { + "summary": "List Factions", + "description": "List all discovered factions in the game.", + "tags": [ + "factions" + ], + "operationId": "get-factions" + } + }, + "/factions/{factionSymbol}": { + "parameters": [ + { + "schema": { + "type": "string", + "default": "CGR" + }, + "name": "factionSymbol", + "in": "path", + "required": true, + "description": "The faction symbol" + } + ], + "get": { + "summary": "View Faction", + "tags": [ + "factions" + ], + "operationId": "get-factions-factionSymbol", + "description": "View the details of a faction." + } } }, "tags": [ + { + "name": "factions" + }, { "name": "ships" }, @@ -3779,9 +3152,6 @@ }, { "name": "shipyards" - }, - { - "name": "markets" } ], "components": {