Clear pipeline cache

  • PATCH
  • /workspaces
  • /:workspace
  • /projects
  • /:project_name
  • /pipelines
  • /:pipeline_id

Clears cache of an existing pipeline in the project

Request

REQUIRED SCOPES
EXECUTION_MANAGE
URL PARAMETERS
workspacerequiredstring
The human-readable ID of the workspace

Example: "my-company"

project_namerequiredstring
The human-readable ID of the project

Example: "my-project"

pipeline_idrequiredinteger
The ID of the pipeline

Example: 123

POST PARAMETERS
clear_cacherequiredboolean
Set to true to clear all action caches for this pipeline

Response

RESPONSE BODY
urlread-onlystring
API endpoint to GET this object
html_urlread-onlystring
Web URL to view this object in Buddy.works
idinteger
The unique identifier of the pipeline
identifierstring
A human-readable ID of pipeline
namestring
The name of the pipeline
definition_sourcestring enum
The source of the pipeline definition
Allowed enum:
LOCAL,
REMOTE
git_config_refstring enum
The git configuration reference type
Allowed enum:
NONE,
DYNAMIC,
FIXED
refsstring[]
Pipeline git context refs. If unset and events is empty, the pipeline counts as codeless
eventsPipelineEventView[]
The list of events that trigger the pipeline run
loopstring[]
The loop configuration for the pipeline

Constraints: Unique items required

prioritystring enum
The priority of the pipeline
Allowed enum:
LOW,
NORMAL,
HIGH
disabledboolean
Indicates if the pipeline is disabled
disabled_reasonstring
The reason why the pipeline is disabled
last_execution_statusstring enum
The status of the last run
Allowed enum:
INPROGRESS,
ENQUEUED,
TERMINATED,
SUCCESSFUL,
FAILED,
INITIAL,
NOT_EXECUTED,
SKIPPED,
TERMINATING,
WAITING_FOR_APPLY,
WAITING_FOR_VARIABLES,
WAITING_FOR_SETTABLE_VARIABLES,
WAITING_FOR_VT_SESSION
last_execution_revisionstring
The git revision of the last run
target_site_urlstring
The URL to the target site after deployment
execution_message_templatestring
The template for commit status messages
create_datestring
The creation date of the pipeline
always_from_scratchboolean
Defines whether to upload everything from scratch on every run
ignore_fail_on_project_statusboolean
If set to true, the status of a given pipeline will not impact the project status on the dashboard
no_skip_to_most_recentboolean
If set to true, the pipeline will not skip queued runs to execute the most recent one
terminate_stale_runsboolean
If set to true, stale runs will be automatically terminated
auto_clear_cacheboolean
Defines whether to automatically clear cache before running the pipeline
pausedboolean
Indicates if the pipeline is paused
pause_on_repeated_failuresinteger
Defines how many repeated failures are required to pause the pipeline
fetch_all_refsboolean
If set to true, all refs will be fetched from the repository
fail_on_prepare_env_warningboolean
If set to true, the pipeline will fail on environment preparation warnings
concurrent_pipeline_runsboolean
Defines whether the pipeline can be run concurrently
clone_depthinteger
Defines the depth of the git clone operation for shallow clones
do_not_create_commit_statusboolean
If set to true, commit statuses will not be created in the repository
staleboolean
Indicates that pipeline definition was probably removed on particular Git ref and pipeline won't be run on events
waiting_for_pushboolean
Indicates if the pipeline is waiting for the first push to the repository
resourcesstring enum
The resource configuration for the pipeline run
Allowed enum:
DEFAULT,
NANO,
SMALL,
MEDIUM,
LARGE,
XLARGE,
CUSTOM,
X2LARGE
remote_pathstring
The path to the remote pipeline definition file
remote_refstring
The ref of the remote pipeline definition
remote_project_namestring
The project name of the remote pipeline definition
remote_parametersPipelinePropertyView[]
The parameters passed to the remote pipeline definition
git_configYamlDefinitionView
YAML pipeline definition configuration
tagsstring[]
The list of tags associated with the pipeline for organization

Constraints: Unique items required

