Struct aws_sdk_apigateway::client::fluent_builders::ImportRestApi [−][src]
pub struct ImportRestApi<C = DynConnector, M = DefaultMiddleware, R = Standard> { /* fields omitted */ }
Expand description
Fluent builder constructing a request to ImportRestApi
.
A feature of the API Gateway control service for creating a new API from an external API definition file.
Implementations
impl<C, M, R> ImportRestApi<C, M, R> where
C: SmithyConnector,
M: SmithyMiddleware<C>,
R: NewRequestPolicy,
impl<C, M, R> ImportRestApi<C, M, R> where
C: SmithyConnector,
M: SmithyMiddleware<C>,
R: NewRequestPolicy,
pub async fn send(
self
) -> Result<ImportRestApiOutput, SdkError<ImportRestApiError>> where
R::Policy: SmithyRetryPolicy<ImportRestApiInputOperationOutputAlias, ImportRestApiOutput, ImportRestApiError, ImportRestApiInputOperationRetryAlias>,
pub async fn send(
self
) -> Result<ImportRestApiOutput, SdkError<ImportRestApiError>> where
R::Policy: SmithyRetryPolicy<ImportRestApiInputOperationOutputAlias, ImportRestApiOutput, ImportRestApiError, ImportRestApiInputOperationRetryAlias>,
Sends the request and returns the response.
If an error occurs, an SdkError
will be returned with additional details that
can be matched against.
By default, any retryable failures will be retried twice. Retry behavior is configurable with the RetryConfig, which can be set when configuring the client.
A query parameter to indicate whether to rollback the API creation (true
) or not (false
) when a warning is encountered. The default value is false
.
A query parameter to indicate whether to rollback the API creation (true
) or not (false
) when a warning is encountered. The default value is false
.
Adds a key-value pair to parameters
.
To override the contents of this collection use set_parameters
.
A key-value map of context-specific query string parameters specifying the behavior of different API importing operations. The following shows operation-specific parameters and their supported values.
To exclude DocumentationParts
from the import, set parameters
as ignore=documentation
.
To configure the endpoint type, set parameters
as endpointConfigurationTypes=EDGE
, endpointConfigurationTypes=REGIONAL
, or endpointConfigurationTypes=PRIVATE
. The default endpoint type is EDGE
.
To handle imported basepath
, set parameters
as basepath=ignore
, basepath=prepend
or basepath=split
.
For example, the AWS CLI command to exclude documentation from the imported API is:
aws apigateway import-rest-api --parameters ignore=documentation --body 'file:///path/to/imported-api-body.json'
The AWS CLI command to set the regional endpoint on the imported API is:
aws apigateway import-rest-api --parameters endpointConfigurationTypes=REGIONAL --body 'file:///path/to/imported-api-body.json'
A key-value map of context-specific query string parameters specifying the behavior of different API importing operations. The following shows operation-specific parameters and their supported values.
To exclude DocumentationParts
from the import, set parameters
as ignore=documentation
.
To configure the endpoint type, set parameters
as endpointConfigurationTypes=EDGE
, endpointConfigurationTypes=REGIONAL
, or endpointConfigurationTypes=PRIVATE
. The default endpoint type is EDGE
.
To handle imported basepath
, set parameters
as basepath=ignore
, basepath=prepend
or basepath=split
.
For example, the AWS CLI command to exclude documentation from the imported API is:
aws apigateway import-rest-api --parameters ignore=documentation --body 'file:///path/to/imported-api-body.json'
The AWS CLI command to set the regional endpoint on the imported API is:
aws apigateway import-rest-api --parameters endpointConfigurationTypes=REGIONAL --body 'file:///path/to/imported-api-body.json'
[Required] The POST request body containing external API definitions. Currently, only OpenAPI definition JSON/YAML files are supported. The maximum size of the API definition file is 6MB.
Trait Implementations
Auto Trait Implementations
impl<C = DynConnector, M = DefaultMiddleware, R = Standard> !RefUnwindSafe for ImportRestApi<C, M, R>
impl<C, M, R> Unpin for ImportRestApi<C, M, R>
impl<C = DynConnector, M = DefaultMiddleware, R = Standard> !UnwindSafe for ImportRestApi<C, M, R>
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more