POST
/v1/bookings/create
We’ve partnered with local and traditional transport services like autorickshaws to provide users with more options to travel. Ola autos are available in selected cities. Find more details here.
Booking an Ola auto is slightly different from booking an Ola cab. You will need to provide both pickup (current) and drop (preferred) location of your user. A request is sent to nearby autorickshaws and booking is confirmed upon acceptance. View the state diagram of auto rickshaw booking here.
When you provide your user’s current and preferred drop locations (latitude & longitude) with a valid authorization code, you’re enabling your users to :Note: Ola does not perform billing for auto rides in certain cities. In such cases, the final bill amount is the fare displayed by the auto meter in addition to convenience fee and any night time charge if applicable.
Name | Data Type | Description | Type |
---|---|---|---|
pickup_lat | float | The latitude part of the pickup location. | Payload |
pickup_lng | float | The longitude of the pickup location. | Payload |
drop_lat | float | The latitude part of the drop location. | Payload |
drop_lng | float | The longitude part of the drop location. | Payload |
pickup_mode | string | Currently only "NOW" is supported | Payload |
category | string | Need to pass category name as auto | Payload |
Authorization | string | OAuth token(OAuth access token must be passed as Authorization header with Bearer token.) | Header |
X-APP-TOKEN | string | Key which identifies the partner | Header |
Content-Type | string | "application/json" to be passed | Header |
POST
https://devapi.olacabs.com/v1/bookings/create
"body": {
"pickup_lat": 12.9490936,
"pickup_lng": 77.6443056,
"drop_lat": 12.950279,
"drop_lng": 77.641938,
"pickup_mode": "NOW",
"category": "auto"
}
"headers": {
"Authorization": "Bearer 6121212f12ff12f12f1f12f1f12f",
"X-APP-TOKEN": "6a56121212f12ff12f12f1f12f1f12fc",
"Content-Type": "application/json"
}
{
"status": "SUCCESS",
"booking_id": "KRN100819",
"message": "Contacting autos near you..."
}