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

List resources

List resources associated with this workspace.

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

Org is the organisation identifier.

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

Project is the project identifier.

Example: 8qh
identifierstring · min: 1 · max: 128Required

Workspace identifier.

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

Limit is the number of records to return for a page. When omitted, all records are returned.

Example: 30
pageinteger · int64 · min: 1Optional

Page is the page number to return relative to the page 'limit'. When omitted, all records are returned.

Example: 1
resource_typesstring[]Optional

Resource types to filter by.

Example: ["aws_instance","google_compute_instance"]
Header parameters
Harness-Accountstring · min: 1 · max: 128Required

Account is the internal customer account ID.

Example: 1ui
Responses
200

OK response.

application/json
get/api/orgs/{org}/projects/{project}/workspaces/{identifier}/resources
GET /api/orgs/{org}/projects/{project}/workspaces/{identifier}/resources HTTP/1.1
Host: localhost:80
Harness-Account: 1ui
Accept: */*
{
  "data_sources": [
    {
      "attributes": {
        "ami": "ami-830c94ec",
        "instance_type": "t2.micro"
      },
      "createdAt": 1627590400,
      "drift_attributes": {
        "instance_type": "t2.nano"
      },
      "drift_status": "changed",
      "lastSyncedAt": 1627686800,
      "mode": "resource",
      "module": "full_stack",
      "monthly_cost": 0.9995936961087005,
      "monthly_saving": 0.27447037863630724,
      "name": "app_server",
      "path_id": "namespace",
      "provider": "AWS",
      "recommendation_count": 1522403799392944600,
      "resource_id": "arn:aws:s3:::my-bucket",
      "sensitive_attributes": [
        "instance_type"
      ],
      "type": "S3 Bucket"
    },
    {
      "attributes": {
        "ami": "ami-830c94ec",
        "instance_type": "t2.micro"
      },
      "createdAt": 1627590400,
      "drift_attributes": {
        "instance_type": "t2.nano"
      },
      "drift_status": "changed",
      "lastSyncedAt": 1627686800,
      "mode": "resource",
      "module": "full_stack",
      "monthly_cost": 0.9995936961087005,
      "monthly_saving": 0.27447037863630724,
      "name": "app_server",
      "path_id": "namespace",
      "provider": "AWS",
      "recommendation_count": 1522403799392944600,
      "resource_id": "arn:aws:s3:::my-bucket",
      "sensitive_attributes": [
        "instance_type"
      ],
      "type": "S3 Bucket"
    },
    {
      "attributes": {
        "ami": "ami-830c94ec",
        "instance_type": "t2.micro"
      },
      "createdAt": 1627590400,
      "drift_attributes": {
        "instance_type": "t2.nano"
      },
      "drift_status": "changed",
      "lastSyncedAt": 1627686800,
      "mode": "resource",
      "module": "full_stack",
      "monthly_cost": 0.9995936961087005,
      "monthly_saving": 0.27447037863630724,
      "name": "app_server",
      "path_id": "namespace",
      "provider": "AWS",
      "recommendation_count": 1522403799392944600,
      "resource_id": "arn:aws:s3:::my-bucket",
      "sensitive_attributes": [
        "instance_type"
      ],
      "type": "S3 Bucket"
    }
  ],
  "outputs": [
    {
      "expression": "<+outputs.instance_id>",
      "name": "instance_public_ip",
      "sensitive": true,
      "stack_path": "IaCM/TGOverride/environments/dev/ec2",
      "value": "Et eos error."
    },
    {
      "expression": "<+outputs.instance_id>",
      "name": "instance_public_ip",
      "sensitive": true,
      "stack_path": "IaCM/TGOverride/environments/dev/ec2",
      "value": "Et eos error."
    },
    {
      "expression": "<+outputs.instance_id>",
      "name": "instance_public_ip",
      "sensitive": true,
      "stack_path": "IaCM/TGOverride/environments/dev/ec2",
      "value": "Et eos error."
    }
  ],
  "resources": [
    {
      "attributes": {
        "ami": "ami-830c94ec",
        "instance_type": "t2.micro"
      },
      "createdAt": 1627590400,
      "drift_attributes": {
        "instance_type": "t2.nano"
      },
      "drift_status": "changed",
      "lastSyncedAt": 1627686800,
      "mode": "resource",
      "module": "full_stack",
      "monthly_cost": 0.9995936961087005,
      "monthly_saving": 0.27447037863630724,
      "name": "app_server",
      "path_id": "namespace",
      "provider": "AWS",
      "recommendation_count": 1522403799392944600,
      "resource_id": "arn:aws:s3:::my-bucket",
      "sensitive_attributes": [
        "instance_type"
      ],
      "type": "S3 Bucket"
    },
    {
      "attributes": {
        "ami": "ami-830c94ec",
        "instance_type": "t2.micro"
      },
      "createdAt": 1627590400,
      "drift_attributes": {
        "instance_type": "t2.nano"
      },
      "drift_status": "changed",
      "lastSyncedAt": 1627686800,
      "mode": "resource",
      "module": "full_stack",
      "monthly_cost": 0.9995936961087005,
      "monthly_saving": 0.27447037863630724,
      "name": "app_server",
      "path_id": "namespace",
      "provider": "AWS",
      "recommendation_count": 1522403799392944600,
      "resource_id": "arn:aws:s3:::my-bucket",
      "sensitive_attributes": [
        "instance_type"
      ],
      "type": "S3 Bucket"
    },
    {
      "attributes": {
        "ami": "ami-830c94ec",
        "instance_type": "t2.micro"
      },
      "createdAt": 1627590400,
      "drift_attributes": {
        "instance_type": "t2.nano"
      },
      "drift_status": "changed",
      "lastSyncedAt": 1627686800,
      "mode": "resource",
      "module": "full_stack",
      "monthly_cost": 0.9995936961087005,
      "monthly_saving": 0.27447037863630724,
      "name": "app_server",
      "path_id": "namespace",
      "provider": "AWS",
      "recommendation_count": 1522403799392944600,
      "resource_id": "arn:aws:s3:::my-bucket",
      "sensitive_attributes": [
        "instance_type"
      ],
      "type": "S3 Bucket"
    }
  ],
  "stack_outputs": {
    "IaCM/TGOverride/environments/dev/ec2": [
      {
        "name": "instance_id",
        "sensitive": false,
        "stack_path": "IaCM/TGOverride/environments/dev/ec2",
        "value": "i-1234567890abcdef0"
      }
    ]
  },
  "total_resources": 42
}

Last updated

Was this helpful?