updateRestrictions method
Future<ContentRestrictionArray>
updateRestrictions({
- required String id,
- List<
String> ? expand, - required ContentRestrictionAddOrUpdateArray body,
Updates restrictions for a piece of content. This removes the existing restrictions and replaces them with the restrictions in the request.
Permissions required: Permission to edit the content.
Implementation
Future<ContentRestrictionArray> updateRestrictions(
{required String id,
List<String>? expand,
required ContentRestrictionAddOrUpdateArray body}) async {
return ContentRestrictionArray.fromJson(await _client.send(
'put',
'wiki/rest/api/content/{id}/restriction',
pathParameters: {
'id': id,
},
queryParameters: {
if (expand != null) 'expand': expand.map((e) => e).join(','),
},
body: body.toJson(),
));
}