Client APIs
The following reference provides detailed documentation for the synchronous and asynchronous clients of the NeMo Platform Python SDK.
Synchronous Client
Use nemo_platform.NeMoPlatform from regular Python code when you want blocking API calls.
The client reads the active CLI context by default, including the base URL,
workspace, and authentication settings configured by nemo auth login.
Constructor
Connection Modes
Use with_options(...) to clone a client with request defaults changed:
Asynchronous Client
Use nemo_platform.AsyncNeMoPlatform from asyncio applications. It exposes the same
resource tree as NeMoPlatform, but API methods are awaited.
Async client constructor
AsyncNeMoPlatform accepts the same connection and authentication parameters as
NeMoPlatform. Pass a custom httpx.AsyncClient through http_client only when
you need to control the underlying transport directly.
Errors
Client construction raises RuntimeError if configuration or authentication bootstrap fails.
Workspace-scoped methods raise ValueError when no workspace is provided on the client or
method call.
API calls raise typed exceptions from nemo_platform, including:
Catch APIStatusError for all non-success HTTP responses, or NeMoPlatformError
for SDK-level errors.
Client Attributes
The NeMo Platform clients provide access to API resources through the following attributes. For endpoint details, see the REST API Reference.
Organization
- workspaces: Manage workspaces
- projects: Manage projects within a workspace
Model Management
- models: Model entity CRUD
- evaluation: Benchmarks, benchmark jobs, metrics, and metric jobs
- inference: Deployments, deployment configs, providers, and OpenAI-compatible gateway
Data & Synthesis
- data_designer: Synthetic data generation jobs
- safe_synthesizer: PII replacement and safe data synthesis jobs
- files: File upload and download
Safety & Compliance
- guardrail: Guardrail configurations and checks
- audit: Model safety audit jobs and configs
Platform
- jobs: Cross-service job management
- entities: Generic entity CRUD
- secrets: Secret management
- iam: Identity and access management
- workspaces.members: Workspace member and RBAC management
Response Handling
- with_raw_response: Access raw HTTP response data
- with_streaming_response: Handle streaming responses