# Radius API for agents

Use only `https://radius.pi.dev` for Radius API requests. Do not send a Radius bearer token to browser action URLs returned by an API response.

- If needed, describe the task in plain English with `GET https://radius.pi.dev/v1/meta/operations?q=<task>` to search available API operations.
- When unclear you can read an operation's exact contract at `GET https://radius.pi.dev/v1/meta/operations/<operationId>`.
- Send the request described by that contract.

The complete OpenAPI 3.1 document is available at `https://radius.pi.dev/v1/openapi.json`. Prefer operation search because it uses less context.

## Safety

- Confirm destructive or externally visible actions unless the user explicitly requested them.
- Publishing an artifact without an explicit visibility uses the organization's default visibility and needs no confirmation.
- Treat returned billing, OAuth, and verification URLs as human actions. Never follow them with the Radius Authorization header.

## Operations

### API keys

- `GET /v1/organizations/{organizationId}/api-keys` — **apiKeys.list**: List organization API keys
- `POST /v1/organizations/{organizationId}/api-keys` — **apiKeys.create**: Create an organization API key
- `PUT /v1/organizations/{organizationId}/api-keys/{keyId}` — **apiKeys.update**: Rename an organization API key
- `PUT /v1/organizations/{organizationId}/api-keys/{keyId}/attribution` — **apiKeys.attribution.update**: Reassign an organization API key
- `DELETE /v1/organizations/{organizationId}/api-keys/{keyId}` — **apiKeys.revoke**: Revoke an organization API key

### Analytics

- `GET /v1/organizations/{organizationId}/analytics/schema` — **analytics.schema.read**: Read the organization analytics table schema
- `GET /v1/organizations/{organizationId}/analytics/snapshot` — **analytics.snapshot.read**: Read the current organization analytics snapshot
- `GET /v1/organizations/{organizationId}/analytics/directory` — **analytics.directory.read**: Read the organization analytics directory
- `POST /v1/organizations/{organizationId}/analytics/query` — **analytics.query.run**: Query the organization analytics Parquet export

### Artifacts

- `GET /v1/organizations/{organizationId}/artifacts` — **artifacts.list**: List artifacts
- `POST /v1/organizations/{organizationId}/artifacts` — **artifacts.create**: Create or publish an artifact
- `GET /v1/organizations/{organizationId}/artifacts/summary` — **artifacts.summary.read**: Read artifact management summary
- `GET /v1/organizations/{organizationId}/artifacts/{slug}` — **artifacts.read**: Read artifact metadata
- `PUT /v1/organizations/{organizationId}/artifacts/{slug}/visibility` — **artifacts.visibility.update**: Set artifact visibility
- `PUT /v1/organizations/{organizationId}/artifacts/{slug}/ttl` — **artifacts.ttl.update**: Reset artifact expiry
- `DELETE /v1/organizations/{organizationId}/artifacts/{slug}` — **artifacts.delete**: Delete an artifact
- `POST /v1/organizations/{organizationId}/artifacts/{slug}/versions` — **artifacts.versions.publish**: Publish a single-file revision
- `GET /v1/organizations/{organizationId}/artifacts/{slug}/versions/{version}` — **artifacts.versions.read**: Read an artifact revision
- `GET /v1/organizations/{organizationId}/artifacts/{slug}/versions/{version}/files/{path}` — **artifacts.files.download**: Download an artifact file
- `POST /v1/organizations/{organizationId}/artifacts/{slug}/scratch` — **artifacts.scratch.open**: Open an artifact scratch area
- `GET /v1/organizations/{organizationId}/artifacts/{slug}/scratch/{scratchId}` — **artifacts.scratch.read**: Read artifact scratch status
- `PUT /v1/organizations/{organizationId}/artifacts/{slug}/scratch/{scratchId}/files/{path}` — **artifacts.scratch.files.put**: Upload an artifact scratch file
- `DELETE /v1/organizations/{organizationId}/artifacts/{slug}/scratch/{scratchId}/files/{path}` — **artifacts.scratch.files.delete**: Delete an artifact scratch path
- `POST /v1/organizations/{organizationId}/artifacts/{slug}/scratch/{scratchId}/commit` — **artifacts.scratch.commit**: Commit an artifact scratch area
- `GET /v1/organizations/{organizationId}/settings` — **organizations.settings.read**: Read organization settings
- `PUT /v1/organizations/{organizationId}/artifact-ttl-policy` — **organizations.artifactTtlPolicy.update**: Set organization artifact retention policy
- `PUT /v1/organizations/{organizationId}/artifact-visibility-policy` — **organizations.artifactVisibilityPolicy.update**: Set organization artifact default visibility

