Create & manage pipelines

List pipelines

Returns the pipelines from the project. Pipeline hidden with the visibility settings will not be fetched.
Required scopes: WORKSPACE, EXECUTION_INFO

Resource URL
GET
/workspaces/:domain/projects/:project_name/pipelines
URL Parameters
Name Description
domain Required String The workspace domain.
project_name Required String The name ID of the project.
GET Parameters
Name Description
page Integer The number of the successive page (results are splitted by pages of per_page elements each).
per_page Integer The number of returned elements on the page.
sort_by String Specifies the ordering. Can be one of name or id.
sort_direction String Specifies the direction of the ordering. Can be one of ASC or DESC.
Example
Request
GET
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines?sort_by=name&sort_direction=ASC&page=1&per_page=2
Sample Response
Status: 200 OK
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines",
  "pipelines": [
    {
      "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
      "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
      "id": 2,
      "name": "dev",
      "trigger_mode": "MANUAL",
      "ref_name": "master",
      "last_execution_status": "SUCCESSFUL",
      "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
    }
  ]
}

Add new pipeline

Creates a new pipeline in the project.
Required scopes: WORKSPACE, EXECUTION_MANAGE

Resource URL
POST
/workspaces/:domain/projects/:project_name/pipelines
URL Parameters
Name Description
domain Required String The workspace domain.
project_name Required String The name ID of the project.
POST Parameters
Name Description
name Required String The name of the pipeline.
ref_name Required String Wildcard or branch.
trigger_mode Required String Trigger mode of pipeline. Can be one of MANUAL, SCHEDULED or ON_EVERY_PUSH.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines
{
  "name": "Tests",
  "trigger_mode": "ON_EVERY_PUSH",
  "ref_name": "master"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
  "id": 2,
  "name": "Tests",
  "trigger_mode": "ON_EVERY_PUSH",
  "ref_name": "master",
  "last_execution_status": "INITIAL",
  "last_execution_revision": null,
  "create_date": "2016-03-29T07:12:30.675Z",
  "project": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website",
    "html_url": "https://app.buddy.works/buddy/company-website",
    "name": "company-website",
    "display_name": "Company Website",
    "status": "ACTIVE"
  },
  "creator": {
    "url": "https://api.buddy.works/workspaces/buddy/member/1",
    "html_url": "https://app.buddy.works/buddy/profile/1",
    "id": 1,
    "name": "Mike Benson",
    "avatar_url": "https://app.buddy.works/image-server/user/0/0/0/0/0/0/1/d643744fbe5ebf2906a4d075a5b97110/w/32/32/AVATAR.png",
    "title": "Creative director"
  },
  "actions": []
}

Get pipeline

Returns a single pipeline
Required scopes: WORKSPACE, EXECUTION_INFO

Resource URL
GET
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id
URL Parameters
Name Description
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.
Example
Request
GET
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2
Sample Response
Status: 200 OK
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
  "id": 2,
  "name": "Live mirror",
  "trigger_mode": "MANUAL",
  "ref_name": "master",
  "status": "SUCCESSFUL",
  "create_date": "2016-02-29T11:23:12Z",
  "project": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website",
    "html_url": "https://app.buddy.works/buddy/company-website",
    "name": "company-website",
    "display_name": "Company Website",
    "status": "ACTIVE"
  },
  "creator": {
    "url": "https://api.buddy.works/workspaces/buddy/member/1",
    "html_url": "https://app.buddy.works/buddy/profile/1",
    "id": 1,
    "name": "Mike Benson",
    "avatar_url": "https://app.buddy.works/image-server/user/0/0/0/0/0/0/1/d643744fbe5ebf2906a4d075a5b97110/w/32/32/AVATAR.png",
    "title": "Creative director"
  },
  "actions": [
    {
      "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/5",
      "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/5/edit",
      "id": 5,
      "name": "Upload files to Live mirror",
      "type": "FTP",
      "trigger_time": "ON_EVERY_EXECUTION",
      "run_only_on_first_failure": false,
      "status": "SUCCESSFUL",
      "revision": null
    }
  ]
}

status can be either SUCCESSFUL, FAILED, INPROGRESS, ENQUEUED, SKIPPED, TERMINATED, or INITIAL

Edit pipeline

Updates a pipeline in the project. If you want to manage the pipelines, use these methods: add, edit, delete.
Required scopes: WORKSPACE, EXECUTION_MANAGE

Resource URL
PATCH
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id
URL Parameters
Name Description
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.
POST Parameters
Name Description
ref_name Required String Wildcard or branch.
trigger_mode Required String Trigger mode of pipeline. Can be one of MANUAL, SCHEDULED or ON_EVERY_PUSH.
name String The name of the pipeline.
last_execution_revision String The hash of the commit that is currently deployed on the server.
Example
Request
PATCH
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2
{
  "name": "Live mirror",
  "trigger_mode": "MANUAL",
  "ref_name": "master",
  "last_execution_revision": "184623451d99d95e75e82b687ba4e1d4e087b4ef"
}
Sample Response
Status: 200 OK
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
  "id": 2,
  "name": "Live mirror",
  "trigger_mode": "MANUAL",
  "ref_name": "master",
  "last_execution_status": "SUCCESSFUL",
  "last_execution_revision": "184623451d99d95e75e82b687ba4e1d4e087b4ef",
  "create_date": "2016-03-29T06:10:10Z",
  "project": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website",
    "html_url": "https://app.buddy.works/buddy/company-website",
    "name": "company-website",
    "display_name": "Company Website",
    "status": "ACTIVE"
  },
  "creator": {
    "url": "https://api.buddy.works/workspaces/buddy/member/1",
    "html_url": "https://app.buddy.works/buddy/profile/1",
    "id": 1,
    "name": "Mike Benson",
    "avatar_url": "https://app.buddy.works/image-server/user/0/0/0/0/0/0/1/d643744fbe5ebf2906a4d075a5b97110/w/32/32/AVATAR.png",
    "title": "Creative director"
  },
  "actions": [
    {
      "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/5",
      "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/5/edit",
      "id": 5,
      "name": "Upload files to dev",
      "type": "FTP",
      "trigger_time": "ON_EVERY_EXECUTION",
      "last_execution_status": "SUCCESSFUL",
      "run_only_on_first_failure": false
    }
  ]
}

Delete pipeline

Deletes existing pipeline from the project.
Required scopes: WORKSPACE, EXECUTION_MANAGE

