pub struct ImportRestApiFluentBuilder { /* private fields */ }
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§
source§impl ImportRestApiFluentBuilder
impl ImportRestApiFluentBuilder
sourcepub fn as_input(&self) -> &ImportRestApiInputBuilder
pub fn as_input(&self) -> &ImportRestApiInputBuilder
Access the ImportRestApi as a reference.
sourcepub async fn send(
self
) -> Result<ImportRestApiOutput, SdkError<ImportRestApiError, HttpResponse>>
pub async fn send( self ) -> Result<ImportRestApiOutput, SdkError<ImportRestApiError, HttpResponse>>
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.
sourcepub async fn customize(
self
) -> Result<CustomizableOperation<ImportRestApiOutput, ImportRestApiError>, SdkError<ImportRestApiError>>
pub async fn customize( self ) -> Result<CustomizableOperation<ImportRestApiOutput, ImportRestApiError>, SdkError<ImportRestApiError>>
Consumes this builder, creating a customizable operation that can be modified before being sent.
sourcepub fn fail_on_warnings(self, input: bool) -> Self
pub fn fail_on_warnings(self, input: bool) -> Self
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
.
sourcepub fn set_fail_on_warnings(self, input: Option<bool>) -> Self
pub fn set_fail_on_warnings(self, input: Option<bool>) -> Self
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
.
sourcepub fn get_fail_on_warnings(&self) -> &Option<bool>
pub fn get_fail_on_warnings(&self) -> &Option<bool>
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
.
sourcepub fn parameters(self, k: impl Into<String>, v: impl Into<String>) -> Self
pub fn parameters(self, k: impl Into<String>, v: impl Into<String>) -> Self
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:
The AWS CLI command to set the regional endpoint on the imported API is:
sourcepub fn set_parameters(self, input: Option<HashMap<String, String>>) -> Self
pub fn set_parameters(self, input: Option<HashMap<String, String>>) -> Self
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:
The AWS CLI command to set the regional endpoint on the imported API is:
sourcepub fn get_parameters(&self) -> &Option<HashMap<String, String>>
pub fn get_parameters(&self) -> &Option<HashMap<String, String>>
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:
The AWS CLI command to set the regional endpoint on the imported API is:
sourcepub fn body(self, input: Blob) -> Self
pub fn body(self, input: Blob) -> Self
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§
source§impl Clone for ImportRestApiFluentBuilder
impl Clone for ImportRestApiFluentBuilder
source§fn clone(&self) -> ImportRestApiFluentBuilder
fn clone(&self) -> ImportRestApiFluentBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more