Retrieves a notify code configuration.
Parameters:
-
notify_code_configuration_id
(NotifyCodeConfigurationIdOrArn)
–
The unique identifier of the notify code configuration. You can specify either the bare ID or the full Amazon Resource Name (ARN).
Raises:
-
AccessDeniedException
–
You do not have sufficient access to perform this action.
-
InternalServerException
–
An unexpected error occurred during the processing of the request.
-
ResourceNotFoundException
–
The request references a resource that does not exist. Verify that the resource identifier is correct and try your request again.
-
ThrottlingException
–
The request was denied because it exceeded the allowed request rate.
-
ValidationException
–
A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
-
UnknownServiceError
–
The service returned an error code this client does not model.
Examples:
Get a notify code configuration
>>> await client.get_notify_code_configuration(notify_code_configuration_id='ncc-abc12345678901234')
Source code in docs_src/capo_endusermessaging/_services/async_end_user_messaging.py
| async def get_notify_code_configuration(
self,
notify_code_configuration_id: "capo_endusermessaging.types.notify_code_configuration_id_or_arn.NotifyCodeConfigurationIdOrArn",
*,
config_overrides: Optional[AsyncEndUserMessagingClientConfig] = None,
) -> "capo_endusermessaging.types.get_notify_code_configuration_output.GetNotifyCodeConfigurationOutput":
"""<p>Retrieves a notify code configuration.</p>
Args:
notify_code_configuration_id: <p>The unique identifier of the notify code configuration. You can specify either the bare ID or the full Amazon Resource Name (ARN).</p>
Raises:
capo_endusermessaging.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient access to perform this action.</p>
capo_endusermessaging.errors.internal_server_exception.InternalServerException: <p>An unexpected error occurred during the processing of the request.</p>
capo_endusermessaging.errors.resource_not_found_exception.ResourceNotFoundException: <p>The request references a resource that does not exist. Verify that the resource identifier is correct and try your request again.</p>
capo_endusermessaging.errors.throttling_exception.ThrottlingException: <p>The request was denied because it exceeded the allowed request rate.</p>
capo_endusermessaging.errors.validation_exception.ValidationException: A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
capo_endusermessaging.errors.UnknownServiceError: The service returned an error code this client does not model.
Examples:
Get a notify code configuration
>>> await client.get_notify_code_configuration(notify_code_configuration_id='ncc-abc12345678901234')
"""
async def _handler(
req: "AsyncOperationRequest[capo_endusermessaging.types.get_notify_code_configuration_input.GetNotifyCodeConfigurationInput]",
) -> AsyncOperationResponse[
"capo_endusermessaging.types.get_notify_code_configuration_output.GetNotifyCodeConfigurationOutput"
]:
import capo_endusermessaging._operations.end_user_messaging.get_notify_code_configuration
(
output,
http_response,
) = await capo_endusermessaging._operations.end_user_messaging.get_notify_code_configuration.async_get_notify_code_configuration(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
def _redact_output(
output: "capo_endusermessaging.types.get_notify_code_configuration_output.GetNotifyCodeConfigurationOutput",
) -> dict[str, Any]:
import capo_endusermessaging.types.get_notify_code_configuration_output
return capo_endusermessaging.types.get_notify_code_configuration_output.redact_sensitive(
output
)
interceptors_, options_ = self.operation_options(
config_overrides,
OperationLogging(
"GetNotifyCodeConfiguration", redact_output=_redact_output
),
)
input_: capo_endusermessaging.types.get_notify_code_configuration_input.GetNotifyCodeConfigurationInput = {
"notify_code_configuration_id": notify_code_configuration_id
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|