Resource URL
DELETE
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id
URL Parameters
Name Description
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.
Example
Request
DELETE
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2
Sample Response
Status: 204 NoContent
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999

List pipeline actions

Returns all actions from the pipeline.
Required scopes: WORKSPACE, EXECUTION_INFO

Resource URL
GET
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id/actions
URL Parameters
Name Description
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.
GET Parameters
Name Description
trigger_time String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
Example
Request
GET
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
Sample Response
Status: 200 OK
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2/manage",
  "actions": [
    {
      "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/5",
      "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/5/edit",
      "id": 5,
      "name": "Upload files to dev",
      "type": "FTP",
      "trigger_time": "ON_EVERY_EXECUTION",
      "last_execution_status": "SUCCESSFUL",
      "run_only_on_first_failure": false
    }
  ]
}

Add action

Creates a new action in the pipeline.
Required scopes: WORKSPACE, EXECUTION_MANAGE

Resource URL
POST
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id/actions
URL Parameters
Name Description
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.

Add Build action

POST Parameters
Name Description
docker_image_name Required String The name of the docker image.
docker_image_tag Required String The tag of the docker image.
execute_commands Required String[] Commands that will be executed.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to BUILD.
cached_dirs String[] Dependencies & directories to be cached and available to every execution in this pipeline.
setup_commands String[] Command that will be executed only on the first run.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Build application",
  "type": "BUILD",
  "trigger_time": "ON_EVERY_EXECUTION",
  "docker_image_name": "library/ubuntu",
  "docker_image_tag": "latest",
  "execute_commands": [
    "ls -al > ls.log"
  ],
  "setup_commands": [
    "apt-get update -y",
    "apt-get install -y wget"
  ],
  "cached_dirs": [
    "/build/test",
    "/bin/Debug"
  ]
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Build application",
  "type": "BUILD",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "docker_image_name": "library/ubuntu",
  "docker_image_tag": "latest",
  "execute_commands": [
    "ls -al > ls.log"
  ],
  "setup_commands": [
    "apt-get update -y",
    "apt-get install -y wget"
  ],
  "cached_dirs": [
    "/build/test",
    "/bin/Debug"
  ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Elastic Beanstalk action

POST Parameters
Name Description
application_name Required String Application name.
environment Required String The Amazon S3 environment.
input_type Required String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
integration Required Integration The integration.
name Required String The name of action.
region Required String The Amazon S3 region name. Full list of regions there.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to ELASTIC_BEANSTALK.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to Elastic Beanstalk/tests",
  "type": "ELASTIC_BEANSTALK",
  "trigger_time": "ON_EVERY_EXECUTION",
  "integration": {
    "id": 33
  },
  "application_name": "tests",
  "region": "us-west-2",
  "environment": "e-rnuptbebz2",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ]
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/845",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/845/edit",
  "id": 845,
  "name": "Upload files to Elastic Beanstalk/tests",
  "type": "ELASTIC_BEANSTALK",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "application_name": "tests",
  "environment": "e-rnuptbebz2",
  "region": "us-west-2",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "integration": {
    "url": "https://api.buddy.works/workspaces/buddy/user/integrations/33",
    "html_url": "https://app.buddy.works/my-id",
    "id": 33
  },
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Email notification action

POST Parameters
Name Description
custom Required Boolean Defines whether the content will be custom.
name Required String The name of action.
recipients Required String Notification recipients - email addresses(one per line).
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to EMAIL.
content String Notification content.
title String Notification title.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "EMAIL Action",
  "type": "EMAIL",
  "trigger_time": "ON_EVERY_EXECUTION",
  "custom": true,
  "content": "Pipeline executed successfully!",
  "recipients": "admin@mailinator.com\nmanage@mailinator.com",
  "title": "Pipeline executed successfully!"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "EMAIL Action",
  "type": "EMAIL",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "title": "Pipeline executed successfully!",
  "content": "Pipeline executed successfully!",
  "custom": true,
  "recipients": "admin@mailinator.com\nmanage@mailinator.com",
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add FTP action

POST Parameters
Name Description
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
password Required String The password required to connect the server.
port Required String The port for the connection.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to FTP.
active_mode Boolean Enables active mode for the connection.
input_type String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
local_path String The path in the repository.
remote_path String The absolute or relative path on the remote server.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to localhost",
  "type": "FTP",
  "input_type": "SCM_REPOSITORY",
  "trigger_time": "ON_EVERY_EXECUTION",
  "host": "localhost",
  "port": "21",
  "login": "api_tests_user",
  "password": "api_tests_password",
  "active_mode": true,
  "local_path": "/asset/",
  "remote_path": "Home/www/",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ]
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Upload files to localhost",
  "type": "FTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "input_type": "SCM_REPOSITORY",
  "local_path": "/asset/",
  "remote_path": "Home/www/",
  "login": "root",
  "active_mode": true,
  "host": "localhost",
  "port": "21",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add FTP over SSL action

POST Parameters
Name Description
authentication_mode Required String The authentication mode for SSH. Can be one of PASS, PRIVATE_KEY or PRIVATE_KEY_AND_PASS.
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
password Required String The password required to connect the server.
port Required String The port for the connection.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to FTPS.
input_type String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
local_path String The path in the repository.
remote_path String The absolute or relative path on the remote server.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to localhost",
  "type": "FTPS",
  "trigger_time": "ON_EVERY_EXECUTION",
  "authentication_mode": "PASS",
  "host": "localhost",
  "port": "21",
  "login": "api_tests_user",
  "password": "api_tests_password",
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ]
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Upload files to localhost",
  "type": "FTPS",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "login": "root",
  "active_mode": false,
  "host": "localhost",
  "port": "21",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Heroku action

