getTeamsForSchemeWithHttpInfo method

Future<Response> getTeamsForSchemeWithHttpInfo(
  1. String schemeId, {
  2. int? page,
  3. int? perPage,
})

Get a page of teams which use this scheme.

Get a page of teams which use this scheme. The provided Scheme ID should be for a Team-scoped Scheme. Use the query parameters to modify the behaviour of this endpoint. ##### Permissions manage_system permission is required. Minimum server version: 5.0

Note: This method returns the HTTP Response.

Parameters:

  • String schemeId (required): Scheme GUID

  • int page: The page to select.

  • int perPage: The number of teams per page.

Implementation

Future<Response> getTeamsForSchemeWithHttpInfo(
  String schemeId, {
  int? page,
  int? perPage,
}) async {
  // ignore: prefer_const_declarations
  final path = r'/schemes/{scheme_id}/teams'.replaceAll('{scheme_id}', schemeId);

  // ignore: prefer_final_locals
  Object? postBody;

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

  if (page != null) {
    queryParams.addAll(_queryParams('', 'page', page));
  }
  if (perPage != null) {
    queryParams.addAll(_queryParams('', 'per_page', perPage));
  }

  const contentTypes = <String>[];

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