Webhooks
NeatQueue sends HTTP POST requests to your endpoint whenever queue or match events occur, allowing you to integrate with external systems, track analytics, or build custom notifications.
What are Webhooks?
Webhooks are automated HTTP POST requests containing JSON data about events. Use them to:
- Track match results and player activity
- Integrate with databases or Discord bots
- Build analytics dashboards
- Send custom notifications
- Automate workflows
Setup
Supported Events
| Event | Description |
|---|---|
| JOIN_QUEUE | Player joins a queue |
| LEAVE_QUEUE | Player leaves a queue |
| MATCH_STARTED | Match validation begins |
| TEAMS_CREATED | Teams are formed and ready |
| MATCH_COMPLETED | Match finishes with a winner |
| MATCH_CANCELLED | Match is cancelled |
| SUBSTITUTION | Player is substituted during a match |
| REGISTER_PLAYER | Player registers their in-game account |
Click any event to see detailed payload documentation.
Authentication & Security
All webhook requests include an Authorization header with your configured token:
POST /your-webhook-endpoint HTTP/1.1
Host: your-domain.com
Content-Type: application/json
Authorization: your-secret-token
Best Practices:
- Always validate the
Authorizationheader - Use HTTPS endpoints only
- Keep your token secure and rotate it periodically
- Respond within 10 seconds (timeouts occur after this)
Common Payload Fields
Every webhook includes these base fields:
| Field | Type | Description |
|---|---|---|
action | string | Event type (e.g., "JOIN_QUEUE", "MATCH_STARTED") |
queue | string | Queue name/identifier |
channel | string | Discord channel ID |
guild | string | Discord server ID |
Additional fields vary by event type. See the event reference for details.