General Flashcards

1
Q

What does REST stand for?

A

Representational State Transfer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is a REST API?

A

An API that conforms to the constraints of the REST architectural style and allows for interaction with RESTful web services.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are the main HTTP methods used in REST?

A

GET, POST, PUT, DELETE, PATCH

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the purpose of the GET method?

A

To retrieve data from a server.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What does the POST method do?

A

To send data to a server to create a new resource.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

When is the PUT method used?

A

To update an existing resource or create it if it does not exist.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the DELETE method used for?

A

To remove a resource from the server.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is the PATCH method?

A

To apply partial modifications to a resource.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is a resource in REST?

A

An object or representation of something that can be accessed or manipulated via a URL.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is an endpoint in REST?

A

A specific URL where a resource can be accessed or an action can be performed.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is meant by statelessness in REST?

A

Each request from client to server must contain all the information needed to understand and process the request, without relying on any stored context on the server.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is JSON?

A

JavaScript Object Notation, a lightweight data-interchange format used in REST APIs for data representation.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is the role of HTTP headers in REST APIs?

A

They convey additional information about the request or response, such as content type, authentication tokens, and caching directives.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What does the status code 200 mean?

A

OK - The request has succeeded.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What does the status code 404 signify?

A

Not Found - The server can’t find the requested resource.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is HATEOAS?

A

Hypermedia As The Engine Of Application State, a constraint of REST that ensures clients interact with the application entirely through provided hypermedia links.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What is CORS?

A

Cross-Origin Resource Sharing, a security feature implemented by browsers to control how resources on a web page can be requested from another domain.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What does idempotent mean in the context of REST methods?

A

An operation that can be applied multiple times without changing the result beyond the initial application. Examples are GET, PUT, and DELETE.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What is a RESTful web service?

A

A web service that adheres to the REST architectural constraints and principles.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What is URI?

A

Uniform Resource Identifier, a string of characters that unambiguously identifies a particular resource.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

What does CRUD stand for in the context of REST?

A

Create, Read, Update, Delete

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

What is an API key?

A

A unique identifier used to authenticate a client making API requests.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

What is OAuth?

A

An open standard for access delegation commonly used to grant websites or applications limited access to a user’s information without exposing passwords.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

What is the purpose of the OPTIONS HTTP method?

A

To describe the communication options for the target resource.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

What is an HTTP request?

A

A message sent by a client to initiate an action on the server.

26
Q

What is an HTTP response?

A

A message sent by the server back to the client following an HTTP request.

27
Q

What is a REST client?

A

A client that interacts with a RESTful web service.

28
Q

What is the role of a REST API documentation?

A

To provide detailed information on how to use the API, including available endpoints, request formats, response formats, and error codes.

29
Q

What does the status code 201 indicate?

A

Created - The request has been fulfilled and has resulted in the creation of a new resource.

30
Q

What does the status code 401 signify?

A

Unauthorized - The request requires user authentication.

31
Q

What does the status code 500 mean?

A

Internal Server Error - A generic error message when the server encounters an unexpected condition.

32
Q

What is the difference between PUT and PATCH?

A

PUT replaces the entire resource, while PATCH applies partial updates to the resource.

33
Q

What is rate limiting in REST APIs?

A

A technique to control the amount of incoming requests to a server within a given time frame.

34
Q

What is an API endpoint?

A

A specific path where API interactions occur, usually a URL mapping to a specific resource or action.

35
Q

What is JSON schema?

A

A vocabulary that allows you to annotate and validate JSON documents.

36
Q

What is meant by ‘representation’ in REST?

A

The format in which a resource is presented, often as JSON or XML.

37
Q

What does the status code 204 indicate?

A

No Content - The server successfully processed the request and is not returning any content.

38
Q

What is an HTTP status code?

A

A code returned by the server to indicate the result of the HTTP request.

39
Q

What is content negotiation in REST?

A

A mechanism that allows the client and server to agree on the content format for the response.

40
Q

What is the purpose of the HEAD HTTP method?

A

To retrieve the headers of a resource without the body, similar to a GET request.

41
Q

What is RESTful routing?

A

The practice of structuring URLs to represent resources and actions in a RESTful API.

42
Q

What is a resource identifier?

A

A unique value used to identify a specific resource, often a URI.

43
Q

What is the role of HTTP methods in REST?

A

They define the action to be performed on a resource, such as retrieving, creating, updating, or deleting it.

44
Q

What is an HTTP request body?

A

The part of an HTTP request that contains the data being sent to the server.

45
Q

What does the status code 403 signify?

A

Forbidden - The server understood the request but refuses to authorize it.

46
Q

What is REST API versioning?

A

A method to manage changes to the API over time, allowing different versions to coexist.

47
Q

What does the status code 409 indicate?

A

Conflict - The request could not be processed because of conflict in the request, such as an edit conflict.

48
Q

What is hypermedia in REST?

A

Links within the returned resources that guide the client on how to interact with the API further.

49
Q

What is a RESTful architecture?

A

An architectural style that uses standard HTTP methods and stateless communication to interact with resources.

50
Q

What is the difference between REST and SOAP?

A

REST is a simpler, more flexible architectural style using standard HTTP methods, while SOAP is a protocol with more rigid standards and built-in security and transaction compliance.

51
Q

What is an API gateway?

A

A server that acts as an API front-end, handling requests, transformations, and other services.

52
Q

What does the status code 202 mean?

A

Accepted - The request has been accepted for processing, but the processing has not been completed.

53
Q

What is an API rate limit?

A

A restriction placed on the number of API calls a user can make in a given time period.

54
Q

What is an endpoint URL?

A

A specific address (URL) where an API can be accessed by clients.

55
Q

What is a response body in REST?

A

The part of an HTTP response containing the data requested by the client.

56
Q

What is an idempotent operation?

A

An operation that has the same result no matter how many times it is performed.

57
Q

What is the status code 301 used for?

A

Moved Permanently - The resource has been permanently moved to a new URL.

58
Q

What does ‘RESTful’ mean?

A

Conforming to the principles of REST, typically meaning the API is designed to use HTTP methods and URLs in a standard way.

59
Q

What is the status code 400 used for?

A

Bad Request - The server cannot process the request due to client error.

60
Q

What is a web service?

A

A software system designed to support interoperable machine-to-machine interaction over a network.