0% found this document useful (0 votes)
73 views2 pages

APi Question

Uploaded by

zeenat
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
73 views2 pages

APi Question

Uploaded by

zeenat
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

00:00 - Introduction

00:29 - How are REST APIs stateless?

01:36 - Explain the HTTP methods

02:09 - Explain the HTTP codes

02:32 - What is a URI?

02:58 - Best practices in making URI for RESTful web services?

03:30 - Differences between REST and SOAP?

04:17 - Differences between REST and AJAX?

04:58 - Tools to develop and test REST APIs?

05:29 - Real-world examples of REST APIs?

05:59 - Pros and cons of RESTful web services

1 What is the difference between PUT, POST and PATCH?

1:22 #2 What is a payload in the context of a REST API?

1:47 #3 What is a REST message?

2:11 #4 What are the core components of an HTTP request?

2:59 #5 What are the core components of an HTTP response?

3:49 #6 What is an idempotent method and why are they important?

4:32 #7 What is the difference between idempotent and safe HTTP


methods?

4:51 #8 Explain caching in a RESTful architecture

𝗚𝘂𝗶𝗱𝗲𝗹𝗶𝗻𝗲𝘀 𝗳𝗼𝗿 𝗲𝗳𝗳𝗲𝗰𝘁𝗶𝘃𝗲 𝗥𝗘𝗦𝗧 𝗔𝗣𝗜 𝗗𝗲𝘃𝗲𝗹𝗼𝗽𝗺𝗲𝗻𝘁

- 𝗗𝗲𝘀𝗰𝗿𝗶𝗽𝘁𝗶𝘃𝗲 𝗥𝗲𝘀𝗼𝘂𝗿𝗰𝗲 𝗡𝗮𝗺𝗲𝘀:


- Choose clear and concise names for your resources (e.g., "/customer/profile"
instead of "/user/123").

- 𝗛𝗧𝗧𝗣 𝗠𝗲𝘁𝗵𝗼𝗱 𝗮𝗻𝗱 𝗦𝘁𝗮𝘁𝘂𝘀 𝗖𝗼𝗱𝗲𝘀:


- Match operations with the right HTTP methods (GET, POST, PUT, DELETE).
- Use appropriate HTTP status codes to indicate success or failure.

- 𝗔𝗣𝗜 𝗩𝗲𝗿𝘀𝗶𝗼𝗻𝗶𝗻𝗴:
- Include a version number in your API endpoint (e.g., "/v1/user/profile") to handle
updates smoothly.
- 𝗝𝗦𝗢𝗡 𝗙𝗶𝗲𝗹𝗱 𝗡𝗮𝗺𝗶𝗻𝗴:
- Stick to a consistent naming convention (camelCase, snake_case) for JSON fields.

- 𝗖𝗼𝗻𝘀𝗶𝘀𝘁𝗲𝗻𝘁 𝗘𝗿𝗿𝗼𝗿 𝗠𝗲𝘀𝘀𝗮𝗴𝗲𝘀:


- Create clear and consistent error messages for easy troubleshooting.
- Allow users to refine queries using parameters for filtering, sorting, and searching.

- 𝗤𝘂𝗲𝗿𝘆 𝗣𝗮𝗿𝗮𝗺𝗲𝘁𝗲𝗿𝘀 𝗳𝗼𝗿 𝗙𝗶𝗹𝘁𝗲𝗿𝗶𝗻𝗴:


- Authentication & Authorization:
- Ensure secure API access with proper authentication and authorization
mechanisms.

- 𝗦𝘁𝗮𝘁𝗲𝗹𝗲𝘀𝘀𝗻𝗲𝘀𝘀:
- Keep APIs stateless; avoid storing client state on the server for scalability and
simplicity.

- 𝗗𝗼𝗰𝘂𝗺𝗲𝗻𝘁𝗮𝘁𝗶𝗼𝗻:
- Provide comprehensive documentation detailing endpoints, formats,
authentication, and examples.

You might also like