Skip to content

describe_gateway_information async

describe_gateway_information(
    gateway_arn: GatewayARN,
    *,
    config_overrides: Optional[AsyncStorageGatewayClientConfig] = None,
) -> DescribeGatewayInformationOutput

Returns metadata about a gateway such as its name, network interfaces, time zone, status, and software version. To specify which gateway to describe, use the Amazon Resource Name (ARN) of the gateway in your request.

Raises:

  • InternalServerError –

    An internal server error has occurred during the request. For more information, see the error and message fields.

  • InvalidGatewayRequestException –

    An exception occurred because an invalid gateway request was issued to the service. For more information, see the error and message fields.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Examples:

To describe metadata about the gateway Returns metadata about a gateway such as its name, network interfaces, configured time zone, and the state (whether the gateway is running or not).

>>> await client.describe_gateway_information(gateway_arn='arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B')
Source code in docs_src/capo_storage_gateway/_services/async_storage_gateway.py
async def describe_gateway_information(
    self,
    gateway_arn: "capo_storage_gateway.types.gateway_arn.GatewayARN",
    *,
    config_overrides: Optional[AsyncStorageGatewayClientConfig] = None,
) -> "capo_storage_gateway.types.describe_gateway_information_output.DescribeGatewayInformationOutput":
    """<p>Returns metadata about a gateway such as its name, network interfaces, time zone, status, and software version. To specify which gateway to describe, use the Amazon Resource Name (ARN) of the gateway in your request.</p>

    Raises:
        capo_storage_gateway.errors.internal_server_error.InternalServerError: <p>An internal server error has occurred during the request. For more information, see the error and message fields.</p>
        capo_storage_gateway.errors.invalid_gateway_request_exception.InvalidGatewayRequestException: <p>An exception occurred because an invalid gateway request was issued to the service. For more information, see the error and message fields.</p>
        capo_storage_gateway.errors.UnknownServiceError: The service returned an error code this client does not model.

    Examples:
        To describe metadata about the gateway
        Returns metadata about a gateway such as its name, network interfaces, configured time zone, and the state (whether the gateway is running or not).

        >>> await client.describe_gateway_information(gateway_arn='arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B')
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_storage_gateway.types.describe_gateway_information_input.DescribeGatewayInformationInput]",
    ) -> AsyncOperationResponse[
        "capo_storage_gateway.types.describe_gateway_information_output.DescribeGatewayInformationOutput"
    ]:
        import capo_storage_gateway._operations.storage_gateway_20130630.describe_gateway_information

        (
            output,
            http_response,
        ) = await capo_storage_gateway._operations.storage_gateway_20130630.describe_gateway_information.async_describe_gateway_information(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_output(
        output: "capo_storage_gateway.types.describe_gateway_information_output.DescribeGatewayInformationOutput",
    ) -> dict[str, Any]:
        import capo_storage_gateway.types.describe_gateway_information_output

        return capo_storage_gateway.types.describe_gateway_information_output.redact_sensitive(
            output
        )

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging(
            "DescribeGatewayInformation", redact_output=_redact_output
        ),
    )
    input_: capo_storage_gateway.types.describe_gateway_information_input.DescribeGatewayInformationInput = {
        "gateway_arn": gateway_arn
    }

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output