The student unsubscription trigger returns information about a User’s subscription to a school’s subscription plan.
subscription: Information about the subscription that comes from Stripe.
subscription_plan: Information about the plan that the User subscribed to.
Monthly
or Yearly
, depending on billing frequency.is_canceled_at_cycle_end
and cycle_end_dtime
.meta: Contains extra attributes about the subscription.
{
"event": {
"type": "student.subscription.canceled",
"sent_time": "2014-11-11T20:58:25.688658+00:00"
},
"id": 14519,
"user": {
"username": "john_doe",
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@example.com",
"membership": {
"membership_type": "Student",
"can_manage_school": false,
"is_school_admin": false,
"can_create_course": false
},
"id": 52047
},
"school": {
"id": 14123,
"name": "Online Academy"
},
"subscription": {
"id": 15138,
"subscription_plan": {
"amount": 27,
"interval": "Monthly",
"id": 7,
"trial_period_days": 0
},
"trial_end_dtime": null,
"canceled_dtime": null,
"cycle_start_dtime": "2014-11-05T10:52:58Z",
"cycle_end_dtime": "2014-12-05T10:52:58Z",
"card_last_4": "5678",
"cancellation_reason": "User unsubscribed",
"is_canceled_at_cycle_end": false,
"is_delinquent": false,
"paused_until_dtime": null
},
"meta": {
"subscription_duration": 0
}
}