Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

With Easy Integration's Issue Listeners, you can integrate your Jira with your internal/external systems by calling REST services accordingly. On this page, you will find out how to define a listener and configure the REST service.

...

  1. First, tick the Send Attachments checkbox.
  2. Write the name of the form-data parameter name that contains attachments. For instance, in Jira REST Api for attachments, this name must be "file" and in ServiceNow REST API, this name must be "uploadFile"
  3. Write a groovy script that returns attachments. These attachments will be sent with the REST Call. If script is empty, then all attachments will be sent.

    Code Block
    languagegroovy
    titleSend Attachments
    linenumberstrue
    import com.atlassian.jira.component.ComponentAccessor;
    import com.atlassian.jira.issue.AttachmentManager;
    
    AttachmentManager attachmentManager = ComponentAccessor.getAttachmentManager();
    def attachments = attachmentManager.getAttachments(issue);
    return attachments;