updateFilter method

Future<Filter> updateFilter({
  1. required int id,
  2. String? expand,
  3. bool? overrideSharePermissions,
  4. required Filter body,
})

Updates a filter. Use this operation to update a filter's name, description, JQL, or sharing.

Permissions required: Permission to access Jira, however the user must own the filter.

Implementation

Future<Filter> updateFilter(
    {required int id,
    String? expand,
    bool? overrideSharePermissions,
    required Filter body}) async {
  return Filter.fromJson(await _client.send(
    'put',
    'rest/api/3/filter/{id}',
    pathParameters: {
      'id': '$id',
    },
    queryParameters: {
      if (expand != null) 'expand': expand,
      if (overrideSharePermissions != null)
        'overrideSharePermissions': '$overrideSharePermissions',
    },
    body: body.toJson(),
  ));
}