# Class Resource (0.7.0)

0.7.0 (latest) 0.6.0 0.5.0 0.4.0 0.3.0 0.2.0 0.1.21

    Resource(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Resource represents a Google Cloud Platform resource actuated
by IM. Resources are child resources of Revisions.

| ## Attributes ||
|---|---|
| **Name** | **Description** |
| `name` | `str` Output only. Resource name. Format: `projects/{project}/locations/{location}/deployments/{deployment}/revisions/{revision}/resources/{resource}` |
| `terraform_info` | `https://docs.cloud.google.com/python/docs/reference/config/latest/google.cloud.config_v1.types.ResourceTerraformInfo` Output only. Terraform-specific info if this resource was created using Terraform. |
| `cai_assets` | `MutableMapping[str, https://docs.cloud.google.com/python/docs/reference/config/latest/google.cloud.config_v1.types.ResourceCAIInfo]` Output only. Map of Cloud Asset Inventory (CAI) type to CAI info (e.g. CAI ID). CAI type format follows https://cloud.google.com/asset-inventory/docs/supported-asset-types |
| `intent` | `https://docs.cloud.google.com/python/docs/reference/config/latest/google.cloud.config_v1.types.Resource.Intent` Output only. Intent of the resource. |
| `state` | `https://docs.cloud.google.com/python/docs/reference/config/latest/google.cloud.config_v1.types.Resource.State` Output only. Current state of the resource. |

## Classes

### CaiAssetsEntry

    CaiAssetsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)

The abstract base class for a message.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `kwargs` | `dict` Keys and values corresponding to the fields of the message. |
| `mapping` | ``Union[dict, `.Message`]`` A dictionary or message to be used to determine the values for this message. |
| `ignore_unknown_fields` | `Optional(bool)` If True, do not raise errors for unknown fields. Only applied if `mapping` is a mapping type or there are keyword parameters. |

### Intent

    Intent(value)

Possible intent of the resource.

### State

    State(value)

Possible states of a resource.