Skip to main content

Uniphore Help Center Portal

Test your webhook endpoint

Put your endpoint online with ngrok

Bash

Copy

# Running ngrok to make your local endpoint publicly accessible ngrok http http://localhost:8083

# You will see something similar to the following console UI in your terminal.

Session Status online

Account your_account

Version 3.0.0

Region United States (us)

Latency 78ms

Web Interface http://127.0.0.1:4040

Forwarding https://ngork-address.ngrok-free.dev -> http://localhost:8083

Connections ttl opn rt1 rt5 p50 p90

0 0 0.00 0.00 0.00

0.00

Test your public endpoint with curl

Bash

Copy

# Generate HMAC signature SECRET="your_secret_here" TIMESTAMP=$(date +%s)

BODY='{"id": "testing", "data": [{ "event_type": "execution.completed", "payload": {

"workflow_id": "123",

"execution_id": "456"

}

}]}'

SIGNATURE=$(echo -n "${BODY}.${TIMESTAMP}" | openssl dgst -sha256 - hmac "$SECRET" -binary | xxd -p -c 256)

# Send POST request

curl -X POST http://localhost:8083/webhook \

-H "Content-Type: application/json" \

-H "X-WEBHOOK-Signature: $SIGNATURE" \

-H "X-WEBHOOK-TIMESTAMP: $TIMESTAMP" \

-H "X-WEBHOOK-REQUEST-ID: fake_request_id" \

-d "$BODY"