This shows how to embed Kaltura Meetings rooms into a Node.js application (it skips the room creation part). This is a very basic node express based app (generated using Express Generator).
For the API and options please review the Kaltura Meeting Embed dDocumentation at https://github.com/kaltura-vpaas/virtual-meeting-rooms .
- Checkout/Download the files
npm install
- Copy
config.template.json
toconfig.json
- Open
config.json
, configure according to the instructions and remove all comments - Run:
- On Mac/Linux -
DEBUG=kalturameeting:* npm start
- Windows -
set DEBUG=myapp:* & npm start
- On Mac/Linux -
- Load http://localhost:3000/ in your browser to access the app.
- express is configured with two routes: index and launchroom
- index (/) - the homepage shows a form mimicing user registration for an event, and allows chosing between rooms and roles
- launchroom renders the room or redirects back to homepage if no valid post data was provided
- It gets all the Kaltura params from the express app (who reads it from config.json)
- It then creates the Kaltura session with respective privileges according to the choices made in the homepage
- And finally renders the room as an iframe (see launchroom.jade)
- Create a resource / virtual room (or reuse an existing one). This step needs to be done outside of the app using the scheduleResource.add API. The created resourceIds should be populated in
config.json
. Key parameters in API:objectType
: KalturaLocationScheduleResourcetags
: vcprovider:newrow
- Generate a Kaltura Session (KS) which will authenticate a user into a room (done on backend)
- The
privileges
parameter should look similar to this:userContextualRole:0,role:viewerRole,resourceId:1092641
userContextualRole
: 0/1 is a host. 3 is a guest.role
should always be set toviewerRole
resourceId
was acquired in step 1
type
should be USERuserId
should be some unique identifier (i.e. email or any alphanumeric string which uniquely itendifies a user)secret
should be your account’s User Secret (not Admin Secret)
- The
- Join the room by launching it into an iframe. The iframe’s src will look similar to this:
https://1234567.kaf.kaltura.com/virtualEvent/launch?ks=XXXXXX
, where XXXXXX is the KS generated in step 2.
- Join the Kaltura Community Forums to ask questions or start discussions
- Read the Code of conduct and be patient and respectful
You can learn more about Kaltura and start a free trial at: http://corp.kaltura.com
Contact us via Twitter @Kaltura or email: community@kaltura.com
We'd love to hear from you!
All code in this project is released under the AGPLv3 license unless a different license for a particular library is specified in the applicable library path.
Copyright © Kaltura Inc. All rights reserved.
Review the list of Open Source 3rd party libraries used in this project.