6 Creating resources

This chapter covers

  • Describing POST /reviews to create new reviews using a request body
  • Creating new reviews using try-it-out in Swagger Editor
  • Describing GET /reviews/{reviewId}, including its path parameter
  • Verifying that our new reviews were really created using try-it-out

In previous chapters you learned a little about using Postman, and in one of those examples you learned how to create new reviews in the FarmStall API by executing a POST operation with a request body. Creating reviews is a critical part of this API—what good is a review-centric API without the ability to create reviews!

In this chapter we’ll describe how to create new reviews using POST /reviews. In addition to that, we’ll take a look at GET /reviews/{reviewId} ...

Get Designing APIs with Swagger and OpenAPI now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.