Trigger Webhook post function

Trigger Webhook post function

Webhooks Pro registers a post function in Jira's workflow designer named Trigger Webhook. Attach it to any workflow transition and pick a webhook — every time the transition runs, the chosen webhook fires immediately, with no debounce.

This is the way to deliver webhooks on specific transitions (e.g. Done → Closed but not Done → Reopened) — something plain Jira event subscriptions can't express on their own.


When to use it

Reach for the post function when:

  • You need per-transition precision. Plain Issue updated events can't tell In Progress → Done apart from Done → Reopened. A post function runs only when its specific transition runs.

  • You want instant delivery, bypassing the debounce window.

  • The receiver expects exact transition context — Webhooks Pro passes workflow id, transition id, and from/to statuses to the payload builder.

Not the right tool when:

  • You want to fire on every issue update regardless of transition → use the Events tab on the webhook form with Issue Updated. See Events and event families.

  • You want scheduled delivery → use the Schedule section on the webhook form. See Scheduled webhooks.


How it works

Webhook post function - How it works.png

 

 

Three things to notice:

  1. No debounce. Each transition click = one delivery. Even if the same user transitions the same issue twice in 10 seconds, you get two deliveries.

  2. The same webhook configuration is used. URL, headers, payload template, HMAC secret — all from the webhook the post function points at.

  3. The Webhook Logs row carries the transition context in entity.transition.* for templates that want it.


Configure

Add it to a workflow

In Jira's workflow designer (Project settings → Workflows → pick the workflow):

  1. Open the transition you want to instrument (e.g. Done → Closed).

  2. Switch to the Post functions tab.

  3. Click Add post function, find Trigger Webhook (provided by Webhooks Pro), add it.

  4. The config screen opens. Pick the webhook from the Use this webhook dropdown.

  5. Click Add. Publish the workflow to apply.

Step-by-step walkthrough: Add Trigger Webhook to a workflow.

See bindings on the webhook side

Open the webhook in Webhooks Pro — the Transitions section at the bottom shows every workflow transition where this webhook is bound. Read-only on this side; remove or re-bind from Jira's workflow designer.

Detail: Transition bindings.


Sub-pages


What the receiver gets

The webhook's payload template applies as usual. The default Issue payload is augmented with an entity block describing the transition that ran:

Path

Means

Path

Means

entity.transition.id

Jira transition id

entity.transition.name

Transition name (e.g. "Resolve Issue")

entity.transition.from.name

Source status name (null on global transitions)

entity.transition.to.name

Target status name

entity.workflow.id

Workflow id

entity.workflow.name

Workflow name

entity.changelog.items

Array of {field, fromString, toString, …}

entity.comment

Comment entered in Jira's transition dialog (full object — author, body, created)

{{issue.*}} is also available — the post function passes the full issue alongside entity. Note that issue.fields.status.name will already reflect the post-transition status by the time the webhook fires.

Full reference: Template variables and {{ … }} reference → Workflow post function — entity.* bindings.


Limits and gotchas

  • The webhook must exist first. You can't create one from the post function config screen. If the dropdown is empty, you see: "Create at least one webhook in Webhooks Pro before attaching this post function."

  • Disabled webhooks still appear in the dropdown so you don't accidentally break an existing binding by toggling Active. A red warning calls out the disabled state.

  • Unpublished workflows don't fire. The post function is only active after you publish the workflow in Jira.

  • No debounce. Two clicks = two deliveries. If the receiver is sensitive to duplicates, dedupe on the receiver side.

  • Removing the post function in Jira doesn't auto-clean the binding row on the webhook side. Orphan rows show until someone re-saves or triggers a reconcile.

  • The entity.comment enrichment swaps Forge's slim stub { id } with the full comment object by looking it up in issue.fields.comment.comments[]. If the comment list is paginated and the new entry is on a later page, only entity.comment.id resolves; deeper paths come back as null / "".


Common mistakes

Mistake

Effect

Fix

Mistake

Effect

Fix

Try to add the post function to a transition without publishing the workflow

Binding doesn't fire

Publish the workflow.

Bind to a disabled webhook expecting it to fire

Delivery never happens; warning was visible at bind-time

Re-enable the webhook.

Use Issue Updated events AND a post function on the same workflow

Two deliveries per transition (one debounced, one immediate)

Pick one approach per webhook.

Expect the post function to run before the transition completes

Post functions run AFTER the transition

If the receiver needs to block the transition, post functions are wrong — use a validator on the transition instead.


Related