From 16c7ff4988d9d1cb1a603cecad2aceb92479abff Mon Sep 17 00:00:00 2001 From: James Clague Date: Fri, 30 Dec 2022 16:16:28 -0700 Subject: [PATCH 1/3] Create .spectral.mjs --- .spectral.mjs | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .spectral.mjs diff --git a/.spectral.mjs b/.spectral.mjs new file mode 100644 index 0000000..cca9041 --- /dev/null +++ b/.spectral.mjs @@ -0,0 +1,2 @@ +import ruleset from "https://stoplight.io/api/v1/projects/cHJqOjE3NTU4OQ/spectral.js?branch=main&token=e4f4ffbe-f8ad-4829-b09f-cf2703afac49"; +export default { extends: ruleset }; From 27f63adf4a0338c0a8b0cb244c9fa848f783bad5 Mon Sep 17 00:00:00 2001 From: "james.clague@brct.io" Date: Fri, 30 Dec 2022 16:25:28 -0700 Subject: [PATCH 2/3] Add pagination params to GET:systems --- reference/SpaceTraders.json | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/reference/SpaceTraders.json b/reference/SpaceTraders.json index 7170af5..1a1e0da 100644 --- a/reference/SpaceTraders.json +++ b/reference/SpaceTraders.json @@ -189,6 +189,24 @@ "summary": "List Systems", "tags": [ "systems" + ], + "parameters": [ + { + "schema": { + "type": "number" + }, + "in": "query", + "name": "page", + "description": "What page to request" + }, + { + "schema": { + "type": "number" + }, + "in": "query", + "name": "limit", + "description": "How many entries to return per page" + } ] } }, From 6dc72cc7e5921512a1fa73529d0e4dc765f3987e Mon Sep 17 00:00:00 2001 From: "james.clague@brct.io" Date: Mon, 2 Jan 2023 09:41:04 -0700 Subject: [PATCH 3/3] Add meta query params to list factions, ships, contracts, systems, waypoints. Fix typo for Galactic faction /register enum. --- reference/SpaceTraders.json | 80 +++++++++++++++++++++++++++++++++++-- 1 file changed, 76 insertions(+), 4 deletions(-) diff --git a/reference/SpaceTraders.json b/reference/SpaceTraders.json index 1a1e0da..6443f28 100644 --- a/reference/SpaceTraders.json +++ b/reference/SpaceTraders.json @@ -72,7 +72,7 @@ "enum": [ "COSMIC", "VOID", - "GALLACTIC", + "GALACTIC", "QUANTUM", "DOMINION", "ASTRO", @@ -193,15 +193,15 @@ "parameters": [ { "schema": { - "type": "number" + "type": "integer" }, "in": "query", "name": "page", - "description": "What page to request" + "description": "What entry offset to request" }, { "schema": { - "type": "number" + "type": "integer" }, "in": "query", "name": "limit", @@ -298,6 +298,24 @@ "summary": "List Waypoints", "tags": [ "systems" + ], + "parameters": [ + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "page", + "description": "What entry offset to request" + }, + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "limit", + "description": "How many entries to return per page" + } ] }, "parameters": [ @@ -569,6 +587,24 @@ "summary": "List Factions", "tags": [ "factions" + ], + "parameters": [ + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "page", + "description": "What entry offset to request" + }, + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "limit", + "description": "How many entries to return per page" + } ] } }, @@ -689,6 +725,24 @@ "summary": "List Contracts", "tags": [ "contracts" + ], + "parameters": [ + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "page", + "description": "What entry offset to request" + }, + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "limit", + "description": "How many entries to return per page" + } ] } }, @@ -978,6 +1032,24 @@ "summary": "List Ships", "tags": [ "fleet" + ], + "parameters": [ + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "page", + "description": "What entry offset to request" + }, + { + "schema": { + "type": "integer" + }, + "in": "query", + "name": "limit", + "description": "How many entries to return per page" + } ] }, "post": {