From 194223476b8df57a56ba096c7a300d51d2e3e750 Mon Sep 17 00:00:00 2001 From: "Z.J. van de Weg" Date: Mon, 6 Mar 2017 10:24:03 +0100 Subject: [PATCH] Rename build to job in the docs --- doc/api/groups.md | 20 +++--- doc/api/{builds.md => jobs.md} | 112 ++++++++++++++++----------------- doc/api/pipelines.md | 4 +- doc/api/projects.md | 52 +++++++-------- doc/api/services.md | 28 ++++----- lib/api/services.rb | 10 +-- 6 files changed, 113 insertions(+), 113 deletions(-) rename doc/api/{builds.md => jobs.md} (82%) diff --git a/doc/api/groups.md b/doc/api/groups.md index 80c08096dea..dfc6b80bfd9 100644 --- a/doc/api/groups.md +++ b/doc/api/groups.md @@ -84,7 +84,7 @@ Example response: "issues_enabled": true, "merge_requests_enabled": true, "wiki_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "snippets_enabled": true, "created_at": "2016-04-05T21:40:50.169Z", "last_activity_at": "2016-04-06T16:52:08.432Z", @@ -100,7 +100,7 @@ Example response: "star_count": 1, "forks_count": 0, "open_issues_count": 3, - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "request_access_enabled": false } @@ -158,7 +158,7 @@ Example response: "issues_enabled": true, "merge_requests_enabled": true, "wiki_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "snippets_enabled": false, "container_registry_enabled": true, "created_at": "2016-06-17T07:47:25.578Z", @@ -175,7 +175,7 @@ Example response: "star_count": 0, "forks_count": 0, "open_issues_count": 3, - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "request_access_enabled": false }, @@ -196,7 +196,7 @@ Example response: "issues_enabled": true, "merge_requests_enabled": true, "wiki_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "snippets_enabled": false, "container_registry_enabled": true, "created_at": "2016-06-17T07:47:24.661Z", @@ -213,7 +213,7 @@ Example response: "star_count": 0, "forks_count": 0, "open_issues_count": 8, - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "request_access_enabled": false } @@ -236,7 +236,7 @@ Example response: "issues_enabled": true, "merge_requests_enabled": true, "wiki_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "snippets_enabled": false, "container_registry_enabled": true, "created_at": "2016-06-17T07:47:27.089Z", @@ -253,7 +253,7 @@ Example response: "star_count": 0, "forks_count": 0, "open_issues_count": 4, - "public_builds": true, + "public_jobs": true, "shared_with_groups": [ { "group_id": 4, @@ -359,7 +359,7 @@ Example response: "issues_enabled": true, "merge_requests_enabled": true, "wiki_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "snippets_enabled": true, "created_at": "2016-04-05T21:40:50.169Z", "last_activity_at": "2016-04-06T16:52:08.432Z", @@ -375,7 +375,7 @@ Example response: "star_count": 1, "forks_count": 0, "open_issues_count": 3, - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "request_access_enabled": false } diff --git a/doc/api/builds.md b/doc/api/jobs.md similarity index 82% rename from doc/api/builds.md rename to doc/api/jobs.md index 84214e4708f..43451ccce4c 100644 --- a/doc/api/builds.md +++ b/doc/api/jobs.md @@ -1,20 +1,20 @@ -# Builds API +# Jobs API -## List project builds +## List project jobs -Get a list of builds in a project. +Get a list of jobs in a project. ``` -GET /projects/:id/builds +GET /projects/:id/jobs ``` | Attribute | Type | Required | Description | |-----------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | -| `scope` | string **or** array of strings | no | The scope of builds to show, one or array of: `created`, `pending`, `running`, `failed`, `success`, `canceled`, `skipped`; showing all builds if none provided | +| `scope` | string **or** array of strings | no | The scope of jobs to show, one or array of: `created`, `pending`, `running`, `failed`, `success`, `canceled`, `skipped`; showing all jobs if none provided | ``` -curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" 'https://gitlab.example.com/api/v4/projects/1/builds?scope%5B0%5D=pending&scope%5B1%5D=running' +curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" 'https://gitlab.example.com/api/v4/projects/1/jobs?scope%5B0%5D=pending&scope%5B1%5D=running' ``` Example of response @@ -115,27 +115,27 @@ Example of response ] ``` -## List commit builds +## List commit jobs -Get a list of builds for specific commit in a project. +Get a list of jobs for specific commit in a project. -This endpoint will return all builds, from all pipelines for a given commit. +This endpoint will return all jobs, from all pipelines for a given commit. If the commit SHA is not found, it will respond with 404, otherwise it will -return an array of builds (an empty array if there are no builds for this +return an array of jobs (an empty array if there are no jobs for this particular commit). ``` -GET /projects/:id/repository/commits/:sha/builds +GET /projects/:id/repository/commits/:sha/jobs ``` | Attribute | Type | Required | Description | |-----------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | | `sha` | string | yes | The SHA id of a commit | -| `scope` | string **or** array of strings | no | The scope of builds to show, one or array of: `created`, `pending`, `running`, `failed`, `success`, `canceled`, `skipped`; showing all builds if none provided | +| `scope` | string **or** array of strings | no | The scope of jobs to show, one or array of: `created`, `pending`, `running`, `failed`, `success`, `canceled`, `skipped`; showing all jobs if none provided | ``` -curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" 'https://gitlab.example.com/api/v4/projects/1/repository/commits/0ff3ae198f8601a285adcf5c0fff204ee6fba5fd/builds?scope%5B0%5D=pending&scope%5B1%5D=running' +curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" 'https://gitlab.example.com/api/v4/projects/1/repository/commits/0ff3ae198f8601a285adcf5c0fff204ee6fba5fd/jobs?scope%5B0%5D=pending&scope%5B1%5D=running' ``` Example of response @@ -219,21 +219,21 @@ Example of response ] ``` -## Get a single build +## Get a single job -Get a single build of a project +Get a single job of a project ``` -GET /projects/:id/builds/:build_id +GET /projects/:id/jobs/:job_id ``` | Attribute | Type | Required | Description | |------------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | -| `build_id` | integer | yes | The ID of a build | +| `job_id` | integer | yes | The ID of a job | ``` -curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/8" +curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/8" ``` Example of response @@ -285,23 +285,23 @@ Example of response } ``` -## Get build artifacts +## Get job artifacts > [Introduced][ce-2893] in GitLab 8.5 -Get build artifacts of a project +Get job artifacts of a project ``` -GET /projects/:id/builds/:build_id/artifacts +GET /projects/:id/jobs/:job_id/artifacts ``` | Attribute | Type | Required | Description | |------------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | -| `build_id` | integer | yes | The ID of a build | +| `job_id` | integer | yes | The ID of a job | ``` -curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/8/artifacts" +curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/8/artifacts" ``` Response: @@ -318,10 +318,10 @@ Response: > [Introduced][ce-5347] in GitLab 8.10. Download the artifacts file from the given reference name and job provided the -build finished successfully. +job finished successfully. ``` -GET /projects/:id/builds/artifacts/:ref_name/download?job=name +GET /projects/:id/jobs/artifacts/:ref_name/download?job=name ``` Parameters @@ -335,7 +335,7 @@ Parameters Example request: ``` -curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/artifacts/master/download?job=test" +curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/artifacts/master/download?job=test" ``` Example response: @@ -349,19 +349,19 @@ Example response: ## Get a trace file -Get a trace of a specific build of a project +Get a trace of a specific job of a project ``` -GET /projects/:id/builds/:build_id/trace +GET /projects/:id/jobs/:job_id/trace ``` | Attribute | Type | Required | Description | |------------|---------|----------|---------------------| | id | integer | yes | The ID of a project | -| build_id | integer | yes | The ID of a build | +| job_id | integer | yes | The ID of a job | ``` -curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/8/trace" +curl --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/8/trace" ``` Response: @@ -371,21 +371,21 @@ Response: | 200 | Serves the trace file | | 404 | Build not found or no trace file | -## Cancel a build +## Cancel a job -Cancel a single build of a project +Cancel a single job of a project ``` -POST /projects/:id/builds/:build_id/cancel +POST /projects/:id/jobs/:job_id/cancel ``` | Attribute | Type | Required | Description | |------------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | -| `build_id` | integer | yes | The ID of a build | +| `job_id` | integer | yes | The ID of a job | ``` -curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/1/cancel" +curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/1/cancel" ``` Example of response @@ -417,21 +417,21 @@ Example of response } ``` -## Retry a build +## Retry a job -Retry a single build of a project +Retry a single job of a project ``` -POST /projects/:id/builds/:build_id/retry +POST /projects/:id/jobs/:job_id/retry ``` | Attribute | Type | Required | Description | |------------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | -| `build_id` | integer | yes | The ID of a build | +| `job_id` | integer | yes | The ID of a job | ``` -curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/1/retry" +curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/1/retry" ``` Example of response @@ -463,12 +463,12 @@ Example of response } ``` -## Erase a build +## Erase a job -Erase a single build of a project (remove build artifacts and a build trace) +Erase a single job of a project (remove job artifacts and a job trace) ``` -POST /projects/:id/builds/:build_id/erase +POST /projects/:id/jobs/:job_id/erase ``` Parameters @@ -476,12 +476,12 @@ Parameters | Attribute | Type | Required | Description | |-------------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | -| `build_id` | integer | yes | The ID of a build | +| `job_id` | integer | yes | The ID of a job | Example of request ``` -curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/1/erase" +curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/1/erase" ``` Example of response @@ -518,7 +518,7 @@ Example of response Prevents artifacts from being deleted when expiration is set. ``` -POST /projects/:id/builds/:build_id/artifacts/keep +POST /projects/:id/jobs/:job_id/artifacts/keep ``` Parameters @@ -526,12 +526,12 @@ Parameters | Attribute | Type | Required | Description | |-------------|---------|----------|---------------------| | `id` | integer | yes | The ID of a project | -| `build_id` | integer | yes | The ID of a build | +| `job_id` | integer | yes | The ID of a job | Example request: ``` -curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/1/artifacts/keep" +curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/1/artifacts/keep" ``` Example response: @@ -563,21 +563,21 @@ Example response: } ``` -## Play a build +## Play a job -Triggers a manual action to start a build. +Triggers a manual action to start a job. ``` -POST /projects/:id/builds/:build_id/play +POST /projects/:id/jobs/:job_id/play ``` -| Attribute | Type | Required | Description | -|------------|---------|----------|---------------------| -| `id` | integer | yes | The ID of a project | -| `build_id` | integer | yes | The ID of a build | +| Attribute | Type | Required | Description | +|-----------|---------|----------|---------------------| +| `id` | integer | yes | The ID of a project | +| `job_id` | integer | yes | The ID of a job | ``` -curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/builds/1/play" +curl --request POST --header "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v4/projects/1/jobs/1/play" ``` Example of response diff --git a/doc/api/pipelines.md b/doc/api/pipelines.md index d809ec032f8..574a8bacb25 100644 --- a/doc/api/pipelines.md +++ b/doc/api/pipelines.md @@ -127,7 +127,7 @@ Example of response } ``` -## Retry builds in a pipeline +## Retry jobs in a pipeline > [Introduced][ce-5837] in GitLab 8.11 @@ -173,7 +173,7 @@ Response: } ``` -## Cancel a pipelines builds +## Cancel a pipelines jobs > [Introduced][ce-5837] in GitLab 8.11 diff --git a/doc/api/projects.md b/doc/api/projects.md index 6062c5ccd71..28e4bfe39dc 100644 --- a/doc/api/projects.md +++ b/doc/api/projects.md @@ -66,7 +66,7 @@ Parameters: "issues_enabled": true, "open_issues_count": 1, "merge_requests_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "wiki_enabled": true, "snippets_enabled": false, "container_registry_enabled": false, @@ -86,7 +86,7 @@ Parameters: "forks_count": 0, "star_count": 0, "runners_token": "b8547b1dc37721d05889db52fa2f02", - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "only_allow_merge_if_pipeline_succeeds": false, "only_allow_merge_if_all_discussions_are_resolved": false, @@ -116,7 +116,7 @@ Parameters: "issues_enabled": true, "open_issues_count": 1, "merge_requests_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "wiki_enabled": true, "snippets_enabled": false, "container_registry_enabled": false, @@ -146,7 +146,7 @@ Parameters: "forks_count": 0, "star_count": 0, "runners_token": "b8547b1dc37721d05889db52fa2f02", - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "only_allow_merge_if_pipeline_succeeds": false, "only_allow_merge_if_all_discussions_are_resolved": false, @@ -196,7 +196,7 @@ Parameters: "issues_enabled": true, "open_issues_count": 1, "merge_requests_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "wiki_enabled": true, "snippets_enabled": false, "container_registry_enabled": false, @@ -226,7 +226,7 @@ Parameters: "forks_count": 0, "star_count": 0, "runners_token": "b8bc4a7a29eb76ea83cf79e4908c2b", - "public_builds": true, + "public_jobs": true, "shared_with_groups": [ { "group_id": 4, @@ -439,15 +439,15 @@ Parameters: | `description` | string | no | Short project description | | `issues_enabled` | boolean | no | Enable issues for this project | | `merge_requests_enabled` | boolean | no | Enable merge requests for this project | -| `builds_enabled` | boolean | no | Enable builds for this project | +| `jobs_enabled` | boolean | no | Enable jobs for this project | | `wiki_enabled` | boolean | no | Enable wiki for this project | | `snippets_enabled` | boolean | no | Enable snippets for this project | | `container_registry_enabled` | boolean | no | Enable container registry for this project | | `shared_runners_enabled` | boolean | no | Enable shared runners for this project | | `visibility` | String | no | See [project visibility level](#project-visibility-level) | | `import_url` | string | no | URL to import repository from | -| `public_builds` | boolean | no | If `true`, builds can be viewed by non-project-members | -| `only_allow_merge_if_pipeline_succeeds` | boolean | no | Set whether merge requests can only be merged with successful builds | +| `public_jobs` | boolean | no | If `true`, jobs can be viewed by non-project-members | +| `only_allow_merge_if_pipeline_succeeds` | boolean | no | Set whether merge requests can only be merged with successful jobs | | `only_allow_merge_if_all_discussions_are_resolved` | boolean | no | Set whether merge requests can only be merged when all the discussions are resolved | | `lfs_enabled` | boolean | no | Enable LFS | | `request_access_enabled` | boolean | no | Allow users to request member access | @@ -472,15 +472,15 @@ Parameters: | `description` | string | no | Short project description | | `issues_enabled` | boolean | no | Enable issues for this project | | `merge_requests_enabled` | boolean | no | Enable merge requests for this project | -| `builds_enabled` | boolean | no | Enable builds for this project | +| `jobs_enabled` | boolean | no | Enable jobs for this project | | `wiki_enabled` | boolean | no | Enable wiki for this project | | `snippets_enabled` | boolean | no | Enable snippets for this project | | `container_registry_enabled` | boolean | no | Enable container registry for this project | | `shared_runners_enabled` | boolean | no | Enable shared runners for this project | | `visibility` | string | no | See [project visibility level](#project-visibility-level) | | `import_url` | string | no | URL to import repository from | -| `public_builds` | boolean | no | If `true`, builds can be viewed by non-project-members | -| `only_allow_merge_if_pipeline_succeeds` | boolean | no | Set whether merge requests can only be merged with successful builds | +| `public_jobs` | boolean | no | If `true`, jobs can be viewed by non-project-members | +| `only_allow_merge_if_pipeline_succeeds` | boolean | no | Set whether merge requests can only be merged with successful jobs | | `only_allow_merge_if_all_discussions_are_resolved` | boolean | no | Set whether merge requests can only be merged when all the discussions are resolved | | `lfs_enabled` | boolean | no | Enable LFS | | `request_access_enabled` | boolean | no | Allow users to request member access | @@ -504,15 +504,15 @@ Parameters: | `description` | string | no | Short project description | | `issues_enabled` | boolean | no | Enable issues for this project | | `merge_requests_enabled` | boolean | no | Enable merge requests for this project | -| `builds_enabled` | boolean | no | Enable builds for this project | +| `jobs_enabled` | boolean | no | Enable jobs for this project | | `wiki_enabled` | boolean | no | Enable wiki for this project | | `snippets_enabled` | boolean | no | Enable snippets for this project | | `container_registry_enabled` | boolean | no | Enable container registry for this project | | `shared_runners_enabled` | boolean | no | Enable shared runners for this project | | `visibility` | string | no | See [project visibility level](#project-visibility-level) | | `import_url` | string | no | URL to import repository from | -| `public_builds` | boolean | no | If `true`, builds can be viewed by non-project-members | -| `only_allow_merge_if_pipeline_succeeds` | boolean | no | Set whether merge requests can only be merged with successful builds | +| `public_jobs` | boolean | no | If `true`, jobs can be viewed by non-project-members | +| `only_allow_merge_if_pipeline_succeeds` | boolean | no | Set whether merge requests can only be merged with successful jobs | | `only_allow_merge_if_all_discussions_are_resolved` | boolean | no | Set whether merge requests can only be merged when all the discussions are resolved | | `lfs_enabled` | boolean | no | Enable LFS | | `request_access_enabled` | boolean | no | Allow users to request member access | @@ -572,7 +572,7 @@ Example response: "issues_enabled": true, "open_issues_count": 1, "merge_requests_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "wiki_enabled": true, "snippets_enabled": false, "container_registry_enabled": false, @@ -591,7 +591,7 @@ Example response: "shared_runners_enabled": true, "forks_count": 0, "star_count": 1, - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "only_allow_merge_if_pipeline_succeeds": false, "only_allow_merge_if_all_discussions_are_resolved": false, @@ -637,7 +637,7 @@ Example response: "issues_enabled": true, "open_issues_count": 1, "merge_requests_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "wiki_enabled": true, "snippets_enabled": false, "container_registry_enabled": false, @@ -656,7 +656,7 @@ Example response: "shared_runners_enabled": true, "forks_count": 0, "star_count": 0, - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "only_allow_merge_if_pipeline_succeeds": false, "only_allow_merge_if_all_discussions_are_resolved": false, @@ -708,7 +708,7 @@ Example response: "issues_enabled": true, "open_issues_count": 1, "merge_requests_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "wiki_enabled": true, "snippets_enabled": false, "container_registry_enabled": false, @@ -738,7 +738,7 @@ Example response: "forks_count": 0, "star_count": 0, "runners_token": "b8bc4a7a29eb76ea83cf79e4908c2b", - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "only_allow_merge_if_pipeline_succeeds": false, "only_allow_merge_if_all_discussions_are_resolved": false, @@ -790,7 +790,7 @@ Example response: "issues_enabled": true, "open_issues_count": 1, "merge_requests_enabled": true, - "builds_enabled": true, + "jobs_enabled": true, "wiki_enabled": true, "snippets_enabled": false, "container_registry_enabled": false, @@ -820,7 +820,7 @@ Example response: "forks_count": 0, "star_count": 0, "runners_token": "b8bc4a7a29eb76ea83cf79e4908c2b", - "public_builds": true, + "public_jobs": true, "shared_with_groups": [], "only_allow_merge_if_pipeline_succeeds": false, "only_allow_merge_if_all_discussions_are_resolved": false, @@ -955,7 +955,7 @@ Parameters: "merge_requests_events": true, "tag_push_events": true, "note_events": true, - "build_events": true, + "job_events": true, "pipeline_events": true, "wiki_page_events": true, "enable_ssl_verification": true, @@ -982,7 +982,7 @@ Parameters: | `merge_requests_events` | boolean | no | Trigger hook on merge requests events | | `tag_push_events` | boolean | no | Trigger hook on tag push events | | `note_events` | boolean | no | Trigger hook on note events | -| `build_events` | boolean | no | Trigger hook on build events | +| `job_events` | boolean | no | Trigger hook on job events | | `pipeline_events` | boolean | no | Trigger hook on pipeline events | | `wiki_events` | boolean | no | Trigger hook on wiki events | | `enable_ssl_verification` | boolean | no | Do SSL verification when triggering the hook | @@ -1008,7 +1008,7 @@ Parameters: | `merge_requests_events` | boolean | no | Trigger hook on merge requests events | | `tag_push_events` | boolean | no | Trigger hook on tag push events | | `note_events` | boolean | no | Trigger hook on note events | -| `build_events` | boolean | no | Trigger hook on build events | +| `job_events` | boolean | no | Trigger hook on job events | | `pipeline_events` | boolean | no | Trigger hook on pipeline events | | `wiki_events` | boolean | no | Trigger hook on wiki events | | `enable_ssl_verification` | boolean | no | Do SSL verification when triggering the hook | diff --git a/doc/api/services.md b/doc/api/services.md index b030a425a7a..4bb45497d11 100644 --- a/doc/api/services.md +++ b/doc/api/services.md @@ -70,7 +70,7 @@ GET /projects/:id/services/assembla ## Atlassian Bamboo CI -A continuous integration and build server +A continuous integration and job server ### Create/Edit Atlassian Bamboo CI service @@ -85,7 +85,7 @@ PUT /projects/:id/services/bamboo Parameters: - `bamboo_url` (**required**) - Bamboo root URL like https://bamboo.example.com -- `build_key` (**required**) - Bamboo build plan key like KEY +- `job_key` (**required**) - Bamboo job plan key like KEY - `username` (**required**) - A user with API access, if applicable - `password` (**required**) @@ -114,13 +114,13 @@ Continuous integration and deployments Set Buildkite service for a project. ``` -PUT /projects/:id/services/buildkite +PUT /projects/:id/services/jobkite ``` Parameters: - `token` (**required**) - Buildkite project GitLab token -- `project_url` (**required**) - https://buildkite.com/example/project +- `project_url` (**required**) - https://jobkite.com/example/project - `enable_ssl_verification` (optional) - Enable SSL verification ### Delete Buildkite service @@ -128,7 +128,7 @@ Parameters: Delete Buildkite service for a project. ``` -DELETE /projects/:id/services/buildkite +DELETE /projects/:id/services/jobkite ``` ### Get Buildkite service settings @@ -136,19 +136,19 @@ DELETE /projects/:id/services/buildkite Get Buildkite service settings for a project. ``` -GET /projects/:id/services/buildkite +GET /projects/:id/services/jobkite ``` ## Build-Emails -Get emails for GitLab CI builds. +Get emails for GitLab CI jobs. ### Create/Edit Build-Emails service Set Build-Emails service for a project. ``` -PUT /projects/:id/services/builds-email +PUT /projects/:id/services/jobs-email ``` Parameters: @@ -157,23 +157,23 @@ Parameters: | --------- | ---- | -------- | ----------- | | `recipients` | string | yes | Comma-separated list of recipient email addresses | | `add_pusher` | boolean | no | Add pusher to recipients list | -| `notify_only_broken_builds` | boolean | no | Notify only broken builds | +| `notify_only_broken_jobs` | boolean | no | Notify only broken jobs | -### Delete Build-Emails service +### Delete Job-Emails service Delete Build-Emails service for a project. ``` -DELETE /projects/:id/services/builds-email +DELETE /projects/:id/services/jobs-email ``` -### Get Build-Emails service settings +### Get Job-Emails service settings Get Build-Emails service settings for a project. ``` -GET /projects/:id/services/builds-email +GET /projects/:id/services/jobs-email ``` ## Campfire @@ -580,7 +580,7 @@ Parameters: | --------- | ---- | -------- | ----------- | | `recipients` | string | yes | Comma-separated list of recipient email addresses | | `add_pusher` | boolean | no | Add pusher to recipients list | -| `notify_only_broken_builds` | boolean | no | Notify only broken pipelines | +| `notify_only_broken_jobs` | boolean | no | Notify only broken pipelines | ### Delete Pipeline-Emails service diff --git a/lib/api/services.rb b/lib/api/services.rb index 79a5f27dc4d..1cf29d9a1a3 100644 --- a/lib/api/services.rb +++ b/lib/api/services.rb @@ -122,9 +122,9 @@ module API }, { required: false, - name: :notify_only_broken_builds, + name: :notify_only_broken_jobs, type: Boolean, - desc: 'Notify only broken builds' + desc: 'Notify only broken jobs' } ], 'campfire' => [ @@ -403,9 +403,9 @@ module API }, { required: false, - name: :notify_only_broken_builds, + name: :notify_only_broken_jobs, type: Boolean, - desc: 'Notify only broken builds' + desc: 'Notify only broken jobs' } ], 'pivotaltracker' => [ @@ -611,7 +611,7 @@ module API desc "Set #{service_slug} service for project" params do service_classes.each do |service| - event_names = service.try(:event_names) || [] + event_names = service.try(:event_names) || next event_names.each do |event_name| services[service.to_param.tr("_", "-")] << { required: false,