...
Note that the limit is very important here, as you could end up returning many vehicles if you allow the user to select something very broad, like all toyotas towed in January.Once you have the correct vehicle you can then retrieve its fees by its vehicleId.
VehicleId is the unique id for each time a vehicle gets towed. If it gets towed twice, it will get 2 vehicleIds. You then make a request to the /impound endpoint which will get you the complete vehicle details including the fees as of the time of the request.
Expand | |||
---|---|---|---|
Expand | |||
| |||
Code Block |
| ||
curl --location 'https://staging-api.autoreturn.net/api-web/api/impound?id=1067632 |
for example will give a response containing most of the details of the vehicle. In particular you’ll want to look at
currentLocation
which represents the best way to get into contact with whoever has current possession of the vehiclemake.name , model.name , color.name , license , licenseState.code
unpaidFeeItems
which contains all of the fee items that are not paid yet. If you want the total then you can sumunpaidFeeItems
.totalPrice
which is the total price of the vehicle, including tax.eligibleForRelease
indicates if the vehicle is currently releasable. Holds may prevent release of the vehicle, in which case you probably don’t want to let people pay for it.
Here is an example of the response
| ||
|
Once you have the correct vehicle you can then retrieve its fees by its vehicleId.
VehicleId is the unique id for each time a vehicle gets towed. If it gets towed twice, it will get 2 vehicleIds. You then make a request to the /impound endpoint which will get you the complete vehicle details including the fees as of the time of the request.
Expand | ||
---|---|---|
| ||
curl --location 'https://staging-api.autoreturn.net/api-web/api/impound?id=1067632 |
for example will give a response containing most of the details of the vehicle. In particular you’ll want to look at
currentLocation
which represents the best way to get into contact with whoever has current possession of the vehiclemake.name , model.name , color.name , license , licenseState.code
unpaidFeeItems
which contains all of the fee items that are not paid yet. If you want the total then you can sumunpaidFeeItems
.totalPrice
which is the total price of the vehicle, including tax.eligibleForRelease
indicates if the vehicle is currently releasable. Holds may prevent release of the vehicle, in which case you probably don’t want to let people pay for it.
Here is an example of the response
Expand | ||
---|---|---|
| ||
|
Once the user has indicated that they want to pay you must collect contact information from the user, this is used to ensure that the vehicle is released to the correct person later in the process.
...