POST Parameters
Name Description
application_name Required String Application name.
integration Required Integration The integration.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to HEROKU.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Push to Your Repo",
  "type": "HEROKU",
  "trigger_time": "ON_EVERY_EXECUTION",
  "integration": {
    "id": 33
  },
  "application_name": "AppName"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/1/actions/1",
  "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/1/action/1/edit",
  "id": 1,
  "name": "Deploy application to Heroku",
  "type": "HEROKU",
  "trigger_time": "ON_EVERY_EXECUTION",
  "run_only_on_first_failure": false,
  "last_execution_status": "INITIAL",
  "application_name": "slskopytko",
  "integration": {
    "url": "https://api.dev.io/workspaces/acme/user/integrations/1",
    "html_url": "https://app.dev.io/my-id",
    "id": 1
  },
  "pipeline": {
    "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/1",
    "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/1",
    "id": 1,
    "name": "test server",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Heroku CLI action

POST Parameters
Name Description
application_name Required String Application name.
commands Required String[] The array of commands invoked on the remote server.
integration Required Integration The integration.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to HEROKU_CLI.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/1/actions
{
  "name": "Execute commands on Heroku",
  "type": "HEROKU_CLI",
  "trigger_time": "ON_EVERY_EXECUTION",
  "commands": [
    "date >> tests.log"
  ],
  "integration": {
    "id": 33
  },
  "application_name": "AppName"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/1/actions/1",
  "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/1/action/1/edit",
  "id": 1,
  "name": "Execute commands on Heroku",
  "type": "HEROKU_CLI",
  "trigger_time": "ON_EVERY_EXECUTION",
  "run_only_on_first_failure": false,
  "last_execution_status": "INITIAL",
  "application_name": "AppName",
  "commands": [
    "date >> tests.log"
  ],
  "integration": {
    "url": "https://api.dev.io/workspaces/acme/user/integrations/1",
    "html_url": "https://app.dev.io/my-id",
    "id": 1
  },
  "pipeline": {
    "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/1",
    "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/1",
    "id": 1,
    "name": "test server",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add HTTP notification action

POST Parameters
Name Description
custom Required Boolean Defines whether the content will be custom.
name Required String The name of action.
notification_url Required String The target URL.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to HTTP.
content String Notification content.
title String Notification title.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "HTTP Action",
  "type": "HTTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "custom": true,
  "content": "Pipeline executed successfully!",
  "title": "Pipeline executed successfully!",
  "notification_url": "http://app.dev.io"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "HTTP Action",
  "type": "HTTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "notification_url": "http://app.dev.io",
  "custom": true,
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Ping monitoring action

POST Parameters
Name Description
destination Required String The target URL.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to PING.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Ping Action",
  "type": "PING",
  "trigger_time": "ON_EVERY_EXECUTION",
  "destination": "app.buddy.works"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Ping Action",
  "type": "PING",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "destination": "app.buddy.works",
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Git Push action

POST Parameters
Name Description
name Required String The name of action.
push_url Required String The url to the repository.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to PUSH.
login String The username required to connect the server.
password String The password required to connect the server.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Push to Your Repo",
  "type": "PUSH",
  "trigger_time": "ON_EVERY_EXECUTION",
  "push_url": "https://app.buddy.works/acme/repo",
  "login": "api_tests_user",
  "password": "api_tests_password"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/851",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/851/edit",
  "id": 851,
  "name": "Push to Your Repo",
  "type": "PUSH",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "login": "root",
  "push_url": "https://app.app.buddy.works/acme/repo",
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Run Next Pipeline action

POST Parameters
Name Description
name Required String The name of action.
next_pipeline Required Pipeline Next pipeline that will be executed.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to RUN_NEXT_PIPELINE.
comment String Next pipeline execution comment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Next Pipeline Action",
  "type": "RUN_NEXT_PIPELINE",
  "trigger_time": "ON_EVERY_EXECUTION",
  "comment": "vkyupthjuj",
  "next_pipeline": {
    "id": 3
  }
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Next Pipeline Action",
  "type": "RUN_NEXT_PIPELINE",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "comment": "vkyupthjuj",
  "next_pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/310",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/310",
    "id": 3,
    "name": "test",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "INITIAL",
    "last_execution_revision": null
  },
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  },
  "revision": "236afa836c2b5902077859c558efbd11351dcaac"
}

Add Amazon S3 action

POST Parameters
Name Description
bucket_name Required String The name of the Amazon S3 Bucket.
integration Required Integration The integration.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to AMAZON_S3.
input_type String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
local_path String The path in the repository.
public_access Boolean Makes files accessible through public HTTP.
remote_path String The absolute or relative path on the remote server.
run_only_on_first_failure Boolean Defines whether the action should be executed on each failure. Restricted to and required if the trigger_time is ON_FAILURE.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to Amazon S3",
  "type": "AMAZON_S3",
  "input_type": "SCM_REPOSITORY",
  "trigger_time": "ON_EVERY_EXECUTION",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "bucket_name": "buddy-tests",
  "public_access": false,
  "run_only_on_first_failure": false,
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "integration": {
    "id": 1
  }
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/2/action/2/edit",
  "id": 2,
  "name": "Upload files to Amazon S3",
  "type": "AMAZON_S3",
  "trigger_time": "ON_EVERY_EXECUTION",
  "run_only_on_first_failure": false,
  "last_execution_status": "INITIAL",
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "bucket_name": "buddy-tests",
  "public_access": false,
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "integration": {
    "url": "https://api.dev.io/workspaces/acme/user/integrations/1",
    "html_url": "https://app.dev.io/my-id",
    "id": 1
  },
  "pipeline": {
    "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/2",
    "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "test server",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add SFTP (Password) action

POST Parameters
Name Description
authentication_mode Required String The authentication mode for SSH. Should be set to PASS.
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
port Required String The port for the connection.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SFTP.
input_type String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
local_path String The path in the repository.
password String The password required to connect the server.
remote_path String The absolute or relative path on the remote server.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to localhost",
  "type": "SFTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "authentication_mode": "PASS",
  "host": "localhost",
  "port": "22",
  "login": "api_tests_user",
  "password": "api_tests_password",
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ]
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Upload files to localhost",
  "type": "SFTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "login": "root",
  "host": "localhost",
  "port": "22",
  "authentication_mode": "PASS",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add SFTP (Private key) action

