workspaces

Workspaces Service handles the API for managing workspaces and triggering workflows against them.

List all workspace tags

List all tags

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: jd
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: c
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: jr
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/tags
Request samples
Response samples
application/json
[
  • "Natus aliquid quae.",
  • "Laboriosam doloremque fuga fugit.",
  • "Nulla in veritatis maxime et dolores eligendi.",
  • "Nulla aut facere."
]

Show workspace metrics

Show metrics for workspaces

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: wlc
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: im
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: 1
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspace-metrics
Request samples
Response samples
application/json
{
  • "status_counts": {
    }
}

List workspaces

List all workspaces.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: w
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: ax9
query Parameters
limit
integer <int64> [ 1 .. 1000 ]
Default: 30

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

Example: limit=30
page
integer <int64> >= 1
Default: 1

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

Example: page=1
searchTerm
string
Default: ""

Filter results by partial name match

Example: searchTerm=mysta
sort
string
Default: "name,ASC"

Sort order for results

Enum: "name,ASC" "name,DESC" "updated,ASC" "updated,DESC"
Example: sort=name,ASC
status
Array of strings

Status of the execution

Example: status=Ducimus sit.&status=Dignissimos optio.
tags
Array of strings

Comma separated list of tags to filter by

Example: tags=Facere velit labore ut repellendus rerum.&tags=Deleniti eius sit ut omnis corporis.&tags=Placeat voluptate delectus necessitatibus.&tags=Natus facere consequatur repellat.
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: fe
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces
Request samples
Response samples
application/json
[
  • {
    },
  • {
    },
  • {
    },
  • {
    }
]

Create workspace

Create a new workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: g
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: h
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: e
Request Body schema: application/json
required
object (AssociatedTemplate)

AssociatedTemplate defines the template details with template_id and version.

budget
number <float>

define the budget for a specific workspace

cost_breakdown_json
string

cost_breakdown_json is the identifier to the breakdown cost file from the current execution that was applied successfully

cost_diff_json
string

cost_diff_json is the identifier to the diff cost file between the previous and current successful executions

cost_estimation_enabled
boolean
Default: false

define if cost estimation operations will be performed in this workspace

object

List of default pipelines associated with this workspace and any per-workspace overrrides.

description
string

Description provides long-form text about the resource.

required
object

list of environment variables configured on the workspace.

identifier
required
string [ 1 .. 128 ] characters

Workspace identifier.

modules_json
string

modules_json is the identifier of any modules metadata associated with this workspace

name
required
string [ 1 .. 128 ] characters

Name is the human readable name for the resource.

provider_connector
required
string

Provider Connector is the reference to the connector for the infrastructure provider.

providers_json
string

providers_json is the identifier of any modules metadata associated with this workspace

provisioner
required
string

Provisioner defines the provisioning tool to use.

Enum: "terraform" "opentofu"
provisioner_version
string
Default: "latest"

Provisioner Version defines the tool version to use.

repository
string

Repository is the name of the repository to use.

repository_branch
string

Repository Branch in which the code should be accessed.

repository_commit
string

Repository Commit/Tag in which the code should be accessed.

repository_connector
string

Repository Connector is the reference to the connector to use for this code.

repository_path
string
Default: ""

Repository Path is the path in which the infra code resides.

repository_sha
string

Repository SHA in which the code should be accessed.

repository_submodules
string
Default: "false"

repository_submodules is the instruction about whether to clone submodules in the pipeline step

Enum: "false" "true" "recursive"
sparse_checkout
string

List of patterens that will be used for sparse checkout option of git clone

state_checksum
string

state_checksum is the sha-256 checksum of terraform state file

tags
string

Tags associated with the workspace.

terraform_plan_json
string

terraform_plan_json is the identifier to the current state file onl in JSON format.

terraform_state
string

terraform_state is the identifier to the plan file used to create the latest state.

terraform_state_json
string

terraform_state_json is the identifier to the plan file used to create the latest state only in JSON format.

