getScriptsWithHttpInfo method

Future<Response> getScriptsWithHttpInfo({
  1. int? limit,
  2. int? offset,
})

List scripts

Note: This method returns the HTTP Response.

Parameters:

  • int limit: The number of scripts to return.

  • int offset: The offset for pagination.

Implementation

Future<Response> getScriptsWithHttpInfo({
  int? limit,
  int? offset,
}) async {
  final path = r'/scripts';

  // ignore: prefer_final_locals
  Object? postBody;

  final queryParams = <QueryParam>[];
  final headerParams = <String, String>{};
  final formParams = <String, String>{};

  if (limit != null) {
    queryParams
        .addAll(_convertParametersForCollectionFormat('', 'limit', limit));
  }
  if (offset != null) {
    queryParams
        .addAll(_convertParametersForCollectionFormat('', 'offset', offset));
  }

  const authNames = <String>['TokenAuthentication'];
  const contentTypes = <String>[];

  return apiClient.invokeAPI(
    path,
    'GET',
    queryParams,
    postBody,
    headerParams,
    formParams,
    contentTypes.isEmpty ? null : contentTypes[0],
    authNames,
  );
}