July 2017
Beginner to intermediate
358 pages
10h 54m
English
It is perfectly acceptable to use a query string as part of an API call; however, I would refrain from using this to pass data to the service. Instead the query should be used to perform actions such as:
If we need to make a call to a controller, we discussed earlier that we should use a POST request as this is most likely a non-idempotent request. To pass data to the service, we should include the data inside of the body. However, we could use a query string to filter the action of the controller:
POST /sendStatusUpdateEmail?$group=admin { "message": "All services are now operational\nPlease accept our apologies for any inconvenience caused.\n The Kitten API team"}
In the preceding example, ...
Read now
Unlock full access