Lists all exports that were created. The results are paginated and can be filtered by domain name.
Parameters:
-
domain_name
(Optional[DomainName], default:
None
)
–
The name of the domain to filter exports. If not provided, exports for all the domains will be listed.
-
max_results
(Optional[MaxResults], default:
None
)
–
The maximum number of exports to return in a single response.
-
next_token
(Optional[NextToken], default:
None
)
–
A pagination token used to retrieve the next page of results. This token is obtained from the nextToken field in the previous ListExportsResponse. Leave empty for the first request.
Raises:
Examples:
List all exports
>>> await client.list_exports()
Source code in docs_src/capo_simpledbv2/_services/async_simple_d_bv2.py
| async def list_exports(
self,
*,
config_overrides: Optional[AsyncSimpleDBv2ClientConfig] = None,
domain_name: Optional["capo_simpledbv2.types.domain_name.DomainName"] = None,
max_results: Optional["capo_simpledbv2.types.max_results.MaxResults"] = None,
next_token: Optional["capo_simpledbv2.types.next_token.NextToken"] = None,
) -> "capo_simpledbv2.types.list_exports_response.ListExportsResponse":
"""Lists all exports that were created. The results are paginated and can be filtered by domain name.
Args:
domain_name: The name of the domain to filter exports. If not provided, exports for all the domains will be listed.
max_results: The maximum number of exports to return in a single response.
next_token: A pagination token used to retrieve the next page of results. This token is obtained from the nextToken field in the previous ListExportsResponse. Leave empty for the first request.
Raises:
capo_simpledbv2.errors.invalid_next_token_exception.InvalidNextTokenException: The specified next token is not valid.
capo_simpledbv2.errors.invalid_parameter_value_exception.InvalidParameterValueException: The specified parameter value is not valid.
capo_simpledbv2.errors.no_such_domain_exception.NoSuchDomainException: The specified domain does not exist.
capo_simpledbv2.errors.UnknownServiceError: The service returned an error code this client does not model.
Examples:
List all exports
>>> await client.list_exports()
"""
async def _handler(
req: "AsyncOperationRequest[capo_simpledbv2.types.list_exports_request.ListExportsRequest]",
) -> AsyncOperationResponse[
"capo_simpledbv2.types.list_exports_response.ListExportsResponse"
]:
import capo_simpledbv2._operations.simple_d_bv2.list_exports
(
output,
http_response,
) = await capo_simpledbv2._operations.simple_d_bv2.list_exports.async_list_exports(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListExports")
)
input_: capo_simpledbv2.types.list_exports_request.ListExportsRequest = {}
if domain_name is not None:
input_["domain_name"] = domain_name
if max_results is not None:
input_["max_results"] = max_results
if next_token is not None:
input_["next_token"] = next_token
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|