Skip to main content

Repull Python SDK

Typed Python client for Repull — one API for vacation-rental tech: Airbnb, Booking.com, Vrbo and more channels, plus 15 PMS platforms, behind one key, with white-label Connect for linking your users' accounts.

Async by default. Generated from OpenAPI. Fully typed (attrs + httpx).

Install

pip install repull-sdk

The package installs as repull-sdk and imports as repull.

Requires Python 3.10+.

Quick start

import asyncio
import os

from repull import AuthenticatedClient
from repull.api.reservations import list_reservations

async def main():
    client = AuthenticatedClient(
        base_url="https://api.repull.dev",
        token=os.environ["REPULL_API_KEY"],
    )
    async with client as c:
        page = await list_reservations.asyncio(client=c, limit=10)

    for r in page.data:
        print(r.id, r.check_in, r.check_out, r.platform)

asyncio.run(main())

There is also a sync flavour for every endpoint — drop the async with and call list_reservations.sync(...) instead.

Authentication

Every call goes through AuthenticatedClient(token=...). The token is your Repull API key — it looks like sk_live_....

Get one at repull.dev/dashboard → API keys.

What's in the SDK

The client is generated tag-by-tag from the OpenAPI spec. The modules mirror the API surface:

Module Endpoints
repull.api.system GET /v1/health
repull.api.properties list / get properties
repull.api.reservations list / get / create / patch / delete reservations
repull.api.availability per-property calendar read + bulk write
repull.api.guests guest CRM list + detail
repull.api.conversations list threads, read & post messages
repull.api.connect white-label OAuth Connect — list, status, create, disconnect
repull.api.webhooks manage subscriptions + fire test events
repull.api.airbnb listings, pricing, availability, photos, messaging, reservations, reviews, sync
repull.api.booking_com properties, availability, content, messaging, sync
repull.api.vrbo listings, reservations
repull.api.billing view & change plan

Everything is fully typed — your editor will autocomplete every parameter and every response field.

Examples

Run them with a real API key:

REPULL_API_KEY=sk_live_... python examples/quickstart.py

Connect (OAuth)

Repull Connect lets you link a property manager's Airbnb, Booking.com, Vrbo or PMS account in a few lines:

from repull.api.connect import create_connect_session
from repull.models.create_connect_session_body import CreateConnectSessionBody

session = await create_connect_session.asyncio(
    client=c,
    body=CreateConnectSessionBody(
        redirect_url="https://yourapp.example.com/airbnb/return",
        allowed_providers=["airbnb"],
    ),
)
# Send the user to session.url

After the user comes back, poll get_connect_status.asyncio(provider="airbnb", client=c) to confirm.

Pagination

Every list endpoint returns the same canonical envelope:

page = await list_reservations.asyncio(client=c, limit=50)
page.data                      # list[Reservation]
page.pagination.next_cursor    # str | None — pass back as `cursor=`
page.pagination.has_more       # bool — stop when False
page.pagination.total          # int | UNSET — present when ?include_total=true

Loop until pagination.has_more is False, threading pagination.next_cursor back as the next call's cursor arg. Cursors are opaque base64 — never parse or construct them by hand.

Error handling

By default, unexpected HTTP statuses return None from the high-level .asyncio() / .sync() calls. To raise instead:

client = AuthenticatedClient(
    base_url="https://api.repull.dev",
    token=os.environ["REPULL_API_KEY"],
    raise_on_unexpected_status=True,
)

You can also call .asyncio_detailed() / .sync_detailed() to get the full Response (status code, headers, raw bytes, parsed body).

Regenerating the client

The repo snapshots the current spec at openapi/v1.json so codegen is fully reproducible.

# Pull a fresh spec from api.repull.dev and regenerate
./scripts/regen.sh

# Use the snapshot in openapi/v1.json without hitting the network
./scripts/regen.sh --offline

You'll need openapi-python-client on your PATH:

uv tool install openapi-python-client
# or
pipx install openapi-python-client

Reference

License

MIT — see LICENSE. The Python client is a thin auto-generated wrapper, free to use anywhere.

(Note: the TypeScript SDK is licensed differently because it ships a hand-written facade plus the demo + channel-manager template. See repull-sdk if you need that.)


Powered by Repull.

Metadata

Release files for repull-sdk 0.2.45

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for repull-sdk 0.2.45
File Size Uploaded Provenance Actions
repull_sdk-0.2.45.tar.gz 925.0 kB Without provenance Details for repull_sdk-0.2.45.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for repull-sdk 0.2.45
File Interpreter ABI Platform Actions
repull_sdk-0.2.45-py3-none-any.whl Python 3 none any Details for repull_sdk-0.2.45-py3-none-any.whl

Total release size: 2.8 MB

Release files / repull_sdk-0.2.45.tar.gz

Download URL repull_sdk-0.2.45.tar.gz
Size 925.0 kB
Tags Source
SHA-256 checksum
How to use checksums
4557f3991cf2d79700172e4452cd3a9d849d21946a12c51404782a44ee46bdfd
BLAKE2b-256 checksum
How to use checksums
1374fb78717b8090fce33d25761dcf54a32b7cc37fef403fce1b7c7fb8a61c33
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / repull_sdk-0.2.45-py3-none-any.whl

Download URL repull_sdk-0.2.45-py3-none-any.whl
Size 1.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
a79dbf6df153d12d6c66659109cfdb767b41e36eb6fc0d567e592fd46aec1322
BLAKE2b-256 checksum
How to use checksums
daee3e58ee04fa5c64d7ae40e098343242d4e023db41e7d425ffd2f4b36373dc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for repull-sdk 0.2.45

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.45 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page