getUsers function

Future<UserList> getUsers (
  1. String accessToken
)

Implements the /api/users.list call

Implementation

Future<UserList> getUsers(String accessToken) async {
  String endpoint = "https://slack.com/api/users.list?token=$accessToken";
  final http.Response response = await http.get(endpoint);

  return new UserList.fromMap(json.decode(response.body));
}