For the complete documentation index, see llms.txt. This page is also available as Markdown.

Approvals

Approval service handles the approval API to approve or reject pipeline executions

List approvals

get

List all the approvals

Path parameters
orgstring · min: 1 · max: 128Required

Org is the organisation identifier.

Example: vv
projectstring · min: 1 · max: 128Required

Project is the project identifier.

Example: i
Query parameters
limitinteger · int64 · min: 1 · max: 1000Optional

Limit is the number of records to return for a page.

Default: 30Example: 30
pageinteger · int64 · min: 1Optional

Page is the page number to return relative to the page 'limit'.

Default: 1Example: 1
workspacestringOptional

Workspace identifier

Example: Recusandae culpa mollitia sequi.
pipeline_execution_idstringOptional

Pipeline identifier

Example: Sunt minus at officia repellendus.
pipeline_stage_idstringOptional

Pipeline stage identifier

Example: Eaque mollitia assumenda.
status_typestring · enumOptional

Status of the approval step

Example: approvedPossible values:
Header parameters
Harness-Accountstring · min: 1 · max: 128Required

Account is the internal customer account ID.

Example: 77x
Responses
200

OK response.

application/json
get/api/orgs/{org}/projects/{project}/approvals
GET /api/orgs/{org}/projects/{project}/approvals HTTP/1.1
Host: localhost:80
Harness-Account: 77x
Accept: */*
[
  {
    "account": "kn8",
    "actioned_by": "John Doe",
    "actioned_by_email": "john.doe@example.com",
    "created": 8923043851235030000,
    "id": "Aliquid quia dignissimos aut accusamus voluptates rerum.",
    "org": "1",
    "pipeline_execution_id": "A tempora asperiores consectetur.",
    "pipeline_stage_id": "Id consequatur atque.",
    "project": "bcz",
    "status": "Quam saepe sit magnam tenetur.",
    "updated": 4501857522395362000,
    "workspace_id": "Itaque sed eum."
  },
  {
    "account": "kn8",
    "actioned_by": "John Doe",
    "actioned_by_email": "john.doe@example.com",
    "created": 8923043851235030000,
    "id": "Aliquid quia dignissimos aut accusamus voluptates rerum.",
    "org": "1",
    "pipeline_execution_id": "A tempora asperiores consectetur.",
    "pipeline_stage_id": "Id consequatur atque.",
    "project": "bcz",
    "status": "Quam saepe sit magnam tenetur.",
    "updated": 4501857522395362000,
    "workspace_id": "Itaque sed eum."
  },
  {
    "account": "kn8",
    "actioned_by": "John Doe",
    "actioned_by_email": "john.doe@example.com",
    "created": 8923043851235030000,
    "id": "Aliquid quia dignissimos aut accusamus voluptates rerum.",
    "org": "1",
    "pipeline_execution_id": "A tempora asperiores consectetur.",
    "pipeline_stage_id": "Id consequatur atque.",
    "project": "bcz",
    "status": "Quam saepe sit magnam tenetur.",
    "updated": 4501857522395362000,
    "workspace_id": "Itaque sed eum."
  }
]

Create approval

post

Create an approval resource

Path parameters
orgstring · min: 1 · max: 128Required

Org is the organisation identifier.

Example: r
projectstring · min: 1 · max: 128Required

Project is the project identifier.

Example: l4
Header parameters
Harness-Accountstring · min: 1 · max: 128Required

Account is the internal customer account ID.

Example: 9mq
Body
pipeline_execution_idstringRequired

The unique identifier for the associated pipeline execution

Example: Incidunt repudiandae.
pipeline_stage_idstringRequired

The unique identifier for the associated pipeline execution stage

Example: Dignissimos ipsa odit temporibus aliquid voluptatibus illum.
statusstring · enumOptional

Status of the approval resource

Default: pendingExample: pendingPossible values:
workspace_idstringRequired

The unique identifier for the workspace_id

Example: Facere dolore dignissimos.
Responses
200

OK response.

application/json

Create-ApprovalResponseBody result type (creation view)

idstringRequiredExample: Atque veritatis a totam quia.
post/api/orgs/{org}/projects/{project}/approvals
POST /api/orgs/{org}/projects/{project}/approvals HTTP/1.1
Host: localhost:80
Harness-Account: 9mq
Content-Type: application/json
Accept: */*
Content-Length: 165

{
  "pipeline_execution_id": "Ut voluptatum provident voluptas.",
  "pipeline_stage_id": "Ipsam cumque.",
  "status": "rejected",
  "workspace_id": "Sunt est quia fuga porro ipsa."
}
{
  "id": "Atque dolor corrupti quae debitis cum voluptatem."
}

Show approval

get

Retrieve a single approval

Path parameters
orgstring · min: 1 · max: 128Required

Org is the organisation identifier.

Example: xy
projectstring · min: 1 · max: 128Required

Project is the project identifier.

Example: 0jw
idstring · uuidRequiredExample: 5d317a1d-4c23-4a7f-a467-1423ad360500
Header parameters
Harness-Accountstring · min: 1 · max: 128Required

Account is the internal customer account ID.

Example: 29
Responses
200

OK response.

application/json

Show-ApprovalResponseBody result type (statusInfo view)

actioned_bystringOptional

User that approved/rejected the step

Example: John Doe
actioned_by_emailstringOptional

Email of the user that approved/rejected the step

Example: john.doe@example.com
createdinteger · int64Required

Created is the unix timestamp at which the resource was originally created in milliseconds.

Example: 4525749087327568400
statusstringRequired

Status of the approval resource

Default: pendingExample: Molestiae vel qui autem rerum repellat.
updatedinteger · int64Required

Modified is the unix timestamp at which the resource was last modified in milliseconds.

Example: 8179483835664226000
get/api/orgs/{org}/projects/{project}/approvals/{id}
GET /api/orgs/{org}/projects/{project}/approvals/{id} HTTP/1.1
Host: localhost:80
Harness-Account: 29
Accept: */*
{
  "actioned_by": "John Doe",
  "actioned_by_email": "john.doe@example.com",
  "created": 7226061072750265000,
  "status": "Beatae vero vero facere corrupti.",
  "updated": 1022861971819077100
}

Update approval

put

Update a single approval

Path parameters
orgstring · min: 1 · max: 128Required

Org is the organisation identifier.

Example: 42
projectstring · min: 1 · max: 128Required

Project is the project identifier.

Example: v
idstring · uuidRequiredExample: 953bb3bd-eb75-460b-8b03-4834d75283ca
Header parameters
Harness-Accountstring · min: 1 · max: 128Required

Account is the internal customer account ID.

Example: e1
Body
actioned_bystringOptional

User that approved/rejected the step

Example: John Doe
actioned_by_emailstringOptional

Email of the user that approved/rejected the step

Example: john.doe@example.com
statusstring · enumRequired

Status update to be performed upon the Approval step

Default: pendingExample: approvedPossible values:
Responses
200

OK response.

No content

put/api/orgs/{org}/projects/{project}/approvals/{id}
PUT /api/orgs/{org}/projects/{project}/approvals/{id} HTTP/1.1
Host: localhost:80
Harness-Account: e1
Content-Type: application/json
Accept: */*
Content-Length: 88

{
  "actioned_by": "John Doe",
  "actioned_by_email": "john.doe@example.com",
  "status": "pending"
}

No content

Last updated

Was this helpful?