reading-notes

API’s

What does REST stand for?

Representational State Transfer

REST APIs are designed around a __

set of architectural constraints or principles, also known as RESTful constraints

What is an identifier of a resource? Give an example.

a unique string or URI (Uniform Resource Identifier) that identifies a specific resource on the web. For example, consider a web service that provides information about Disney.https://example.com/anime/123

What are the most common HTTP verbs?

Get, Post, Delete, Patch, Head, Options

What should the URIs be based on?

based on the resources that they identify

Give an example of a good URI.

https://disney.com/onepiece/v1/love2watch/12345/

What does it mean to have a ‘chatty’ web API? Is this a good or a bad thing?

efers to an API that requires a large number of small requests (chatty requests) to perform a single high-level action or retrieve a large amount of data.

What status code does a successful GET request return?

a status code of 200 OK

What status code does an unsuccessful GET request return?

404 Not Found,401 Unauthorized,403 Forbidden,400 Bad Request

What status code does a successful POST request return?

201 Created or 200 OK.

What status code does a successful DELETE request return?

204 No Content.