Snippets

Update snippet

Update a snippet

patch/workspaces/{workspace_id}/snippets/{snippet_id}

Request

  • Base URL: https://app.mammoth.io/api/v2
  • URL: https://app.mammoth.io/api/v2/workspaces/{workspace_id}/snippets/{snippet_id}
  • Auth: one of:
    • HTTP bearer
    • API key in header X-API-KEY and API key in header X-API-SECRET and API key in header X-WORKSPACE-ID

Path parameters

workspace_idinteger required

Workspace refers to a collection of projects. Workspace ID is unique identifier for workspace.

Example:4
snippet_idinteger required

Request body

namestring nullable

Updated snippet name

codestring nullable

Updated snippet source code

languagestring nullable

Updated language of the snippet

descriptionstring nullable

Updated description

group_idinteger nullable

Updated group ID

Response

Update SnippetResponse

idinteger required

Snippet ID

namestring required

Snippet name

codestring required

Snippet source code

languagestring required

Snippet language

descriptionstring nullable

Snippet description

scopestring required

Scope of the snippet

group_idinteger nullable

Parameter group ID

group_namestring nullable

Name of the parameter group

pipeline_countinteger required

Number of pipelines using this snippet

stale_pipelinesinteger[]

Dataview IDs of stale pipelines using this snippet

referenced_parametersstring[] required

Names of parameters used in the snippet code

created_byinteger required

User ID who created the snippet

created_atstring required

Creation timestamp

updated_byinteger nullable

User ID who last updated the snippet

updated_atstring required

Last update timestamp

Changes

No recorded changes to this operation across all 5 revisions of this API.