Jira Data Center share issue feature

When you use the share button of an issue:

What does it actually do? If I enter an email/user, the recipient receives a link to the issue, but does Jira ensure the recipient has access to the issue?

And if the project is a Service Management project, the issue will have a field “Request Participants”. Sharing from customer portal will add people to Request Participant, but sharing from Jira won’t.

Is there an event triggered for sharing, or any fields changed when sharing from Jira, so I can update Request Participants?

Answering myself again.

The share feature does do something other than sending email, it will create those users you input an email address.

So I implemented what I want this way:

  1. Inject JavaScript with announcement banner. The script installs a MutationObserver to look for the share dialog. When found, modify the submit button to invoke an event handler instead.
  2. The event handler grabs issue key and partipant list from the form, submits them to a REST API, and if success, submits the original share form.
  3. Add a custom REST API with ScriptRunner. Take the data from the JavaScript, create new users if needed, then add the users to request participant custom field.