codecombat/app/schemas/models/analytics_users_active.coffee
Matt Lott e3abb9ceb3 Capture active user metrics
Watching for these events:
Level completed
User registered
Playtime of 30s in a level
Purchase
Payment
Subscribe
Earned an achievement
2014-12-04 12:57:57 -08:00

16 lines
464 B
CoffeeScript

c = require './../schemas'
AnalyticsUsersActiveSchema = c.object {
title: 'Analytics Users Active'
description: 'Active users data.'
}
_.extend AnalyticsUsersActiveSchema.properties,
creator: c.objectId(links: [{rel: 'extra', href: '/db/user/{($)}'}])
created: c.date({title: 'Created', readOnly: true})
event: {type: 'string'}
c.extendBasicProperties AnalyticsUsersActiveSchema, 'analytics.users.active'
module.exports = AnalyticsUsersActiveSchema