POST Parameters
Name Description
authentication_mode Required String The authentication mode for SSH. Should be set to PRIVATE_KEY.
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
port Required String The port for the connection.
server_key Required String The private SSH key.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SFTP.
input_type String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
local_path String The path in the repository.
passphrase String The passphrase for the private SSH key.
remote_path String The absolute or relative path on the remote server.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to localhost",
  "type": "SFTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "authentication_mode": "PRIVATE_KEY",
  "host": "localhost",
  "port": "22",
  "login": "api_tests_user",
  "passphrase": "password",
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "server_key": "-----BEGIN RSA PRIVATE KEY-----\r\nProc-Type: 4,ENCRYPTED\r\nDEK-Info: DES-EDE3-CBC,688DBB59CFC83D58\r\n\r\n1m3qZGEqXEfLPIm9KZacr17/iMVOIJcvSLoMJueM8+QbcK4JStzbre2AN99TkCN/\r\nr1V12deiq/lJUPX07K30tnsTS+7z4Pq/D2WhirD+WQcREgdQU1A8dlx2NMRDi7d0\r\n32w8ZPlciz3bc5rpF0vy5Ll2q9TWye4fpgQwPUnEkam0SaRRwAMpnT/46/AeWgmn\r\n9nu8CNZp7QcOIR2WH6RNRhQTOD/hC+kVCxbEQUL5MOHV7iZX6BeUwd8bBNmci+o0\r\nz/I7ZLQo596Ih+0KPgA+vwS9c4c1TrUYhupU7tyIL6PwpAzhlq/UwxeE032AypiI\r\nkpm7z8I7MBYZs0bsS5UOa3FdHF8p38KrxozwQfsOmBxEHpAWM3slvqJpauuJLlyx\r\ncFfzgOTFSsLJ5J59ZdVRpeFr/W5+/9wpc+AJUP80i4pMEWsnamwdK9rU6QwpFiPf\r\nARzk6VdIiDlZRWeyoYcEfOGEJt+J0aSlXkt6BHgvkmDGq0YA9CNqb6GdB9t073yX\r\nCAqsQ/XEvDuZw14KHxErr5aL6uuZiioDhUmoGz9S3HstFR4T0nRmfCSrLyxTFQf1\r\nF0Sn9Dv4LrSGrzM/0svdlqUc5TDxPBVoW2Q56dNkAQwJg0k25x5YLdTUcd4GjbJW\r\n0qLJaO+bxfTDk5rCMHflYNCW18fEdeEvpBwL0ey93+Qya4xqjTOy2fgoz9U0QLUD\r\nfbgWSiFWnurC8I/SYcQUAEOKiYCDRzud92WzyjwRr2yPlcqf/Qi8+VNDyvoGYZgi\r\nD3vgqA9KPKnYkODYKIFTMW0bbRkgnLOsc1v5mkPTerUpeOGWPysOu3WV9if9e2lG\r\npG1gVfRJQei0k5Mex6CCV0gSQbf2MjswiyDvrPQ1yhpCsFeDAGKcLx+GU1/AhLRP\r\np32mqF5XJrMSTvifCGNOHkBMVUXmTjF7KCYZvcsERi1i2xNcwtcsLRm+QJKQsYQf\r\nhJ17/lOOcC8cqVLGmik3adOcOMCWq2b+NjgoJT55Hc0N07ikuQqazhFpZKkMFZEr\r\nFqbDZ2zGMwODjcDancXaghSS7ciIEdoAPGor1rftJ+l2oQVzBPk4pNfBKHJC7UmS\r\nUOGW3rGLSlRQcVEBFHbrsGP/JKXd06Cbrc3kDrdXbO430qRZh9LQQKbjvxHonU8Z\r\nXFeRpwG32YLSCSQunJtoEWQRJpVefc7rEmBAdLfNyA7xyqH2JLtlflaH9QApl7vE\r\nGNJJ5iuHCHPJwfhlaSMBF/Cb9Ofp4BM5fnNKrwaI9twv//U6XhVfYRcaKhCFEoMb\r\nYo4k7cKTQzL95xT1aYnwqSqtaDfoXASoA9j/mD0aMU+9zQEa0tVbJ/6Zjn3vMSTx\r\npvCYkXy9kZzEJZ2r7BiaQX0HX5Ki/Opt4eTWL5NbokDsE1bQu+D2BskJz30pRRRK\r\nvRargCRNl26158HNRLPkbo/gkwfJbfIBFgJ8YEQkcNap110oEaW6l3lnktZ0Ct3P\r\nEjkrppoV6UU1HCVmcoljOldTXQZuKmpz7aIuSwmUqoU4vWNvYteIZ3BhaVwCu/p8\r\nVaFL8Sapda0WYXPWXHuV+Dj295bedJxeqraWrQB87vKP4NVyzWv1WA==\r\n-----END RSA PRIVATE KEY-----\r\n"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Upload files to localhost",
  "type": "SFTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "login": "root",
  "host": "localhost",
  "port": "22",
  "authentication_mode": "PRIVATE_KEY",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add SFTP (Private key & password) action

