Interpret REST requests, responses and credentials
An inventory integration needs to read one interface record. Its API expects a bearer token in the HTTPS Authorization header. Which request design fits?
Interpret REST requests, responses and credentials
The REST authentication lesson compares credential schemes including a bearer token in the request header.
Work through the decision
An inventory integration needs to read one interface record. Its API expects a bearer token in the HTTPS Authorization header. Which request design fits?
Check your reasoning
Send a GET for the documented resource using the scoped token over TLS. Check the HTTP status and decode the documented response representation. Keep the token out of query strings and logs.
Interpret the evidence
- GET
- A documented GET retrieves a representation without requesting a state change.
- POST
- Commonly submits a new resource to a collection or invokes a documented operation.
- DELETE
- Requests removal of the identified resource when authorized and defined by the API.
- Bearer token
- The client presents an access token in the Authorization header. Protect it in transit and at rest.
Practice the guide skills
- Map create, read, update and delete to a documented API’s HTTP verbs, including the distinction between replacing with PUT and a partial PATCH.
- Read a TLS-protected request’s authentication, content type, status and JSON response. Compare basic, bearer and API-key requirements without logging secrets.
Official objectives for this lesson
Related lesson · Maintain a change record that another operator can use
Interpret REST requests, responses and credentials quiz
Answer 3 questions. Check each answer for an explanation.