REST API
Note
This page is a work-in-progress as the OpenAPI spec is not yet complete.
- GET /api
Example request:
GET /api HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/authorizations
Example request:
GET /api/authorizations HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/components
Example request:
GET /api/components HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/connections
Example request:
GET /api/connections HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/info
Example request:
GET /api/info HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/authorizations
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/authorizations HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/autohold
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/autohold HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- DELETE /api/tenant/{tenant_name}/autohold/{request_id}
- Parameters:
tenant_name (string)
request_id (string)
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/autohold/{request_id}
- Parameters:
tenant_name (string)
request_id (string)
Example request:
GET /api/tenant/{tenant_name}/autohold/{request_id} HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/badge
Get a badge describing the result of the latest buildset found.
- Parameters:
tenant_name (string) – The tenant name
- Query Parameters:
project (string) – A project name
pipeline (string) – A pipeline name
branch (string) – A branch name
Example request:
GET /api/tenant/{tenant_name}/badge HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Badge describing the result of the latest buildset found.
404 Not Found – No buildset found
- GET /api/tenant/{tenant_name}/build-times
- Parameters:
tenant_name (string)
- Query Parameters:
project (string)
pipeline (string)
branch (string)
ref (string)
job_name (string)
final (string)
start_time (string)
end_time (string)
limit (string)
skip (string)
exclude_result (string)
Example request:
GET /api/tenant/{tenant_name}/build-times HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/build/{uuid}
- Parameters:
tenant_name (string)
uuid (string)
Example request:
GET /api/tenant/{tenant_name}/build/{uuid} HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/builds
List the executed builds
- Parameters:
tenant_name (string)
- Query Parameters:
project (string)
pipeline (string)
change (string)
branch (string)
patchset (string)
ref (string)
newrev (string)
uuid (string)
job_name (string)
voting (string)
nodeset (string)
result (string)
final (string)
held (string)
complete (string)
limit (string)
skip (string)
idx_min (string)
idx_max (string)
exclude_result (string)
Example request:
GET /api/tenant/{tenant_name}/builds HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of builds
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "_id": "string", "artifacts": [ { "metadata": {}, "name": "string", "url": "string" } ], "duration": "string", "end_time": "string", "error_detail": "string", "final": "string", "held": "string", "job_name": "string", "log_url": "string", "nodeset": "string", "provides": [ { "name": "string" } ], "ref": { "branch": "string", "change": "string", "newrev": "string", "oldrev": "string", "patchset": "string", "project": "string", "ref": "string", "ref_url": "string" }, "result": "string", "start_time": "string", "uuid": "string", "voting": "string" } ]
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/buildset/{uuid}
- Parameters:
tenant_name (string)
uuid (string)
Example request:
GET /api/tenant/{tenant_name}/buildset/{uuid} HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns a buildset
Example response:
HTTP/1.1 200 OK Content-Type: application/json { "_id": "string", "builds": [ { "_id": "string", "artifacts": [ { "metadata": {}, "name": "string", "url": "string" } ], "duration": "string", "end_time": "string", "error_detail": "string", "final": "string", "held": "string", "job_name": "string", "log_url": "string", "nodeset": "string", "provides": [ { "name": "string" } ], "ref": { "branch": "string", "change": "string", "newrev": "string", "oldrev": "string", "patchset": "string", "project": "string", "ref": "string", "ref_url": "string" }, "result": "string", "start_time": "string", "uuid": "string", "voting": "string" } ], "event_id": "string", "event_timestamp": "string", "events": [ { "description": "string", "event_time": "string", "event_type": "string" } ], "first_build_start_time": "string", "last_build_end_time": "string", "message": "string", "pipeline": "string", "refs": [ { "branch": "string", "change": "string", "newrev": "string", "oldrev": "string", "patchset": "string", "project": "string", "ref": "string", "ref_url": "string" } ], "result": "string", "uuid": "string" }
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/buildsets
- Parameters:
tenant_name (string)
- Query Parameters:
project (string)
pipeline (string)
change (string)
branch (string)
patchset (string)
ref (string)
newrev (string)
uuid (string)
result (string)
complete (string)
limit (string)
skip (string)
idx_min (string)
idx_max (string)
exclude_result (string)
Example request:
GET /api/tenant/{tenant_name}/buildsets HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of buildsets
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "_id": "string", "event_id": "string", "event_timestamp": "string", "first_build_start_time": "string", "last_build_end_time": "string", "message": "string", "pipeline": "string", "refs": [ { "branch": "string", "change": "string", "newrev": "string", "oldrev": "string", "patchset": "string", "project": "string", "ref": "string", "ref_url": "string" } ], "result": "string", "uuid": "string" } ]
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/config-errors
- Parameters:
tenant_name (string)
- Query Parameters:
project (string)
branch (string)
severity (string)
name (string)
limit (string)
skip (string)
Example request:
GET /api/tenant/{tenant_name}/config-errors HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/console-stream
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/console-stream HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/flavors
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/flavors HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of flavors
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "canonical_name": "string", "description": "string", "name": "string" } ]
404 Not Found – Tenant not found
- DELETE /api/tenant/{tenant_name}/image-build-artifact/{artifact_id}
- Parameters:
tenant_name (string)
artifact_id (string)
- Status Codes:
200 OK – Response not yet documented
- DELETE /api/tenant/{tenant_name}/image-upload/{upload_id}
- Parameters:
tenant_name (string)
upload_id (string)
- Status Codes:
200 OK – Response not yet documented
- POST /api/tenant/{tenant_name}/image-upload/{upload_id}/validate
- Parameters:
tenant_name (string)
upload_id (string)
- Status Codes:
200 OK – Response not yet documented
- POST /api/tenant/{tenant_name}/image/{image_name}/build
- Parameters:
tenant_name (string)
image_name (string)
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/images
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/images HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of images
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "branch": "string", "build_artifacts": [ { "build_tenant": true, "build_uuid": "string", "canonical_name": "string", "format": "string", "is_locked": true, "lock_holder": "string", "md5sum": "string", "sha256": "string", "state": "string", "state_time": "string", "timestamp": "string", "uploads": [ { "artifact_uuid": "string", "canonical_name": "string", "endpoint_name": "string", "external_id": "string", "is_locked": true, "lock_holder": "string", "state": "string", "state_time": "string", "timestamp": "string", "uuid": "string", "validated": "string" } ], "url": "string", "uuid": "string", "validated": "string" } ], "canonical_name": "string", "name": "string", "project_canonical_name": "string", "type": "string" } ]
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/info
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/info HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/job/{job_name}
- Parameters:
tenant_name (string)
job_name (string)
Example request:
GET /api/tenant/{tenant_name}/job/{job_name} HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/jobs
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/jobs HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of jobs
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "description": "string", "name": "string", "tags": [ "string" ], "variants": [ { "branches": [ "string" ], "parent": "string" } ] } ]
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/key/{project_name}.pub
- Parameters:
tenant_name (string)
project_name (string)
Example request:
GET /api/tenant/{tenant_name}/key/{project_name}.pub HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the project public key that is used to encrypt secrets
Example response:
HTTP/1.1 200 OK Content-Type: text/plain -----BEGIN PUBLIC KEY----- MIICI... -----END PUBLIC KEY-----
404 Not Found – Tenant or Project not found
- GET /api/tenant/{tenant_name}/labels
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/labels HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/nodes
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/nodes HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- PUT /api/tenant/{tenant_name}/nodes/{node_id}
- Parameters:
tenant_name (string)
node_id (string)
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/nodeset-requests
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/nodeset-requests HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- DELETE /api/tenant/{tenant_name}/nodeset-requests/{request_id}
- Parameters:
tenant_name (string)
request_id (string)
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/pipeline/{pipeline_name}/project/{project_name}/branch/{branch_name}/freeze-job/{job_name}
- Parameters:
tenant_name (string)
pipeline_name (string)
project_name (string)
branch_name (string)
job_name (string)
Example request:
GET /api/tenant/{tenant_name}/pipeline/{pipeline_name}/project/{project_name}/branch/{branch_name}/freeze-job/{job_name} HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/pipeline/{pipeline_name}/project/{project_name}/branch/{branch_name}/freeze-jobs
- Parameters:
tenant_name (string)
pipeline_name (string)
project_name (string)
branch_name (string)
Example request:
GET /api/tenant/{tenant_name}/pipeline/{pipeline_name}/project/{project_name}/branch/{branch_name}/freeze-jobs HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/pipelines
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/pipelines HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/project-ssh-key/{project_name}.pub
- Parameters:
tenant_name (string)
project_name (string)
Example request:
GET /api/tenant/{tenant_name}/project-ssh-key/{project_name}.pub HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the project public key that executor adds to SSH agent
Example response:
HTTP/1.1 200 OK Content-Type: text/plain ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACA
404 Not Found – Tenant or Project not found
- GET /api/tenant/{tenant_name}/project/{project_name}
- Parameters:
tenant_name (string)
project_name (string)
Example request:
GET /api/tenant/{tenant_name}/project/{project_name} HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/project/{project_name}/autohold
- Parameters:
tenant_name (string)
project_name (string)
Example request:
GET /api/tenant/{tenant_name}/project/{project_name}/autohold HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- POST /api/tenant/{tenant_name}/project/{project_name}/autohold
- Parameters:
tenant_name (string)
project_name (string)
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/project/{project_name}/dequeue
- Parameters:
tenant_name (string)
project_name (string)
Example request:
GET /api/tenant/{tenant_name}/project/{project_name}/dequeue HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/project/{project_name}/enqueue
- Parameters:
tenant_name (string)
project_name (string)
Example request:
GET /api/tenant/{tenant_name}/project/{project_name}/enqueue HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/projects
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/projects HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/promote
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/promote HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/providers
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/providers HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of providers
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "canonical_name": "string", "flavors": [ { "canonical_name": "string", "name": "string" } ], "images": [ { "build_artifacts": [ { "build_tenant": true, "build_uuid": "string", "canonical_name": "string", "format": "string", "is_locked": true, "lock_holder": "string", "md5sum": "string", "sha256": "string", "state": "string", "state_time": "string", "timestamp": "string", "uploads": [ { "artifact_uuid": "string", "canonical_name": "string", "endpoint_name": "string", "external_id": "string", "is_locked": true, "lock_holder": "string", "state": "string", "state_time": "string", "timestamp": "string", "uuid": "string", "validated": "string" } ], "url": "string", "uuid": "string", "validated": "string" } ], "canonical_name": "string", "name": "string", "type": "string" } ], "labels": [ { "canonical_name": "string", "name": "string" } ], "name": "string" } ]
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/semaphores
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/semaphores HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Returns the list of semaphores
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/state
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/state HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/status
Return the tenant status. Note: the output format is not currently documented and subject to change without notice.
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/status HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/status/change/{change}
Return the status for a single change. Note: the output format is not currently documented and subject to change without notice.
- Parameters:
tenant_name (string)
change (string)
Example request:
GET /api/tenant/{tenant_name}/status/change/{change} HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenant/{tenant_name}/system-events
- Parameters:
tenant_name (string)
- Query Parameters:
event_type (string)
limit (string)
skip (string)
Example request:
GET /api/tenant/{tenant_name}/system-events HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of system events
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "description": "string", "event_id": "string", "event_time": "string", "event_type": "string" } ]
404 Not Found – Tenant not found
- GET /api/tenant/{tenant_name}/tenant-ssh-key/ssh.pub
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/tenant-ssh-key/ssh.pub HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the tenant public key that executor adds to SSH agent
Example response:
HTTP/1.1 200 OK Content-Type: text/plain ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACA
404 Not Found – Tenant or Project not found
- GET /api/tenant/{tenant_name}/tenant-status
- Parameters:
tenant_name (string)
Example request:
GET /api/tenant/{tenant_name}/tenant-status HTTP/1.1 Host: example.com
- Status Codes:
200 OK – Response not yet documented
- GET /api/tenants
Example request:
GET /api/tenants HTTP/1.1 Host: example.com
- Status Codes:
200 OK –
Returns the list of tenants
Example response:
HTTP/1.1 200 OK Content-Type: application/json [ { "name": "string" } ]
404 Not Found – Tenant not found