Can a API resource have multiple methods? For example, a resource '/flights' has GET method to read flights info; POST to add a flight record, PUT to update and DELETE to remove.....Possible?
Solved! Go to Solution.
Welcome to the community !!!
Yes - you can, truly RESTFul approach. Resource verb controls the action you want to take over the resource (in your case resource is flights). That corresponds to the CRUD operation:
Create - POST /flights
Read - GET /flights or /flights/{id}
Update - PUT /flights/{id}
Delete - DELETE /flights/{id}
There are many articles about this in our community or in the internet. The same can be implemented easily in Apigee Edge as well using Conditional flows. If you have any further questions, please reach out and once again thanks for reaching out to the community !
If this resolves your question, please accept the answer
Welcome to the community !!!
Yes - you can, truly RESTFul approach. Resource verb controls the action you want to take over the resource (in your case resource is flights). That corresponds to the CRUD operation:
Create - POST /flights
Read - GET /flights or /flights/{id}
Update - PUT /flights/{id}
Delete - DELETE /flights/{id}
There are many articles about this in our community or in the internet. The same can be implemented easily in Apigee Edge as well using Conditional flows. If you have any further questions, please reach out and once again thanks for reaching out to the community !
If this resolves your question, please accept the answer
Thank you Sai. Can you please also try sending those links to the articles that you were referring to?
@Krishnarup Basu - I would start with Apigee Academy and Web API Design. There are many other materials in the internet as well
User | Count |
---|---|
7 | |
2 | |
2 | |
1 | |
1 |