getSpacePermissions method

Future<MultiEntityResult<SpacePermission>> getSpacePermissions({
  1. required int id,
  2. String? cursor,
  3. int? limit,
})

Returns space permissions for a specific space.

Permissions required: Permission to view the space.

Implementation

Future<MultiEntityResult<SpacePermission>> getSpacePermissions(
    {required int id, String? cursor, int? limit}) async {
  return MultiEntityResult.fromJson(
    await _client.send(
      'get',
      'spaces/{id}/permissions',
      pathParameters: {
        'id': '$id',
      },
      queryParameters: {
        if (cursor != null) 'cursor': cursor,
        if (limit != null) 'limit': '$limit',
      },
    ),
    reviver: (v) => SpacePermission.fromJson(v as Map<String, Object?>),
  );
}