Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Creates a self-service action.
Synopsis
- data CreateServiceAction = CreateServiceAction' {}
- newCreateServiceAction :: Text -> ServiceActionDefinitionType -> Text -> CreateServiceAction
- createServiceAction_acceptLanguage :: Lens' CreateServiceAction (Maybe Text)
- createServiceAction_description :: Lens' CreateServiceAction (Maybe Text)
- createServiceAction_name :: Lens' CreateServiceAction Text
- createServiceAction_definitionType :: Lens' CreateServiceAction ServiceActionDefinitionType
- createServiceAction_definition :: Lens' CreateServiceAction (HashMap ServiceActionDefinitionKey Text)
- createServiceAction_idempotencyToken :: Lens' CreateServiceAction Text
- data CreateServiceActionResponse = CreateServiceActionResponse' {}
- newCreateServiceActionResponse :: Int -> CreateServiceActionResponse
- createServiceActionResponse_serviceActionDetail :: Lens' CreateServiceActionResponse (Maybe ServiceActionDetail)
- createServiceActionResponse_httpStatus :: Lens' CreateServiceActionResponse Int
Creating a Request
data CreateServiceAction Source #
See: newCreateServiceAction
smart constructor.
CreateServiceAction' | |
|
Instances
newCreateServiceAction Source #
Create a value of CreateServiceAction
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:acceptLanguage:CreateServiceAction'
, createServiceAction_acceptLanguage
- The language code.
en
- English (default)jp
- Japanesezh
- Chinese
$sel:description:CreateServiceAction'
, createServiceAction_description
- The self-service action description.
$sel:name:CreateServiceAction'
, createServiceAction_name
- The self-service action name.
$sel:definitionType:CreateServiceAction'
, createServiceAction_definitionType
- The service action definition type. For example, SSM_AUTOMATION
.
$sel:definition:CreateServiceAction'
, createServiceAction_definition
- The self-service action definition. Can be one of the following:
- Name
- The name of the AWS Systems Manager document (SSM document). For
example,
AWS-RestartEC2Instance
.If you are using a shared SSM document, you must provide the ARN instead of the name.
- Version
- The AWS Systems Manager automation document version. For example,
"Version": "1"
- AssumeRole
- The Amazon Resource Name (ARN) of the role that performs the
self-service actions on your behalf. For example,
"AssumeRole": "arn:aws:iam::12345678910:role/ActionRole"
.To reuse the provisioned product launch role, set to
"AssumeRole": "LAUNCH_ROLE"
. - Parameters
- The list of parameters in JSON format.
For example:
[{\"Name\":\"InstanceId\",\"Type\":\"TARGET\"}]
or[{\"Name\":\"InstanceId\",\"Type\":\"TEXT_VALUE\"}]
.
$sel:idempotencyToken:CreateServiceAction'
, createServiceAction_idempotencyToken
- A unique identifier that you provide to ensure idempotency. If multiple
requests differ only by the idempotency token, the same response is
returned for each repeated request.
Request Lenses
createServiceAction_acceptLanguage :: Lens' CreateServiceAction (Maybe Text) Source #
The language code.
en
- English (default)jp
- Japanesezh
- Chinese
createServiceAction_description :: Lens' CreateServiceAction (Maybe Text) Source #
The self-service action description.
createServiceAction_name :: Lens' CreateServiceAction Text Source #
The self-service action name.
createServiceAction_definitionType :: Lens' CreateServiceAction ServiceActionDefinitionType Source #
The service action definition type. For example, SSM_AUTOMATION
.
createServiceAction_definition :: Lens' CreateServiceAction (HashMap ServiceActionDefinitionKey Text) Source #
The self-service action definition. Can be one of the following:
- Name
- The name of the AWS Systems Manager document (SSM document). For
example,
AWS-RestartEC2Instance
.If you are using a shared SSM document, you must provide the ARN instead of the name.
- Version
- The AWS Systems Manager automation document version. For example,
"Version": "1"
- AssumeRole
- The Amazon Resource Name (ARN) of the role that performs the
self-service actions on your behalf. For example,
"AssumeRole": "arn:aws:iam::12345678910:role/ActionRole"
.To reuse the provisioned product launch role, set to
"AssumeRole": "LAUNCH_ROLE"
. - Parameters
- The list of parameters in JSON format.
For example:
[{\"Name\":\"InstanceId\",\"Type\":\"TARGET\"}]
or[{\"Name\":\"InstanceId\",\"Type\":\"TEXT_VALUE\"}]
.
createServiceAction_idempotencyToken :: Lens' CreateServiceAction Text Source #
A unique identifier that you provide to ensure idempotency. If multiple requests differ only by the idempotency token, the same response is returned for each repeated request.
Destructuring the Response
data CreateServiceActionResponse Source #
See: newCreateServiceActionResponse
smart constructor.
CreateServiceActionResponse' | |
|
Instances
newCreateServiceActionResponse Source #
Create a value of CreateServiceActionResponse
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:serviceActionDetail:CreateServiceActionResponse'
, createServiceActionResponse_serviceActionDetail
- An object containing information about the self-service action.
$sel:httpStatus:CreateServiceActionResponse'
, createServiceActionResponse_httpStatus
- The response's http status code.
Response Lenses
createServiceActionResponse_serviceActionDetail :: Lens' CreateServiceActionResponse (Maybe ServiceActionDetail) Source #
An object containing information about the self-service action.
createServiceActionResponse_httpStatus :: Lens' CreateServiceActionResponse Int Source #
The response's http status code.