getAccounts method
Parameters:
- Object authorization:
Implementation
Future<List<AccountModel>> getAccounts({
required Object authorization,
}) async {
final response = await _getAccountsWithHttpInfo(
authorization: authorization,
);
if (response.statusCode >= HttpStatus.badRequest) {
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
}
final responseBody = await _decodeBodyBytes(response);
return (await apiClient.deserializeAsync(responseBody, 'List<AccountModel>')
as List)
.cast<AccountModel>()
.toList(growable: false);
}