Array of objects (WorkspaceTerraformVariableFiles)

define an array of terraform variables files that belong to a different repository

required
object

list of terraform variables configured on the workspace.

variable_sets
Array of strings

Optional Variable Sets as references

Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces
Request samples
application/json
{
  • "associated_template": {
    },
  • "budget": 0.12296778,
  • "cost_breakdown_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "cost_diff_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "cost_estimation_enabled": true,
  • "default_pipelines": {
    },
  • "description": "this is a more detailed explanation of the resource.",
  • "environment_variables": {
    },
  • "identifier": "pnv",
  • "modules_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "name": "resource name",
  • "provider_connector": "Rem illum accusantium ut voluptate.",
  • "providers_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "provisioner": "terraform",
  • "provisioner_version": "Sed assumenda.",
  • "repository": "Qui placeat quidem.",
  • "repository_branch": "main",
  • "repository_commit": "abc10ed",
  • "repository_connector": "Explicabo debitis odit hic porro.",
  • "repository_path": "",
  • "repository_sha": "abc10ed",
  • "repository_submodules": "recursive",
  • "sparse_checkout": "Nostrum nostrum molestiae et est porro.",
  • "state_checksum": "d21c1662d8ce2c74f24efdc8db93eb34473b86810aeccca4b1518f70b0ccde8f",
  • "tags": {
    },
  • "terraform_plan_json": "f9e21473daaa2674d862b67a1339f4570e86de17",
  • "terraform_state": "fc1200c7a7aa52109d762a9f005b149abef01479",
  • "terraform_state_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "terraform_variable_files": [
    ],
  • "terraform_variables": {
    },
  • "variable_sets": [
    ]
}
Response samples
application/json
{
  • "policy_evaluation": {
    }
}

Destroy workspace

Deletes the given workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: 5j
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: m
identifier
required
string [ 1 .. 128 ] characters

Identifier is the project identifier.

Example: 5
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: x
Responses
204

No Content response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

delete/iacm/api/orgs/{org}/projects/{project}/workspaces/{identifier}
Request samples

Show workspace

Show an individual workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: v1
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: 0a
identifier
required
string [ 1 .. 128 ] characters

Identifier is the project identifier.

Example: e0o
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: o90
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{identifier}
Request samples
Response samples
application/json
{
  • "account": "51y",
  • "associated_template": {
    },
  • "backend_locked": false,
  • "budget": 0.08924627,
  • "cost_breakdown_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "cost_diff_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "cost_estimation_enabled": true,
  • "created": 5066140238654963000,
  • "default_pipelines": {
    },
  • "description": "this is a more detailed explanation of the resource.",
  • "environment_variables": {
    },
  • "identifier": "7",
  • "modules_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "name": "resource name",
  • "org": "0j",
  • "project": "tm",
  • "provider_connector": "Et aut non.",
  • "providers_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "provisioner": "terraform",
  • "provisioner_data": "Eum totam aut in.",
  • "provisioner_version": "Inventore consequatur qui dolores ipsum autem.",
  • "repository": "Eligendi corporis eum.",
  • "repository_branch": "main",
  • "repository_commit": "abc10ed",
  • "repository_connector": "Nisi dolor harum illo.",
  • "repository_path": "",
  • "repository_sha": "abc10ed",
  • "repository_submodules": "recursive",
  • "sparse_checkout": "Qui nesciunt maiores rem necessitatibus natus odit.",
  • "state_checksum": "d21c1662d8ce2c74f24efdc8db93eb34473b86810aeccca4b1518f70b0ccde8f",
  • "status": "active",
  • "tags": {
    },
  • "terraform_plan_json": "f9e21473daaa2674d862b67a1339f4570e86de17",
  • "terraform_state": "fc1200c7a7aa52109d762a9f005b149abef01479",
  • "terraform_state_json": "c4a2d99bc28d236098a095277b7eb0718d6be068",
  • "terraform_variable_files": [
    ],
  • "terraform_variables": {
    },
  • "updated": 5895057065149330000,
  • "variable_sets": [
    ]
}

