> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://help.sigmacomputing.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://help.sigmacomputing.com/_mcp/server.

# Add documents to a deployment policy

POST https://api.sigmacomputing.com/v2/deploymentPolicies/{deploymentPolicyId}/files
Content-Type: application/json

Add documents to a deployment policy.

### Usage notes
- Retrieve the `deploymentPolicyId` from the [/v2/deploymentPolicies](https://help.sigmacomputing.com/reference/list-deployments) endpoint.
- To add workbooks to a deployment policy, retrieve the relevant `workbookId` from the [/v2/workbooks](https://help.sigmacomputing.com/reference/list-workbooks) endpoint.
- To add data models to a deployment policy, retrieve the relevant `dataModelId` from the [/v2/datamodels](https://help.sigmacomputing.com/reference/list-data-models) endpoint.
- To add reports to a deployment policy, retrieve the relevant `reportId` from the [/v2/reports](https://help.sigmacomputing.com/reference/list-reports) endpoint.
- To add folders to a deployment policy, retrieve the relevant folder ID from the [/v2/files](https://help.sigmacomputing.com/reference/list-files) endpoint and review the `id` field in the response for files with a `type` of `folder`.
- Adding a folder deploys the documents it contains. Templates cannot be added to a deployment policy.

### Usage scenarios
- Centrally manage documents that are deployed to specific tenant organizations.
- Deploy an entire folder of documents to tenant organizations without listing each document individually.


Reference: https://help.sigmacomputing.com/reference/add-inodes-to-deployment

## Authentication

- OAuth2 — send the obtained token as `Authorization: Bearer <token>`

## Servers

- `https://api.sigmacomputing.com` (Server for GCP (US) hosted organizations, default)
- `https://api.sa.gcp.sigmacomputing.com` (Server for GCP (KSA) hosted organizations)
- `https://aws-api.sigmacomputing.com` (Server for AWS US (West) hosted organizations)
- `https://api.us-a.aws.sigmacomputing.com` (Server for AWS US (East) hosted organizations)
- `https://api.ca.aws.sigmacomputing.com` (Server for AWS Canada hosted organizations)
- `https://api.eu.aws.sigmacomputing.com` (Server for AWS Europe (Frankfurt) hosted organizations)
- `https://api.ch.aws.sigmacomputing.com` (Server for AWS Europe (Zurich) hosted organizations)
- `https://api.au.aws.sigmacomputing.com` (Server for AWS Australia and APAC hosted organizations)
- `https://api.uk.aws.sigmacomputing.com` (Server for AWS UK hosted organizations)
- `https://api.in.aws.sigmacomputing.com` (Server for AWS Asia Pacific (Mumbai) hosted organizations)
- `https://api.us.azure.sigmacomputing.com` (Server for Azure US hosted organizations)
- `https://api.eu.azure.sigmacomputing.com` (Server for Azure Europe hosted organizations)
- `https://api.ca.azure.sigmacomputing.com` (Server for Azure Canada hosted organizations)
- `https://api.uk.azure.sigmacomputing.com` (Server for Azure United Kingdom hosted organizations)
- `https://api.au.azure.sigmacomputing.com` (Server for Azure Australia hosted organizations)

## Request

### Path parameters

- `deploymentPolicyId` (string, required) — Unique identifier of the deployment policy.

### Body (application/json)

This endpoint expects an object.

- `inodeIds` (list of string, required) — Unique identifier of the workbook, data model, report, or folder.

## Response

### 200

The response body.

## Examples

### Deploy quarterly sales dashboard

**Request**

```json
{
  "inodeIds": [
    "6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d"
  ]
}
```

**Response**

```json
{}
```

**SDK Code**

```python Deploy quarterly sales dashboard
import requests

url = "https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files"

payload = { "inodeIds": ["6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d"] }
headers = {
    "Authorization": "<token>.",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Deploy quarterly sales dashboard
const url = 'https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files';
const options = {
  method: 'POST',
  headers: {Authorization: '<token>.', 'Content-Type': 'application/json'},
  body: '{"inodeIds":["6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d"]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Deploy quarterly sales dashboard
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files"

	payload := strings.NewReader("{\n  \"inodeIds\": [\n    \"6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d\"\n  ]\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "<token>.")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Deploy quarterly sales dashboard
require 'uri'
require 'net/http'

url = URI("https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = '<token>.'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"inodeIds\": [\n    \"6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d\"\n  ]\n}"

response = http.request(request)
puts response.read_body
```

```java Deploy quarterly sales dashboard
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files")
  .header("Authorization", "<token>.")
  .header("Content-Type", "application/json")
  .body("{\n  \"inodeIds\": [\n    \"6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d\"\n  ]\n}")
  .asString();
```

```php Deploy quarterly sales dashboard
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files', [
  'body' => '{
  "inodeIds": [
    "6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d"
  ]
}',
  'headers' => [
    'Authorization' => '<token>.',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Deploy quarterly sales dashboard
using RestSharp;

var client = new RestClient("https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "<token>.");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"inodeIds\": [\n    \"6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d\"\n  ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Deploy quarterly sales dashboard
import Foundation

let headers = [
  "Authorization": "<token>.",
  "Content-Type": "application/json"
]
let parameters = ["inodeIds": ["6a1d8f3b-2e5c-4b7a-9d1e-4c8b6a3f7e2d"]] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### Deploy a tagged version

**Request**

```json
{
  "inodeIds": [
    "9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e"
  ]
}
```

**Response**

```json
{}
```

**SDK Code**

```python Deploy a tagged version
import requests

url = "https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files"

payload = { "inodeIds": ["9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e"] }
headers = {
    "Authorization": "<token>.",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Deploy a tagged version
const url = 'https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files';
const options = {
  method: 'POST',
  headers: {Authorization: '<token>.', 'Content-Type': 'application/json'},
  body: '{"inodeIds":["9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e"]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Deploy a tagged version
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files"

	payload := strings.NewReader("{\n  \"inodeIds\": [\n    \"9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e\"\n  ]\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "<token>.")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Deploy a tagged version
require 'uri'
require 'net/http'

url = URI("https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = '<token>.'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"inodeIds\": [\n    \"9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e\"\n  ]\n}"

response = http.request(request)
puts response.read_body
```

```java Deploy a tagged version
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files")
  .header("Authorization", "<token>.")
  .header("Content-Type", "application/json")
  .body("{\n  \"inodeIds\": [\n    \"9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e\"\n  ]\n}")
  .asString();
```

```php Deploy a tagged version
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files', [
  'body' => '{
  "inodeIds": [
    "9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e"
  ]
}',
  'headers' => [
    'Authorization' => '<token>.',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Deploy a tagged version
using RestSharp;

var client = new RestClient("https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "<token>.");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"inodeIds\": [\n    \"9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e\"\n  ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Deploy a tagged version
import Foundation

let headers = [
  "Authorization": "<token>.",
  "Content-Type": "application/json"
]
let parameters = ["inodeIds": ["9c3e7a1f-4b6d-4c8a-9e2f-1d5c8b3a6f9e"]] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.sigmacomputing.com/v2/deploymentPolicies/deploymentPolicyId/files")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```