This is a RESTful API that provides information about cars. The API is built using Spring Boot framework. It exposes endpoints to retrieve information about cars, including their make, model, year, and other details.
To get started with this API, you will need to clone this repository onto your local machine. You will also need to have Java and Maven installed. Once you have cloned the repository and installed the necessary dependencies, you can run the application using the following command:
- Clone this repository to your local machine
- Setup a MySQL database on your local machine
- For development use the
application-dev.properties
4. Add you database information into theapplication-dev.properties
- Use Java corretto-17 and run the application. All the database tables should be set up
This will start the application on http://localhost:8080
.
The following are the available endpoints for this API:
This endpoint returns a paginated list of all vehicles in the database.
Parameter | Type | Required | Description |
---|---|---|---|
page |
Integer | No | The page number to retrieve. Default is 0. |
This endpoint returns a single vehicle with the given ID.
Parameter | Type | Required | Description |
---|---|---|---|
id |
Long | Yes | The ID of the vehicle to retrieve. |
This endpoint returns a paginated list of vehicles that match the given search criteria.
Parameter | Type | Required | Description |
---|---|---|---|
maker |
String | No | The make of the vehicle. |
name |
String | No | The model of the vehicle. |
date |
String | No | The year of the vehicle. |
page |
Integer | No | The page number to retrieve. Default is 0. |
This endpoint returns a paginated list of vehicles that match the given HSN and TSN values.
Parameter | Type | Required | Description |
---|---|---|---|
hsn |
String | Yes | The HSN value of the vehicle. |
tsn |
String | Yes | The TSN value of the vehicle. |
page |
Integer | No | The page number to retrieve. Default is 0. |
Examples can be found on RapidAPI
This controller provides REST endpoints for managing brands.
Returns a list of all brands, or a filtered list of brands by name.
name
(optional): Filters the list of brands by name. If provided, only brands whose name contains the specified value will be returned.
- Status code: 200 OK
- Content: A list of
Brand
objects.
Examples can be found on RapidAPI
This REST API allows you to retrieve information about car model series and their generations.
Retrieves a paginated list of all available car model series.
page
(optional): Specifies the page number to retrieve.
Retrieves a paginated list of car model series that match the specified search criteria.
name
(optional): The name of the car model series to search for.page
(optional): Specifies the page number to retrieve.
Retrieves a paginated list of all available car model series generations.
page
(optional): Specifies the page number to retrieve.
Retrieves a paginated list of car model series generations that match the specified search criteria.
name
(optional): The name of the car model series generation to search for.page
(optional): Specifies the page number to retrieve.
Examples can be found on RapidAPI
- Spring Boot - The web framework used
- Maven - Dependency Management
- Buggxs - Car database