Update workspace

Updates the given workspace with new info.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: a
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: n
identifier
required
string [ 1 .. 128 ] characters

Workspace identifier.

Example: w
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: 89
Request Body schema: application/json
required
budget
number <float>

define the budget for a specific workspace

cost_estimation_enabled
boolean
Default: false

define if cost estimation operations will be performed in this workspace

object

List of default pipelines associated with this workspace and any per-workspace overrrides.

description
string

Description provides long-form text about the resource.

required
object

list of environment variables configured on the workspace.

name
required
string [ 1 .. 128 ] characters

Name is the human readable name for the resource.

provider_connector
required
string

Provider Connector is the reference to the connector for the infrastructure provider.

provisioner
required
string

Provisioner defines the provisioning tool to use.

Enum: "terraform" "opentofu"
provisioner_version
string
Default: "latest"

Provisioner Version defines the tool version to use.

repository
string

Repository is the name of the repository to use.

repository_branch
string

Repository Branch in which the code should be accessed.

repository_commit
string

Repository Commit/Tag in which the code should be accessed.

repository_connector
string

Repository Connector is the reference to the connector to use for this code.

repository_path
string
Default: ""

Repository Path is the path in which the infra code resides.

repository_sha
string

Repository SHA in which the code should be accessed.

repository_submodules
string
Default: "false"

repository_submodules is the instruction about whether to clone submodules in the pipeline step

Enum: "false" "true" "recursive"
sparse_checkout
string

List of patterens that will be used for sparse checkout option of git clone

tags
string

Tags associated with the workspace.

Array of objects (WorkspaceTerraformVariableFiles)

define an array of terraform variables files that belong to a different repository

required
object

list of terraform variables configured on the workspace.

variable_sets
Array of strings

Optional Variable Sets as references

Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

put/iacm/api/orgs/{org}/projects/{project}/workspaces/{identifier}
Request samples
application/json
{
  • "budget": 0.9958707,
  • "cost_estimation_enabled": true,
  • "default_pipelines": {
    },
  • "description": "this is a more detailed explanation of the resource.",
  • "environment_variables": {
    },
  • "name": "resource name",
  • "provider_connector": "Molestiae iusto.",
  • "provisioner": "terraform",
  • "provisioner_version": "Ullam similique.",
  • "repository": "Dolores odio placeat et.",
  • "repository_branch": "main",
  • "repository_commit": "abc10ed",
  • "repository_connector": "Aut doloremque rerum id.",
  • "repository_path": "",
  • "repository_sha": "abc10ed",
  • "repository_submodules": "recursive",
  • "sparse_checkout": "Accusamus harum aliquid minus.",
  • "tags": {
    },
  • "terraform_variable_files": [
    ],
  • "terraform_variables": {
    },
  • "variable_sets": [
    ]
}
Response samples
application/json
{
  • "policy_evaluation": {
    }
}

Force unlock workspace

Force unlock a workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: rd
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: v
identifier
required
string [ 1 .. 128 ] characters

Identifier is the project identifier.

Example: r
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: sb
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces/{identifier}/actions/force-unlock
Request samples

List modules

List modules associated with this workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: mxl
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: eng
identifier
required
string [ 1 .. 128 ] characters

Identifier is the project identifier.

Example: a
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: 2
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{identifier}/modules
Request samples
Response samples
application/json
[
  • {
    },
  • {
    },
  • {
    },
  • {
    }
]

List resources

List resources associated with this workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: o
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: dh
identifier
required
string [ 1 .. 128 ] characters

Identifier is the project identifier.

Example: jqq
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: gl
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{identifier}/resources
Request samples
Response samples
application/json
{
  • "data_sources": [
    ],
  • "outputs": [
    ],
  • "resources": [
    ]
}

