variables

Variables Service handles the API for managing workspace variables.

list-variables variables

List all workspace variables.

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: w
workspace
required
string

Workspace is the resource workspace this variable is associated with.

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

Account is the internal customer account ID.

Example: k
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}/variables
Request samples
Response samples
application/json
[
  • {
    },
  • {
    },
  • {
    }
]

create-variable variables

Creates a new workspace variable

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: s
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Et nihil cum.
header Parameters
Harness-Account
required
string [ 1 .. 128 ] characters

Account is the internal customer account ID.

Example: t
Request Body schema: application/json
required
key
required
string [ 1 .. 128 ] characters ^[a-zA-Z0-9_]+$

Key is the identifier for the secret.

kind
required
string

Kind is the classfcation of the variable.

Enum: "env" "tf"
value
required
string

Value is the value of the secret.

value_type
required
string

Type indecates the value type of the secret. In the case of secret this is a reference to an item in the secret store

Enum: "string" "secret"
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}/variables
Request samples
application/json
{
  • "key": "isl",
  • "kind": "env",
  • "value": "Voluptatem optio et.",
  • "value_type": "string"
}
Response samples
application/json
{
  • "account": "tp",
  • "created": 8662245035287341000,
  • "key": "ie",
  • "kind": "tf",
  • "org": "zv",
  • "policy_evaluation": {
    },
  • "project": "sj",
  • "updated": 3546039204857170400,
  • "value": "Velit rem velit aut ut sit.",
  • "value_type": "secret",
  • "workspace": "Laborum modi voluptate repellendus blanditiis repudiandae ipsum."
}

destroy-variable variables

Deletes the given workspace variable.

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: iu
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Ut natus.
kind
required
string

Kind is the classfcation of the variable.

Enum: "env" "tf"
Example: tf
key
required
string [ 1 .. 128 ] characters ^[a-zA-Z0-9_]+$

Key is the identifier for the secret.

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

Account is the internal customer account ID.

Example: 5
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.

delete/iacm/api/orgs/{org}/projects/{project}/workspaces/{workspace}/variables/{kind}/{key}
Request samples
Response samples
application/json
{
  • "policy_evaluation": {
    }
}

show-variable variables

Show an individual workspace variable.

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: v
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Et et minus voluptate non consequatur.
kind
required
string

Kind is the classfcation of the variable.

Enum: "env" "tf"
Example: tf
key
required
string [ 1 .. 128 ] characters ^[a-zA-Z0-9_]+$

Key is the identifier for the secret.

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

Account is the internal customer account ID.

Example: z
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}/variables/{kind}/{key}
Request samples
Response samples
application/json
{
  • "account": "x",
  • "created": 8431017123773719000,
  • "key": "a2",
  • "kind": "tf",
  • "org": "wnu",
  • "project": "wnh",
  • "updated": 4186553836383613000,
  • "value": "Dolorem eius corporis cumque harum.",
  • "value_type": "string",
  • "workspace": "Delectus quia."
}

update-variable variables

Updates the given workspace variable with new info.

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: 0na
workspace
required
string

Workspace is the resource workspace this variable is associated with.

Example: Voluptas vitae.
kind
required
string

Kind is the classfcation of the variable.

Enum: "env" "tf"
Example: tf
key
required
string [ 1 .. 128 ] characters ^[a-zA-Z0-9_]+$

Key is the identifier for the secret.

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

Account is the internal customer account ID.

Example: klk
Request Body schema: application/json
required
value
required
string

Value is the value of the secret.

value_type
required
string

Type indecates the value type of the secret. In the case of secret this is a reference to an item in the secret store

Enum: "string" "secret"
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/{workspace}/variables/{kind}/{key}
Request samples
application/json
{
  • "value": "Sit ut eius inventore.",
  • "value_type": "secret"
}
Response samples
application/json
{
  • "policy_evaluation": {
    }
}