Skip to content

Instantly share code, notes, and snippets.

@commuterjoy
Last active August 29, 2015 14:22
Show Gist options
  • Save commuterjoy/d17bd35af792c3f3a0c3 to your computer and use it in GitHub Desktop.
Save commuterjoy/d17bd35af792c3f3a0c3 to your computer and use it in GitHub Desktop.
Spoor models

Thems the rules

  • event.source is mandatory, everything else is optional.
  • if user.session.token is included it will be validated against the session api and expanded in to a membership uuid.
  • if content.uuid is included it will be expanded in to a set of content api meta-data.
  • ...
{
"event": {
"source": "email.simple-email-service", // name of the sender's system, Eg. email.simple-email-service.uat
"type": "opened", // the type of event that happened
},
"user": {
"session": {
"token": "asdf324dfag1ds%asdf1A-1sadsadf", // ft session token
"valid": true, // expanded
"uuid": "123" // expanded
}
},
"content": {
"uuid": "0f7464b4-3f4d-11e4-984b-00144feabdc0" // content api reference
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment