Webhook filter in atlassian-connect.json not working with project.property

Hi,

I’ve tried to set up a webhook in atlassian-connect.json which will be filtered by project.property. It’s not working. I’ve tried many combinations, like

project IN project.property[someProperty].someKey

or

project.property[someProperty].someKey = someValue

or

project.property[someProperty] = someValue

and many, many others various combinations. Tried almost everything, with single quotes like project.property[‘asd’] etc.
Sometimes webhook wasn’t called at all, sometimes was called every time like filter would not exist (first example I’ve pasted). Project property was set correctly, I’ve tried with many project properties which looked different and no one worked.

Webhook looked like:

  "webhooks": [
      {
        "event": "jira:issue_updated",
        "url": "/webhook-issue",
        "filter": "project in project.property[someName].someKey = someListStringValue"
      }
    ]

Please, help, and thanks for all answers.

Following filter works in our case:

"filter": "project.checklistDisabled is EMPTY or project.checklistDisabled != 'true'"

+ part of jiraEntityProperties:

{
        "keyConfigurations": [
          {
            "extractions": [
              {
                "objectName": "checklistDisabled",
                "type": "string",
                "alias": "checklistDisabled"
              }
            ],
            "propertyKey": "property-key"
          }
        ],
        "entityType": "project",
        "key": "checklist-disabled",
        "name": {
          "value": "Checklist Disabled",
          "i18n": "checklist.disabled"
        }
      }
1 Like

Hi,

Is your property indexed?
https://developer.atlassian.com/cloud/jira/platform/jira-entity-properties/#making-searchable-entity-properties

1 Like

Here is example:


"webhooks": [
  {
	"event": "jira:issue_created",
	"url": "/webhook/issue/created?issueId={issue.id}&projectId={project.id}",
	"filter" : "project.property[settings].enabled = \"true\""
  }
],
{
	"key": "settings-indexing",
	"name": {
	  "value": "settings index"
	},
	"entityType": "project",
	"keyConfigurations": [
	  {
		"propertyKey": "settings",
		"extractions": [
		  {
			"objectName": "enabled",
			"type": "string"
		  }
		]
	  }
	]
}
1 Like