### Billing

- `GET /v1/organizations/{organizationId}/billing` — **billing.summary.read**: Read the organization billing summary
- `POST /v1/organizations/{organizationId}/billing/checkout-sessions` — **billing.checkoutSessions.create**: Create a Stripe credit checkout
- `POST /v1/organizations/{organizationId}/billing/portal-sessions` — **billing.portalSessions.create**: Create a Stripe billing portal session
- `POST /v1/organizations/{organizationId}/billing/credit-code-redemptions` — **billing.creditCodes.redeem**: Redeem a Radius credit code
- `GET /v1/organizations/{organizationId}/billing/auto-top-up` — **billing.autoTopUp.read**: Read automatic top-up settings
- `PUT /v1/organizations/{organizationId}/billing/auto-top-up` — **billing.autoTopUp.update**: Set up or update automatic top-up
- `DELETE /v1/organizations/{organizationId}/billing/auto-top-up` — **billing.autoTopUp.disable**: Disable automatic top-up
- `GET /v1/organizations/{organizationId}/billing/transactions` — **billing.transactions.list**: List organization billing transactions

### Budgets

- `GET /v1/organizations/{organizationId}/budgets` — **budgets.list**: List organization budgets
- `GET /v1/organizations/{organizationId}/budgets/usage` — **budgets.usage.list**: Read organization budget usage
- `GET /v1/organizations/{organizationId}/budgets/{budgetId}/usage` — **budgets.usage.read**: Read budget usage
- `GET /v1/organizations/{organizationId}/budgets/{budgetId}/principals` — **budgets.principals.list**: List budget principals
- `GET /v1/organizations/{organizationId}/budgets/{budgetId}` — **budgets.read**: Read an organization budget
- `POST /v1/organizations/{organizationId}/budgets` — **budgets.create**: Create an organization budget
- `PUT /v1/organizations/{organizationId}/budgets/{budgetId}` — **budgets.update**: Update an organization budget
- `DELETE /v1/organizations/{organizationId}/budgets/{budgetId}` — **budgets.delete**: Delete an organization budget

### Bug Reports

- `POST /v1/bug-reports` — **bugReports.create**: Submit a Pi bug report

### Context

- `GET /v1/context` — **context.read**: Read the authenticated Radius context

### Discovery

- `GET /v1/openapi.json` — **meta.openapi.read**: Read the Radius OpenAPI document
- `GET /v1/agent.md` — **meta.agentGuide.read**: Read the Radius agent API guide
- `GET /v1/meta/operations` — **meta.operations.search**: Search Radius API operations
- `GET /v1/meta/operations/{operationId}` — **meta.operations.read**: Read one Radius API operation

### Gateway

- `GET /v1/health` — **gateway.health.read**: Read gateway health
- `GET /v1/config` — **gateway.config.read**: Read the model and tool catalog
- `GET /v1/credential-providers` — **gateway.credentialProviders.list**: List BYOK credential providers
- `GET /v1/providers` — **gateway.modelProviders.list**: List upstream providers for a model

### Groups

- `GET /v1/organizations/{organizationId}/groups` — **groups.list**: List organization groups
- `GET /v1/organizations/{organizationId}/groups/{groupId}` — **groups.read**: Read a group and its memberships
- `POST /v1/organizations/{organizationId}/groups` — **groups.create**: Create a group
- `PUT /v1/organizations/{organizationId}/groups/{groupId}` — **groups.update**: Rename a group
- `DELETE /v1/organizations/{organizationId}/groups/{groupId}` — **groups.delete**: Delete a group
- `PUT /v1/organizations/{organizationId}/groups/{groupId}/members` — **groups.members.replace**: Replace all group members
- `POST /v1/organizations/{organizationId}/groups/{groupId}/members/{principalId}` — **groups.members.add**: Add a principal to a group
- `DELETE /v1/organizations/{organizationId}/groups/{groupId}/members/{principalId}` — **groups.members.remove**: Remove a principal from a group
- `PUT /v1/organizations/{organizationId}/members/{userId}/groups` — **members.groups.replace**: Replace a member's local groups

