I saw the documentation we can surely do it but an example would be useful for better understanding.
API- /rest/branch-permissions/2.0/projects/{projectKey}/repos/{repositorySlug}/restrictions
Correct me if I am wrong with the selection of API call.
I want to give set of users in JSON format and restrict permission for all others except those in that JSON. I am not sure what should be my JSON schema. The same way we do it in the UI using Prevent all changes, except by: