Lists the available transformers. A transformer can take an EDI file as input and transform it into a JSON-or XML-formatted document. Alternatively, a transformer can take a JSON-or XML-formatted document as input and transform it into an EDI file.
Parameters:
-
next_token
(Optional[PageToken], default:
None
)
–
When additional results are obtained from the command, a NextToken parameter is returned in the output. You can then pass the NextToken parameter in a subsequent command to continue listing additional resources.
-
max_results
(Optional[MaxResults], default:
None
)
–
Specifies the number of items to return for the API response.
Raises:
-
AccessDeniedException
–
You do not have sufficient access to perform this action.
-
InternalServerException
–
This exception is thrown when an error occurs in the Amazon Web Services B2B Data Interchange service.
-
ThrottlingException
–
The request was denied due to throttling: the data speed and rendering may be limited depending on various parameters and conditions.
-
ValidationException
–
Occurs when a B2BI object cannot be validated against a request from another object. This exception can be thrown during standard EDI validation or when custom validation rules fail, such as when element length constraints are violated, invalid codes are used in code list validations, or required elements are missing based on configured element requirement rules.
-
UnknownServiceError
–
The service returned an error code this client does not model.
Examples:
Sample ListTransformers call
>>> client.list_transformers(max_results=50, next_token='foo')
Source code in docs_src/capo_b2bi/_services/b2bi.py
| def list_transformers(
self,
*,
config_overrides: Optional[b2biClientConfig] = None,
next_token: Optional["capo_b2bi.types.page_token.PageToken"] = None,
max_results: Optional["capo_b2bi.types.max_results.MaxResults"] = None,
) -> "capo_b2bi.types.list_transformers_response.ListTransformersResponse":
"""<p>Lists the available transformers. A transformer can take an EDI file as input and transform it into a JSON-or XML-formatted document. Alternatively, a transformer can take a JSON-or XML-formatted document as input and transform it into an EDI file.</p>
Args:
next_token: <p>When additional results are obtained from the command, a <code>NextToken</code> parameter is returned in the output. You can then pass the <code>NextToken</code> parameter in a subsequent command to continue listing additional resources.</p>
max_results: <p>Specifies the number of items to return for the API response.</p>
Raises:
capo_b2bi.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient access to perform this action.</p>
capo_b2bi.errors.internal_server_exception.InternalServerException: <p>This exception is thrown when an error occurs in the Amazon Web Services B2B Data Interchange service.</p>
capo_b2bi.errors.throttling_exception.ThrottlingException: <p>The request was denied due to throttling: the data speed and rendering may be limited depending on various parameters and conditions.</p>
capo_b2bi.errors.validation_exception.ValidationException: <p>Occurs when a B2BI object cannot be validated against a request from another object. This exception can be thrown during standard EDI validation or when custom validation rules fail, such as when element length constraints are violated, invalid codes are used in code list validations, or required elements are missing based on configured element requirement rules.</p>
capo_b2bi.errors.UnknownServiceError: The service returned an error code this client does not model.
Examples:
Sample ListTransformers call
>>> client.list_transformers(max_results=50, next_token='foo')
"""
def _handler(
req: "OperationRequest[capo_b2bi.types.list_transformers_request.ListTransformersRequest]",
) -> OperationResponse[
"capo_b2bi.types.list_transformers_response.ListTransformersResponse"
]:
import capo_b2bi._operations.b2_bi.list_transformers
output, http_response = (
capo_b2bi._operations.b2_bi.list_transformers.list_transformers(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListTransformers")
)
input_: capo_b2bi.types.list_transformers_request.ListTransformersRequest = {}
if next_token is not None:
input_["next_token"] = next_token
if max_results is not None:
input_["max_results"] = max_results
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|