Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This document covers the design and modifications needed to support events related use cases in Sunbird.

...

  • A single event listed (eg: a ask me anything session)

  • A collection of events (eg: a multi-day conference with one event each for the specific sessions)

  • Recurring events (eg: a 4 month course being taught on Mondays & Fridays)

  • A collection with an event within (eg: a content collection with training material, leading up to a live session)

Event Model

...

...

Attributes

EVENTS

Code Block
"name", 
"code", //identifiermandatory
"descriptioncode",
"status", // [live, draft, retired], cancelled]mandatory
"posterImagestartDate", //main image to show on the UImandatory
"thumbnailendDate", //small image to show for listing
"moreDetailsLinkmandatory
"startTime", //link to more details of the event
"languagemandatory
"endTime", "ageGroup",//mandatory
"topicsregistrationStartDate", "participationMethod", //[by invitation link, by registration, by scope {<org>, <group>}]
"startDate",
"endDate",
"startTime",
"endTime",
"bookingStartDate",
"bookingEndDate",
"totalSeats",
"availableSeatsmandatory
"registrationEndDate",
"eventType", //[online, offline, online_and_offline] //mandatory
"onlineProvider", //should this be an edge instead, as there would be a known set of providers ?
"onlineProviderConfige.g. zoom
"onlineProviderData", //e.g. {meetingId:<>, meetingLink:<>, recordedMediaInfo: ..},
"venue", //location object
"visibility",
"audience",
"posterImage", //meetingmain id,image passwordto orshow directon linksthe can be captured here
"venueUI
"appIcon", //venuesmall ofimage physicalto locationshow in case of offline meeting. Should this be an edge instead?
"recordingLinkfor listing
"description",
"recordingLinkPasswordcreatedFor",
"dialcodessource",
"createdOnowner",
"createdBycollaborators",
"updatedOn",
"updatedBy",
"flagReasonsparticipationMethod", //[by invitation link, by registration, by scope {<org>, <group>}, open] **phase 2**
"language",
"flagsageGroup",
"flaggedBykeywords",
"lastFlaggedOndialcodes"

Event Relations

Code Block
eventSet hasSequenceMember event
collection hasSequenceMember event
event associatedTo content or collection //link to all the content shared as part of event

Event APIs

  • Create Event

  • Update Event

  • Publish Event

  • Read Event

  • Search Events

  • Link Content to Event

EventSet Attributes

...

EVENTSET

EventSet will be a collection of Event objects. Below are the additional attributes that EventSet will have apart from Event, barring a few which will be stored at event level (startTime, endTime, recordingLink, flagReasons, flags, flaggedBy, lastFlaggedOne)).

Code Block
 "scheduleTypeschedule", 
      "type": //[recurring, non-recurring], 
"schedule",       "value" :
  //recurring template -> 
      {
        repeatEvery:<N>, repeatEveryType:<days|weeks|months|years>, 
        //if weeks selected:
        repeatOnDays:[<day of week1>,..], //e.g. every Monday and Friday
        //if month selected:
        repeatOnWeek:<N>, repeatOnWeekday:<day of the week>, //e.g. Every Second Thursday of the month
        startTime: <startTime>,
        endTime: <endTime>
        //child events would be named with the <event set name>-<sequence>
      }
  //non-recurring template
      [{date:<date>,startTime:<startTime>,endTime:<endTime>}]




,name:<name>,description:<description>}]

Note currently only non-recurring is supported.

EventSet Relations

Code Block
eventSet hasSequenceMember event
collection hasSequenceMember eventSet

APIs

EVENT

  • Create Event (kp=>/event/v4/create) - Creates an event in Graph with status Live. The event can thereafter be enrolled.

  • Update Event (kp=>/event/v4/update/:identifier) - Updates an event in Graph.

  • Read Event (kp=>/event/v4/read/:identifier) - Reads an event from Graph.

  • Discard Event (cs=>/v1/event/discard/:identifier) - Checks if the event has enrollments, if not, deletes the event in Graph by using private KP API.

  • Retire Event (kp=>/event/v4/retire/:identifier) - Marks the status as Retired.

  • Search Events (kp=>/v3/search) - Search for event or event set in Graph.

  • Enroll Event (cs=>/v1/event/enroll) - Allows a user to enroll to an event. Maintains information in sunbird_courses.user_enrolments.

  • Unenroll Event (cs=>/v1/event/unenroll) - Allows a user to unenroll an event. Marks active=false in sunbird_courses.user_enrolments.

  • Get User Enrolled Events (cs=> /v1/user/event/list/:uid) - Gets enrolled events for a user from sunbird_courses.user_enrolments.

  • Get Participants for Event (cs=> /v1/event/participants/list) - Gets registered participant list for an event. Gets userids from sunbird_courses.user_enrolments based on batchId (see below note on batchId for events.)

  • Update user event status (cs=> /v1/user/event/state/update) - Updates user progress for an event into sunbird_courses.user_content_consumption.

  • Read user event status (cs=>/v1/user/event/state/read) - Gets user progress for an event from sunbird_courses.user_content_consumption.

  • Link Content to Event (work in progress)

  • Get Event Attendees (work in progress)

EVENT SET

  • Create Event Set (kp=> /eventset/v4/create) - Creates Event Set as well as child Event objects in Graph and links them.

  • Update Event Set (cs=> /v1/eventset/update) - Checks if the child events has any enrollments, if not, updates the event set in Graph by using private KP API. This deletes the older child events and recreates new ones. It is currently assumed that all the child events have metadata same as parent. If in future, if child events are vastly dissimilar to each other, then we can fix this by doing a detailed comparison for each child and no longer delete and recreate everything.

  • Get Event Set Hierarchy (kp=>/eventset/v4/hierarchy/:identifier) - Fetches the child Events of Event Set from graph.

  • Read Event Set (kp=>/eventset/v4/read/:identifier) - Gets Event Set details from the graph.

  • Discard Event Set (cs=>/v1/eventset/discard/:identifier) - Checks if the child events has enrollments, if not, deletes the event set & child events in Graph by using private KP API.

  • Retire Event Set (kp=>/eventset/v4/retire/:identifier) - Marks the status of event set and child events as Retired.

  • Enroll Event Set (cs=>/v1/eventset/enroll) - Enrolls user to all the child events under the event set.

  • Unenroll Event Set (cs=>/v1/eventset/enroll) - Unenrolls user to all the child events under the event set.

*kp = knowledge platform

*cs = course service

Info
  • For enrollment and event tracking, the course flow is reused (with some generalization), so courseId is used for denoting eventId. Difference is that batchId is generated and is equal to (fixedPrefix + “-” + courseId). The fixed prefix is defaulted to a value in event schema so it can be easily passed to API, plus it also distinguishes between various other event like entities coming into the system in future. There is no entry made in “course_batch” as the batch is simply implied.

Updated Enrolment table design

...

  • Can create / edit / publish events

  • Can view and download the attendee list for a event

Other API Endpoints (Work In Progress)

...

Create Event

...

Edit Event

...

Publish Event

...

Create Participation

...

Delete Participation

...

  • Get attendees CSV export

  • Get join link

...