Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Answer completely and carefully based on web services for thumbs up. We want to design a RESTful API for a car rental business. The business
Answer completely and carefully based on web services for thumbs up.
We want to design a RESTful API for a car rental business. The business owns a number of cars of different sizes. There are three size groups for cars called Group A (for small cars), Group B (for medium cars), and Group C (for large cars). Each car group has a specific per-day rental price. A customer can book a car online by specifying the car's size group, the rental start date, and the rental end date. In return the customer gets a unique booking number. We are assuming that there is only one branch for this business in one location, and that the customer can only pick up and return a car to this location. We are also assuming that the customer does not have to pay online to book a car (payment is made in person at the branch when the car is picked up). You do not need to consider payment details and procedures for this exercise. No logging in or authentication is required for any of the services. Customers do not need to provide their details (such as name or address) to make a booking. b) Write a detailed, comprehensive, and clear RESTful API specification for each of the following services: i. Getting a list of all available cars for a certain pick up and return dates (regardless of car category), that includes the total rental price for that period. ii. Booking a car of a certain size for a certain pick up and return dates. For each service you have to specify an HTTP verb, a URL, the request payload, the response status codes, and the response payload. Assume that JSON objects are used for both the request and response payloads. We want to design a RESTful API for a car rental business. The business owns a number of cars of different sizes. There are three size groups for cars called Group A (for small cars), Group B (for medium cars), and Group C (for large cars). Each car group has a specific per-day rental price. A customer can book a car online by specifying the car's size group, the rental start date, and the rental end date. In return the customer gets a unique booking number. We are assuming that there is only one branch for this business in one location, and that the customer can only pick up and return a car to this location. We are also assuming that the customer does not have to pay online to book a car (payment is made in person at the branch when the car is picked up). You do not need to consider payment details and procedures for this exercise. No logging in or authentication is required for any of the services. Customers do not need to provide their details (such as name or address) to make a booking. b) Write a detailed, comprehensive, and clear RESTful API specification for each of the following services: i. Getting a list of all available cars for a certain pick up and return dates (regardless of car category), that includes the total rental price for that period. ii. Booking a car of a certain size for a certain pick up and return dates. For each service you have to specify an HTTP verb, a URL, the request payload, the response status codes, and the response payload. Assume that JSON objects are used for both the request and response payloadsStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started