{
  "key":"amoeboids.releasenotes",
  "baseUrl":"https://arn.upraise.io",
  "name":"Automated release notes & reports",
  "description":"Easiest way to generate release notes & reports in multiple formats. Automate the process fully from creation to distribution.",
  "editionsEnabled": true,
  "vendor":{
    "name":"Amoeboids Technologies Pvt Ltd",
    "url":"https://www.amoeboids.com"
  },
  "links":{
    "self":"https://arn.upraise.io/atlassian-connect.json",
    "homepage":"https://arn.upraise.io/atlassian-connect.json"
  },
  "authentication":{
    "type":"jwt"
  },
  "apiMigrations":{
    "gdpr":true,
    "context-qsh": true,
    "signed-install": true
  },
  "cloudAppMigration": {
    "migrationWebhookPath" : "/migration/notification"
  },
  "enableLicensing":true,
  "editionsEnabled":true,
  "lifecycle":{
    "installed":"/installed",
    "uninstalled":"/uninstalled"
  },
  "translations": {
    "paths": {
        "de-DE": "/i18n/de_DE.json",
        "fr-FR": "/i18n/fr_FR.json",
        "ru-RU": "/i18n/ru_RU.json",
        "es-ES": "/i18n/es_ES.json"
    }
  },
  "scopes":[
    "READ",
    "WRITE",
    "ADMIN",
    "ACT_AS_USER",
    "ACCESS_EMAIL_ADDRESSES"
  ],
  "modules":{
    "jiraProjectPages":[
      {
        "url":"/arn/page/view?page=rules&pkey={project.key}&pid={project.id}&boardId={board.id}",
        "iconUrl":"https://arn-resources.upraise.io/images/logo.png",
        "name":{
          "value":"Automated release notes and reports"
        },
        "key":"arn-main-page",
        "conditions":[
          {
            "or":[
              {
                "and":[
                  {
                    "condition":"addon_property_equal_to",
                    "invert":true,
                    "params":{
                      "entity":"addon",
                      "propertyKey":"default-arn-enabled",
                      "value":"false"
                    }
                  },
                  {
                    "condition":"entity_property_equal_to",
                    "invert":true,
                    "params":{
                      "entity":"project",
                      "propertyKey":"amoeboids.releasenotes-arn-enabled",
                      "value":"false"
                    }
                  }
                ]
              },
              {
                "and":[
                  {
                    "condition":"addon_property_equal_to",
                    "params":{
                      "entity":"addon",
                      "propertyKey":"default-arn-enabled",
                      "value":"false"
                    }
                  },
                  {
                    "condition":"entity_property_equal_to",
                    "params":{
                      "entity":"project",
                      "propertyKey":"amoeboids.releasenotes-arn-enabled",
                      "value":"true"
                    }
                  }
                ]
              }
            ]
          },
         {
			  "and": [
			    {
			      "or": [
			        {
			          "condition": "user_is_project_admin"
			        },
			        {
			          "condition": "has_project_permission",
			          "params": {
			            "permission": "amoeboids.releasenotes__manageARN"
			          }
			        }
			      ]
			    },
			    {
			      "condition": "has_project_permission",
			      "params": {
			        "permission": "browse_projects"
			      }
			    }
			  ]
			}
        ]
      }
    ],
    "webItems": [
			{
				"key": "arn-page-view",
				"url": "/release-page/jwt-login?redirectPath={ac.redirectPath}&redirectDomain={ac.redirectDomain}",
				"context": "addon",
				"location": "system.user.options/set_my_jira_home",
				"name": {
					"value":"Automated Release Notes & Reports"
				},
				"conditions":[{"condition":"user_is_logged_in"}]
			}
		],
    "webSections":[
      {
        "key":"arn-menu-section",
        "location":"admin_plugins_menu",
        "name":{
          "value":"Automated Release Notes & Reports"
        }
      }
    ],
    "generalPages":[
      {
        "url":"/arn/page/view?page=settings",
        "key":"arn-settings",
        "location":"admin_plugins_menu/arn-menu-section",
        "name":{
          "value":"Configurations"
        },
        "conditions":[
          {
            "condition":"user_is_admin"
          }
        ]
      },
      {
 	    "name":{
          "value":"Automated release notes and reports"
        },
 	    "location": "system.top.navigation.bar",
 	    "key": "arn-cross-project",
 	    "icon": {
 	        "height": 16,
 	    	"width": 16,
 	    	"url": "https://arn-resources.upraise.io/images/logo.png"
 	    },
 	    "url": "/arn/page/view?page=crossProject",
 	    "conditions":[
			{
	          	"or": [
		          	{
					  "condition": "addon_property_contains_any_user_group",
					  "params": {
					      "propertyKey": "arnCrossProjectAccessGroups",
					      "value": "true"
					  }
					},
					{
			            "condition": "addon_property_equal_to",
			            "params": {
			              "propertyKey": "arnCrossProjectAccessUsers",
			              "value": "true"
			            }
			          }
	          	]
          	}
		]
	}
    ],
    "jiraProjectPermissions":[
      {
        "description":{
          "value":"Allows user to manage Automated Release Notes & Reports templates and rules"
        },
        "category":"projects",
        "name":{
          "value":"Manage Automated Release Notes & Reports"
        },
        "key":"manageARN"
      }
    ],
    "webhooks":[
      {
        "event":"jira:version_released",
        "url":"/rest/arn/latest/webhook/version/released"
      },
      {
        "event":"jira:version_created",
        "url":"/rest/arn/latest/webhook/version/created"
      },
      {
        "event":"sprint_closed",
        "url":"/rest/arn/latest/webhook/sprint/completed"
      },
      {
        "event":"sprint_started",
        "url":"/rest/arn/latest/webhook/sprint/started"
      }
    ],
     "jiraDashboardItems": [
		  {
		    "key": "arn-cross-project-calendar-gadget",
		    "name": {
		      "value": "Automated release notes & reports - calendar"
		    },
		    "description": {
		      "value": "This gadget will show releases in a calendar for the configured projects",
		      "i18n" : "com.amoeboids.apps.arn.calendar.gadgets.desc"
		    },
		    "url": "/arn/page/view?page=crossProjectCalendarGadget&dashboardId={dashboard.id}&dashboardItemId={dashboardItem.id}",
		    "configurable": true,
		    "thumbnailUrl": "/img/ARN-calendar-thumbnail.jpg"
		  }
		]
  }
}