Architecture
How the OTOBO Python SDK is structured and how it talks to GenericInterface.
Architecture — OTOBO Python SDK
The otobo PyPI package is a thin, OTOBO-branded layer over a shared GenericInterface client.
flowchart LR
App[Your Python app] --> OTOBO[otobo package]
OTOBO --> GI[otrs_gi_core]
GI --> REST[OTOBO GenericInterface REST]
CLI[otobo-cli] --> GI
What you import
from otobo import OTOBOClient, ClientConfig, TicketCreate, OTOBOError
OTOBOClient is the async HTTP client. Domain models (TicketCreate, TicketSearch, …) are Pydantic v2 types validated before each request.
Request flow
- You call
client.login(BasicAuth(...)). - Each method builds a JSON payload (credentials + ticket data).
- The client POSTs/PUTs to
{base_url}/Webservice/{name}/{operation}. - Responses are parsed into
Ticketmodels or raiseOTOBOError.
CLI vs library
| Component | Purpose |
|---|---|
OTOBOClient | Runtime ticket CRUD from your application |
otobo-cli setup-system | One-time webservice and user provisioning on the OTOBO host |
Related package
If you run Znuny instead of OTOBO, use the separate znuny package — same API shape, Znuny-specific CLI defaults.
