Retrieves information about a Domain.
Parameters:
-
domain_id
(DomainId)
–
The id of the Domain to get
Raises:
Source code in docs_src/capo_connecthealth/_services/async_connect_health.py
| async def get_domain(
self,
domain_id: "capo_connecthealth.types.domain_id.DomainId",
*,
config_overrides: Optional[AsyncConnectHealthClientConfig] = None,
) -> "capo_connecthealth.types.get_domain_output.GetDomainOutput":
"""<p>Retrieves information about a Domain.</p>
Args:
domain_id: <p>The id of the Domain to get</p>
Raises:
capo_connecthealth.errors.resource_not_found_exception.ResourceNotFoundException: <p>This error is thrown when the requested resource is not found.</p>
capo_connecthealth.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_connecthealth.types.get_domain_input.GetDomainInput]",
) -> AsyncOperationResponse[
"capo_connecthealth.types.get_domain_output.GetDomainOutput"
]:
import capo_connecthealth._operations.connect_health.get_domain
(
output,
http_response,
) = await capo_connecthealth._operations.connect_health.get_domain.async_get_domain(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("GetDomain")
)
input_: capo_connecthealth.types.get_domain_input.GetDomainInput = {
"domain_id": domain_id
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|