POST Parameters
Name Description
authentication_mode Required String The authentication mode for SSH. Should be set to PRIVATE_KEY_AND_PASS.
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
password Required String The password required to connect the server.
port Required String The port for the connection.
server_key Required String The private SSH key.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SFTP.
input_type String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
local_path String The path in the repository.
passphrase String The passphrase for the private SSH key.
remote_path String The absolute or relative path on the remote server.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to localhost",
  "type": "SFTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "authentication_mode": "PRIVATE_KEY_AND_PASS",
  "host": "localhost",
  "port": "22",
  "login": "api_tests_user",
  "password": "password",
  "passphrase": "password",
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "server_key": "-----BEGIN RSA PRIVATE KEY-----\r\nProc-Type: 4,ENCRYPTED\r\nDEK-Info: DES-EDE3-CBC,688DBB59CFC83D58\r\n\r\n1m3qZGEqXEfLPIm9KZacr17/iMVOIJcvSLoMJueM8+QbcK4JStzbre2AN99TkCN/\r\nr1V12deiq/lJUPX07K30tnsTS+7z4Pq/D2WhirD+WQcREgdQU1A8dlx2NMRDi7d0\r\n32w8ZPlciz3bc5rpF0vy5Ll2q9TWye4fpgQwPUnEkam0SaRRwAMpnT/46/AeWgmn\r\n9nu8CNZp7QcOIR2WH6RNRhQTOD/hC+kVCxbEQUL5MOHV7iZX6BeUwd8bBNmci+o0\r\nz/I7ZLQo596Ih+0KPgA+vwS9c4c1TrUYhupU7tyIL6PwpAzhlq/UwxeE032AypiI\r\nkpm7z8I7MBYZs0bsS5UOa3FdHF8p38KrxozwQfsOmBxEHpAWM3slvqJpauuJLlyx\r\ncFfzgOTFSsLJ5J59ZdVRpeFr/W5+/9wpc+AJUP80i4pMEWsnamwdK9rU6QwpFiPf\r\nARzk6VdIiDlZRWeyoYcEfOGEJt+J0aSlXkt6BHgvkmDGq0YA9CNqb6GdB9t073yX\r\nCAqsQ/XEvDuZw14KHxErr5aL6uuZiioDhUmoGz9S3HstFR4T0nRmfCSrLyxTFQf1\r\nF0Sn9Dv4LrSGrzM/0svdlqUc5TDxPBVoW2Q56dNkAQwJg0k25x5YLdTUcd4GjbJW\r\n0qLJaO+bxfTDk5rCMHflYNCW18fEdeEvpBwL0ey93+Qya4xqjTOy2fgoz9U0QLUD\r\nfbgWSiFWnurC8I/SYcQUAEOKiYCDRzud92WzyjwRr2yPlcqf/Qi8+VNDyvoGYZgi\r\nD3vgqA9KPKnYkODYKIFTMW0bbRkgnLOsc1v5mkPTerUpeOGWPysOu3WV9if9e2lG\r\npG1gVfRJQei0k5Mex6CCV0gSQbf2MjswiyDvrPQ1yhpCsFeDAGKcLx+GU1/AhLRP\r\np32mqF5XJrMSTvifCGNOHkBMVUXmTjF7KCYZvcsERi1i2xNcwtcsLRm+QJKQsYQf\r\nhJ17/lOOcC8cqVLGmik3adOcOMCWq2b+NjgoJT55Hc0N07ikuQqazhFpZKkMFZEr\r\nFqbDZ2zGMwODjcDancXaghSS7ciIEdoAPGor1rftJ+l2oQVzBPk4pNfBKHJC7UmS\r\nUOGW3rGLSlRQcVEBFHbrsGP/JKXd06Cbrc3kDrdXbO430qRZh9LQQKbjvxHonU8Z\r\nXFeRpwG32YLSCSQunJtoEWQRJpVefc7rEmBAdLfNyA7xyqH2JLtlflaH9QApl7vE\r\nGNJJ5iuHCHPJwfhlaSMBF/Cb9Ofp4BM5fnNKrwaI9twv//U6XhVfYRcaKhCFEoMb\r\nYo4k7cKTQzL95xT1aYnwqSqtaDfoXASoA9j/mD0aMU+9zQEa0tVbJ/6Zjn3vMSTx\r\npvCYkXy9kZzEJZ2r7BiaQX0HX5Ki/Opt4eTWL5NbokDsE1bQu+D2BskJz30pRRRK\r\nvRargCRNl26158HNRLPkbo/gkwfJbfIBFgJ8YEQkcNap110oEaW6l3lnktZ0Ct3P\r\nEjkrppoV6UU1HCVmcoljOldTXQZuKmpz7aIuSwmUqoU4vWNvYteIZ3BhaVwCu/p8\r\nVaFL8Sapda0WYXPWXHuV+Dj295bedJxeqraWrQB87vKP4NVyzWv1WA==\r\n-----END RSA PRIVATE KEY-----\r\n"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/855",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/855/edit",
  "id": 855,
  "name": "Upload files to localhost",
  "type": "SFTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "login": "root",
  "host": "localhost",
  "port": "22",
  "authentication_mode": "PRIVATE_KEY_AND_PASS",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Slack notification action

