Setting up automated Jira Tickets by using email

Setting up automated Jira Tickets by using email

There is a way you can set up an email to automatically create a ticket for any project you like.

The best way for this to work is to use a Gmail account — as JIRA links most easily with Gmail. You would then need to add this Gmail email to a distribution list email address for staff members to email for creating those tickets. But if you’d like to use your own company’s email distribution list, then its simple enough to do — just check with your service desk team that the email list you want to use has a username and password associated with it.

There are 2 steps to complete to get this system set up.

NOTE: Please set up the Mail Server FIRST, then the Mail Handler.

Step 2: Create an Incoming Mail Server

  1. Go to: JIRA Admin > System > Incoming Mail
  2. Click Add POP/IMAP mail server
  3. Fill in the following details:
  4. Name: Give the mail server a name
  5. Description: Add something useful to identify what this mail server is being used for
  6. Protocol: SECURE_IMAP
  7. Host Name: imap.gmail.com (Or whichever host you are using — may be your company’s own host)
  8. POP/IMAP Port: 993
  9. Timeout: 10000
  10. Username: use the email address as the username
  11. Save this

Step 2: Create a Mail Handler

  1. Go to: JIRA Admin > System > Incoming Mail
  2. Click on Add incoming mail handler
  3. Fill in the following details:
  4. Name: Name this to link with the mail server you setup above
  5. Server: Select the server you created from Step 1
  6. Delay: You could set this to whatever you want, but we set it as 1
  7. Handler: The best option is the first one: “Create a new issue or add a comment to an existing issue”. This allows you to create a ticket when you send an email to that email account and also adds a comment to the ticket whenever you reply to that specific email chain.
  8. Folder Name: Usually you should leave empty
  9. Click Next
  10. Select the JIRA Project you want the ticket to be created to
  11. Set the issue type the ticket will be raised as by default
  12. Leave Strip Quotes unchecked
  13. Catch email address: Leave empty
  14. Bulk: Ignore the email and do nothing
  15. Forward email address: Leave empty
  16. Create Users: Leave unchecked. (This will not create a new user every time an email is sent by an email address that does not exist in Jira)
  17. The default reporter needs to be set from an existing JIRA user
  18. Notify Users, CC Assignee, and CC Watchers should all be checked.
  19. Click TEST to see if the connection works. If so, Click SAVE.

This should cover everything that is required to get emails to automatically create tickets to a certain JIRA project, without it creating user accounts.

As soon as an email is sent to that email account, the mail server is automatically checking if that sender’s email address already exists in the current JIRA user account database.

If it does, then that user will be set as the REPORTER. If not, the default REPORTER will be set. Either way, NO New user accounts are created, which is an issue when you have limited users.

All the best,

Techmandra Avatar

Leave a Reply

Your email address will not be published. Required fields are marked *