diff --git a/source/_components/sensor.lyft.markdown b/source/_components/sensor.lyft.markdown index c86b811e161..6241bad852f 100644 --- a/source/_components/sensor.lyft.markdown +++ b/source/_components/sensor.lyft.markdown @@ -13,10 +13,8 @@ ha_iot_class: "Cloud Polling" ha_release: 0.41 --- - The `lyft` sensor will give you time and price estimates for all available [Lyft](https://lyft.com) products at the given `start_latitude` and `start_longitude`.The `ATTRIBUTES` are used to provide extra information about products, such as vehicle capacity and fare rates. If an `end_latitude` and `end_longitude` are specified, a price estimate will also be provided. One sensor will be created for each product at the given `start` location, for pickup time. A second sensor for each product, for estimated price, will be created if a destination is specified. The sensor is powered by the official Lyft [API](https://developer.lyft.com/reference/). - You must create an application [here](https://www.lyft.com/developers/manage) to obtain a `client_id` and `client_secret`. To enable this sensor, add the following lines to your `configuration.yaml` file: @@ -27,20 +25,41 @@ sensor: - platform: lyft client_id: CLIENT_ID client_secret: CLIENT_SECRET - start_latitude: 37.8116380 + start_latitude: 37.8116380 ``` -Configuration variables: +{% configuration %} +client_id: + description: "A client id obtained from [developer.lyft.com](https://developer.lyft.com) after [creating an app](https://www.lyft.com/developers/manage)." + required: true + type: string +client_secret: + description: "A client secret obtained from [developer.lyft.com](https://developer.lyft.com) after [creating an app](https://www.lyft.com/developers/manage)." + required: true + type: string +start_latitude: + description: The starting latitude for a trip. + required: true + type: float +start_longitude: + description: The starting longitude for a trip. + required: true + type: float +end_latitude: + description: The ending latitude for a trip. While `end_latitude` is optional, providing an `end_latitude`/`end_longitude` allows price estimates as well as time. + required: false + type: float +end_longitude: + description: The ending longitude for a trip. While `end_longitude` is optional, providing an `end_latitude`/`end_longitude` allows price estimates as well as time. + required: false + type: float +product_ids: + description: A list of Lyft product IDs. + required: false + type: [list, string] +{% endconfiguration %} -- **client_id** (*Required*): A client id obtained from [developer.lyft.com](https://developer.lyft.com) after [creating an app](https://www.lyft.com/developers/manage). -- **client_secret** (*Required*) A client secret obtained from [developer.lyft.com](https://developer.lyft.com) after [creating an app](https://www.lyft.com/developers/manage). -- **start_latitude** (*Required*): The starting latitude for a trip. -- **start_longitude** (*Required*): The starting longitude for a trip. -- **end_latitude** (*Optional*): The ending latitude for a trip. While `end_latitude` is optional, providing an `end_latitude`/`end_longitude` allows price estimates as well as time. -- **end_longitude** (*Optional*): The ending longitude for a trip. While `end_longitude` is optional, providing an `end_latitude`/`end_longitude` allows price estimates as well as time. -- **product_ids** (*Optional*): A list of Lyft product IDs. - -A full configuration entry could look like the sample below: +A full configuration entry could look like the sample below: ```yaml # Example configuration.yaml entry @@ -48,7 +67,7 @@ sensor: - platform: lyft client_id: CLIENT_ID client_secret: CLIENT_SECRET - start_latitude: 37.8116380 + start_latitude: 37.8116380 start_longitude: -122.2648050 end_latitude: 37.615223 end_longitude: -122.389977