A Python client library for the CATAPA Private API with session-based authentication.
Features
π Session-Based Authentication - Automatic login and session management with cookie handling
π Simple API - Clean interface for making authenticated requests to CATAPA Private API
π Automatic Session Management - Sessions are automatically maintained and refreshed
Installation
Using pip
pip install catapa-private
poetry add catapa-private
uv add catapa-private
Quick Start
A complete Hello World example to get you started immediately.
from catapa_private import CatapaPrivatedefmain()->None: client =CatapaPrivate(tenant="zfrl",username="demo",password="dmo-password") response = client.get("/core/countries",params={"page":0,"size":10}) response.raise_for_status() data = response.json()print(f"Found {len(data.get('content',[]))} countries")if__name__=="__main__":main()
π‘ Tip: By default, the SDK connects to https://api.catapa.com. To use a different base URL (e.g., for staging or testing), pass the base_url parameter:
Getting Your Credentials
To use the SDK with your own account, you'll need the following authentication credentials:
Tenant ID
Your tenant ID is your organization's unique identifier in CATAPA. To obtain it, please contact support@catapa.com.
Username and Password
Your username and password are your CATAPA account credentials used for session-based authentication.
β οΈ Important: Keep your credentials secure and never commit them to version control. Consider using environment variables or a secrets management system.
Private API Documentation
Explore our interactive Swagger documentation to understand the available endpoints, request schemas, and response models for each module.