Lyft API
  1. Public
Lyft API
  • Restricted
  • Public
    • Cost estimates
      GET
    • Available drivers nearby
      GET
    • Pickup ETAs
      GET
    • Types of rides
      GET
  • User
    • The user's general info
      GET
    • List rides
      GET
    • Request a Lyft
      POST
    • Get the ride detail of a given ride ID
      GET
    • Cancel a ongoing requested ride
      POST
    • Update the destination of the ride
      PUT
    • Add the passenger's rating, feedback, and tip
      PUT
    • Get the receipt of the rides.
      GET
  • Sandbox
    • Preset Prime Time percentage
      PUT
    • Propagate ride through ride status
      PUT
    • Preset types of rides for sandbox
      PUT
    • Driver availability for processing ride request
      PUT
  1. Public

Pickup ETAs

GET
/eta
Public
The ETA endpoint lets you know how quickly a Lyft driver can come get you
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://api.lyft.com/eta?lat&lng'
响应示例响应示例
200 - 示例 1
{
    "eta_estimates": [
        {
            "display_name": "Lyft Line",
            "eta_seconds": 120,
            "is_valid_estimate": true,
            "ride_type": "lyft_line"
        }
    ]
}

请求参数

Query 参数
lat
number <double>
必需
Latitude of a location
lng
number <double>
必需
Longitude of a location
destination_lat
number <double>
可选
Latitude of destination location
destination_lng
number <double>
可选
Longitude of destination location
ride_type
enum<string> 
可选
ID of a ride type
枚举值:
lyftlyft_linelyft_pluslyft_premierlyft_luxlyft_luxsuv

返回响应

🟢200成功
application/json
An object with an array of ETAs by ride type for the given location
Body
eta_estimates
array[object (Eta) {5}] 
可选
display_name
string 
可选
A human readable description of the ride type
eta_seconds
integer <int32>
可选
Estimated seconds for a driver to arrive
eta_seconds_max
integer <int32>
可选
Estimated upper bound of seconds for a driver to arrive
is_valid_estimate
boolean 
可选
The validity of the ETA estimate returned
ride_type
enum<string> 
可选
The ID of the ride type
枚举值:
lyftlyft_linelyft_pluslyft_premierlyft_luxlyft_luxsuv
🟠400请求有误

【Lyft】API开发者 微信交流群

用微信扫右侧二维码,加入【Lyft】API开发者 交流群,互助沟通

扫码加入交流群
上一页
Available drivers nearby
下一页
Types of rides
Built with