Pods API

Spin up compute in seconds. The Pods API lets you create, list, pause, resume, and delete GPU-backed containers across Yotta’s distributed cloud.

Versioning All endpoints are currently under the v1 namespace (e.g., /openapi/v1/...). Backward-compatible enhancements may be added to v1. Breaking changes will ship under a new version (e.g., v2).


Create Pod

Endpoint: /openapi/v1/pods/create

Method: POST Description: Launches a new compute Pod on the Yotta platform using a container image.

Params

Name
Location
Type
Required
Description

x-api-key

header

string

Yes

none

Request Body (JSON)

Field
Type
Required
Description

image

string

✓

Docker image name (e.g., yottalabsai/pytorch:2.8.0-py3.11-cuda12.8.1-cudnn-devel-ubuntu22.04-2025050802).

gpuType

string

✓

GPU type identifier (e.g., NVIDIA_L4_24G, NVIDIA_H100_80GB_HBM3_80G, NVIDIA_GeForce_RTX_4090_24G, NVIDIA_GeForce_RTX_5090_32G).

gpuCount

integer

✓

Number of GPUs to attach to the Pod.

environmentVars

KeyValuePair[]

Environment variables (e.g., Jupyter password).

expose

ExposePort[]

Ports to expose (e.g., SSH on 22).

imagePublicType

enum

One of OFFICIAL, CUSTOM, PUBLIC, PRIVATE. Use PRIVATE with registry credentials.

imageRegistryUsername

string

Username for private registry (when imagePublicType = PRIVATE).

imageRegistryToken

string

Token/password for private registry (when imagePublicType = PRIVATE).

initializationCommand

string

Command to run on startup (e.g., "sshd &").

See short model snippets at the end of this page, and full schemas in Common Models.

Example (Public Image) — curl

Example (Public Image) — Python

Example (Private Image) — curl

Example (Private Image) — Python

Responses

HTTP Status Code
Response Code
Meaning
Description
Data schema

200

10000

Request OK

create success

500

Internal Server Error

Response Example (200)


List Pods

Endpoint: /openapi/v1/pods/list

Method: GET Description: Returns all Pods owned by the current organization. Supports multi-value filtering.

Params

Name
Location
Type
Required
Description

regionList

query

array<string>

No

Filter by regions. e.g. regionList=ap-southeast-1&regionList=us-west-1

statusList

query

array<int>

No

Filter by status codes. e.g. statusList=1&statusList=3

x-api-key

header

string

Yes

API key token

Note: Both regionList and statusList are multi-value query parameters. Send the parameter multiple times to specify multiple values. The server matches any of the provided values (logical OR).

statusList Values

Supported status codes and their meanings:

Value
Name
Meaning

0

INITIALIZE

Initializing: created and preparing resources/configuration.

1

RUNNING

Running: available and serving traffic.

2

PAUSING

Pausing: entering shutdown flow; may stop accepting new work.

3

PAUSED

Paused: unavailable to serve; resources retained and can be resumed.

4

TERMINATING

Terminating: tearing down resources and shutting down.

Validation Rules

  • When statusList is omitted, no status filter is applied (all statuses are returned).

Example — curl

Example — Python

Responses

HTTP Status Code
Response Code
Meaning
Description
Data schema

200

10000

Request OK

create success

500

Internal Server Error

Response Example (200)


Pause Pod

Endpoint: /openapi/v1/pods/pause/{podId}

Method: POST Description: Pauses a running Pod to reduce cost.

Params

Name
Location
Type
Required
Description

podId

path

string

Yes

The Pod ID to pause.

x-api-key

header

string

Yes

none

Example — curl

Example — Python

Responses

HTTP Status Code
Response Code
Meaning
Description
Data schema

200

10000

Request OK

pause success

500

Internal Server Error

Response Example (200)


Resume Pod

Endpoint: /openapi/v1/pods/resume/{podId}

Method: POST Description: Resumes a previously paused Pod.

Params

Name
Location
Type
Required
Description

podId

path

string

Yes

The Pod ID to resume.

x-api-key

header

string

Yes

none

Example — curl

Example — Python

Responses

HTTP Status Code
Response Code
Meaning
Description
Data schema

200

10000

Request OK

resume success

500

Internal Server Error

Response Example (200)


Delete Pod

Endpoint: /openapi/v1/pods/{podId}

Method: DELETE Description: Permanently deletes a Pod.

Params

Name
Location
Type
Required
Description

podId

path

string

Yes

The Pod ID to delete.

x-api-key

header

string

Yes

none

Example — curl

Example — Python

Responses

HTTP Status Code
Response Code
Meaning
Description
Data schema

200

10000

Request OK

delete success

500

Internal Server Error

Response Examples (200)


Best Practices

  • Secure images: Use PRIVATE images with registry credentials when needed.

  • Harden access: Set a strong JUPYTER_PASSWORD (or disable public endpoints you don’t need).

  • Lifecycle hygiene: Pause or delete idle Pods to optimize cost.

  • Automate flows: Use List → Pause/Resume in CI/agents to orchestrate workloads.

Last updated

Was this helpful?