### Inference

- `POST /v1/messages` — **inference.messages.create**: Create a Pi messages response
- `POST /v1/completions` — **inference.completions.create**: Create an OpenAI-compatible chat completion
- `POST /v1/chat/completions` — **inference.chatCompletions.create**: Create an OpenAI-compatible chat completion

### Invitations

- `GET /v1/organizations/{organizationId}/invitations` — **invitations.list**: List pending organization invitations
- `POST /v1/organizations/{organizationId}/invitations` — **invitations.create**: Invite a person to the organization
- `DELETE /v1/organizations/{organizationId}/invitations/{invitationId}` — **invitations.revoke**: Revoke an organization invitation

### Members

- `PUT /v1/organizations/{organizationId}/membership-domain` — **organizations.membershipDomain.update**: Set the automatic membership domain
- `GET /v1/organizations/{organizationId}/members` — **members.list**: List organization members
- `GET /v1/organizations/{organizationId}/members/{userId}` — **members.read**: Read an organization member
- `PUT /v1/organizations/{organizationId}/members/{userId}/role` — **members.role.update**: Change a member role
- `PUT /v1/organizations/{organizationId}/members/{userId}/groups` — **members.groups.replace**: Replace a member's local groups
- `DELETE /v1/organizations/{organizationId}/members/{userId}` — **members.remove**: Remove a member or leave the organization
- `GET /v1/organizations/{organizationId}/invitations` — **invitations.list**: List pending organization invitations
- `POST /v1/organizations/{organizationId}/invitations` — **invitations.create**: Invite a person to the organization
- `DELETE /v1/organizations/{organizationId}/invitations/{invitationId}` — **invitations.revoke**: Revoke an organization invitation

### Models

- `GET /v1/organizations/{organizationId}/model-availability` — **models.availability.list**: List organization model availability
- `PUT /v1/organizations/{organizationId}/model-availability` — **models.availability.update**: Set organization model availability
- `POST /v1/organizations/{organizationId}/model-availability/batch` — **models.availability.batch**: Change availability for several models
- `GET /v1/organizations/{organizationId}/model-cost-estimates` — **models.costEstimates.list**: List estimated model costs

### OAuth

- `GET /v1/oauth` — **gateway.oauth.read**: Read Radius OAuth client configuration
- `GET /v1/oauth/google-workspaces/start` — **oauth.googleWorkspace.start**: Start Google Workspace authorization
- `GET /v1/oauth/google-workspaces/callback` — **oauth.googleWorkspace.callback**: Complete Google Workspace authorization
- `POST /v1/oauth/google-workspaces/refresh` — **oauth.googleWorkspace.refresh**: Refresh a Google Workspace token
- `POST /v1/oauth/google-workspaces/revoke` — **oauth.googleWorkspace.revoke**: Revoke a Google Workspace token
- `POST /v1/oauth/device` — **oauth.device.start**: Start OAuth device authorization
- `GET /v1/oauth/device/events` — **oauth.device.events**: Watch OAuth device authorization
- `POST /v1/oauth/token` — **oauth.token.exchange**: Exchange or refresh a Radius OAuth token

### Organizations

