describeConnectors method

Future<DescribeConnectorsResponse> describeConnectors({
  1. List<ConnectorType>? connectorTypes,
  2. int? maxResults,
  3. String? nextToken,
})

Describes the connectors vended by Amazon AppFlow for specified connector types. If you don't specify a connector type, this operation describes all connectors vended by Amazon AppFlow. If there are more connectors than can be returned in one page, the response contains a nextToken object, which can be be passed in to the next call to the DescribeConnectors API operation to retrieve the next page.

May throw InternalServerException. May throw ValidationException.

Parameter connectorTypes : The type of connector, such as Salesforce, Amplitude, and so on.

Parameter maxResults : The maximum number of items that should be returned in the result set. The default is 20.

Parameter nextToken : The pagination token for the next page of data.

Implementation

Future<DescribeConnectorsResponse> describeConnectors({
  List<ConnectorType>? connectorTypes,
  int? maxResults,
  String? nextToken,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    100,
  );
  final $payload = <String, dynamic>{
    if (connectorTypes != null)
      'connectorTypes': connectorTypes.map((e) => e.value).toList(),
    if (maxResults != null) 'maxResults': maxResults,
    if (nextToken != null) 'nextToken': nextToken,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/describe-connectors',
    exceptionFnMap: _exceptionFns,
  );
  return DescribeConnectorsResponse.fromJson(response);
}