{"id":49883677,"url":"https://github.com/codetheweb/bay-wheels-hass","last_synced_at":"2026-05-15T16:36:16.450Z","repository":{"id":354617118,"uuid":"1138737873","full_name":"codetheweb/bay-wheels-hass","owner":"codetheweb","description":"A Home Assistent integration for Bay Wheels","archived":false,"fork":false,"pushed_at":"2026-01-21T03:51:31.000Z","size":129,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-29T10:44:09.010Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codetheweb.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-01-21T03:50:37.000Z","updated_at":"2026-01-27T19:27:31.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/codetheweb/bay-wheels-hass","commit_stats":null,"previous_names":["codetheweb/bay-wheels-hass"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/codetheweb/bay-wheels-hass","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codetheweb%2Fbay-wheels-hass","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codetheweb%2Fbay-wheels-hass/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codetheweb%2Fbay-wheels-hass/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codetheweb%2Fbay-wheels-hass/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codetheweb","download_url":"https://codeload.github.com/codetheweb/bay-wheels-hass/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codetheweb%2Fbay-wheels-hass/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33072719,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-15T11:35:32.926Z","status":"ssl_error","status_checked_at":"2026-05-15T11:35:31.362Z","response_time":103,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-05-15T16:36:15.827Z","updated_at":"2026-05-15T16:36:16.435Z","avatar_url":"https://github.com/codetheweb.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bay Wheels Home Assistant Integration\n\nA Home Assistant custom integration for Bay Wheels bike-share that provides station monitoring sensors and services for creating and canceling bike reservations. Vibe coded, so use at your own risk.\n\n## Features\n\n- **Station monitoring**: Track bike availability at your favorite stations with sensors for e-bikes available, regular bikes available, and maximum e-bike range\n- **Automatic range validation**: When creating a reservation, the integration checks if the assigned bike meets your minimum range requirement and automatically cancels if it doesn't\n- **Token refresh**: Automatically refreshes authentication tokens when they expire\n- **Reauth flow**: Prompts for re-authentication when tokens can't be refreshed\n\n## Installation\n\n### HACS (Recommended)\n\n1. Open HACS in your Home Assistant instance\n2. Click the three dots in the top right corner and select **Custom repositories**\n3. Add `https://github.com/codetheweb/bay-wheels-hass` with category **Integration**\n4. Click **Add**\n5. Search for \"Bay Wheels\" in HACS and click **Download**\n6. Restart Home Assistant\n\n### Manual\n\n1. Download the latest release from [GitHub](https://github.com/codetheweb/bay-wheels-hass/releases)\n2. Extract and copy the `custom_components/bay_wheels` directory to your Home Assistant `config/custom_components/` directory\n3. Restart Home Assistant\n\n## Configuration\n\n### Initial Setup\n\n1. Go to **Settings** → **Devices \u0026 Services** → **Add Integration**\n2. Search for \"Bay Wheels\"\n3. Enter your phone number in E.164 format (e.g., `+14155551234`)\n4. Enter the SMS verification code sent to your phone\n5. If prompted, enter your email address for verification\n\n### Selecting Stations to Monitor\n\nAfter initial setup, configure which stations to monitor:\n\n1. Go to **Settings** → **Devices \u0026 Services**\n2. Find the Bay Wheels integration and click **Configure**\n3. Select the stations you want to monitor from the list\n4. Click **Submit**\n\nEach selected station creates three sensors:\n- **E-Bikes Available**: Number of e-bikes currently at the station\n- **Bikes Available**: Number of regular bikes at the station\n- **Max E-Bike Range**: Highest battery range (in miles) among available e-bikes\n\nSensors update every 60 seconds and include extra attributes: `station_id`, `latitude`, `longitude`, `docks_available`, and `is_offline`.\n\n## Services\n\n### `bay_wheels.create_reservation`\n\nReserve an e-bike at a Bay Wheels station with minimum range validation.\n\n| Parameter | Type | Required | Description |\n|-----------|------|----------|-------------|\n| `station_id` | string | Yes | Bay Wheels station ID (e.g., `motivate_BAY_abc123`) |\n| `min_range` | float | Yes | Minimum acceptable battery range in miles |\n\n**Response:**\n```yaml\nride_id: \"12345678\"\nbike_id: \"BAY12345\"\nestimated_range_miles: 25\nstation_id: \"motivate_BAY_abc123\"\n```\n\n**Behavior:**\n- Creates a reservation at the specified station\n- Fetches the assigned bike's battery range\n- If the range is below `min_range`, automatically cancels and returns an error\n- If the bike range can't be verified, automatically cancels for safety\n\n### `bay_wheels.cancel_reservation`\n\nCancel an active Bay Wheels reservation.\n\n| Parameter | Type | Required | Description |\n|-----------|------|----------|-------------|\n| `ride_id` | string | Yes | The reservation/ride ID to cancel |\n\n## Example Automation\n\n```yaml\nautomation:\n  - alias: \"Reserve bike when leaving work\"\n    trigger:\n      - platform: zone\n        entity_id: person.me\n        zone: zone.work\n        event: leave\n    action:\n      - service: bay_wheels.create_reservation\n        data:\n          station_id: \"motivate_BAY_abc123\"\n          min_range: 15\n        response_variable: reservation\n      - service: notify.mobile_app\n        data:\n          message: \"Bike {{ reservation.bike_id }} reserved with {{ reservation.estimated_range_miles }} miles range\"\n```\n\n## Requirements\n\n- Home Assistant 2024.1.0 or newer\n- A Bay Wheels account with a valid phone number\n\nThe `bay-wheels` Python package is installed automatically.\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodetheweb%2Fbay-wheels-hass","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodetheweb%2Fbay-wheels-hass","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodetheweb%2Fbay-wheels-hass/lists"}