Jira Sidebarchat Integration¶
- Works with Grape Cloud/On-Premise and Jira On-Premise
- Chats can be created with the click of a button in Jira
- The chat is embedded as a sidebar in Jira
- Users from Jira fields that contain users or groups can be automatically added
- Watchers are added to the chat and un-watching removes a user from the chat
- Jira Fields with users or groups that are automatically synced to chat groups can be selected per project, including custom fields.
- Individual users can be added manually to a specific chat by pression the cogwheel next to the Grape button in Jira
- The add-on can be enabled for certain groups only, so you can test it with a subset of your Jira users.
Same chat in Grape
Button to create chat
Adding/removing individual users
- Jira On-Premise Server
- Jira admin account
- Grape admin account
- Network: Jira Server can talk to Grape Server over HTTPS
- Jira users exist in Grape (ideal: central user management), see “How are Jira users matched to Grape users?” below
- Doesn’t work with Jira Cloud
- The Organization id can be set at the add-on level, not at project level.
- The Auth Token is not refreshed automatically. It can be manually changed in Grape and in Jira.
create a separate Bot user in Grape who will be used to create the Jira groups:
- Click the cogwheel in the Chat
- Click Integrations
- Scroll down to “Bot API” and click on “Bot API”
- Click “Create new Bot” (“Neuen Bot erstellen”)
- Enter a name, e.g. “Jira Integration Service User”
- upload an avatar image (this will not be displayed anywhere)
- Scroll down to your bot, click the eye button to see the token.
- Copy the token
Set up an Application link
Note: you can reuse the application link for the Jira Integration with Grape Search and Actvities if you have already created this. Make sure the application link’s name is “Grape” and it is set to primary.
To create a fresh application link do the following:
- In Jira’s admin interface, go to “Applications” –> “Application links”
- Enter your Grape Server’s URL, e.g. https//grape.example.com and click “Create new link”
- If Jira warns you about redirects, check “Use this URL” and click “Continue”
- Enter “Grape” as name (don’t change the name!) and click “continue”
- Make it a primary link: In the application link table, click the three-dots menu button in the row of the newly created link and click “Make primary”
- Disable and enable the addon each time you change a setting
Install add-on jar file
- In Jira’s admin interface, go to “Add-ons” –> “Manage apps”
- Click “Upload app”
- Paste into the “From this URL” input:
https://www.chatgrape.com/download/grape-jira.jarand press “Upload” (or download grape-jira.jar and upload it to Jira)
Click “Grape Settings” in the sidebar
URL: Use the Grape URL inlcuding organization subdomain: e.g. https://company.chatgrape.com
- if you run in single organization mode you don’t have a organization subdomain)
- no trailing
1if you are running Grape Server.
for cloud users:
Open the chat in the browser, view the source code (Chrome/Firefx on Windows: CTRL + U. On macOS Command + Option + U)
"organization"(with quotation marks)
find your id:
auth token: the token from your Bot user
Optional: configure project specific settings:
- Open “Project Settings” for your Jira project
- click “Grape settings” in the menu
To test your setup, open an issue in Jira and click the “Create Grape Chat” button on right side.
No users setup needed.
How are Jira users matched to Grape users?¶
Users are matched by email only, so it’s recommended to use a central source of users for both Jira and Grape, like Crowd or Active Directory to make sure that users exist in both Jira and Grape, with the same email address.
Migrating from one service user to another one¶
If you have already created rooms with the Jira integration but want to change the service user that is used to create the rooms, you need to assign all existing rooms to the new user.
Copy the following code to a text editor and adjust the first three variables. You can find the user ids in the Django Admin (grape.example.com/admin).
organization_id = 1 old_user_id = 123 new_user_id = 456 rooms = Room.objects.filter(is_managed=True, organization_id=organization_id, creator_id=old_user_id) for room in rooms: print(room.slug) input('\nThose %s rooms will be changed. Press any key to continue or ctrl+c to cancel' % rooms.count()) for room in rooms: room.creator_id = new_user_id room.save()
SSH into your server and open a Django shell on your server.
Copy & paste the code and press Enter twice to run the code and Enter again to confirm the changes.