git_changeset_basestring enum
The base for git changeset calculation. Determines which changes trigger the pipeline
Allowed enum:
LATEST_RUN,
LATEST_RUN_MATCHING_REF,
PULL_REQUEST
filesystem_changeset_basestring enum
The base for filesystem changeset calculation. Determines which file changes trigger the pipeline
Allowed enum:
DATE_MODIFIED,
CONTENTS
cpustring enum
The CPU architecture for the pipeline run
Allowed enum:
X64,
ARM,
X86
description_requiredboolean
If set to true, a description is required when executing the pipeline manually
folderstring
The folder name where the pipeline is organized
projectShortProjectView
Short representation of a project
creatorMemberView
User/member reference
cache_scopestring enum
Defines the cache scope
Allowed enum:
PIPELINE,
PROJECT,
WORKSPACE
trigger_conditionsTriggerConditionView[]
The list of trigger conditions to meet so that the pipeline can be triggered
variablesEnvironmentVariableView[]
The list of environment variables defined for the pipeline
environmentsEnvironmentView[]
The list of environments attached to the pipeline
packagesPipelinePkgContextView[]
The list of package contexts configured for the pipeline
permissionsPermissionsView
Access permissions configuration
manage_variables_by_yamlboolean
If set to true, variables are managed by YAML configuration
manage_permissions_by_yamlboolean
If set to true, permissions are managed by YAML configuration
actionsShortActionResponse[]
The list of actions configured in the pipeline

Last modified on Feb 18, 2026

Request example

curl -X PATCH "https://api.buddy.works/workspaces/:workspace/projects/:project_name/pipelines/:pipeline_id" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "Content-Type: application/json" \ -d '{ "clear_cache": true }'
EXAMPLE RESPONSE
{ "url": "https://api.buddy.works/workspaces/my-workspace/projects/my-project/pipelines/123", "html_url": "https://app.buddy.works/my-workspace/my-project/pipelines/pipeline/123", "id": 123, "identifier": "deploy-production", "name": "Deploy to production", "definition_source": "LOCAL", "git_config_ref": "NONE", "refs": [ "refs/heads/main" ], "events": [ { "type": "PUSH" } ], "priority": "NORMAL", "disabled": false, "last_execution_status": "SUCCESSFUL", "create_date": "2023-01-15T10:30:00Z", "always_from_scratch": false, "ignore_fail_on_project_status": false, "strict_context": false, "no_skip_to_most_recent": false, "terminate_stale_runs": false, "auto_clear_cache": false, "fetch_all_refs": false, "fail_on_prepare_env_warning": true, "concurrent_pipeline_runs": false, "do_not_create_commit_status": false, "stale": false, "waiting_for_push": false, "resources": "DEFAULT", "git_changeset_base": "LATEST_RUN", "filesystem_changeset_base": "DATE_MODIFIED", "cpu": "X64", "description_required": false, "project": { "url": "https://api.buddy.works/workspaces/my-workspace/projects/my-project", "html_url": "https://app.buddy.works/my-workspace/projects/my-project", "name": "my-project", "display_name": "My Project", "status": "ACTIVE" }, "creator": { "url": "https://api.buddy.works/workspaces/my-workspace/members/123", "html_url": "https://app.buddy.works/my-workspace/-/profile/123", "id": 123, "name": "John Doe", "avatar_url": "https://app.buddy.works/image-server/user/0/0/0/0/0/0/123/a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6/w/32/32/AVATAR.png?ts=1674644200000", "email": "john.doe@company.com", "admin": true, "workspace_owner": false }, "cache_scope": "PIPELINE", "variables": [], "environments": [], "permissions": { "others": "DEFAULT" }, "manage_variables_by_yaml": false, "manage_permissions_by_yaml": false, "actions": [ { "url": "https://api.buddy.works/workspaces/my-workspace/projects/my-project/pipelines/123/actions/456", "html_url": "https://app.buddy.works/my-workspace/my-project/pipelines/pipeline/123/action/456/edit", "id": 456, "name": "Build application", "type": "BUILD", "trigger_time": "ON_EVERY_EXECUTION", "last_execution_status": "SUCCESSFUL", "current_revision": "abc123def456", "disabled": false, "ignore_errors": false, "run_next": "WAIT_ON_SUCCESS" } ] }
STATUS
200 OK