Copyright | (c) 2013-2023 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Amazonka.CloudControl.GetResource
Description
Returns information about the current state of the specified resource. For details, see Reading a resource's current state.
You can use this action to return information about an existing resource in your account and Amazon Web Services Region, whether those resources were provisioned using Cloud Control API.
Synopsis
- data GetResource = GetResource' {
- roleArn :: Maybe Text
- typeVersionId :: Maybe Text
- typeName :: Text
- identifier :: Text
- newGetResource :: Text -> Text -> GetResource
- getResource_roleArn :: Lens' GetResource (Maybe Text)
- getResource_typeVersionId :: Lens' GetResource (Maybe Text)
- getResource_typeName :: Lens' GetResource Text
- getResource_identifier :: Lens' GetResource Text
- data GetResourceResponse = GetResourceResponse' {}
- newGetResourceResponse :: Int -> GetResourceResponse
- getResourceResponse_resourceDescription :: Lens' GetResourceResponse (Maybe ResourceDescription)
- getResourceResponse_typeName :: Lens' GetResourceResponse (Maybe Text)
- getResourceResponse_httpStatus :: Lens' GetResourceResponse Int
Creating a Request
data GetResource Source #
See: newGetResource
smart constructor.
Constructors
GetResource' | |
Fields
|
Instances
Arguments
:: Text | |
-> Text | |
-> GetResource |
Create a value of GetResource
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:roleArn:GetResource'
, getResource_roleArn
- The Amazon Resource Name (ARN) of the Identity and Access Management
(IAM) role for Cloud Control API to use when performing this resource
operation. The role specified must have the permissions required for
this operation. The necessary permissions for each event handler are
defined in the
handlers
section of the
resource type definition schema.
If you do not specify a role, Cloud Control API uses a temporary session created using your Amazon Web Services user credentials.
For more information, see Specifying credentials in the Amazon Web Services Cloud Control API User Guide.
$sel:typeVersionId:GetResource'
, getResource_typeVersionId
- For private resource types, the type version to use in this resource
operation. If you do not specify a resource version, CloudFormation uses
the default version.
GetResource
, getResource_typeName
- The name of the resource type.
GetResource
, getResource_identifier
- The identifier for the resource.
You can specify the primary identifier, or any secondary identifier defined for the resource type in its resource schema. You can only specify one identifier. Primary identifiers can be specified as a string or JSON; secondary identifiers must be specified as JSON.
For compound primary identifiers (that is, one that consists of multiple
resource properties strung together), to specify the primary identifier
as a string, list the property values in the order they are specified
in the primary identifier definition, separated by |
.
For more information, see Identifying resources in the Amazon Web Services Cloud Control API User Guide.
Request Lenses
getResource_roleArn :: Lens' GetResource (Maybe Text) Source #
The Amazon Resource Name (ARN) of the Identity and Access Management
(IAM) role for Cloud Control API to use when performing this resource
operation. The role specified must have the permissions required for
this operation. The necessary permissions for each event handler are
defined in the
handlers
section of the
resource type definition schema.
If you do not specify a role, Cloud Control API uses a temporary session created using your Amazon Web Services user credentials.
For more information, see Specifying credentials in the Amazon Web Services Cloud Control API User Guide.
getResource_typeVersionId :: Lens' GetResource (Maybe Text) Source #
For private resource types, the type version to use in this resource operation. If you do not specify a resource version, CloudFormation uses the default version.
getResource_typeName :: Lens' GetResource Text Source #
The name of the resource type.
getResource_identifier :: Lens' GetResource Text Source #
The identifier for the resource.
You can specify the primary identifier, or any secondary identifier defined for the resource type in its resource schema. You can only specify one identifier. Primary identifiers can be specified as a string or JSON; secondary identifiers must be specified as JSON.
For compound primary identifiers (that is, one that consists of multiple
resource properties strung together), to specify the primary identifier
as a string, list the property values in the order they are specified
in the primary identifier definition, separated by |
.
For more information, see Identifying resources in the Amazon Web Services Cloud Control API User Guide.
Destructuring the Response
data GetResourceResponse Source #
See: newGetResourceResponse
smart constructor.
Constructors
GetResourceResponse' | |
Fields
|
Instances
newGetResourceResponse Source #
Arguments
:: Int | |
-> GetResourceResponse |
Create a value of GetResourceResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:resourceDescription:GetResourceResponse'
, getResourceResponse_resourceDescription
- Undocumented member.
GetResource
, getResourceResponse_typeName
- The name of the resource type.
$sel:httpStatus:GetResourceResponse'
, getResourceResponse_httpStatus
- The response's http status code.
Response Lenses
getResourceResponse_resourceDescription :: Lens' GetResourceResponse (Maybe ResourceDescription) Source #
Undocumented member.
getResourceResponse_typeName :: Lens' GetResourceResponse (Maybe Text) Source #
The name of the resource type.
getResourceResponse_httpStatus :: Lens' GetResourceResponse Int Source #
The response's http status code.