Triggered when a user’s leaderboard rank changes.
The webhook event.
The webhook event type.
leaderboard.rank_changed The user whose rank changed.
Show child attributes
The ID of the user in your database. Must be a string.
"user-id"
The user's email address.
The name of the user.
"John Doe"
The user's timezone.
"Europe/London"
The user's device tokens.
The device token.
["token1", "token2"]Whether the user is opted into receiving Trophy-powered emails.
true
Whether the user is in the control group, meaning they do not receive emails or other communications from Trophy.
false
The date and time the user was created, in ISO 8601 format.
"2021-01-01T00:00:00Z"
The date and time the user was last updated, in ISO 8601 format.
"2021-01-01T00:00:00Z"
The user's leaderboard data that changed. A user's data for a specific leaderboard including rank, value, and history. A leaderboard with its configuration details.
Show child attributes
The unique ID of the leaderboard.
"5100fe51-6bce-6j44-b0hs-bddc4e123682"
The user-facing name of the leaderboard.
"Weekly Word Count Challenge"
The unique key used to reference the leaderboard in APIs.
"weekly-words"
What the leaderboard ranks by.
points, streak, metric "metric"
The key of the attribute to break down this leaderboard by.
"country"
The user-facing description of the leaderboard.
"Compete weekly to see who writes the most words"
The start date of the leaderboard in YYYY-MM-DD format.
"2025-01-01"
The end date of the leaderboard in YYYY-MM-DD format, or null if it runs forever.
"2025-12-31"
The maximum number of participants in the leaderboard.
100
The repetition type for recurring leaderboards, or null for one-time leaderboards.
day, month, year, "day"
The interval between repetitions, relative to the start date and repetition type. Null for one-time leaderboards.
7
The user's current rank in this leaderboard. Null if the user is not on the leaderboard.
2
The user's current value in this leaderboard. Null if the user is not on the leaderboard.
4500
The user's rank before this event, or null if they were not on the leaderboard.
5
The user's value before this event, or null if they were not on the leaderboard.
1000
The key of the metric to rank by, if rankBy is 'metric'.
"words-written"
The name of the metric to rank by, if rankBy is 'metric'.
"Words Written"
The key of the points system to rank by, if rankBy is 'points'.
"xp-system"
The name of the points system to rank by, if rankBy is 'points'.
"Experience Points"
Return a 200 status to indicate the webhook was received and processed.
Was this page helpful?