Sharing Jira filter with a user group via API fails with error "You do not have permission to share with Group"

Still need help?

The Atlassian Community is here for you.

Ask the community

Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.

Summary

Sharing Jira filter with a user group via API fails with the error You do not have permission to share with the Group

(info) API to share filter permission: Add share permission

(info) API endpoint: https://<yoursitename>.atlassian.net/rest/api/3/filter/<filterID>/permission

POST /rest/api/3/filter/{id}/permission

Body:

{

    "groupname": "jira-administrators",

    "rights": 1,

    "type": "group"

}

Error message:

Environment

Jira Service Management Cloud

Diagnosis

When referring to the Add share permission page for the errors on APIs, a 400 error is returned when:

  • the request object is invalid. For example, it contains an invalid type, the ID does not match the type, or the project or group is not found.
  • the user does not own the filter.
  • the user does not have the required permissions.

(lightbulb) If the error presents itself even after checking all the possibilities above, refer to this article for a solution.

Cause

The user who is executing this API is not added to the group.

Solution

Add the impacted user to the user group and re-execute the API request.

(lightbulb)The details about sharing filter via UI is documented in Share a filter

To add users to a group, refer to the Add users page or follow the below steps:

  1. Go to admin.atlassian.com. Select your organization if you have more than one.
  2. Select Directory > Groups.
  3. Select the group that you want to add the user to.
  4. Select Add group members and search for the user/s you want to add.
  5. Select Add users.


A permanent solution will be in place when the below open feature is implemented:

JRACLOUD-15900: As an Admin I want the ability to share the visibility of a filter with Groups and Roles that I am not a member of

Please vote for it by clicking on Vote for this issue and add yourself as a watcher by clicking on Start watching this issue to get the latest updates about it.

Contact Atlassian support if you have any questions. 


Last modified on Nov 27, 2023

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.