[API] Unassign Vehicle
Un-assigns a vehicle of the vehicle supplier from a driver.
¶ Resource
/v1/vehicle-suppliers/vehicles/:vehicle_id/unassign
¶ HTTP Method
POST
¶ Access Method
¶ Required scopes
vehicle_suppliers.vehicles.assignment
¶ Example Request
curl -X POST "https://api.uber.com/v1/vehicle-suppliers/vehicles/:vehicle_id/unassign" \
-H "Authorization: Bearer <TOKEN>" \
-H "Content-Type: application/json" \
-d '{
"driver_id":"driver_id"
}'
¶ Request Path Parameters
Name | Type | Description |
---|---|---|
vehicle_id |
string | Vehicle ID returned from Create Vehicle response. |
¶ Request Fields
Name | Type | Description |
---|---|---|
driver_id (optional) |
string | Driver ID returned from Get Driver Info response. If driver_id is not provided, all drivers will be unassigned from the given vehicle |
¶ Example Response
Status-code: 204 No Content
{
}
¶ Endpoint Success Codes
Http Status Code | Code | Message |
---|---|---|
200 |
OK | Driver was successfully unassigned |
204 |
NO_CONTENT | There was no drivers to unassign |
¶ Endpoint Specific Errors
Http Status Code | Code | Message |
---|---|---|
400 |
bad_request | The request parameters are invalid, e.g. vehicle_id is not recognized |
401 |
unauthorized | Invalid OAuth 2.0 credentials provided |
404 |
vehicle_not_found | The vehicle is not found |
404 |
driver_not_found | The driver is not found |
429 |
rate_limited | Number of requests exceeds allowed limit |
500 |
internal_server_error | Internal server error |
503 |
service_unavailable | Service unavailable |