Reward via Webhook
Automatically call your reward endpoint when a quest is completed.
Description
Overview
Trigger an external reward service or distribution endpoint whenever a Domino "Quest Completed" event occurs. This template listens for quest completion events and then performs a GET request to the URL you configure. Use it to notify third‑party systems, redeem codes, trigger off‑chain distributions, or signal any webhook‑driven reward workflow.
How it works
- A "Quest Completed" event starts the automation (the template provides a trigger webhook URL you can post to).
- The workflow performs a GET request to the URL you supply in the template inputs. The URL is called exactly as provided.
Setup (what to provide)
- tableId (required): select the table that contains your reward codes or distribution data. This ties the automation to the dataset you use for rewards (you can extend the workflow to read/consume rows from this table as needed).
- url (required): the full URL to call with a GET request. You can include query parameters and template variables in this field (for example: https://your.api/redeem?user={{userId}}&quest={{questId}}) — the GET action sends the URL you enter.
- network: default is mainnet (provided by the template inputs).
How to wire it up
- Use the provided trigger webhook URL (shown in the trigger step) as the endpoint that receives or proxies your "quest completed" events. When Domino receives that event the automation runs and calls your configured URL.
- If you need the automation to actually pick a code from the table and send it to your endpoint, extend the workflow by adding actions to read/claim a table row and append that value to the URL or body before the request.
Security & best practices
- Prefer POST for sensitive payloads: GET URLs can leak data in logs. If your endpoint requires secrets or sends codes, consider changing the action to POST and send the code in the request body with authentication.
- Authenticate your endpoint: require an HMAC header, API key, or bearer token. Keep secrets out of public GET query strings.
- Idempotency: ensure your endpoint can handle duplicate calls or the automation re‑runs. Use unique claim IDs when possible.
- Rate limits & retries: have your endpoint handle occasional bursts or implement retries/backoff on the Domino side if needed.
Testing & debugging
- Test the trigger by POSTing a sample payload to the trigger webhook URL. Confirm Domino runs the workflow and the GET request reaches your endpoint.
- Log incoming requests server‑side and include a small success response to help validate runs.
- If you need richer responses or structured replies, switch the request action to a more advanced request type (POST/JSON) and extend the template.
Example inputs
- network: mainnet
- tableId: <your-reward-codes-table-id>
- url: https://api.yourservice.com/redeem?user={{trigger.userId}}&quest={{trigger.questId}}
Notes
- This template is minimal by design: it calls the URL you provide after a quest completion trigger. If you want the automation to read a code from the table and insert it into the request, add table-read and update actions before the HTTP call.
- Use this template as a lightweight bridge between Domino quest events and your external reward systems.
How to Use
- 1
Add to your workspace
Click "Use Template" to add this automation to your Domino workspace. - 2
Connect your accounts
Authorize the apps this template uses: Domino Quests, Requests. - 3
Customize & activate
Adjust triggers, actions, and conditions to fit your needs, then turn it on.
Related Templates
More automation templates that use similar apps or serve similar purposes.
Ready to automate with this template?
Add this template to your workspace and customize it in minutes—or explore more templates to find the perfect fit.
