Este contenido no está disponible en el idioma seleccionado.
Chapter 24. trigger
Create, list and manage build triggers.
24.1. activateBuildTrigger Copiar enlaceEnlace copiado en el portapapeles!
Activate the specified build trigger.
POST /api/v1/repository/{repository}/trigger/{trigger_uuid}/activate
Authorizations: oauth2_implicit (repo:admin)
Path parameters
Type | Name | Description | Schema |
---|---|---|---|
path |
trigger_uuid | The UUID of the build trigger | string |
path |
repository | The full path of the repository. e.g. namespace/name | string |
Request body schema (application/json)
Name | Description | Schema |
---|---|---|
config | Arbitrary json. | object |
pull_robot | The name of the robot that will be used to pull images. | string |
Responses
HTTP Code | Description | Schema |
---|---|---|
201 | Successful creation | |
400 | Bad Request | |
401 | Session required | |
403 | Unauthorized access | |
404 | Not found |
Example command
24.2. listTriggerRecentBuilds Copiar enlaceEnlace copiado en el portapapeles!
List the builds started by the specified trigger.
GET /api/v1/repository/{repository}/trigger/{trigger_uuid}/builds
Authorizations: oauth2_implicit (repo:admin)
Path parameters
Type | Name | Description | Schema |
---|---|---|---|
path |
trigger_uuid | The UUID of the build trigger | string |
path |
repository | The full path of the repository. e.g. namespace/name | string |
Query parameters
Type | Name | Description | Schema |
---|---|---|---|
query |
limit | The maximum number of builds to return | integer |
Responses
HTTP Code | Description | Schema |
---|---|---|
200 | Successful invocation | |
400 | Bad Request | |
401 | Session required | |
403 | Unauthorized access | |
404 | Not found |
Example command
curl -X GET "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid/builds?limit=10" \ -H "Authorization: Bearer <your_access_token>"
$ curl -X GET "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid/builds?limit=10" \
-H "Authorization: Bearer <your_access_token>"
24.3. manuallyStartBuildTrigger Copiar enlaceEnlace copiado en el portapapeles!
Manually start a build from the specified trigger.
POST /api/v1/repository/{repository}/trigger/{trigger_uuid}/start
Authorizations: oauth2_implicit (repo:admin)
Path parameters
Type | Name | Description | Schema |
---|---|---|---|
path |
trigger_uuid | The UUID of the build trigger | string |
path |
repository | The full path of the repository. e.g. namespace/name | string |
Request body schema (application/json)
Optional run parameters for activating the build trigger
Name | Description | Schema |
---|---|---|
branch_name | (SCM only) If specified, the name of the branch to build. | string |
commit_sha | (Custom Only) If specified, the ref/SHA1 used to checkout a git repository. | string |
refs | (SCM Only) If specified, the ref to build. |
Responses
HTTP Code | Description | Schema |
---|---|---|
201 | Successful creation | |
400 | Bad Request | |
401 | Session required | |
403 | Unauthorized access | |
404 | Not found |
Example command
24.4. getBuildTrigger Copiar enlaceEnlace copiado en el portapapeles!
Get information for the specified build trigger.
GET /api/v1/repository/{repository}/trigger/{trigger_uuid}
Authorizations: oauth2_implicit (repo:admin)
Path parameters
Type | Name | Description | Schema |
---|---|---|---|
path |
trigger_uuid | The UUID of the build trigger | string |
path |
repository | The full path of the repository. e.g. namespace/name | string |
Responses
HTTP Code | Description | Schema |
---|---|---|
200 | Successful invocation | |
400 | Bad Request | |
401 | Session required | |
403 | Unauthorized access | |
404 | Not found |
Example command
curl -X GET "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid" \ -H "Authorization: Bearer <your_access_token>"
$ curl -X GET "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid" \
-H "Authorization: Bearer <your_access_token>"
24.5. updateBuildTrigger Copiar enlaceEnlace copiado en el portapapeles!
Updates the specified build trigger.
PUT /api/v1/repository/{repository}/trigger/{trigger_uuid}
Authorizations: oauth2_implicit (repo:admin)
Path parameters
Type | Name | Description | Schema |
---|---|---|---|
path |
trigger_uuid | The UUID of the build trigger | string |
path |
repository | The full path of the repository. e.g. namespace/name | string |
Request body schema (application/json)
Options for updating a build trigger
Name | Description | Schema |
---|---|---|
enabled | Whether the build trigger is enabled | boolean |
Responses
HTTP Code | Description | Schema |
---|---|---|
200 | Successful invocation | |
400 | Bad Request | |
401 | Session required | |
403 | Unauthorized access | |
404 | Not found |
Example command
curl -X PUT "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid" \ -H "Authorization: Bearer <your_access_token>" \ -H "Content-Type: application/json" \ -d '{"enabled": true}'
$ curl -X PUT "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid" \
-H "Authorization: Bearer <your_access_token>" \
-H "Content-Type: application/json" \
-d '{"enabled": true}'
24.6. deleteBuildTrigger Copiar enlaceEnlace copiado en el portapapeles!
Delete the specified build trigger.
DELETE /api/v1/repository/{repository}/trigger/{trigger_uuid}
Authorizations: oauth2_implicit (repo:admin)
Path parameters
Type | Name | Description | Schema |
---|---|---|---|
path |
trigger_uuid | The UUID of the build trigger | string |
path |
repository | The full path of the repository. e.g. namespace/name | string |
Responses
HTTP Code | Description | Schema |
---|---|---|
204 | Deleted | |
400 | Bad Request | |
401 | Session required | |
403 | Unauthorized access | |
404 | Not found |
Example command
curl -X DELETE "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid" \ -H "Authorization: Bearer <your_access_token>"
$ curl -X DELETE "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/example-trigger-uuid" \
-H "Authorization: Bearer <your_access_token>"
24.7. listBuildTriggers Copiar enlaceEnlace copiado en el portapapeles!
List the triggers for the specified repository.
GET /api/v1/repository/{repository}/trigger/
Authorizations: oauth2_implicit (repo:admin)
Path parameters
Type | Name | Description | Schema |
---|---|---|---|
path |
repository | The full path of the repository. e.g. namespace/name | string |
Responses
HTTP Code | Description | Schema |
---|---|---|
200 | Successful invocation | |
400 | Bad Request | |
401 | Session required | |
403 | Unauthorized access | |
404 | Not found |
Example command
curl -X GET "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/" \ -H "Authorization: Bearer <your_access_token>"
$ curl -X GET "https://quay-server.example.com/api/v1/repository/example_namespace/example_repo/trigger/" \
-H "Authorization: Bearer <your_access_token>"