POST Parameters
Name Description
channel Required String Slack channel id. More informations there.
custom Required Boolean Defines whether the content will be custom.
integration Required Integration The integration.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SLACK.
content String Notification content.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/1/actions
{
  "name": "SLACK Action",
  "type": "SLACK",
  "trigger_time": "ON_EVERY_EXECUTION",
  "custom": true,
  "content": "Pipeline Execution successful!",
  "channel": "C024BE91L",
  "integration": {
    "id": 1
  }
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/1/actions/1",
  "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/1/action/1/edit",
  "id": 1,
  "name": "SLACK Action",
  "type": "SLACK",
  "trigger_time": "ON_EVERY_EXECUTION",
  "run_only_on_first_failure": false,
  "last_execution_status": "INITIAL",
  "content": "Pipeline Execution successful!",
  "custom": true,
  "channel": "C024BE91L",
  "integration": {
    "url": "https://api.dev.io/workspaces/acme/user/integrations/1",
    "html_url": "https://app.dev.io/integrations",
    "id": 1
  },
  "pipeline": {
    "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/1",
    "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/1",
    "id": 1,
    "name": "test server",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Sms notification action

POST Parameters
Name Description
custom Required Boolean Defines whether the content will be custom.
name Required String The name of action.
recipients Required String Notification recipients - phone numbers(one per line).
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SMS.
content String Notification content.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "SMS Action",
  "type": "SMS",
  "custom": true,
  "content": "Pipeline executed successfully!",
  "recipients": "11234567890\n12345678901"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/2/actions/21",
  "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/2/action/2/edit",
  "id": 2,
  "name": "SMS Action",
  "type": "SMS",
  "trigger_time": "ON_EVERY_EXECUTION",
  "run_only_on_first_failure": false,
  "status": "INITIAL",
  "custom": true,
  "recipients": "11234567890\n12345678901",
  "content": "Pipeline executed successfully!",
  "pipeline": {
    "url": "https://api.dev.io/workspaces/acme/projects/company-website/pipelines/1",
    "html_url": "https://app.dev.io/acme/company-website/pipelines/pipeline/1",
    "id": 1,
    "name": "test server",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add SSH command action (Password)

POST Parameters
Name Description
authentication_mode Required String The authentication mode for SSH. Should be set to PASS.
commands Required String[] The array of commands invoked on the remote server.
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
password Required String The password required to connect the server.
port Required String The port for the connection.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SSH_COMMAND.
working_directory String The absolute or relative path on the remote server.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Execute commands on localhost",
  "type": "SSH_COMMAND",
  "trigger_time": "ON_EVERY_EXECUTION",
  "authentication_mode": "PASS",
  "host": "localhost",
  "port": "22",
  "login": "api_tests_user",
  "password": "api_tests_password",
  "working_directory": "/",
  "commands": [
    "npm prune",
    "npm install --silent"
  ]
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Execute commands on localhost",
  "type": "SSH_COMMAND",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "working_directory": "/",
  "login": "root",
  "host": "localhost",
  "port": "22",
  "authentication_mode": "PASS",
  "commands": [
    "npm prune",
    "npm install --silent"
  ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add SSH command action (Private key)

POST Parameters
Name Description
authentication_mode Required String The authentication mode for SSH. Should be set to PRIVATE_KEY.
commands Required String[] The array of commands invoked on the remote server.
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
port Required String The port for the connection.
server_key Required String The private SSH key.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SSH_COMMAND.
passphrase String The passphrase for the private SSH key.
working_directory String The absolute or relative path on the remote server.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Execute commands on localhost",
  "type": "SSH_COMMAND",
  "trigger_time": "ON_EVERY_EXECUTION",
  "authentication_mode": "PRIVATE_KEY",
  "host": "localhost",
  "port": "22",
  "login": "api_tests_user",
  "passphrase": "api_tests_password",
  "working_directory": "/",
  "commands": [
    "npm prune",
    "npm install --silent"
  ],
  "server_key": "-----BEGIN RSA PRIVATE KEY-----\r\nProc-Type: 4,ENCRYPTED\r\nDEK-Info: DES-EDE3-CBC,688DBB59CFC83D58\r\n\r\n1m3qZGEqXEfLPIm9KZacr17/iMVOIJcvSLoMJueM8+QbcK4JStzbre2AN99TkCN/\r\nr1V12deiq/lJUPX07K30tnsTS+7z4Pq/D2WhirD+WQcREgdQU1A8dlx2NMRDi7d0\r\n32w8ZPlciz3bc5rpF0vy5Ll2q9TWye4fpgQwPUnEkam0SaRRwAMpnT/46/AeWgmn\r\n9nu8CNZp7QcOIR2WH6RNRhQTOD/hC+kVCxbEQUL5MOHV7iZX6BeUwd8bBNmci+o0\r\nz/I7ZLQo596Ih+0KPgA+vwS9c4c1TrUYhupU7tyIL6PwpAzhlq/UwxeE032AypiI\r\nkpm7z8I7MBYZs0bsS5UOa3FdHF8p38KrxozwQfsOmBxEHpAWM3slvqJpauuJLlyx\r\ncFfzgOTFSsLJ5J59ZdVRpeFr/W5+/9wpc+AJUP80i4pMEWsnamwdK9rU6QwpFiPf\r\nARzk6VdIiDlZRWeyoYcEfOGEJt+J0aSlXkt6BHgvkmDGq0YA9CNqb6GdB9t073yX\r\nCAqsQ/XEvDuZw14KHxErr5aL6uuZiioDhUmoGz9S3HstFR4T0nRmfCSrLyxTFQf1\r\nF0Sn9Dv4LrSGrzM/0svdlqUc5TDxPBVoW2Q56dNkAQwJg0k25x5YLdTUcd4GjbJW\r\n0qLJaO+bxfTDk5rCMHflYNCW18fEdeEvpBwL0ey93+Qya4xqjTOy2fgoz9U0QLUD\r\nfbgWSiFWnurC8I/SYcQUAEOKiYCDRzud92WzyjwRr2yPlcqf/Qi8+VNDyvoGYZgi\r\nD3vgqA9KPKnYkODYKIFTMW0bbRkgnLOsc1v5mkPTerUpeOGWPysOu3WV9if9e2lG\r\npG1gVfRJQei0k5Mex6CCV0gSQbf2MjswiyDvrPQ1yhpCsFeDAGKcLx+GU1/AhLRP\r\np32mqF5XJrMSTvifCGNOHkBMVUXmTjF7KCYZvcsERi1i2xNcwtcsLRm+QJKQsYQf\r\nhJ17/lOOcC8cqVLGmik3adOcOMCWq2b+NjgoJT55Hc0N07ikuQqazhFpZKkMFZEr\r\nFqbDZ2zGMwODjcDancXaghSS7ciIEdoAPGor1rftJ+l2oQVzBPk4pNfBKHJC7UmS\r\nUOGW3rGLSlRQcVEBFHbrsGP/JKXd06Cbrc3kDrdXbO430qRZh9LQQKbjvxHonU8Z\r\nXFeRpwG32YLSCSQunJtoEWQRJpVefc7rEmBAdLfNyA7xyqH2JLtlflaH9QApl7vE\r\nGNJJ5iuHCHPJwfhlaSMBF/Cb9Ofp4BM5fnNKrwaI9twv//U6XhVfYRcaKhCFEoMb\r\nYo4k7cKTQzL95xT1aYnwqSqtaDfoXASoA9j/mD0aMU+9zQEa0tVbJ/6Zjn3vMSTx\r\npvCYkXy9kZzEJZ2r7BiaQX0HX5Ki/Opt4eTWL5NbokDsE1bQu+D2BskJz30pRRRK\r\nvRargCRNl26158HNRLPkbo/gkwfJbfIBFgJ8YEQkcNap110oEaW6l3lnktZ0Ct3P\r\nEjkrppoV6UU1HCVmcoljOldTXQZuKmpz7aIuSwmUqoU4vWNvYteIZ3BhaVwCu/p8\r\nVaFL8Sapda0WYXPWXHuV+Dj295bedJxeqraWrQB87vKP4NVyzWv1WA==\r\n-----END RSA PRIVATE KEY-----\r\n"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/2/edit",
  "id": 2,
  "name": "Execute commands on localhost",
  "type": "SSH_COMMAND",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "working_directory": "/",
  "login": "root",
  "host": "localhost",
  "port": "22",
  "authentication_mode": "PRIVATE_KEY",
  "commands": [
    "npm prune",
    "npm install --silent"
  ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add SSH command action (Private key & password)

POST Parameters
Name Description
authentication_mode Required String The authentication mode for SSH. Should be set to PRIVATE_KEY_AND_PASS.
commands Required String[] The array of commands invoked on the remote server.
host Required String The host for the connection.
login Required String The username required to connect the server.
name Required String The name of action.
password Required String The password required to connect the server.
port Required String The port for the connection.
server_key Required String The private SSH key.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to SSH_COMMAND.
passphrase String The passphrase for the private SSH key.
working_directory String The absolute or relative path on the remote server.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Execute commands on localhost",
  "type": "SSH_COMMAND",
  "trigger_time": "ON_EVERY_EXECUTION",
  "authentication_mode": "PRIVATE_KEY_AND_PASS",
  "host": "localhost",
  "port": "22",
  "login": "api_tests_user",
  "passphrase": "api_tests_password",
  "password": "testtest",
  "working_directory": "/",
  "commands": [
    "npm prune",
    "npm install --silent"
  ],
  "server_key": "-----BEGIN RSA PRIVATE KEY-----\r\nProc-Type: 4,ENCRYPTED\r\nDEK-Info: DES-EDE3-CBC,688DBB59CFC83D58\r\n\r\n1m3qZGEqXEfLPIm9KZacr17/iMVOIJcvSLoMJueM8+QbcK4JStzbre2AN99TkCN/\r\nr1V12deiq/lJUPX07K30tnsTS+7z4Pq/D2WhirD+WQcREgdQU1A8dlx2NMRDi7d0\r\n32w8ZPlciz3bc5rpF0vy5Ll2q9TWye4fpgQwPUnEkam0SaRRwAMpnT/46/AeWgmn\r\n9nu8CNZp7QcOIR2WH6RNRhQTOD/hC+kVCxbEQUL5MOHV7iZX6BeUwd8bBNmci+o0\r\nz/I7ZLQo596Ih+0KPgA+vwS9c4c1TrUYhupU7tyIL6PwpAzhlq/UwxeE032AypiI\r\nkpm7z8I7MBYZs0bsS5UOa3FdHF8p38KrxozwQfsOmBxEHpAWM3slvqJpauuJLlyx\r\ncFfzgOTFSsLJ5J59ZdVRpeFr/W5+/9wpc+AJUP80i4pMEWsnamwdK9rU6QwpFiPf\r\nARzk6VdIiDlZRWeyoYcEfOGEJt+J0aSlXkt6BHgvkmDGq0YA9CNqb6GdB9t073yX\r\nCAqsQ/XEvDuZw14KHxErr5aL6uuZiioDhUmoGz9S3HstFR4T0nRmfCSrLyxTFQf1\r\nF0Sn9Dv4LrSGrzM/0svdlqUc5TDxPBVoW2Q56dNkAQwJg0k25x5YLdTUcd4GjbJW\r\n0qLJaO+bxfTDk5rCMHflYNCW18fEdeEvpBwL0ey93+Qya4xqjTOy2fgoz9U0QLUD\r\nfbgWSiFWnurC8I/SYcQUAEOKiYCDRzud92WzyjwRr2yPlcqf/Qi8+VNDyvoGYZgi\r\nD3vgqA9KPKnYkODYKIFTMW0bbRkgnLOsc1v5mkPTerUpeOGWPysOu3WV9if9e2lG\r\npG1gVfRJQei0k5Mex6CCV0gSQbf2MjswiyDvrPQ1yhpCsFeDAGKcLx+GU1/AhLRP\r\np32mqF5XJrMSTvifCGNOHkBMVUXmTjF7KCYZvcsERi1i2xNcwtcsLRm+QJKQsYQf\r\nhJ17/lOOcC8cqVLGmik3adOcOMCWq2b+NjgoJT55Hc0N07ikuQqazhFpZKkMFZEr\r\nFqbDZ2zGMwODjcDancXaghSS7ciIEdoAPGor1rftJ+l2oQVzBPk4pNfBKHJC7UmS\r\nUOGW3rGLSlRQcVEBFHbrsGP/JKXd06Cbrc3kDrdXbO430qRZh9LQQKbjvxHonU8Z\r\nXFeRpwG32YLSCSQunJtoEWQRJpVefc7rEmBAdLfNyA7xyqH2JLtlflaH9QApl7vE\r\nGNJJ5iuHCHPJwfhlaSMBF/Cb9Ofp4BM5fnNKrwaI9twv//U6XhVfYRcaKhCFEoMb\r\nYo4k7cKTQzL95xT1aYnwqSqtaDfoXASoA9j/mD0aMU+9zQEa0tVbJ/6Zjn3vMSTx\r\npvCYkXy9kZzEJZ2r7BiaQX0HX5Ki/Opt4eTWL5NbokDsE1bQu+D2BskJz30pRRRK\r\nvRargCRNl26158HNRLPkbo/gkwfJbfIBFgJ8YEQkcNap110oEaW6l3lnktZ0Ct3P\r\nEjkrppoV6UU1HCVmcoljOldTXQZuKmpz7aIuSwmUqoU4vWNvYteIZ3BhaVwCu/p8\r\nVaFL8Sapda0WYXPWXHuV+Dj295bedJxeqraWrQB87vKP4NVyzWv1WA==\r\n-----END RSA PRIVATE KEY-----\r\n"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/858",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/858/edit",
  "id": 858,
  "name": "Execute commands on localhost",
  "type": "SSH_COMMAND",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "working_directory": "/",
  "login": "root",
  "host": "localhost",
  "port": "22",
  "authentication_mode": "PRIVATE_KEY_AND_PASS",
  "commands": [
    "npm prune",
    "npm install --silent"
  ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add TCP monitoring action

POST Parameters
Name Description
destination Required String The target URL.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to TCP.
port String The port for the connection.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Check app.buddy.works status",
  "type": "TCP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "port": "8080",
  "destination": "app.buddy.works"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/859",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/859/edit",
  "id": 859,
  "name": "Check app.buddy.works status",
  "type": "TCP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "port": "8080",
  "destination": "app.buddy.works",
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Web monitoring action

POST Parameters
Name Description
destination Required String The target URL.
name Required String The name of action.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to WEB.
headers Header[] Headers that will be send with the request.
login String The username required to connect the server.
password String The password required to connect the server.
port String The port for the connection.
post_data String Data that will be send.
text String Text that should, or should not be present in the response.
text_existance Boolean Defines whether the response should or should not contain given text. If set, the text argument is required.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Check http://buddy.works/ status",
  "type": "WEB",
  "trigger_time": "ON_EVERY_EXECUTION",
  "login": "owner@buddy.works",
  "password": "supersecretpassword",
  "port": "8080",
  "destination": "http://buddy.works/",
  "post_data": "{\r\n\"test\": \"ok\"\r\n}",
  "headers": [
    {
      "name": "User-Agent",
      "value": "Buddy"
    },
    {
      "name": "myHeader",
      "value": "myHeaderValue"
    }
  ],
  "text_existance": true,
  "text": "ok"
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/860",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/860/edit",
  "id": 860,
  "name": "Check http://buddy.works/ status",
  "type": "WEB",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "login": "owner@buddy.works",
  "port": "8080",
  "headers": [
    {
      "name": "User-Agent",
      "value": "Buddy"
    },
    {
      "name": "myHeader",
      "value": "myHeaderValue"
    }
  ],
  "post_data": "{\r\n\"test\": \"ok\"\r\n}",
  "destination": "http://buddy.works/",
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Add Webdav action

POST Parameters
Name Description
login Required String The username required to connect the server.
name Required String The name of action.
password Required String The password required to connect the server.
trigger_time Required String Specifies when action should be executed. Can be one of ON_EVERY_EXECUTION, ON_SUCCESS, ON_FAILURE or ON_BACK_TO_SUCCESS.
type Required String The type of the action. Should be set to WEB_DAV.
web_dav_url Required String URL to your Webdav server.
input_type String Defines whether files are deployed from repository or from build file system. Can be one of SCM_REPOSITORY or BUILD_ARTIFACTS.
local_path String The path in the repository.
remote_path String The absolute or relative path on the remote server.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
POST
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions
{
  "name": "Upload files to localhost",
  "type": "WEB_DAV",
  "trigger_time": "ON_EVERY_EXECUTION",
  "web_dav_url": "https://mysite.com/webdav/",
  "login": "webdav",
  "password": "webdav123",
  "input_type": "SCM_REPOSITORY",
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ]
}
Sample Response
Status: 201 Created
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/861",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/861/edit",
  "id": 861,
  "name": "Upload files to localhost",
  "type": "WEB_DAV",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "INITIAL",
  "run_only_on_first_failure": false,
  "local_path": "/assets/",
  "remote_path": "Home/www/",
  "login": "webdav",
  "web_dav_url": "https://mysite.com/webdav/",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Gets a single action

Returns a single action.
Required scopes: WORKSPACE, EXECUTION_INFO

Resource URL
GET
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id/actions/:action_id
URL Parameters
Name Description
action_id Required Integer The numerical ID of the desired action.
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.
Example
Request
GET
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/5
Sample Response
Status: 200 OK
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/5",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/5/edit",
  "id": 5,
  "name": "Upload files to dev",
  "type": "FTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "SUCCESSFUL",
  "run_only_on_first_failure": false,
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

status can be either SUCCESSFUL, FAILED, INPROGRESS, ENQUEUED, SKIPPED, TERMINATED, or INITIAL

Edit action

Updates an action in the pipeline. It's not possible to change the type of an action. If you want to change the type, remove the action and add it again. Model of each action type is the same as presented in Add Action examples
Required scopes: WORKSPACE, EXECUTION_MANAGE

Resource URL
PATCH
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id/actions/:action_id
URL Parameters
Name Description
action_id Required Integer The numerical ID of the desired action.
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.
POST Parameters
Name Description
access_key String The Access Key for Amazon S3. Restricted to and required for AMAZON_S3.
active_mode Boolean Enables the active mode for the connection. Restricted to FTP and FTPS.
authentication_mode String The authentication mode for SSH. Possible values: PASS, PRIVATE_KEY, PRIVATE_KEY_AND_PASS. Restricted to SFTP or SSH_COMMAND.
bucket_name String The name of the Amazon S3 Bucket. Restricted to and required for AMAZON_S3.
cloudfront_id String The ID of the Amazon Cloud Front. Restricted to AMAZON_S3.
commands String[] The array of commands invoked on the remote server. Only for SSH_COMMAND.
host String The host for the connection. Restricted to FTP, FTPS, SFTP or SSH_COMMAND.
local_path String The path in the repository. Restricted to FTP, FTPS, SFTP and AMAZON_S3.
login String The username required to connect the server. Restricted to FTP, FTPS, SFTP or SSH_COMMAND.
passphrase String The passphrase for the private SSH key. Restricted to SFTP and SSH_COMMAND. Required if authentication_mode is PRIVATE_KEY_AND_PASS.
password String The password required to connect the server. Restricted to FTP, FTPS, SFTP or SSH_COMMAND.
public_access Boolean Makes the files accessible through public HTTP. Restricted to AMAZON_S3.
reduced_redundancy Boolean The user's reduced redundancy. Restricted to AMAZON_S3.
remote_path String The absolute or relative path on the remote server. Restricted to FTP, FTPS and SFTP.
secret_key String The Secret Key for Amazon S3. Restricted to and required for AMAZON_S3.
server_key String The private SSH key. Restricted to SFTP and SSH_COMMAND. Required if the authentication_mode is PRIVATE_KEY, PRIVATE_KEY_AND_PASS.
working_directory String The absolute or relative path on the remote server. Restricted to SSH_COMMAND.
deployment_excludes String[] The paths and/or files that will be left our during the deployment.
Example
Request
PATCH
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/5
{
  "name": "Upload files to Live mirror",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ]
}
Sample Response
Status: 200 OK
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999
{
  "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/5",
  "html_url": "https://app.buddy.works/buddy/company-website/pipelines/action/5/edit",
  "id": 5,
  "name": "Upload files to Live mirror",
  "type": "FTP",
  "trigger_time": "ON_EVERY_EXECUTION",
  "last_execution_status": "SUCCESSFUL",
  "run_only_on_first_failure": false,
  "input_type": "SCM_REPOSITORY",
  "local_path": "/",
  "remote_path": "",
  "login": "pass",
  "active_mode": false,
  "host": "localhost",
  "port": "21",
  "deployment_excludes": [
    "/assets/",
    "file.txt"
    ],
  "pipeline": {
    "url": "https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2",
    "html_url": "https://app.buddy.works/buddy/company-website/pipelines/pipeline/2",
    "id": 2,
    "name": "Live mirror",
    "trigger_mode": "MANUAL",
    "ref_name": "master",
    "last_execution_status": "SUCCESSFUL",
    "last_execution_revision": "506a3963507943d6908154f4bc9646e829128a08"
  }
}

Delete action

Removes the action from the pipeline.
Required scopes: WORKSPACE, EXECUTION_MANAGE

Resource URL
DELETE
/workspaces/:domain/projects/:project_name/pipelines/:pipeline_id/actions/:action_id
URL Parameters
Name Description
action_id Required Integer The numerical ID of the desired action.
domain Required String The workspace domain.
pipeline_id Required Integer The numerical ID of the desired pipeline.
project_name Required String The name ID of the project.
Example
Request
DELETE
https://api.buddy.works/workspaces/buddy/projects/company-website/pipelines/2/actions/2
Sample Response
Status: 204 NoContent
X-Rate-Limit-Limit: 1
X-Rate-Limit-Remaining: 999