The American Flights API is a system API for operations on the american table in the flights database. It supports the following operations: get all flights, get a flight with a specific ID, add a flight, delete a flight, partially update a flight, and replace a flight.
- Mulesoft
- Anypoint Platform
- Anypoint Studio
- REST
- PostgreSQL
- AWS RDS
- Get all flights from an AWS RDS databae
- Get a single flight via flight ID
- Add a flight to the AWS RDS database
- Delete a flight
- Partially update a flight by updating its price and empty seats capacity
- Replacing a flight
- Refactor to follow best practices
- Implement MUnit for testing
git clone https://github.com/PorkodiVenkatesh/PROJECT-NAME#project-name
The database that the application works with requires the table to have the following columns:
- id - integer/serial
- code - text
- price - float
- departuredate - text
- origin - text
- destination - text
- emptyseats - int
- planetype - text
- totalseats - int
The application must be opened in Anypoint Studio and run.
Use Advanced Rest Client to see how the application works. A sample input data is included below.
{
"id": 4,
"code": "ffee0192",
"price": 300,
"origin": "MUA",
"destination": "LAX",
"departureDate": "2016-01-19",
"emptySeats": 0,
"plane": {
"totalSeats": 300,
"type": "Boeing 777"
}
}