Clone workspace

Clone the given workspace with new name.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: q
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: h
workspace
required
string
Example: Saepe quo totam aut sed.
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: jv7
Request Body schema: application/json
required
identifier
required
string [ 1 .. 128 ] characters

Workspace identifier.

name
required
string [ 1 .. 128 ] characters

Name is the human readable name for the resource.

Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/clone
Request samples
application/json
{
  • "identifier": "3j",
  • "name": "resource name"
}
Response samples
application/json
{
  • "policy_evaluation": {
    }
}

List data

List all stored data for a workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: g
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: l
workspace
required
string

Workspace identifier

Example: Et eum assumenda culpa.
query Parameters
pipeline_execution_id
string

Filter by pipeline execution ID

Example: pipeline_execution_id=Iste quia corporis qui.
pipeline_stage_id
string

Filter by pipeline execution stage ID

Example: pipeline_stage_id=Totam deleniti accusamus accusamus nulla.
provisioner_type
string

Filter by provisioner type

Example: provisioner_type=Nobis non sit quia aperiam eligendi doloribus.
data_type
string

Filter by data type

Example: data_type=Modi nesciunt modi labore perferendis harum.
limit
integer <int64> [ 1 .. 1000 ]
Default: 30

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

Example: limit=30
page
integer <int64> >= 1
Default: 1

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

Example: page=1
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: xio
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/data
Request samples
Response samples
application/json
[
  • {
    },
  • {
    },
  • {
    }
]

Create data

Store binary data generated by the provisioner, such as plans and state files.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: 7ez
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: 4c
workspace
required
string

Workspace identifier

Example: workspace123
query Parameters
pipeline_id
required
string

The unique identifier for the associated pipeline

Example: pipeline_id=Rerum accusantium asperiores sit.
stage_id
required
string

The unique identifier for a stage

Example: stage_id=Illo aut id sit perferendis.
pipeline_execution_id
required
string

The unique identifier for the associated pipeline execution

Example: pipeline_execution_id=Maxime cumque voluptas dolores sed.
pipeline_stage_id
required
string

The unique identifier for the associated pipeline execution stage

Example: pipeline_stage_id=Molestiae excepturi illo ullam iste id.
provisioner_type
required
string

Type of provisioner that created the data

Value: "tf"
Example: provisioner_type=tf
data_type
required
string

Type of data stored

Enum: "plan_human" "state_raw" "state_human" "cost_breakdown" "cost_diff" "modules" "providers"
Example: data_type=cost_diff
policy_action
string

Policy action used during OPA evaluation

Example: policy_action=afterTerraformApply
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: k
Content-Length
integer <int64>

Size in bytes of the data.

Example: 8447197739326849000
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/data
Request samples
Response samples
application/json
{
  • "id": "dc538c61-de48-4220-958c-5f3c4f983daa",
  • "policy_evaluation": [
    ],
  • "policy_evaluation_message": "- instance type 'xlarge' is not permitted",
  • "policy_evaluation_status": "error"
}

Show data

Get binary data generated by the provisioner, such as plans and state files.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: v7
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: 8
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Quis repellat et consequuntur non.
id
required
string

The unique identifier for the data

Example: dc538c61-de48-4220-958c-5f3c4f983daa
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: fv3
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/data/{id}
Request samples
Response samples
application/json
"string"

Evaluate data

Evaluate policy against previously stored data, such as plans and state files.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: 52
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: 7r1
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Ut sed in est.
id
required
string

The unique identifier for the data

Example: dc538c61-de48-4220-958c-5f3c4f983daa
query Parameters
pipeline_execution_id
string

Pipeline execution associated with this evaluation

Example: pipeline_execution_id=Repellat distinctio occaecati eos provident.
policy_action
required
string

Policy action used during OPA evaluation

