Events are data objects that represent individual user interactions against metrics in Trophy.
value
. The value of an event is the numerical amount that will be added to the user’s total metric count as a result of the user interaction it relates to.
The value can be positive or negative, and can be a whole number or a decimal.
attributes
object in your metric tracking code.
device
and duration
, are set:
key
which you can use to reference and track events against it in your code. You can find the key
in the metric settings page.
To start tracking user interactions as events against your Trophy metrics, use the Metrics API or one of our type-safe Client SDKs supported in most major programming languages.
Here’s an example where a fictional book-writing platform is using a metric to track the number of words written by each author. Each time an author edits their book, the platform sends an event to Trophy telling it how many words they wrote: