> ## Documentation Index
> Fetch the complete documentation index at: https://docs.salad.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> For autonomous tasks, use live SaladCloud API responses for current state, availability, quotas, models, and other dynamic values. Use current OpenAPI specifications where provided for paths, schemas, required fields, and enums. Never invent endpoints, fields, prices, availability, quotas, models, or state. Prefer API workflows over Portal steps. Read before changing and never expose credentials, signed media URLs, prompts, or sensitive outputs. Retry only safe or idempotent operations with bounded backoff, honoring Retry-After. Verify every write with a read. Stop rather than repeat an uncertain non-idempotent or billable request. AI Gateway uses an organization-specific Bearer key and live /v1/models discovery. Do not delete, cancel, stop, or reduce capacity without explicit user intent. Bind shared operation IDs to the selected product path. Treat Container Engine instances as interruptible and local state as ephemeral. Install the SaladCloud skills (npx skills add https://docs.salad.com), start from the salad skill and /agents/overview; docs MCP: https://docs.salad.com/mcp.

# Deploy via API

*Last Updated: October 10, 2024*

## **Prerequisites**

Before you begin, make sure you have the following:

* An account with SaladCloud . If you don't have one yet, you can sign up for a free trial at
  [https://portal.salad.com](https://portal.salad.com) .
* A project in SaladCloud . If you don't have a project yet, you can create one by following the instructions in the
  SaladCloud documentation.
* A container image that you want to deploy. If you don't have a container image yet, you can build one using a tool
  like **[Docker.](https://www.docker.com/)**

## **Step 1: Obtain Your API Key**

To authenticate your API requests, you'll need an API key. To obtain your API key, follow these steps:

* Log in to your SaladCloud account at [https://portal.salad.com](https://portal.salad.com)
* Click on your profile in the top right corner of the page, then click API Keys.
* Copy the API key that is displayed. You'll need this in the next step.

## **Step 2: Deploy the Container Image**

To deploy the container image, you'll need to send a POST request to the following URL:

```json theme={null}
https://api.salad.com/api/public/organizations/organization_name/projects/project_name/containers \
```

Replace `{organization_name}` and `{project_name}` with the name of your organization and project, respectively.

Here's an example of how to send the POST request using `curl` :

```json theme={null}
curl --request POST \
     --url https://api.salad.com/api/public/organizations/organization_name/projects/project_name/containers \
     --header 'accept: application/json' \
     --header 'content-type: application/json'
```

Replace `{API_KEY}` with your API key, and `{CONTAINER_IMAGE_URL}` with the URL of the container image you want to
deploy.

## **Step 3: Check the Deployment Status**

After you send the POST request, SaladCloud will begin the process of deploying your container image. To check the
status of the deployment, you can send a GET request to the following URL:

```json theme={null}
https://api.salad.com/api/public/organizations/organization_name/projects/project_name/containers/container_group_name \
```

Replace `{organization_name}` , `{project_name}` , and `{container_id}` with the name of your organization, project, and
the container you want to check, respectively.

Here's an example of how to send the **GET** request using `curl` :

```json theme={null}
curl --request GET \
     --url https://api.salad.com/api/public/organizations/organization_name/projects/project_name/containers/container_group_name \
     --header 'accept: application/json'
```

Replace `{API_KEY}` with your API key.

The response will include the current status of the deployment, as well as other details about the container.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.