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: oy
projectstring · min: 1 · max: 128Required

Project is the project identifier.

Example: ie
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: Reiciendis asperiores eveniet earum deserunt perspiciatis.
pipeline_execution_idstringOptional

Pipeline identifier

Example: Inventore quaerat laudantium et repudiandae occaecati.
pipeline_stage_idstringOptional

Pipeline stage identifier

Example: Itaque perspiciatis eum enim dolores quia voluptatum.
status_typestring · enumOptional

Status of the approval step

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

Account is the internal customer account ID.

Example: c
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: c
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: j
projectstring · min: 1 · max: 128Required

Project is the project identifier.

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

Account is the internal customer account ID.

Example: v
Body
pipeline_execution_idstringRequired

The unique identifier for the associated pipeline execution

Example: Molestiae consequatur ipsam fuga.
pipeline_stage_idstringRequired

The unique identifier for the associated pipeline execution stage

Example: Mollitia dolor.
statusstring · enumOptional

Status of the approval resource

Default: pendingExample: pendingPossible values:
workspace_idstringRequired

The unique identifier for the workspace_id

Example: Aperiam consectetur et ut aperiam.
Responses
200

OK response.

application/json

Create-ApprovalResponseBody result type (creation view)

idstringRequiredExample: Corporis ea eum est ullam in.
post/api/orgs/{org}/projects/{project}/approvals
POST /api/orgs/{org}/projects/{project}/approvals HTTP/1.1
Host: localhost:80
Harness-Account: v
Content-Type: application/json
Accept: */*
Content-Length: 177

{
  "pipeline_execution_id": "Ipsum quasi earum est nesciunt.",
  "pipeline_stage_id": "Aliquam aut in ut nihil reiciendis.",
  "status": "rejected",
  "workspace_id": "Sed vel aperiam minus."
}
{
  "id": "Libero dolor voluptatibus ipsa ipsam."
}

Show approval

get

Retrieve a single approval

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: z
idstring · uuidRequiredExample: bb091d10-0e9f-4333-91af-97e52e9e4889
Header parameters
Harness-Accountstring · min: 1 · max: 128Required

Account is the internal customer account ID.

Example: i5s
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: 3754574567575199000
statusstringRequired

Status of the approval resource

Default: pendingExample: Fugiat facere aut corrupti voluptas animi quia.
updatedinteger · int64Required

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

Example: 1306990353884779000
get/api/orgs/{org}/projects/{project}/approvals/{id}
GET /api/orgs/{org}/projects/{project}/approvals/{id} HTTP/1.1
Host: localhost:80
Harness-Account: i5s
Accept: */*
{
  "actioned_by": "John Doe",
  "actioned_by_email": "john.doe@example.com",
  "created": 4544608182846329000,
  "status": "Corrupti et nihil voluptates cupiditate.",
  "updated": 9114982333013444000
}

Update approval

put

Update a single approval

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: k9i
idstring · uuidRequiredExample: 3197ae50-2348-4357-ba8f-94e5c7115d09
Header parameters
Harness-Accountstring · min: 1 · max: 128Required

Account is the internal customer account ID.

Example: 25z
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: rejectedPossible 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: 25z
Content-Type: application/json
Accept: */*
Content-Length: 89

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

No content

Last updated

Was this helpful?