async def batch_associate_service_action_with_provisioning_artifact(
self,
service_action_associations: "capo_service_catalog.types.service_action_associations.ServiceActionAssociations",
*,
config_overrides: Optional[AsyncServiceCatalogClientConfig] = None,
accept_language: Optional[
"capo_service_catalog.types.accept_language.AcceptLanguage"
] = None,
) -> "capo_service_catalog.types.batch_associate_service_action_with_provisioning_artifact_output.BatchAssociateServiceActionWithProvisioningArtifactOutput":
"""<p>Associates multiple self-service actions with provisioning artifacts.</p>
Args:
service_action_associations: <p>One or more associations, each consisting of the Action ID, the Product ID, and the Provisioning Artifact ID.</p>
accept_language: <p>The language code.</p> <ul> <li> <p> <code>jp</code> - Japanese</p> </li> <li> <p> <code>zh</code> - Chinese</p> </li> </ul>
Raises:
capo_service_catalog.errors.invalid_parameters_exception.InvalidParametersException: <p>One or more parameters provided to the operation are not valid.</p>
capo_service_catalog.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_service_catalog.types.batch_associate_service_action_with_provisioning_artifact_input.BatchAssociateServiceActionWithProvisioningArtifactInput]",
) -> AsyncOperationResponse[
"capo_service_catalog.types.batch_associate_service_action_with_provisioning_artifact_output.BatchAssociateServiceActionWithProvisioningArtifactOutput"
]:
if req.options.protocol == "awsJson1_1":
import capo_service_catalog._operations.aws242_service_catalog_service.aws_json1_1.batch_associate_service_action_with_provisioning_artifact
(
output,
http_response,
) = await capo_service_catalog._operations.aws242_service_catalog_service.aws_json1_1.batch_associate_service_action_with_provisioning_artifact.async_batch_associate_service_action_with_provisioning_artifact(
req.options, req.input
)
elif req.options.protocol == "rpcv2Cbor":
import capo_service_catalog._operations.aws242_service_catalog_service.rpcv2_cbor.batch_associate_service_action_with_provisioning_artifact
(
output,
http_response,
) = await capo_service_catalog._operations.aws242_service_catalog_service.rpcv2_cbor.batch_associate_service_action_with_provisioning_artifact.async_batch_associate_service_action_with_provisioning_artifact(
req.options, req.input
)
else:
raise ValueError(f"unknown protocol {req.options.protocol!r}")
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides,
OperationLogging("BatchAssociateServiceActionWithProvisioningArtifact"),
)
input_: capo_service_catalog.types.batch_associate_service_action_with_provisioning_artifact_input.BatchAssociateServiceActionWithProvisioningArtifactInput = {
"service_action_associations": service_action_associations
}
if accept_language is not None:
input_["accept_language"] = accept_language
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output