Example: policy_action=afterTerraformApply
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: 9t
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/data/{id}/evaluate-policy
Request samples
Response samples
application/json
{
  • "id": "dc538c61-de48-4220-958c-5f3c4f983daa",
  • "policy_evaluation": [
    ],
  • "policy_evaluation_message": "- instance type 'xlarge' is not permitted",
  • "policy_evaluation_status": "error"
}

Send event

Store binary data generated by the provisioner, such as plans and state files.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: t
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: 7x
workspace
required
string [ 1 .. 1024 ] characters

Workspace associated with this event

Example: oh
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: p
Request Body schema: application/json
required
object
event_type
required
string

The type of event that occurred

Enum: "plan" "drifted" "provisioning" "destroying" "active" "inactive" "apply_needed" "failed" "stage-complete"
object (ActivityMetadata)
pipeline_execution_id
string
Default: ""

Deprecated: use metadata instead

pipeline_stage_id
string
Default: ""

Deprecated: use metadata instead

Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/events
Request samples
application/json
{
  • "data": {
    },
  • "event_type": "provisioning",
  • "metadata": {
    },
  • "pipeline_execution_id": "Eius earum hic id sunt doloremque.",
  • "pipeline_stage_id": "Debitis vero voluptas iusto facilis."
}

List pipelines

List the pipelines where the workspace is been used

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: or
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: k
workspace
required
string

Workspace identifier

Example: Asperiores iure voluptates est molestiae perferendis et.
query Parameters
limit
integer <int64> [ 1 .. 1000 ]
Default: 30

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

Example: limit=30
page
integer <int64> >= 1
Default: 1

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

Example: page=1
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: 9
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/pipelines
Request samples
Response samples
application/json
{
  • "account": "5fj",
  • "org": "n13",
  • "pipelines": [
    ],
  • "project": "ari"
}

Create remote execution

Create a remote execution for a workspace.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: 0yf
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: n
workspace
required
string

The workspace associated with the remote execution.

Example: Voluptate voluptatem ut expedita provident.
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: zy
Request Body schema: application/json
required
object

The arguments supplied to the plan.

Responses
201

Created response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/remote-executions
Request samples
application/json
{
  • "custom_arguments": {
    }
}
Response samples
application/json
{
  • "account": "vt9",
  • "created": 4049154488295601000,
  • "custom_arguments": {
    },
  • "executed": false,
  • "id": "453fbbb3-2b72-4371-b567-cf507dca2749",
  • "org": "xo",
  • "pipeline_execution_id": "Praesentium ducimus vitae rem culpa accusamus.",
  • "pipeline_execution_url": "Qui aliquid molestias.",
  • "project": "j2e",
  • "sha256_checksum": "Vero quasi.",
  • "updated": 4067837438472890400,
  • "workspace": "Porro quibusdam similique ipsum pariatur laboriosam."
}

Show remote execution

Find remote execution

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: hf
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: k
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Sint harum amet veritatis optio id.
id
required
string <uuid>

The ID of the remote execution

Example: 8a0fa6f7-9fd4-44eb-b1a9-d670f74f3135
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: tk
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/remote-executions/{id}
Request samples
Response samples
application/json
{
  • "account": "ha",
  • "created": 58454111637659780,
  • "custom_arguments": {
    },
  • "executed": false,
  • "id": "ab5028ff-063a-4a30-b344-9f02df57c6d4",
  • "org": "c",
  • "pipeline_execution_id": "Cumque aliquam placeat ut saepe.",
  • "pipeline_execution_url": "Et distinctio iure animi facilis.",
  • "project": "hg",
  • "sha256_checksum": "Sit molestias.",
  • "updated": 1524913541778651600,
  • "workspace": "Quia et provident molestiae."
}

Download remote exectution

Download the source code for the remote plan.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: yx5
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: bc
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Est eos eaque non voluptas.
id
required
string <uuid>

The ID of the remote execution

Example: 202b10ae-847f-456b-b963-7595020aa47c
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: i
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/remote-executions/{id}/download
Request samples
Response samples
application/json
"string"

