diff options
Diffstat (limited to 'doc/api/pipeline_triggers.md')
-rw-r--r-- | doc/api/pipeline_triggers.md | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/doc/api/pipeline_triggers.md b/doc/api/pipeline_triggers.md index e207ff8e98a..55c6e37c164 100644 --- a/doc/api/pipeline_triggers.md +++ b/doc/api/pipeline_triggers.md @@ -6,7 +6,7 @@ You can read more about [triggering pipelines through the API](../ci/triggers/RE Get a list of project's build triggers. -``` +```plaintext GET /projects/:id/triggers ``` @@ -14,7 +14,7 @@ GET /projects/:id/triggers |-----------|---------|----------|---------------------| | `id` | integer/string | yes | The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user | -``` +```shell curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/projects/1/triggers" ``` @@ -36,7 +36,7 @@ curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/a Get details of project's build trigger. -``` +```plaintext GET /projects/:id/triggers/:trigger_id ``` @@ -45,7 +45,7 @@ GET /projects/:id/triggers/:trigger_id | `id` | integer/string | yes | The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user | | `trigger_id` | integer | yes | The trigger id | -``` +```shell curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/projects/1/triggers/5" ``` @@ -65,7 +65,7 @@ curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/a Create a trigger for a project. -``` +```plaintext POST /projects/:id/triggers ``` @@ -74,7 +74,7 @@ POST /projects/:id/triggers | `id` | integer/string | yes | The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user | | `description` | string | yes | The trigger name | -``` +```shell curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" --form description="my description" "https://gitlab.example.com/api/v4/projects/1/triggers" ``` @@ -94,7 +94,7 @@ curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" --form descrip Update a trigger for a project. -``` +```plaintext PUT /projects/:id/triggers/:trigger_id ``` @@ -104,7 +104,7 @@ PUT /projects/:id/triggers/:trigger_id | `trigger_id` | integer | yes | The trigger id | | `description` | string | no | The trigger name | -``` +```shell curl --request PUT --header "PRIVATE-TOKEN: <your_access_token>" --form description="my description" "https://gitlab.example.com/api/v4/projects/1/triggers/10" ``` @@ -124,7 +124,7 @@ curl --request PUT --header "PRIVATE-TOKEN: <your_access_token>" --form descript Remove a project's build trigger. -``` +```plaintext DELETE /projects/:id/triggers/:trigger_id ``` @@ -133,6 +133,6 @@ DELETE /projects/:id/triggers/:trigger_id | `id` | integer/string | yes | The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user | | `trigger_id` | integer | yes | The trigger id | -``` +```shell curl --request DELETE --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/projects/1/triggers/5" ``` |