- `GET /v1/organizations/{organizationId}/privacy` — **organizations.privacy.read**: Read organization model privacy settings
- `PUT /v1/organizations/{organizationId}/privacy` — **organizations.privacy.update**: Update organization model privacy settings
- `GET /v1/organizations/{organizationId}/web-search` — **organizations.webSearch.read**: Read the organization web search option
- `PUT /v1/organizations/{organizationId}/web-search` — **organizations.webSearch.update**: Select the organization web search option
- `GET /v1/organizations` — **organizations.list**: List organizations available to the credential
- `GET /v1/organizations/{organizationId}` — **organizations.read**: Read an organization
- `POST /v1/organizations` — **organizations.create**: Create an organization
- `GET /v1/organizations/{organizationId}/settings` — **organizations.settings.read**: Read organization settings
- `PUT /v1/organizations/{organizationId}` — **organizations.update**: Update organization details
- `PUT /v1/organizations/{organizationId}/artifact-ttl-policy` — **organizations.artifactTtlPolicy.update**: Set organization artifact retention policy
- `PUT /v1/organizations/{organizationId}/artifact-visibility-policy` — **organizations.artifactVisibilityPolicy.update**: Set organization artifact default visibility
- `PUT /v1/organizations/{organizationId}/two-factor` — **organizations.twoFactor.update**: Set the organization two-factor requirement
- `PUT /v1/organizations/{organizationId}/membership-domain` — **organizations.membershipDomain.update**: Set the automatic membership domain
- `GET /v1/organizations/{organizationId}/service-accounts` — **serviceAccounts.list**: List organization service accounts
- `POST /v1/organizations/{organizationId}/service-accounts` — **serviceAccounts.create**: Create a service account
- `PUT /v1/organizations/{organizationId}/service-accounts/{serviceAccountId}` — **serviceAccounts.update**: Rename a service account
- `DELETE /v1/organizations/{organizationId}/service-accounts/{serviceAccountId}` — **serviceAccounts.delete**: Remove a service account

### Packages

- `GET /v1/organizations/{organizationId}/packages` — **packages.list**: List packages
- `GET /v1/organizations/{organizationId}/packages/{name}` — **packages.read**: Read a package
- `GET /v1/organizations/{organizationId}/packages/{scope}/{name}` — **packages.scoped.read**: Read a package (scoped name)
- `DELETE /v1/organizations/{organizationId}/packages/{name}` — **packages.delete**: Delete a package
- `DELETE /v1/organizations/{organizationId}/packages/{scope}/{name}` — **packages.scoped.delete**: Delete a package (scoped name)
- `PUT /v1/organizations/{organizationId}/packages/{name}/visibility` — **packages.visibility.update**: Set package visibility
- `PUT /v1/organizations/{organizationId}/packages/{scope}/{name}/visibility` — **packages.scoped.visibility.update**: Set package visibility (scoped name)
- `PUT /v1/organizations/{organizationId}/packages/{name}/groups/{groupId}` — **packages.groups.add**: Add a maintainer group
- `PUT /v1/organizations/{organizationId}/packages/{scope}/{name}/groups/{groupId}` — **packages.scoped.groups.add**: Add a maintainer group (scoped name)
- `PUT /v1/organizations/{organizationId}/packages/{name}/groups` — **packages.groups.replace**: Replace maintainer groups
- `PUT /v1/organizations/{organizationId}/packages/{scope}/{name}/groups` — **packages.scoped.groups.replace**: Replace maintainer groups (scoped name)
- `DELETE /v1/organizations/{organizationId}/packages/{name}/groups/{groupId}` — **packages.groups.remove**: Remove a maintainer group
- `DELETE /v1/organizations/{organizationId}/packages/{scope}/{name}/groups/{groupId}` — **packages.scoped.groups.remove**: Remove a maintainer group (scoped name)
- `PUT /v1/organizations/{organizationId}/packages/{name}/versions/{version}` — **packages.versions.publish**: Publish a package version
- `PUT /v1/organizations/{organizationId}/packages/{scope}/{name}/versions/{version}` — **packages.scoped.versions.publish**: Publish a package version (scoped name)
- `GET /v1/organizations/{organizationId}/packages/{name}/versions/{version}` — **packages.versions.read**: Read a package version
- `GET /v1/organizations/{organizationId}/packages/{scope}/{name}/versions/{version}` — **packages.scoped.versions.read**: Read a package version (scoped name)
- `GET /v1/organizations/{organizationId}/packages/{name}/versions/{version}/tarball` — **packages.versions.download**: Download a package tarball
- `GET /v1/organizations/{organizationId}/packages/{scope}/{name}/versions/{version}/tarball` — **packages.scoped.versions.download**: Download a package tarball (scoped name)
- `PUT /v1/organizations/{organizationId}/packages/{name}/versions/{version}/yank` — **packages.versions.yank**: Yank or restore a package version
- `PUT /v1/organizations/{organizationId}/packages/{scope}/{name}/versions/{version}/yank` — **packages.scoped.versions.yank**: Yank or restore a package version (scoped name)

