CLI Reference
Use Type CLI to deploy a project folder and to manage the automation after the deploy. Install it and log in first:
curl -fsSL https://type.com/install.sh | shtype-cli auth loginCommands
Section titled “Commands”| Goal | Command |
|---|---|
| Deploy or update a folder | type-cli automations deploy <folder> --space <space> |
| Follow a deploy | type-cli automations deployment <deployment-id> --space <space> --follow |
| Show the saved automation | type-cli automations get <automation-id> --kind scheduled --json |
| List automations | type-cli automations list --space <space> |
| Show runs | type-cli automations history --space <space> --automation <automation-id> |
| Show one run in detail | type-cli automations history --space <space> --run <run-id> --include-activity |
| Test saved code with a fixture | type-cli automations test-code <automation-id> --space <space> --arguments-file ./fixture.json |
| Pause | type-cli scheduled-actions disable <automation-id> --space <space> |
| Resume | type-cli scheduled-actions enable <automation-id> --space <space> |
| Archive | type-cli scheduled-actions archive <automation-id> --yes |
| Delete permanently | type-cli scheduled-actions delete <automation-id> --permanent --yes |
Type stores a deployed code automation as a scheduled action. That is why pause, resume, archive, and delete use scheduled-actions commands.
To see every automation command and flag that your workspace allows, run type-cli automations schema --live --json.
automations deploy
Section titled “automations deploy”type-cli automations deploy [<folder>] --space <space> [--timeout <seconds>] [--expires-in <duration> | --expires-at <time> | --max-runs <count> | --no-expiration] [--json]| Argument or flag | Default | Meaning |
|---|---|---|
<folder> | . | The project folder. It must contain type.json. |
--space | — | Required. The Space that owns the automation. |
--timeout | 600 | How long the CLI waits, in seconds. 1 to 3600. |
--expires-in | — | Expire after a duration from the first activation: a whole number with s, m, h, or d, for example 30s, 15m, 5h, or 7d. 1 to 315,576,000 seconds. |
--expires-at | — | Expire at an ISO timestamp with Z or an offset, for example 2026-10-10T10:00:00-06:00. |
--max-runs | — | Expire after this number of live runs. 1 to 2,147,483,647. |
--no-expiration | — | Remove the expiration for this deploy. |
--follow | — | Accepted, but has no effect. deploy always prints progress. |
--json | off | Print JSON lines. |
Use at most one expiration flag. It replaces type.json and the source for this deploy only. The next deploy without a flag uses the project value again. See Expiration.
What the command does:
- Reads and validates the folder on your computer. See Project Files.
- Creates
.type/project.jsonif it does not exist. This file is the identity of the project. - Writes a new deployment ID to
.type/deployment.json. - Sends the project to Type and prints the deployment ID.
- Prints each deploy step until the deploy is
active,paused, orfailed. - Writes the automation ID to
.type/deployment.json.
Example output for the project in Project Files:
Deployment 3f6c2a4e-8b1d-4c2a-9f0e-1a2b3c4d5e6fdeployment: startedvalidation: startedvalidation: succeededfixtures [records the scheduled time]: startedfixtures [records the scheduled time]: succeededsubscription [hourly]: startedsubscription [hourly]: succeededactivation: startedactivation: succeededdeployment: succeededDeployment 3f6c2a4e-8b1d-4c2a-9f0e-1a2b3c4d5e6f: activeAutomation: atask_01k...Each line is <step> [<key>]: <status> — <message>. The steps are deployment, validation, fixtures, subscription, and activation. The key is a fixture name, a subscription key, or a webhook adapter key. A failed step shows the error message.
With --json, the command prints one JSON object on each line:
{"type":"deployment","deploymentId":"3f6c2a4e-..."}{"type":"checkpoint","deploymentId":"3f6c2a4e-...","automationId":"atask_...","stage":"validation","status":"succeeded","sequence":2,"at":"2026-10-13T12:00:01.000Z"}{"ok":true,"operation":"automations.deploy","deploymentId":"3f6c2a4e-...","automationId":"atask_...","status":"active","events":[...]}Deploy rules:
- The first deploy of a folder turns the automation on. A later deploy keeps the current state. If the automation is paused, the deploy ends
pausedwith “Saved paused. Enable the automation explicitly when ready.” - If a deploy fails, the automation keeps its last active revision.
- A folder can have only one deploy in progress.
- Only the person who created the automation can deploy to it again.
- While Type has paused an automation for a person (repeated failures, an account to reconnect, or an agent’s request), a deploy is refused until it is enabled again.
- Two automations in the same Space cannot have the same
name. - Type stops a deploy that runs longer than 10 minutes.
- If the CLI stops waiting, it prints the command to follow the deploy and exits with code 6. The deploy keeps running.
- If you lose the connection during a deploy, do not deploy again at once. Use
automations deploymentwith the ID from.type/deployment.jsonto read the result.
automations deployment
Section titled “automations deployment”type-cli automations deployment <deployment-id> --space <space> [--follow] [--timeout <seconds>] [--json]Reads the status of a deploy. <deployment-id> is the UUID that deploy printed. Without --follow, it prints the current status one time. With --follow, it prints each step until the deploy ends, or until --timeout (default 600 seconds).
Statuses: running, active, paused, failed. A failed deploy exits with code 6.
automations get
Section titled “automations get”type-cli automations get <automation-id> --kind scheduled [--json]Shows the saved automation. --kind is required. For a code automation, the result includes codeExecution, codeFiles, and subscriptionStatuses. Each subscription status is pending, active, paused, or disabled. The result can also include connection health, recovery details, and a request for human intervention.
automations list
Section titled “automations list”type-cli automations list (--space <space> | --all-spaces) [--kind scheduled|event|all] [--json]Lists the automations in one Space, or in all Spaces that you can access. Use exactly one of --space and --all-spaces. --kind defaults to all.
automations history
Section titled “automations history”type-cli automations history --space <space> [--automation <id>] [--status <status>] [--mode <mode>] [--since <time>] [--until <time>] [--limit <n>] [--kind <kind>]type-cli automations history --space <space> --run <id> [--include-activity [--include-content [--max-chars <n>]]]| Flag | Meaning |
|---|---|
--automation | Show runs of one automation. |
--run | Show one run. Do not combine it with --automation, --status, --mode, --since, or --until. |
--status | running, completed, failed, or cancelled. |
--mode | live, test, unknown, or all. |
--kind | scheduled, event, or all. Default all. |
--since, --until | An ISO time with a time zone, or a relative time such as 7d or 12h. --until is exclusive. |
--limit | 1 to 100. Default 20. |
--cursor | The next page. Use it without the other filters. |
--include-activity | Add the steps of the run. Requires --run. |
--include-content | Add message content. Requires --include-activity. |
--max-chars | 1 to 48,000. Default 8,000. Requires --include-content. |
Use --all-spaces instead of --space for a summary report across all Spaces that you can access. The report has no run details.
For a code automation, run details can include the code result, the call journal, recovery details, and report errors.
automations test-code
Section titled “automations test-code”type-cli automations test-code <automation-id> --space <space> (--arguments-file <path> | --arguments '<JSON>') [--json]Runs one fixture against the saved code. Use --arguments-file - to read the fixture from stdin.
- The automation can be on or paused.
- You must be a member of the automation’s Space.
- The fixture has the same fields as a case in
fixtures.json, withoutname,expectedOutput, andexpectedError. See Project Files. - The command returns the result and
testedDefinitionHash. It does not turn the automation on. If a member’s Enable was waiting for a test, a passing test can complete it.
Pause, resume, archive, and delete
Section titled “Pause, resume, archive, and delete”| Command | Notes |
|---|---|
scheduled-actions disable <id> --space <space> [--finish-runs | --stop-runs] | Stops new runs. By default, runs in progress stop at their next stage; an agent stage that is already running finishes its turn first. --finish-runs lets them finish; --stop-runs asks for the default explicitly. |
scheduled-actions enable <id> --space <space> | In some workspaces, enable requires a completed private test of the current definition first. The command then fails with test_required or test_in_progress. A person can always enable the automation from its page in Type. |
scheduled-actions archive <id> --yes | Turns off and hides the automation, and stops its runs in progress. Configuration and run history remain. |
scheduled-actions delete <id> --permanent --yes | Deletes the automation. Run records and delivered output remain. This cannot be undone. Without --permanent, delete archives. |
Without --yes, archive and delete ask before they change anything.
Reports
Section titled “Reports”type-cli automations visualization get <automation-id> --space <space> --jsontype-cli automations visualization update <automation-id> --space <space> --patch-file ./report.json --expected-revision 4 --jsontype-cli automations visualization hide <automation-id> --space <space> --expected-revision 5 --jsontype-cli automations visualization restore <automation-id> --space <space> --expected-revision 6 --jsontype-cli automations visualization export <automation-id> --space <space> --destination json --jsonupdate,hide, andrestorerequire the current revision in--expected-revision. Read the report first. After a version conflict, read it again.- The update file contains
visualization, and optionallayoutPrompt,stateSources, anddataSources. Use--patch-file -for stdin. hidekeeps the saved report.restoreshows it again.exportsupports--destination json(the default) andimage.
Global flags
Section titled “Global flags”| Flag | Environment variable | Meaning |
|---|---|---|
--json | TYPE_JSON=1 | Print JSON. |
--no-input | TYPE_NO_INPUT=1 | Do not ask questions. Commands that need approval fail unless you add --yes. |
--profile <name> | TYPE_PROFILE | Use a saved login profile. Default default. |
--org <org> | TYPE_ORG_ID | Use a workspace. |
--server <url> | TYPE_SERVER_URL | Default https://api.type.com. |
Exit codes
Section titled “Exit codes”| Exit code | Error code | Meaning |
|---|---|---|
| 0 | — | Success. |
| 1 | unexpected_error | An unknown error. |
| 2 | invalid_input, version_conflict, test_required, test_in_progress | The input is not valid, or the data changed. Also returned when you deploy and code automations are not on for the workspace. |
| 3 | auth_required | Run type-cli auth login. |
| 4 | permission_denied | You do not have access. Also returned by test-code and report commands when their feature is not on. |
| 5 | ambiguous_resource | More than one item matches. |
| 6 | unavailable, rate_limited | The deploy failed, the wait timed out, or Type is not available. |
| 8 | not_found | The item does not exist. |
With --json, an error prints {"ok":false,"error":{"code","message","details"}}.
Limitations
Section titled “Limitations”automations test-coderuns one fixture against saved, paused code. Each deploy still runs the project’sfixtures.json.automations tests startandscheduled-actions testsend the automation’s instructions to an agent in a private thread. They do not run your code with fixtures.- The CLI has no
logscommand. Useautomations history --run <id> --include-activity. - Offline
automations schemaomits code commands. Useautomations schema --liveto see them when the feature is on.