This post contains a few useful REST API multiple-choice questions (quiz) to self-test your knowledge of REST API development.
The answers to each question have been given at end of this post.
- Representational State Transform
- Representational State Transfer
- Represent State Transform
- Represent State Transfer
Q2. What is the protocol used in REST?
- FTP
- HTTP
- JMX
- SOAP
Q3. What is the HTTP Status Code Related to Page Not Found?
- 402
- 404
- 403
- 401
Q4. What is the HTTP Code Related to Internal Server Error?
- 500
- 501
- 504
- 502
Q5. What is the HTTP Code 200 Indicate?
- Error
- Completed
- Success
- Warning
Q6. Which HTTP method do we use to make an HTTP request to create a new resource?
- POST
- PUT
- GET
- CREATE
Q7. Which HTTP method do we use to make an HTTP request to update an existing resource?
- POST
- PUT
- UPDATE
- DELETE
Q8. Choose the correct URI format to get a sub-resource by resource id and sub-resource id
- /{resource}/{resource-id}/{sub-resource}/{sub-resource-id}
- /{resource}/{sub-resource}/{sub-resource-id}
- {sub-resource}/{sub-resource-id}/{resource}/{resource-id}
- /{resource}/{resource-id}/{sub-resource-id}/{sub-resource}
Q9. Which is not REST Architectural Constraints?
- Client-Server
- Stateless
- Cacheable
- Service orchestration
Q10. What is the HTTP status code 201 indicate?
- OK
- Created
- Accepted
- No Content
Answers
Q1
2. Representational State Transfer
Q2
2. HTTP
Q3
2. 404
Q4
1. 500
Q5
3. Success
Q6
1. POST
Q7
2. PUT
Q8
1. /{resource}/{resource-id}/{sub-resource}/{sub-resource-id}
Q9
4. Service orchestration
Q10
2. Created
Related Posts
Free Spring Boot Tutorial | Full In-depth Course | Learn Spring Boot in 10 Hours
Watch this course on YouTube at Spring Boot Tutorial | Fee 10 Hours Full Course
Comments
Post a Comment