Closed SReject closed 1 year ago
Thanks for the great feedback, I think we'll add the factions to the docs while we figure out how to handle endpoints that maybe shouldn't require a token.
I was able to see the factions by going to https://api.spacetraders.io/v2/factions
This may be a documentation issue. If the endpoint is documented with a playerFaction ENUM it is clear witch values are allowed. The game documentation then should have basic player faction stats/description.
Edit: This is already documented...
"description": "The faction you choose determines your headquarters.",
"enum": [
"COSMIC",
"VOID",
"GALACTIC",
"QUANTUM",
"DOMINION"
]
},
Given that /factions
is available without auth, and now has an isRecruiting
field. I propose that we should change that enum to a string, and send an appropriate error based on the string given: 404 Not Found
for a faction not found and 403 Forbidden
for a faction that's not recruiting?
issue title could also use an update, at this point. (As we've established the factions endpoint does not require auth)
This has been resolved with factions endpoint no longer being gated
To create an agent/account the request body requires an initial faction to be specified but the API endpoint to list factions is gated by auth.