### Presigned URLs

- `POST /v1/presigned-urls` — **presignedUrls.create**: Create a presigned URL

### Rewrite rules

- `POST /v1/organizations/{organizationId}/rewrite-rules/test` — **rewriteRules.test**: Test a rewrite rule
- `PUT /v1/organizations/{organizationId}/rewrite-rules/{kind}/{ruleId}/priority` — **rewriteRules.updatePriority**: Update a rewrite rule priority
- `GET /v1/organizations/{organizationId}/rewrite-rules` — **rewriteRules.list**: List active rewrite rules
- `POST /v1/organizations/{organizationId}/rewrite-rules` — **rewriteRules.publish**: Publish a rewrite rule version
- `GET /v1/organizations/{organizationId}/rewrite-rules/{ruleId}` — **rewriteRules.read**: Read a rewrite rule
- `DELETE /v1/organizations/{organizationId}/rewrite-rules/{ruleId}` — **rewriteRules.revoke**: Revoke the active rewrite rule version
- `GET /v1/organizations/{organizationId}/rewrite-rules/{ruleId}/versions` — **rewriteRules.versions.list**: List rewrite rule versions
- `GET /v1/organizations/{organizationId}/rewrite-rules/{ruleId}/versions/{version}` — **rewriteRules.versions.read**: Read a rewrite rule version

### Routing rules

- `POST /v1/organizations/{organizationId}/routing-rules/test` — **routingRules.test**: Test a routing rule
- `GET /v1/organizations/{organizationId}/routing-rules` — **routingRules.list**: List active routing rules
- `POST /v1/organizations/{organizationId}/routing-rules` — **routingRules.publish**: Publish a routing rule version
- `GET /v1/organizations/{organizationId}/routing-rules/{ruleId}` — **routingRules.read**: Read an active routing rule
- `DELETE /v1/organizations/{organizationId}/routing-rules/{ruleId}` — **routingRules.revoke**: Revoke the active routing rule version
- `GET /v1/organizations/{organizationId}/routing-rules/{ruleId}/versions` — **routingRules.versions.list**: List routing rule versions
- `GET /v1/organizations/{organizationId}/routing-rules/{ruleId}/versions/{version}` — **routingRules.versions.read**: Read a routing rule version
- `GET /v1/organizations/{organizationId}/builtin-routing-rules` — **routingRules.builtins.list**: List built-in routing rules

### Security

- `PUT /v1/organizations/{organizationId}/two-factor` — **organizations.twoFactor.update**: Set the organization two-factor requirement

### Servers

- `GET /v1/servers` — **servers.list**: List available Pi servers

### Tools

- `POST /v1/search` — **tools.webSearch.run**: Search the web
- `POST /v1/fetch` — **tools.webFetch.run**: Fetch web pages
- `POST /v1/images/generate` — **tools.imageGeneration.run**: Generate images
- `POST /v1/describe-file` — **tools.describeFile.run**: Describe files
- `GET /v1/organizations/{organizationId}/web-search` — **organizations.webSearch.read**: Read the organization web search option
- `PUT /v1/organizations/{organizationId}/web-search` — **organizations.webSearch.update**: Select the organization web search option

### Virtual models

- `GET /v1/organizations/{organizationId}/models` — **models.list**: List effective model configurations
- `POST /v1/organizations/{organizationId}/models` — **models.create**: Create a virtual model
- `POST /v1/organizations/{organizationId}/models/{name}` — **models.upsert**: Create or update a virtual model configuration
- `DELETE /v1/organizations/{organizationId}/models/{name}` — **models.delete**: Delete a virtual model or model override
- `GET /v1/organizations/{organizationId}/model-catalog` — **organizations.modelCatalog.read**: Read the organization model catalog
