Dev Ops · n8n

Instantly Alert On-Call Teams When Zendrop Fulfillment Fails

Polls Zendrop for failed fulfillment orders and fires a PagerDuty incident the moment an error is detected. Keeps your on-call engineers informed without manual log checking.

difficulty Intermediatesetup 40 minresult A PagerDuty incident is automatically created with order details whenever Zendrop reports a fulfillment error, so your team can respond before customers notice.
  1. 1

    Schedule a regular poll of Zendrop orders

    Add a Schedule Trigger node. Set Interval to every 5 minutes. This node wakes the workflow on a cadence so no fulfillment error sits undetected for long.

  2. 2

    Fetch recent orders from Zendrop API

    Add an HTTP Request node named Get Zendrop Orders. Set Method to GET and URL to https://api.zendrop.com/api/v1/orders?status=failed. Under Authentication choose Header Auth and add your Zendrop API key as Authorization: Bearer YOUR_API_KEY. Store the key in an n8n credential and reference it here.

  3. 3

    Check whether any failed orders were returned

    Add an IF node named Has Errors?. Set the condition to check {{ $json.data.length }} is greater than 0. The TRUE branch continues to alerting; the FALSE branch ends the workflow silently.

  4. 4

    Shape the alert payload

    Add a Set node named Build Alert Body on the TRUE branch. Create a field called summary with value Zendrop fulfillment failure: {{ $json.data[0].order_id }} - {{ $json.data[0].error_message }} and a field order_count with value {{ $json.data.length }}. This keeps the PagerDuty alert concise and actionable.

  5. 5

    Create a PagerDuty incident

    Add a final HTTP Request node named Fire PagerDuty Incident. Set Method to POST, URL to https://events.pagerduty.com/v2/enqueue, and Body Content Type to JSON. Paste this body: { "routing_key": "YOUR_PAGERDUTY_INTEGRATION_KEY", "event_action": "trigger", "payload": { "summary": "{{ $json.summary }}", "severity": "critical", "source": "Zendrop", "custom_details": { "order_count": "{{ $json.order_count }}" } } }. Replace YOUR_PAGERDUTY_INTEGRATION_KEY with the key from your PagerDuty Events API v2 integration.

Frequently asked questions

How do I get my Zendrop API key?

Log in to your Zendrop dashboard, navigate to Settings > API, and generate or copy your API key. Paste it into an n8n Header Auth credential so it is stored securely and never hard-coded in the node.

Where do I find the PagerDuty integration key?

In PagerDuty go to Services > select your service > Integrations > Add Integration, choose Events API v2, and copy the Integration Key that appears. This key routes the alert to the correct on-call schedule.

What if multiple orders fail at the same time — will I get spammed with alerts?

The current workflow fires one PagerDuty event per polling cycle and includes the total failed order count in the payload. PagerDuty's deduplication (using the same routing key and similar summary) will group repeated alerts into a single incident rather than flooding your team.

About this recipe. Recipes on FlowRecipesHub are written for business owners, not developers, and are tested before publishing — how recipes get made. Some ingredient links are affiliate links that cost you nothing — full disclosure.