HTTP Flashcards

(26 cards)

1
Q

Define HTTP.

A

Hypertext Transfer Protocol, the foundation of data communication on the web.

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

What does REST stand for?

A

Representational State Transfer, an architectural style for designing networked applications.

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

True or false: GET requests can modify server data.

A

FALSE

GET requests are intended for retrieving data only.

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

Fill in the blank: POST is used to _______ data to the server.

A

send

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

What is the purpose of the PUT method?

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
6
Q

Define DELETE method.

A

A method used to remove a specified resource from the server.

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

What does HEAD request return?

A

Similar to GET, but only returns HTTP headers, not the body.

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

True or false: OPTIONS method shows allowed HTTP methods for a resource.

A

TRUE

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

What is the PATCH method used for?

A

To apply partial modifications to a resource.

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

Define status codes.

A

Three-digit codes indicating the result of an HTTP request.

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

What does 200 OK status code mean?

A

The request was successful, and the server returned the requested data.

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

Fill in the blank: 404 indicates that a resource was _______.

A

not found

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

What does 500 Internal Server Error signify?

A

A generic error indicating the server encountered an unexpected condition.

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

True or false: 301 Moved Permanently indicates a temporary redirect.

A

FALSE

301 indicates a permanent change in resource location.

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

Define CORS.

A

Cross-Origin Resource Sharing, a security feature that allows restricted resources to be requested from another domain.

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

What is the purpose of HTTP headers?

A

To provide additional information about the request or response.

17
Q

Fill in the blank: User-Agent header identifies the _______.

A

client software making the request.

18
Q

What does Content-Type header specify?

A

The media type of the resource being sent or received.

19
Q

True or false: HTTP/2 improves performance over HTTP/1.1.

20
Q

Define session in web context.

A

A temporary interaction between a user and a web application.

21
Q

What is the role of cookies?

A

To store user-specific information on the client side for session management.

22
Q

Fill in the blank: JWT stands for _______.

A

JSON Web Token

23
Q

What is API?

A

Application Programming Interface, a set of rules for building software applications.

24
Q

True or false: WebSockets allow full-duplex communication.

25
Define **throttling** in API context.
Limiting the number of requests a user can make to an API in a given time.
26
What is the purpose of **rate limiting**?
To control the amount of incoming requests to prevent abuse and ensure service availability.