create_service_action
async
¶
create_service_action(
name: ServiceActionName,
definition_type: ServiceActionDefinitionType,
definition: ServiceActionDefinitionMap,
idempotency_token: IdempotencyToken,
*,
config_overrides: Optional[AsyncServiceCatalogClientConfig] = None,
description: Optional[ServiceActionDescription] = None,
accept_language: Optional[AcceptLanguage] = None,
) -> CreateServiceActionOutput
Creates a self-service action.
Parameters:
-
name(ServiceActionName) –The self-service action name.
-
definition_type(ServiceActionDefinitionType) –The service action definition type. For example,
SSM_AUTOMATION. -
definition(ServiceActionDefinitionMap) –The self-service action definition. Can be one of the following:
- Name
-
The name of the Amazon Web Services 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 Amazon Web Services 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\"}].
-
description(Optional[ServiceActionDescription], default:None) –The self-service action description.
-
accept_language(Optional[AcceptLanguage], default:None) –The language code.
-
jp- Japanese -
zh- Chinese
-
-
idempotency_token(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.
Raises:
-
InvalidParametersException–One or more parameters provided to the operation are not valid.
-
LimitExceededException–The current limits of the service would have been exceeded by this operation. Decrease your resource use or increase your service limits and retry the operation.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_service_catalog/_services/async_service_catalog.py
1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 | |