- [Resource: AffectedResource](https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/projects.locations.experiments.affectedResources#AffectedResource)
  - [JSON representation](https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/projects.locations.experiments.affectedResources#AffectedResource.SCHEMA_REPRESENTATION)
- [Methods](https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/projects.locations.experiments.affectedResources#METHODS_SUMMARY)

## Resource: AffectedResource

Represents a specific Google Cloud resource, like a virtual machine or database that is targeted by an experiment.

| JSON representation |
|---|
| ``` { "name": string, "displayName": string, "affectedResourceUri": string, "cloudConsolePath": string, "state": enum (`https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/State`), "stateMessage": string, "error": { object (`https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/Status`) } } ``` |

| Fields ||
|---|---|
| `name` | `string` Identifier. Unique identifier for this record, linking it to a specific experiment and resource. Format: `projects/{projectId}/locations/{location}/experiments/{experimentId}/affectedResources/{affected_resource_id}`. |
| `displayName` | `string` Optional. A human-readable name for the affected resource record. |
| `affectedResourceUri` | `string` Required. The full unique address (URI) of the Google Cloud resource affected by this `Experiment`. Example: the full path to a specific Compute Engine instance. |
| `cloudConsolePath` | `string` Output only. A direct link to view this specific resource in the Google Cloud Console. |
| `state` | ``enum (`https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/State`)`` The current state of this resource within the experiment. Example: `PREPARING`, `INJECTED`, `COMPLETED`. |
| `stateMessage` | `string` A plain-language explanation of what is currently happening with this resource in the experiment. |
| `error` | ``object (`https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/Status`)`` Output only. Details of any error that occurred while setting up, running, or stopping the experiment on this specific resource. Empty if no errors occurred. |

| ## Methods ||
|---|---|
| ### `https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/projects.locations.experiments.affectedResources/get` | Gets the details of a specific cloud resource that is being or was affected by a particular `Experiment`. |
| ### `https://docs.cloud.google.com/fault-injection-testing/reference/rest/v1alpha/projects.locations.experiments.affectedResources/list` | Lists all cloud resources that are being or were affected by a specific `Experiment`. |