execute-remote-execution workspaces

Execute the remote execution

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: ahc
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: 1kr
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Et beatae perspiciatis qui et repellendus.
id
required
string <uuid>

The ID of the remote execution

Example: af82d217-2f18-49d6-97e3-420437fc78bd
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: gd
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/remote-executions/{id}/execute
Request samples
Response samples
application/json
{
  • "account": "ts",
  • "created": 2922382896646483500,
  • "custom_arguments": {
    },
  • "executed": true,
  • "id": "41869a8d-fec6-49b1-8f01-1a48f6aff809",
  • "org": "q0",
  • "pipeline_execution_id": "Adipisci ratione nemo odio ipsum aspernatur.",
  • "pipeline_execution_url": "Veniam consequatur quis dignissimos corporis.",
  • "project": "2hu",
  • "sha256_checksum": "Voluptatem sed possimus quis quasi.",
  • "updated": 1605532457460987000,
  • "workspace": "Vel suscipit et qui."
}

Upload remote execution source

Upload the source code for the remote execution.

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: tek
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: yi5
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Consectetur eius facere quam.
id
required
string <uuid>

The ID of the remote execution

Example: 241cfe9b-ef28-4869-bb0f-6d40c5d682d4
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: 5v
Content-Length
integer <int64>

Size in bytes of the source code.

Example: 6070561420762577000
Content-Digest
required
string

Content-Digest header as defined in https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Digest. Sha256 is the only supported algorithm.

Example: Quod sunt quia.
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

post/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/remote-executions/{id}/upload
Request samples
Response samples
application/json
{
  • "account": "ka7",
  • "created": 7980559509712199000,
  • "custom_arguments": {
    },
  • "executed": false,
  • "id": "87c7f5d7-231e-4006-a630-ddf9e3bfb729",
  • "org": "pm",
  • "pipeline_execution_id": "Est eos sit ipsum placeat maxime.",
  • "pipeline_execution_url": "Ipsum ullam tempore adipisci voluptas ea.",
  • "project": "1w",
  • "sha256_checksum": "Debitis pariatur vel ut earum.",
  • "updated": 5835851703595412000,
  • "workspace": "Dolor qui at quas at."
}

List provisioners ratio

Retrieves the ratio of provisioners used by workspaces

Securityx-api-key
Request
path Parameters
org
required
string [ 1 .. 128 ] characters

Org is the organisation identifier.

Example: y
project
required
string [ 1 .. 128 ] characters

Project is the project identifier.

Example: xzy
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: 4
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/orgs/{org}/projects/{project}/workspaces/provisioners-ratio
Request samples
Response samples
application/json
{
  • "provisioner": {
    },
  • "total": 0.8405302200268504
}

List workspaces associated with a template ID

Get all workspaces associated with a specific template ID

Securityx-api-key
Request
path Parameters
template_id
required
string [ 1 .. 128 ] characters

Template identifier to filter workspaces

Example: 8s6
query Parameters
org
string [ 1 .. 128 ] characters

Organization identifier (required for 'org' and 'project' scope).

Example: org=8l2
project
string [ 1 .. 128 ] characters

Project identifier (required for 'project' scope).

Example: project=bn
version
string [ 1 .. 32 ] characters

Template version associated with the workspace.

Example: version=tf
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account identifier.

Example: a5u
Responses
200

OK response.

400

BadRequestError: Bad Request response.

401

UnauthorizedError: Unauthorized response.

403

ForbiddenError: Forbidden response.

404

NotFoundError: Not Found response.

408

TimeoutError: Request Timeout response.

409

ConflictError: Conflict response.

423

LockedError: Locked response.

499

ContextCancelledError: response.

500

InternalServerError: Internal Server Error response.

502

BadGatewayError: Bad Gateway response.

get/iacm/api/workspace/templates/{template_id}
Request samples
Response samples
application/json
[
  • {
    },
  • {
    },
  • {
    },
  • {
    }
]