> ## Documentation Index
> Fetch the complete documentation index at: https://runpod-b18f5ded-new-sls-quickstart.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# serverless

export const VolumeDiskTooltip = () => {
  return <Tooltip headline="Volume disk" tip="Persistent storage that remains available for the duration of the Pod's lease. It functions like a dedicated hard drive, allowing you to store data that needs to be retained even if the Pod is stopped or rebooted. Mounted at /workspace by default." cta="Learn more about volume disks" href="/pods/storage/types">volume disk</Tooltip>;
};

Manage Serverless endpoints, including creating, listing, updating, and deleting endpoints.

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
runpodctl serverless <subcommand> [flags]
```

## Alias

You can use `sls` as a shorthand for `serverless`:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
runpodctl sls list
```

## Subcommands

### List endpoints

List all your Serverless endpoints:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
runpodctl serverless list
```

#### List flags

<ResponseField name="--include-template" type="bool">
  Include template information in the output.
</ResponseField>

<ResponseField name="--include-workers" type="bool">
  Include workers information in the output.
</ResponseField>

### Get endpoint details

Get detailed information about a specific endpoint:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
runpodctl serverless get <endpoint-id>
```

#### Get flags

<ResponseField name="--include-template" type="bool">
  Include template information in the output.
</ResponseField>

<ResponseField name="--include-workers" type="bool">
  Include workers information in the output.
</ResponseField>

### Create an endpoint

Create a new Serverless endpoint from a template or from a Hub repo:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
# Create from a template
runpodctl serverless create --name "my-endpoint" --template-id "tpl_abc123"

# Create from a Hub repo
runpodctl hub search vllm                                         # Find the hub ID
runpodctl serverless create --hub-id cm8h09d9n000008jvh2rqdsmb --name "my-vllm"
```

When using `--hub-id`, GPU IDs and container disk size are automatically pulled from the Hub release config. You can override the GPU type with `--gpu-id`.

<Note>
  **Serverless templates vs Pod templates**: Serverless endpoints require a Serverless-specific template. Pod templates (like `runpod-torch-v21`) cannot be used because they include <VolumeDiskTooltip /> configuration, which Serverless does not support. When creating a template with [`runpodctl template create`](/runpodctl/reference/runpodctl-template), use the `--serverless` flag to create a Serverless template.

  Each Serverless template can only be bound to one endpoint at a time. To create multiple endpoints with the same configuration, create separate templates for each.
</Note>

#### Create flags

<ResponseField name="--name" type="string">
  Name for the endpoint.
</ResponseField>

<ResponseField name="--template-id" type="string">
  Template ID to use (required if `--hub-id` is not specified). Use [`runpodctl template search`](/runpodctl/reference/runpodctl-template) to find templates.
</ResponseField>

<ResponseField name="--hub-id" type="string">
  Hub listing ID to deploy from (alternative to `--template-id`). Use [`runpodctl hub search`](/runpodctl/reference/runpodctl-hub) to find repos.
</ResponseField>

<ResponseField name="--gpu-id" type="string">
  GPU type for workers. Use [`runpodctl gpu list`](/runpodctl/reference/runpodctl-gpu) to see available GPUs.
</ResponseField>

<ResponseField name="--gpu-count" type="int" default="1">
  Number of GPUs per worker.
</ResponseField>

<ResponseField name="--compute-type" type="string" default="GPU">
  Compute type (`GPU` or `CPU`).
</ResponseField>

<ResponseField name="--workers-min" type="int" default="0">
  Minimum number of workers.
</ResponseField>

<ResponseField name="--workers-max" type="int" default="3">
  Maximum number of workers.
</ResponseField>

<ResponseField name="--data-center-ids" type="string">
  Comma-separated list of preferred datacenter IDs. Use [`runpodctl datacenter list`](/runpodctl/reference/runpodctl-datacenter) to see available datacenters.
</ResponseField>

<ResponseField name="--network-volume-id" type="string">
  Network volume ID to attach. Use [`runpodctl network-volume list`](/runpodctl/reference/runpodctl-network-volume) to see available network volumes.
</ResponseField>

### Update an endpoint

Update endpoint configuration:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
runpodctl serverless update <endpoint-id> --workers-max 5
```

#### Update flags

<ResponseField name="--name" type="string">
  New name for the endpoint.
</ResponseField>

<ResponseField name="--workers-min" type="int">
  New minimum number of workers.
</ResponseField>

<ResponseField name="--workers-max" type="int">
  New maximum number of workers.
</ResponseField>

<ResponseField name="--idle-timeout" type="int">
  New idle timeout in seconds.
</ResponseField>

<ResponseField name="--scaler-type" type="string">
  Scaler type (`QUEUE_DELAY` or `REQUEST_COUNT`).
</ResponseField>

<ResponseField name="--scaler-value" type="int">
  Scaler value.
</ResponseField>

### Delete an endpoint

Delete an endpoint:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
runpodctl serverless delete <endpoint-id>
```

## Serverless URLs

Access your Serverless endpoint using these URL patterns:

| Operation     | URL                                                      |
| ------------- | -------------------------------------------------------- |
| Async request | `https://api.runpod.ai/v2/<endpoint-id>/run`             |
| Sync request  | `https://api.runpod.ai/v2/<endpoint-id>/runsync`         |
| Health check  | `https://api.runpod.ai/v2/<endpoint-id>/health`          |
| Job status    | `https://api.runpod.ai/v2/<endpoint-id>/status/<job-id>` |

## Related commands

* [`runpodctl hub`](/runpodctl/reference/runpodctl-hub)
* [`runpodctl template`](/runpodctl/reference/runpodctl-template)
* [`runpodctl gpu list`](/runpodctl/reference/runpodctl-gpu)
