Build on GPUaaS¶
Implemented Contract
How to consume the GPUaaS platform programmatically: the CLI, Python SDK, App SDK, and direct REST API.
Pick your tool¶
CLI — gpuaas-cli
Operator / user binary. Browser-OIDC login, catalog browsing, allocation create/release, project ops, balance + refunds, audit export. 19 command groups.
Python SDK
gpuaas-sdk on PyPI. Typed client (mypy strict), async-ready, modules covering auth, catalog, allocations, apps, IAM, storage, billing, ops.
App SDK
For developers building apps that run on GPUaaS: manifest, OCI artifact, lifecycle contract, billing alignment, external-team integration.
Direct REST API
OIDC flow, terminal-token mint, WebSocket terminal, raw curl examples. Use when no language SDK exists yet.
End-to-end quick start
5-minute path: log in → list catalog → create allocation → open terminal → release. Both CLI and SDK variants.
Decision tree¶
flowchart TB
Q1{What are you building?}
Q1 --> Q2[Operator tooling /<br/>scripted workflows /<br/>CI on a developer laptop]
Q1 --> Q3[Programmatic integration<br/>from Python code]
Q1 --> Q4[An app that runs<br/>inside a tenant allocation]
Q1 --> Q5[Client in a language<br/>that doesn't have an SDK yet]
Q2 --> T1[Use the CLI:<br/>gpuaas auth login<br/>gpuaas allocations create ...]
Q3 --> T2[Use the Python SDK:<br/>pip install gpuaas-sdk<br/>client = Client...]
Q4 --> T3[Use the App SDK:<br/>register manifest<br/>publish OCI artifact<br/>implement lifecycle hooks]
Q5 --> T4[Hit the REST API directly:<br/>OIDC PKCE login<br/>Bearer token<br/>curl + ws]
classDef tool fill:#d1e7dd,stroke:#0a3622
class T1,T2,T3,T4 tool
What's in each tool¶
mindmap
root((Build surfaces))
CLI gpuaas-cli
3,687 LOC
Cobra commands
Browser OIDC PKCE
auth allocations apps billing
catalog iam nodes ops projects
service-accounts storage
JSON or table output
Python SDK
gpuaas-sdk on PyPI
strict mypy typed
httpx async-ready
modules
auth allocations apps_catalog
apps_instances apps_artifacts
apps_entitlements billing
catalog iam nodes ops projects
service_accounts storage errors
pytest + respx fixtures
App SDK
Manifest registration
OCI artifact trust + promotion
Launchable workload profile
App-runtime lifecycle hooks
Tenant-scoped service accounts
App-runtime billing model
App UI extension contract
Direct REST API
OpenAPI 33k lines
AsyncAPI 2.3k lines
Stable correlation_id
Error code catalog
Rate limit + idempotency
Where to look next¶
- CLI —
gpuaasbinary detail - Python SDK —
gpuaas-sdkmodule reference + examples - App SDK — building apps on GPUaaS
- Direct REST API — curl + WS examples
- End-to-end quick start — first allocation in under 5 minutes
- Reference: REST API explorer, AsyncAPI explorer, Error codes