Agent-native stay search for Airbnb and Booking.com with total-price ranking.
pip install letsbooking
# or: pip install -e .from letsbooking import LetsBooking
client = LetsBooking(api_key="lb_live_…") # or ADMIN key
# Natural language
result = client.search("Barcelona apartment 2 guests Aug 10-14 2026")
print(result.cheapest.summary())
print(result.cheapest.url)
# Structured
result = client.search_stays(
location="Lisbon",
check_in="2026-09-01",
check_out="2026-09-05",
guests=2,
sources=["airbnb", "booking"],
currency="EUR",
)
for offer in result.offers[:5]:
print(offer.source, offer.price.total, offer.title)import asyncio
from letsbooking import AsyncLetsBooking
async def main():
async with AsyncLetsBooking(api_key="lb_live_…") as client:
result = await client.search("Paris loft 2 guests Sep 12-16 2026")
print(result.total_results, result.cheapest)
asyncio.run(main())export LETSBOOKING_API_KEY=lb_live_…
letsbooking search "Barcelona 2 guests Aug 10-14 2026"
letsbooking search --location Lisbon --check-in 2026-09-01 --check-out 2026-09-05 --guests 2
letsbooking health
letsbooking sources- Open https://letsbooking.bitscorp.co and request a key, or
- Admin mints one at
/admin
export LETSBOOKING_API_KEY=lb_live_…
# or pass api_key= to the constructorDefault base URL: https://letsbooking.bitscorp.co
LetsBooking(api_key="…", base_url="http://localhost:8787")POST /api/search(NL or structured)- Polls
GET /api/results/{id}until completed - Returns typed
SearchResultwithStayOfferlist sorted by total price
Also supports:
request_access(name, email, …)— public key requestpublic_search(…)— no auth, sandbox demosources()— connector readiness- Admin helpers when using an admin key
MIT