-
Notifications
You must be signed in to change notification settings - Fork 67
Open
Description
First let me say thanks for this great API.
I've noticed while playing around with it that all the POST methods seem to be broken i.e.:
❯ curl --location 'https://countriesnow.space/api/v0.1/countries/states' \
--data '{
"country": "Nigeria"
}'
{"error":true,"msg":"missing param (country or iso2)"}
I've got these requests to work with the query string, IE
❯ curl --location 'https://countriesnow.space/api/v0.1/countries/states/?country="Nigeria"'
So I am guessing something is going wrong with the Middleware redirection in
* Redirect all POST requests by appending "/q" to the end of the route |
Is there anyway of investigating this further? I've cloned the repo and the tests pass, which contradicts my lived experience.
Alternatively, is it time to remove all the POST requests (at least in the documentation) for their proper GET versions? I'm happy to take this on
Metadata
Metadata
Assignees
Labels
No labels