TANITARDevelopers
WebhooksEvent catalogTournaments

tournament.stage.generated

Version 1 of the tournament.stage.generated webhook event.

The tournament.stage.generated event.

Event typetournament.stage.generated
Schema version1
Routing keyevent.tournament.stage.generated.v1
Produced byTournament Management
Schemaurn:defendr:contract:tournament:stage-generated:1

data fields

FieldTypeRequiredDescription
tournamentIdstringyes
organizationIdstringyes
stageIdstringyes
generationRevisionintegeryes
operation"generated", "regenerated"yes
requestedFormatstringyes
actualFormatstringyes
entrantCountintegeryes
topologySummaryobjectyes
topologySummary.matchCountintegeryes
topologySummary.roundCountintegeryes
topologySummary.groupCountintegeryes
topologySummary.byeCountintegeryes

Some fields are required only in particular states. The JSON Schema below is authoritative.

Example delivery

Signed with the example secret whsec_placeholder_example_webhooks_signing_secret, so you can check your verifier against it. See Verifying signatures.

POST /your/webhook/endpoint HTTP/1.1
content-type: application/json
webhook-id: whd_00000000-0000-4000-8000-000000000066
webhook-timestamp: 1800000000
webhook-signature: v1,tm+G4LCbuXbxGmbzVWkMJtnUPdBckUJxlajSZq4yyo8=
tanitar-event-type: tournament.stage.generated
tanitar-schema-version: 1
tanitar-delivery-attempt: 1

{"messageId":"evt_00000000-0000-4000-8000-000000000066","kind":"event","type":"tournament.stage.generated","schemaVersion":1,"occurredAt":"2027-01-15T10:00:00.000Z","producer":"tournament-management-service","accountId":"acc_11111111-1111-4111-8111-111111111111","correlationId":"corr_00000000-0000-4000-8000-000000000066","data":{"tournamentId":"trn_01J5EXAMPLE","organizationId":"org_01J5EXAMPLE","stageId":"stg_01J5EXAMPLE","generationRevision":1,"operation":"generated","requestedFormat":"single_elimination","actualFormat":"single_elimination","entrantCount":8,"topologySummary":{"matchCount":7,"roundCount":3,"groupCount":0,"byeCount":0}}}

The same body, formatted:

{
  "messageId": "evt_00000000-0000-4000-8000-000000000066",
  "kind": "event",
  "type": "tournament.stage.generated",
  "schemaVersion": 1,
  "occurredAt": "2027-01-15T10:00:00.000Z",
  "producer": "tournament-management-service",
  "accountId": "acc_11111111-1111-4111-8111-111111111111",
  "correlationId": "corr_00000000-0000-4000-8000-000000000066",
  "data": {
    "tournamentId": "trn_01J5EXAMPLE",
    "organizationId": "org_01J5EXAMPLE",
    "stageId": "stg_01J5EXAMPLE",
    "generationRevision": 1,
    "operation": "generated",
    "requestedFormat": "single_elimination",
    "actualFormat": "single_elimination",
    "entrantCount": 8,
    "topologySummary": {
      "matchCount": 7,
      "roundCount": 3,
      "groupCount": 0,
      "byeCount": 0
    }
  }
}

JSON Schema

urn:defendr:contract:tournament:stage-generated:1
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "urn:defendr:contract:tournament:stage-generated:1",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "tournamentId",
    "organizationId",
    "stageId",
    "generationRevision",
    "operation",
    "requestedFormat",
    "actualFormat",
    "entrantCount",
    "topologySummary"
  ],
  "properties": {
    "tournamentId": {
      "type": "string"
    },
    "organizationId": {
      "type": "string"
    },
    "stageId": {
      "type": "string"
    },
    "generationRevision": {
      "type": "integer",
      "minimum": 1
    },
    "operation": {
      "enum": [
        "generated",
        "regenerated"
      ]
    },
    "requestedFormat": {
      "type": "string"
    },
    "actualFormat": {
      "type": "string"
    },
    "entrantCount": {
      "type": "integer",
      "minimum": 0
    },
    "topologySummary": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "matchCount",
        "roundCount",
        "groupCount",
        "byeCount"
      ],
      "properties": {
        "matchCount": {
          "type": "integer",
          "minimum": 0
        },
        "roundCount": {
          "type": "integer",
          "minimum": 0
        },
        "groupCount": {
          "type": "integer",
          "minimum": 0
        },
        "byeCount": {
          "type": "integer",
          "minimum": 0
        }
      }
    }
  }
}

On this page