Skip to content

Select a set of resources from an organization.

GET
/v1/resources/{org_uuid}

Select a set of resources from an organization.

Authorizations

apiKey

API key as username in Basic Authorization with
empty password.

TypeAPI Key (header: Authorization)
or
jwtToken
TypeHTTP (bearer)

Parameters

Path Parameters

org_uuid*

UUID of the organization

Typestring
Required
format"uuid"

Query Parameters

page

Page number to return

Typeinteger
Example1
format"int64"
minimum1
per_page

Number of elements per page

Typeinteger
format"int64"
minimum1
default10
sort

Resources are sorted with updated_at by default.

Available sorts are:

  • created_at[,(asc|desc)
  • extracted_account[,(asc|desc)]
  • extracted_name[,(asc|desc)]
  • path[,(asc|desc)]
  • policy_severity
  • provider[,(asc|desc)]
  • repository[,(asc|desc)]
  • status[,(asc|desc)]
  • target[,(asc|desc)]
  • technology[,(asc|desc)]
  • type[,(asc|desc)]
  • updated_at[,(desc|asc)
Typearray
Example{ "UpdatedAtDescPathDescExample": { "Value": [ "updated_at,asc", "path,desc" ] } }
status

Only select resources with these statuses.

Typearray
Example{ "OKOrDriftedExample": { "value": [ "ok", "drifted" ] } }
technology

Only select resources with these technologies.

Typearray
Example{ "TerraformOrOpenTofuExample": { "value": [ "terraform", "opentofu" ] } }
provider

Only select resources with these providers.

Typearray
Example{ "AWSOrGcloudExample": { "value": [ "aws", "gcloud" ] } }
type

Only select resources with these types.

Typearray
Example{ "VPCOrLoadBalancerExample": { "value": [ "vpc", "loadbalancer" ] } }
repository

Only select entities whose repository matches any
of the strings in the provided array. Only full strings will
be matched.

Typearray
target

Only select entities whose deployment target matches any
of the strings in the provided array. Only full strings will
be matched.

Typearray
extracted_account

Only select resources with these accounts.

Typearray
stack_id

Only select entities whose stack id matches the given value.

Typeinteger
format"int64"
is_archived

true - Only select entities that are archived.
false - Only select entities that are not archived (default).
true,false - Select all entities.

Typearray
Example{ "AllPossibleValues": { "value": [ true, false ] } }
policy_severity

Only select entities that have specific policy check results.
Available options:

  • missing: No analysis data available.
  • none: No checks defined for the entity.
  • passed: Entity has no violations.
  • low: Entity has violations with low severity.
  • medium: Entity has violations with medium severity.
  • high: Entity has violations with high severity.
Typearray
search

Select resource where the following attributes match the provided
search query. Match is done using case-insensitive regular
expression search. If string contains a comma or spaces all terms will be
searched and matched. The following attributes will be searched:

  • stack title, description, path
  • resource extracted name, extracted id, address
Typestring
Example"stackTitle"

Responses

OK

application/json
JSON
{
"resources": [
{
"resource_uuid": "f1c9ecfe-1a45-499b-ab6d-1aa0a8ea2f95",
"stack": {
"stack_id": 1337,
"repository": "github.com/terramate-io/iac-gcloud",
"target": "staging",
"path": "/path/to/stack",
"default_branch": "main",
"meta_id": "a754255a-c92a-4aeb-9668-bd3ce21dc8a2",
"meta_name": "My Stack Name",
"meta_description": "My Stack Description",
"meta_tags": [
[
"tagA",
"tagB"
]
],
"status": "string",
"created_at": "string",
"updated_at": "string",
"seen_at": "string",
"is_archived": true,
"archived_at": "string",
"archived_by_user_uuid": "string",
"unarchived_at": "string",
"unarchived_by_user_uuid": "string",
"deployment_status": "string",
"drift_status": "string",
"draft": true,
"related_stacks": [
{
"stack_id": 0,
"target": "string"
}
],
"resources": {
"count": 42,
"policy_check": {
"created_at": "2024-09-12T07:06:00Z",
"passed": false,
"counters": {
"passed_count": 42,
"severity_low_count": 3,
"severity_medium_count": 2,
"severity_high_count": 1
}
}
}
},
"provisioner": "string",
"descriptor": {
"address": "string",
"mode": "string",
"type": "string",
"name": "string",
"index": "string",
"provider_name": "string",
"extracted_id": "string",
"extracted_name": "string",
"extracted_account": "string",
"schema_version": 0,
"depends_on": [
"string"
],
"tainted": true,
"deposed_key": "string"
},
"details": {
"values": "string",
"sensitive_values": "string"
},
"status": "string",
"drifted": true,
"pending": true,
"created_at": "2024-04-12T07:06:00Z",
"updated_at": "2024-04-15T11:05:00Z",
"policy_check": {
"created_at": "2024-09-12T07:06:00Z",
"passed": false,
"start_violated_at": "2024-09-12T05:06:00Z",
"counters": {
"passed_count": 42,
"severity_low_count": 3,
"severity_medium_count": 2,
"severity_high_count": 1
}
}
}
],
"paginated_result": {
"total": 0,
"page": 0,
"per_page": 0
}
}

Playground

Authorization
Variables
Key
Value

Samples

Powered by VitePress OpenAPI