mammoth snippet
Generated from mammoth-cli 2.4.2, released 2026-11-02:
mammoth schema list,mammoth capability listand the CLI's own--help. Do not edit by hand; runnpm run docs:capabilities.
Manage reusable snippets. 8 commands.
Every command also takes the global flags (--output, --yes, --confirm, --dry-run, --input, --profile, ...), which are not repeated below. --input takes a JSON or YAML document of the input fields; mammoth schema get COMMAND_ID prints a command's full input schema.
Confirmation. Commands marked --yes --confirm TARGET or --yes always need those flags, even at a terminal: they never prompt. Commands marked "--yes or prompt" ask at an interactive terminal (table output, no --no-input) and otherwise need --yes. --dry-run skips confirmation and sends nothing.
Summary
| Command | What it does | Effect | Confirmation |
|---|---|---|---|
snippet create | Create a snippet. Name comes from a positional or the 'name' field. | Benign mutation | — |
snippet delete | Delete one snippet by id. Prompt or '--yes' required. | Destructive | --yes or prompt |
snippet dependencies | Report dependencies for one snippet by id. | Read | — |
snippet duplicate | Duplicate one snippet by id. | Benign mutation | — |
snippet get | Get one snippet by id. | Read | — |
snippet list | List snippets in the active project. | Read | — |
snippet rerun | Rerun one snippet by id. | Benign mutation | — |
snippet update | Update a snippet's fields. Snippet id is positional; fields come from '--input'. | Benign mutation | — |
snippet commands
mammoth snippet create
Create a snippet. Name comes from a positional or the 'name' field.
mammoth snippet create 'Revenue report' --input '{"code": "SELECT * FROM orders", "language": "sql"}'
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
NAME | positional | no | — | str | Name of the new snippet; or pass it via the 'name' input field. Or the name input field. |
name | --input field | no | — | str | |
code | --input field | yes | — | str | |
language | --input field | yes | — | str | |
description | --input field | no | — | str | |
group_id | --input field | no | — | int | |
scope | --input field | no | project | str |
- Effect: Benign mutation, scope
project· Confirmation: none - Id:
snippet.create· Result:SnippetCreateResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.create, APIPOST /workspaces/{workspace_id}/snippets(CreateSnippet)
mammoth snippet delete
Delete one snippet by id. Prompt or '--yes' required.
mammoth snippet delete 123 --yes
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
SNIPPET_ID | positional | yes | — | int | ID of the snippet. |
- Effect: Destructive, scope
project· Confirmation:--yes, or answer the prompt at an interactive terminal - Preconditions: Required inputs: SNIPPET_ID.
- Id:
snippet.delete· Result:SnippetDeleteResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.delete, APIDELETE /workspaces/{workspace_id}/snippets/{snippet_id}(DeleteSnippet)
mammoth snippet dependencies
Report dependencies for one snippet by id.
mammoth snippet dependencies 123
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
SNIPPET_ID | positional | yes | — | int | ID of the snippet. |
- Effect: Read, scope
project· Confirmation: none - Preconditions: Required inputs: SNIPPET_ID.
- Id:
snippet.dependencies· Result:SnippetDependenciesResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.dependencies, APIGET /workspaces/{workspace_id}/snippets/{snippet_id}/dependencies(GetSnippetDependencies)
mammoth snippet duplicate
Duplicate one snippet by id.
mammoth snippet duplicate 123
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
SNIPPET_ID | positional | yes | — | int | ID of the snippet. |
- Effect: Benign mutation, scope
project· Confirmation: none - Preconditions: Required inputs: SNIPPET_ID.
- Id:
snippet.duplicate· Result:SnippetDuplicateResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.duplicate, APIPOST /workspaces/{workspace_id}/snippets/{snippet_id}/duplicate(DuplicateSnippet)
mammoth snippet get
Get one snippet by id.
mammoth snippet get 123
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
SNIPPET_ID | positional | yes | — | int | ID of the snippet. |
- Effect: Read, scope
project· Confirmation: none - Preconditions: Required inputs: SNIPPET_ID.
- Id:
snippet.get· Result:SnippetGetResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.get, APIGET /workspaces/{workspace_id}/snippets/{snippet_id}(GetSnippetDetail)
mammoth snippet list
List snippets in the active project.
mammoth snippet list
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
limit | --input field | no | — | int | |
offset | --input field | no | — | int | |
search | --input field | no | — | str | |
group_id | --input field | no | — | int | |
sort | --input field | no | — | str |
- Effect: Read, scope
project· Confirmation: none · Pages:single_page - Id:
snippet.list· Result:SnippetListResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.list, APIGET /workspaces/{workspace_id}/snippets(ListSnippets)
mammoth snippet rerun
Rerun one snippet by id.
mammoth snippet rerun 123
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
SNIPPET_ID | positional | yes | — | int | ID of the snippet. |
- Effect: Benign mutation, scope
project· Confirmation: none - Preconditions: Required inputs: SNIPPET_ID.
- Id:
snippet.rerun· Result:SnippetRerunResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.rerun, APIPOST /workspaces/{workspace_id}/snippets/{snippet_id}/rerun(RerunSnippet)
mammoth snippet update
Update a snippet's fields. Snippet id is positional; fields come from '--input'.
mammoth snippet update 123
| Name | Passed as | Required | Default | Type | Notes |
|---|---|---|---|---|---|
SNIPPET_ID | positional | yes | — | int | ID of the snippet. |
name | --input field | no | — | str | |
code | --input field | no | — | str | |
language | --input field | no | — | str | |
description | --input field | no | — | str | |
group_id | --input field | no | — | int |
- Effect: Benign mutation, scope
project· Confirmation: none - Preconditions: Required inputs: SNIPPET_ID.
- Id:
snippet.update· Result:SnippetUpdateResult· Backed by: SDKmammoth.api.snippets.SnippetsAPI.update, APIPATCH /workspaces/{workspace_id}/snippets/{snippet_id}(UpdateSnippet)