Unofficial Python client for the Bay Wheels bike-share API
Project description
bay-wheels
An unofficial Python client for the Bay Wheels bike-share API. Supports authentication, station lookup, bike availability, and reservations. Mostly vibe coded; use at your own risk.
Installation
uv add bay-wheels
Usage
import asyncio
from bay_wheels import BayWheelsClient
async def main():
async with BayWheelsClient() as client:
# Authenticate via SMS
await client.request_code("+14155551234")
code = input("Enter code: ")
await client.login("+14155551234", code)
# List stations
stations = await client.list_stations()
for station in stations[:5]:
print(f"{station.name}: {station.ebikes_available} e-bikes")
# Get bikes at a station
bikes = await client.get_station_bikes(stations[0].id)
for bike in bikes:
print(f" Bike {bike.bike_id}: {bike.estimated_range_miles} mi")
# Reserve a bike
reservation = await client.create_reservation(stations[0].id)
print(f"Reserved: {reservation.ride_id}")
# Cancel reservation
await client.cancel_reservation(reservation.ride_id)
asyncio.run(main())
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
bay_wheels-0.3.0.tar.gz
(30.5 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file bay_wheels-0.3.0.tar.gz.
File metadata
- Download URL: bay_wheels-0.3.0.tar.gz
- Upload date:
- Size: 30.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.4.29
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7fc5e876457fc9167e3277fd0e9bbb63f0cb9eeff2a4d70a05ac0cdc4f24a77f
|
|
| MD5 |
510070deae04244569209c8f49e567db
|
|
| BLAKE2b-256 |
988f9cd09360bb5907f2b7f55187719ac6d65e6cfc1dfc587b9f55eda1b400a5
|
File details
Details for the file bay_wheels-0.3.0-py3-none-any.whl.
File metadata
- Download URL: bay_wheels-0.3.0-py3-none-any.whl
- Upload date:
- Size: 10.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.4.29
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
70d7735e01861ce22756d2da5d0ee098bb1be28c771cf13d2819e94b1688ea26
|
|
| MD5 |
f4ef9c65b7dd812febfd97090d369fbb
|
|
| BLAKE2b-256 |
13a82f97f10a7fbb413d0019e21afbb3422695ea745d7fe5fe835ebe17d57145
|