Create a template
Create a reusable Runpod template for Pod and Serverless container settings, including images, storage, ports, environment, and mounts.
Authorizations
Runpod API key authentication. Generate an API key in the Runpod console and send it in the Authorization header as Bearer <api_key>. Keys are scoped to the permissions granted when created; requests may return 403 when a valid key lacks access to the requested resource or action.
Console sessions (Clerk JWTs) act for the signed-in user. To act for a team instead, also send X-Team-Id: <team_id>; it applies only when the user owns or belongs to that team, otherwise the request runs against the user's own account. API keys created inside a team already act for that team and do not need the header.
Body
Reusable container configuration shared across templates, pods, serverless endpoints, and clusters. Adding a field here automatically propagates to all of them.
The container's command, as a single raw string. This is the field entrypoint and cmd encode into, exposed in its stored form.
Two shapes are accepted. A bare shell string is treated as CMD and split into arguments, which is what the console's "Container start command" field writes. A JSON object of the form {"entrypoint":[...],"cmd":[...]} sets either or both explicitly.
Responses always return both representations: args exactly as stored, plus the deconstructed entrypoint and cmd. Supplying args together with entrypoint or cmd is allowed only when they describe the same command, so a read-modify-write client can send back everything it received. Send "" to clear, omit to leave unchanged.
"--model meta-llama/Llama-3-8B --max-model-len 8192"
"{\"entrypoint\":[\"/bin/bash\",\"-c\"],\"cmd\":[\"python -u main.py\"]}"
""
Container registry credential ID for a private image: one of
your credentials from /v2/registries. Leave it unset for a
private Amazon ECR image. Runpod pulls those with an ECR
delegation (/v2/registries/delegations) matched to the
image's account, region and repository at pull time, so there
is no delegation ID to pass here (a delegation ID is not a
credential ID). A credential set here is used instead of any
delegation.
null
Start JupyterLab in containers created from this template:
injects a generated JUPYTER_PASSWORD environment variable,
unless env already sets one. Only images that honor the
convention start Jupyter from it (Runpod official images do);
expose 8888/http in ports to reach it. Defaults to true
when omitted, matching console-created templates.
false
Provision SSH access in containers created from this template:
injects a PUBLIC_KEY environment variable carrying the
deployer's registered SSH public keys (PUT /v2/account/ssh-keys — with none registered the flag does
nothing), unless env already sets one. Only images that
honor the convention start sshd from it (all Runpod official
images do); direct SSH also needs a 22/tcp entry in
ports. Defaults to true when omitted, matching
console-created templates.
true
Response
Created
Reusable container configuration shared across templates, pods, serverless endpoints, and clusters. Adding a field here automatically propagates to all of them.
The container's command, as a single raw string. This is the field entrypoint and cmd encode into, exposed in its stored form.
Two shapes are accepted. A bare shell string is treated as CMD and split into arguments, which is what the console's "Container start command" field writes. A JSON object of the form {"entrypoint":[...],"cmd":[...]} sets either or both explicitly.
Responses always return both representations: args exactly as stored, plus the deconstructed entrypoint and cmd. Supplying args together with entrypoint or cmd is allowed only when they describe the same command, so a read-modify-write client can send back everything it received. Send "" to clear, omit to leave unchanged.
"--model meta-llama/Llama-3-8B --max-model-len 8192"
"{\"entrypoint\":[\"/bin/bash\",\"-c\"],\"cmd\":[\"python -u main.py\"]}"
""
Container registry credential ID for a private image: one of
your credentials from /v2/registries. Leave it unset for a
private Amazon ECR image. Runpod pulls those with an ECR
delegation (/v2/registries/delegations) matched to the
image's account, region and repository at pull time, so there
is no delegation ID to pass here (a delegation ID is not a
credential ID). A credential set here is used instead of any
delegation.
null