artifactory-client-java icon indicating copy to clipboard operation
artifactory-client-java copied to clipboard

Support for PermissionTargetV2

Open dodie opened this issue 6 years ago • 2 comments

Hi!

Currently the library supports application/vnd.org.jfrog.artifactory.security.PermissionTarget+json when it comes to managing permissions, but not application/vnd.org.jfrog.artifactory.security.PermissionTargetV2+json. (API Docs)

We are managing permissions via REST calls through the API. Since 6.11, in order to have access to Builds, explicit permissions must be granted, which can not be defined in the V1 API.

Is it possible to allow "Any Build" in a permission without the V2 API? If not, are there any plans adding support for V2? I found an old PR #209 , but it was closed without further discussion.

Thank you, David

dodie avatar Aug 22 '19 15:08 dodie

~~I've just noticed one odd thing regarding the REST API: based on this documentation it seems to me that querying permissions is only possible in PermissionTarget+json format (link), while updating is possible in both PermissionTarget+json and PermissionTargetV2+json (link). Is there a way to query permissions in the V2 format?~~ Please ignore this comment: I just found out that it is possible, just the documentation is not up to date and also contains incorrect examples.

dodie avatar Aug 22 '19 15:08 dodie

hi there. this is an old thread but it seems the documentation is still not up to date. do you remember how you fixed your issue? I have the exact same problem: i need to create a permission target that includes builds and the API is not letting me use the v2 json

larryenvacances avatar Jan 24 '23 22:01 larryenvacances