updatePackageScope method
Updates the scope of a package. Scope of the package defines users who can view and associate a package.
May throw BaseException.
May throw DisabledOperationException.
May throw InternalException.
May throw ResourceNotFoundException.
May throw ValidationException.
Parameter operation :
The operation to perform on the package scope (e.g., add/remove/override
users).
Parameter packageID :
ID of the package whose scope is being updated.
Parameter packageUserList :
List of users to be added or removed from the package scope.
Implementation
Future<UpdatePackageScopeResponse> updatePackageScope({
required PackageScopeOperationEnum operation,
required String packageID,
required List<String> packageUserList,
}) async {
final $payload = <String, dynamic>{
'Operation': operation.value,
'PackageID': packageID,
'PackageUserList': packageUserList,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/2021-01-01/packages/updateScope',
exceptionFnMap: _exceptionFns,
);
return UpdatePackageScopeResponse.fromJson(response);
}