Car: PUT
Allows user to update car properties.
Request
To update a specific car's properties, make a PUT request to:
/api/car/:carID
where :carID is the car's unique id.
Original Car:
body: {
_id: '599611d7166668c23c245b80',
make: 'Subaru',
model: 'Outback',
color: 'Evergreen',
licensePlate: 'PNW-123',
userID: '599611d7166668c23c245b7f',
__v: 0
}
Updated Car:
updatedCar = {
make: 'Ferrari',
model: '458',
color: 'Neon Purple',
};
Response
JSON object with updated price object.
body: {
_id: '599611d7166668c23c245b80',
make: 'Ferrari',
model: '458',
color: 'Neon Purple',
licensePlate: 'PNW-123',
userID: '599611d7166668c23c245b7f',
__v: 0
}