Hi,
I need to delete Jira Service Management portal-only customers through an API.
I have tried the Jira Cloud Delete user endpoint:
DELETE /rest/api/3/user?accountId=<accountId>
This works for some customers, but it fails when the portal-only customer has request/comment history. I also cannot delete the comments because the author is a portal-only customer, not a normal Atlassian user.
The only method that works for these customers is deleting them manually through the Atlassian Admin UI under Jira Service Management > Portal-only customers.
I’m aware of the revoke portal-only access endpoint:
PUT /rest/servicedeskapi/customer/user/{accountId}/revoke-portal-only-access
However, this only revokes access and does not delete the customer.
Is there any public REST API equivalent to the UI “Delete customer” action for portal-only customers? If not, is there an existing feature request or roadmap item for this?
Thanks.
Hello @Mads Illemann
The current situation is a bit of a mess because of how Atlassian handles user data:
The Revoke Endpoint: PUT /rest/servicedeskapi/customer/user/{accountId}/revoke-portal-only-access only kills their access to the portal. The account technically remains in your site's directory, which is why it doesn't feel like a true deletion.
The Jira Platform Endpoint: DELETE /rest/api/3/user?accountId=... is the "official" way to delete users, but it's notoriously finicky.
Your test results, where the API works for some but fails for others actually align perfectly with a long-standing limitation (JRACLOUD-82526). If a portal-only customer has a significant history of requests, comments, or is still referenced in certain Jira fields, the API often throws an error to "protect" the integrity of that data.
Paradoxically, the Admin UI has a more powerful backend process that can bypass or clean up these references, which is why the manual click succeeds where your script fails.
Even though Atlassian previously marked similar tickets (JSDCLOUD-8934) as "fixed" by pointing everyone to the platform-level delete API, the reality is that the API isn't as robust as the UI-only flow. Until they release a specific JSM-centric "Force Delete" endpoint, you're stuck in a loop where the API only works for "clean" users.
For now, the safest bet is to watch those specific Jira tickets and, if you're hitting this at scale, open a support case to see if they can trigger a backend cleanup for your tenant.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.