What you’ll build
- A Slack incoming webhook URL.
- A Slack channel to post into.
- A Signa API key with
portfolios:manage(used to register the webhook endpoint). - A Signa watch already created, see Watches.
Your Signa API key only needs to live wherever you call
signa.webhooks.create. The Cloudflare Worker / Lambda below verifies signatures with the webhook secret and never calls the Signa API, so it does not need a Signa API key at runtime, only SIGNA_WEBHOOK_SECRET and SLACK_WEBHOOK_URL.Cloudflare Worker
Save asworker.ts:
alert.created body is self-contained: it carries the full alert object (event.summary, watch.name, trademark.mark_text, deadline, etc.) inline, so the message above renders human-readable names with no extra API call. See the payload shape for the full field reference.
If you still want to enrich beyond what the body carries (e.g. fetch the full goods/services list), add a GET /v1/trademarks/{id} or GET /v1/watches/{id} call. Give the Worker its own Signa API key with the minimum scope (trademarks:read for trademark lookups, portfolios:manage for watch lookups), stored in a different secret than SIGNA_WEBHOOK_SECRET so the two can be rotated independently.
Set the env vars and deploy:
wh.secret into the Worker as SIGNA_WEBHOOK_SECRET.
AWS Lambda + API Gateway alternative
POST to the Lambda. Set SIGNA_WEBHOOK_SECRET and SLACK_WEBHOOK_URL as Lambda env vars.
Tips
- Slack rate-limits incoming webhooks. For high-volume watches, batch with a 30-second buffer, or fan out to a topic and let multiple webhooks consume.
- Slack truncates messages over 40k chars. Keep formatting compact.