> For the complete documentation index, see [llms.txt](https://docs.hedge.video/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hedge.video/~/revisions/tYrvN1vxhY8KQLkeHiim/canister/features/automation.md). Agents can also search and read this documentation through its [MCP server](https://docs.hedge.video/~gitbook/mcp).

# Automation

Automate transfers and fetch information about mounted tapes using Canister's API.

{% hint style="info" %}
A `Pro` license is required to use the Canister API. Mac support is coming soon.
{% endhint %}

## How it works

The Canister API responds to URLs beginning with `canister://`. These can be triggered from a browser, shell, or script. [Deployment calls](https://app.gitbook.com/o/-LStRji1SZuLAktaB8Sd/s/-LStRji2w1AYja1bLBFv/~/edit/~/changes/2214/canister/features/deployment#deployment-call-list) can be included in your automated workflows.

\
**Example script usage**

{% tabs %}
{% tab title="Windows" %}
Using Python:

```
import os
os.system("start canister://open")
```

{% endtab %}
{% endtabs %}

#### Add Archive <a href="#deactivate" id="deactivate"></a>

Archive a source to all mounted tapes:

```
canister://addarchive?sources="E:\Important footage"
```

| URL Parameter | Type   | Required? |
| ------------- | ------ | --------- |
| sources       | String | Mandatory |

A Collection of different sources, files, or folders can be combined using the `|` ("pipe") operator. Source paths must either be wrapped in quotes or URL encoded.

```
canister://addarchive?sources="E:\Important footage 1"|"F:\Important footage 2"
```

Optional parameters for choosing a destination tape and folder are available:

| URL Parameter     | Type   | Required? |
| ----------------- | ------ | --------- |
| destinationtape   | string | optional  |
| destinationfolder | string | optional  |

Putting it together:

{% code overflow="wrap" %}

```
canister://addarchive?sources="E:\Important footage 1"&destinationtape="Archive 01"&destinationfolder="260304"
```

{% endcode %}

#### Add Retrieve <a href="#deactivate" id="deactivate"></a>

Retrieve folders or files from tape:

{% code overflow="wrap" %}

```
canister://addretrieve?sources="260304\Important footage 1"&sourcetape="Archive 01"&destinationpath="E:\Retrieved Footage"
```

{% endcode %}

| URL Parameter   | Type   | Required? |
| --------------- | ------ | --------- |
| sources         | string | mandatory |
| sourcetape      | string | mandatory |
| destinationpath | string | mandatory |

#### Get Tapes <a href="#deactivate" id="deactivate"></a>

Generate a JSON list of mounted tapes using `gettapes`. Set an optional path for the dump using the `path` parameter:

```
canister://gettapes?path="c:\temp scripts"
```

| URL Parameter | Type   | Required? |
| ------------- | ------ | --------- |
| path          | String | optional  |

Sample output:

```
[
  {
    "name"               : "Archive 01",
    "serial"             : "19WT134678",
    "driveLetter"        : "Z",
    "status"             : "READY",
    "totalCapacityBytes" : 2408088338432,
    "freeBytes"          : 2408085192704
  }
]
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.hedge.video/~/revisions/tYrvN1vxhY8KQLkeHiim/canister/features/automation.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
