Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Programmable Video Fundamentals

Programmable Video Fundamentals

Mark Roberts, Tech Lead of the JavaScript Video SDK Team at Twilio, explains WebRTC and how Twilio's Programmable Video APIs make it easy to build video apps using cross-platform client-side SDKs along with REST APIs for server-side control.

Mark Roberts

May 23, 2017
Tweet

More Decks by Mark Roberts

Other Decks in Programming

Transcript

  1. Programmable Video Fundamentals 1. Video Apps & WebRTC 2. Programmable

    Video 3. Basic Multiparty Video Chat 4. Access Tokens & Room Security 5. REST API & Status Callbacks 6. Production Check-list © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  2. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS WebRTC •

    Specification for real-time communication © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  3. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS WebRTC •

    Specification for real-time communication • WebRTC’s core API is the RTCPeerConnection © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  4. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS WebRTC •

    Specification for real-time communication • WebRTC’s core API is the RTCPeerConnection • But not just browsers—mobile, desktop, embedded, etc. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  5. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS WebRTC •

    Twilio built its Programmable Voice SDKs in part using WebRTC. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  6. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS WebRTC •

    Twilio built its Programmable Voice SDKs in part using WebRTC. • Twilio’s Programmable Video SDKs also make use of WebRTC. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  7. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS WebRTC •

    Twilio built its Programmable Voice SDKs in part using WebRTC. • Twilio’s Programmable Video SDKs also make use of WebRTC. • 6.2 billion WebRTC-enabled devices forecasted by end of 2018 © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  8. What do we need to build a video app using

    WebRTC? © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS
  9. Signaling Servers STUN & TURN Servers © 2017 TWILIO, INC.

    ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  10. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. ALICE BOB
  11. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING ALICE BOB
  12. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING ALICE BOB
  13. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING ALICE BOB
  14. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING ALICE BOB
  15. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB
  16. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB
  17. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB
  18. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB STUN STUN
  19. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB STUN STUN
  20. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB STUN STUN
  21. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB STUN STUN
  22. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB STUN STUN TURN TURN
  23. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. SIGNALING NAT NAT ALICE BOB STUN STUN TURN TURN
  24. Signaling Servers STUN & TURN Servers © 2017 TWILIO, INC.

    ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  25. Signaling Servers STUN & TURN Servers Media Servers © 2017

    TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  26. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. PEER-TO-PEER ONLY WITH MEDIA SERVER
  27. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. RTCPEERCONNECTION RTCPEERCONNECTION RTCPEERCONNECTION PEER-TO-PEER ONLY WITH MEDIA SERVER
  28. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. PEER-TO-PEER ONLY WITH MEDIA SERVER
  29. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. PEER-TO-PEER ONLY WITH MEDIA SERVER
  30. Signaling Servers STUN & TURN Servers Media Servers © 2017

    TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  31. Signaling Servers STUN & TURN Servers Media Servers Higher-level APIs

    © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  32. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    RTCPEERCONNECTION RTCPEERCONNECTION RTCPEERCONNECTION
  33. Signaling Servers STUN & TURN Servers Media Servers Higher-level APIs

    © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  34. Signaling Servers STUN & TURN Servers Media Servers + Higher-level

    APIs Programmable Video © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED.
  35. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    Cross-platform SDKs REST API for Server-side Control
  36. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  37. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  38. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  39. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  40. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  41. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  42. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  43. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  44. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  45. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  46. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  47. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  48. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  49. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  50. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  51. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  52. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  53. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  54. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  55. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  56. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  57. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  58. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  59. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  60. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  61. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  62. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  63. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  64. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  65. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • sid • name • connect() • disconnect() • participants • “participantConnected” • “participantDisconnected” • sid • identity • tracks • addTrack() • removeTrack() • “trackAdded” • “trackRemoved” • sid • kind • isEnabled • enable() • disable() • “trackEnabled” • “trackDisabled” Room Participant Track
  66. Basic Multiparty
 Video Chat © 2017 TWILIO, INC. ALL RIGHTS

    RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS
  67. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. JAVASCRIPT
  68. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) JAVASCRIPT
  69. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) JAVASCRIPT
  70. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) JAVASCRIPT
  71. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: { deviceId: ‘xxx’ }, video: true }) JAVASCRIPT
  72. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: { deviceId: ‘xxx’ }, video: { width: 640, height: 480, frameRate: 60 } }) JAVASCRIPT
  73. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) JAVASCRIPT
  74. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room JAVASCRIPT
  75. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { tracks }) JAVASCRIPT
  76. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { name: ‘My Cool Room’, tracks }) JAVASCRIPT
  77. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { name: ‘My Cool Room’, logLevel: ‘debug’, tracks }) JAVASCRIPT
  78. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { name: ‘My Cool Room’, logLevel: ‘debug’, iceServers: [ /* … */ ], tracks }) JAVASCRIPT
  79. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { tracks }) JAVASCRIPT
  80. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { tracks }) const { name, sid } = room JAVASCRIPT
  81. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { tracks }) const { name, sid } = room console.log(‘Connected to “%s” (%s)’, name, sid) JAVASCRIPT
  82. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. const { connect, createLocalTracks } = require(‘twilio-video’) // 1. Acquire LocalTracks const tracks = await createLocalTracks({ audio: true, video: true }) // 2. Connect to a Room const room = await connect(token, { tracks }) const { name, sid } = room console.log(‘Connected to “%s” (%s)’, name, sid) addRoomView(room) JAVASCRIPT
  83. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity } = participant console.log(‘%s connected’, identity) participant.on(‘disconnected’, () => { // Cleanup whatever UI component we created // for the Participant. console.log(‘%s disconnected’, identity) }) // … } JAVASCRIPT
  84. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity } = participant console.log(‘%s connected’, identity) participant.on(‘disconnected’, () => { // Cleanup whatever UI component we created // for the Participant. console.log(‘%s disconnected’, identity) }) // … } JAVASCRIPT
  85. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity } = participant console.log(‘%s connected’, identity) participant.on(‘disconnected’, () => { // Cleanup whatever UI component we created // for the Participant. console.log(‘%s disconnected’, identity) }) // … } JAVASCRIPT
  86. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  87. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  88. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity } = participant console.log(‘%s connected’, identity) participant.on(‘disconnected’, () => { // Cleanup whatever UI component we created // for the Participant. console.log(‘%s disconnected’, identity) }) // … } JAVASCRIPT
  89. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { } JAVASCRIPT
  90. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant } JAVASCRIPT
  91. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) } JAVASCRIPT
  92. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) addParticipantView(participant) } JAVASCRIPT
  93. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) addParticipantView(participant) participant.once(‘disconnected’, () => { console.log(‘%s disconnected’, identity) }) } JAVASCRIPT
  94. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) addParticipantView(participant) participant.once(‘disconnected’, () => { console.log(‘%s disconnected’, identity) }) } JAVASCRIPT
  95. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) addParticipantView(participant) participant.once(‘disconnected’, () => { console.log(‘%s disconnected’, identity) removeParticipantView(participant) }) } JAVASCRIPT
  96. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) addParticipantView(participant) participant.once(‘disconnected’, () => { console.log(‘%s disconnected’, identity) removeParticipantView(participant) }) // 4. Handle Participants’ Tracks } JAVASCRIPT
  97. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) addParticipantView(participant) participant.once(‘disconnected’, () => { console.log(‘%s disconnected’, identity) removeParticipantView(participant) }) // 4. Handle Participants’ Tracks participant.tracks.forEach(handleTrackAdded) } JAVASCRIPT
  98. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { const { identity, sid } = participant console.log(‘%s (%s) connected’, identity, sid) addParticipantView(participant) participant.once(‘disconnected’, () => { console.log(‘%s disconnected’, identity) removeParticipantView(participant) }) // 4. Handle Participants’ Tracks participant.tracks.forEach(handleTrackAdded) participant.on(‘trackAdded’, handleTrackAdded) } JAVASCRIPT
  99. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { // … // 4. Handle Participants’ Tracks participant.tracks.forEach(handleTrackAdded) participant.on(‘trackAdded’, handleTrackAdded) } JAVASCRIPT
  100. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { // … // 4. Handle Participants’ Tracks participant.tracks.forEach(handleTrackAdded) participant.on(‘trackAdded’, handleTrackAdded) participant.on(‘trackRemoved’, handleTrackRemoved) } JAVASCRIPT
  101. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { // … // 4. Handle Participants’ Tracks participant.tracks.forEach(handleTrackAdded) participant.on(‘trackAdded’, handleTrackAdded) participant.on(‘trackRemoved’, handleTrackRemoved) } JAVASCRIPT
  102. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. // 3. Handle Participants room.participants.forEach(handleParticipant) room.on(‘participantConnected’, handleParticipant) function handleParticipant(participant) { // … // 4. Handle Participants’ Tracks participant.tracks.forEach(handleTrackAdded) participant.on(‘trackAdded’, handleTrackAdded) participant.on(‘trackRemoved’, handleTrackRemoved) } JAVASCRIPT
  103. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach(); videoElement.id = ‘track-‘ track.id; document.body.appendChild(videoElement); } function handleTrackRemoved(track) { const videoElements = track.detach(); videoElements.forEach(videoElement => { videoElement.remove(); });
 } JAVASCRIPT
  104. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() } function handleTrackRemoved(track) { const videoElements = track.detach(); videoElements.forEach(videoElement => { videoElement.remove(); });
 } JAVASCRIPT
  105. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id } function handleTrackRemoved(track) { const videoElements = track.detach(); videoElements.forEach(videoElement => { videoElement.remove(); });
 } JAVASCRIPT
  106. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach(); videoElements.forEach(videoElement => { videoElement.remove(); });
 } JAVASCRIPT
  107. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach(); videoElements.forEach(videoElement => { videoElement.remove(); });
 } JAVASCRIPT
  108. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach() } JAVASCRIPT
  109. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach() videoElements.forEach(videoElement => { })
 } JAVASCRIPT
  110. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach() videoElements.forEach(videoElement => { videoElement.remove() })
 } JAVASCRIPT
  111. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach() videoElements.forEach(videoElement => { videoElement.remove() })
 } // 5. Disconnect JAVASCRIPT
  112. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach() videoElements.forEach(videoElement => { videoElement.remove() })
 } // 5. Disconnect room.disconnect() JAVASCRIPT
  113. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach() videoElements.forEach(videoElement => { videoElement.remove() })
 } // 5. Disconnect room.disconnect() room.participants.forEach(removeParticipantView) JAVASCRIPT
  114. 1. Acquire LocalTracks 2. Connect to a Room 3. Handle

    Participants 4. Handle Participants’ Tracks 5. Disconnect © 2017 TWILIO, INC. ALL RIGHTS RESERVED. MAIN CONTENT AND SUPPORTING TEXT PROGRAMMABLE VIDEO FUNDAMENTALS © 2017 TWILIO, INC. ALL RIGHTS RESERVED. function handleTrackAdded(track) { const videoElement = track.attach() videoElement.id = ‘track-‘ track.id document.body.appendChild(videoElement) } function handleTrackRemoved(track) { const videoElements = track.detach() videoElements.forEach(videoElement => { videoElement.remove() })
 } // 5. Disconnect room.disconnect() room.participants.forEach(removeParticipantView) removeRoomView(room) JAVASCRIPT
  115. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  116. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  117. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  118. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    • https://github.com/twilio/video-quickstart-android • https://github.com/twilio/video-quickstart-js • https://github.com/twilio/video-quickstart-objc • https://github.com/twilio/video-quickstart-swift
  119. Access Tokens & Room Security © 2017 TWILIO, INC. ALL

    RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS
  120. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. Access Tokens grant your apps access to Twilio services
  121. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. Access Tokens grant your apps access to Twilio services 2. Used by Programmable Voice, Video, Chat, Sync, etc.
  122. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. Access Tokens grant your apps access to Twilio services 2. Used by Programmable Voice, Video, Chat, Sync, etc. 3. Encode client identity & product- specific capabilities
  123. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. Access Tokens grant your apps access to Twilio services 2. Used by Programmable Voice, Video, Chat, Sync, etc. 3. Encode client identity & product- specific capabilities 4. Mix-and-match capabilities from different products in the same Access Token
  124. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  125. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  126. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  127. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Programmable Video APIs
  128. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": "Alice", "video": { "room": "My Cool Room” } } } ACCESS TOKENS
  129. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": "Alice", "video": { "room": "My Cool Room” } } } 1. API Key SID ACCESS TOKENS
  130. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": "Alice", "video": { "room": "My Cool Room” } } } 1. API Key SID 2. Account SID ACCESS TOKENS
  131. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": "Alice", "video": { "room": "My Cool Room” } } } 1. API Key SID 2. Account SID 3. Expiration Date ACCESS TOKENS
  132. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": "Alice", "video": { "room": "My Cool Room” } } } 1. API Key SID 2. Account SID 3. Expiration Date 4. Client Identity ACCESS TOKENS
  133. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": “[email protected]”, "video": { "room": "My Cool Room” } } } 1. API Key SID 2. Account SID 3. Expiration Date 4. Client Identity ACCESS TOKENS
  134. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": “1234567890”, "video": { "room": "My Cool Room” } } } 1. API Key SID 2. Account SID 3. Expiration Date 4. Client Identity ACCESS TOKENS
  135. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": "Alice", "video": { "room": "My Cool Room” } } } 1. API Key SID 2. Account SID 3. Expiration Date 4. Client Identity 5. Room Name (optional) ACCESS TOKENS
  136. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. { "iss": "SK9eae711dc87feb56fdcfce9ef0b93354", "sub": "ACcd224d70006373d9b37eb3202c52df90", "exp": 1494914080, "grants": { "identity": "Alice", "video": {} } } 1. API Key SID 2. Account SID 3. Expiration Date 4. Client Identity 5. Room Name (optional) ACCESS TOKENS
  137. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. Create Access Tokens in the Twilio Console during development.
  138. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. Create Access Tokens in the Twilio Console during development. 2. Vend Access Tokens from an application server in production.
  139. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. Create Access Tokens in the Twilio Console during development. 2. Vend Access Tokens from an application server in production. 3. Helper libraries for Node, PHP, Python, Java, C#, etc.
  140. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB { identity: “Alice”, video: {} } { identity: “Bob”, video: {} } USER DATABASE
  141. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB { identity: “Alice”, video: {} } { identity: “Bob”, video: {} } USER DATABASE
  142. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB { identity: “Alice”, video: { room: “Foo” } } { identity: “Bob”, video: { room: “Foo” } } USER DATABASE
  143. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB USER DATABASE Foo ROOM { identity: “Alice”, video: { room: “Foo” } } { identity: “Bob”, video: { room: “Foo” } }
  144. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB USER DATABASE Foo ROOM { identity: “Alice”, video: { room: “Foo” } } { identity: “Bob”, video: { room: “Foo” } }
  145. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB USER DATABASE ????
  146. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB USER DATABASE ????
  147. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB USER DATABASE ROOM
  148. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  149. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  150. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  151. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. GET /v1/Rooms
 Get the list of Rooms created in your account.
  152. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. GET /v1/Rooms
 Get the list of Rooms created in your account. 2. GET /v1/Rooms/{RoomNameOrSid}
 Get a particular Room by name or SID.
  153. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. 1. GET /v1/Rooms
 Get the list of Rooms created in your account. 2. GET /v1/Rooms/{RoomNameOrSid}
 Get a particular Room by name or SID. 3. POST /v1/Rooms
 Create a new Room.
  154. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB POST /v1/Rooms UniqueName=Foo
  155. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB POST /v1/Rooms UniqueName=Foo Foo ROOM
  156. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB { identity: “Alice”, video: { room: “Foo”
 } } { identity: “Bob”, video: { room: “Foo”
 } } Foo ROOM
  157. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB { identity: “Alice”, video: { room: “Foo”
 } } { identity: “Bob”, video: { room: “Foo”
 } } Foo ROOM
  158. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    ALICE APP SERVER TWILIO BOB Foo ROOM { identity: “Alice”, video: { room: “Foo”
 } } { identity: “Bob”, video: { room: “Foo”
 } }
  159. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • UniqueName
 The name of the Room to create
  160. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • UniqueName
 The name of the Room to create • EnableTurn
 “true” or “false”
  161. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • UniqueName
 The name of the Room to create • EnableTurn
 “true” or “false” • Type
 “peer-to-peer” or “group”
  162. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. PEER-TO-PEER ROOM GROUP ROOM
  163. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • UniqueName
 The name of the Room to create • EnableTurn
 “true” or “false” • Type
 “peer-to-peer” or “group”
  164. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • UniqueName
 The name of the Room to create • EnableTurn
 “true” or “false” • Type
 “peer-to-peer” or “group” • MaxParticipants
 Number of Participants that can connect to the Room at a time
  165. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • RecordParticipantsOnConnect
 Whether or not to start recording Participants
  166. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. • RecordParticipantsOnConnect
 Whether or not to start recording Participants • StatusCallback
 A URL that Twilio sends webhook requests to on Room events
  167. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    APP SERVER TWILIO participant connected ALICE BOB
  168. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    APP SERVER TWILIO participant connected ALICE BOB
  169. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. PROGRAMMABLE VIDEO FUNDAMENTALS

    APP SERVER TWILIO participant disconnected ✕ 2 ALICE BOB
  170. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  171. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  172. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  173. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  174. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  175. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  176. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  177. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  178. 1. Set the default Room type, either P2P or Group

    2. Enable or disable TURN 3. Limit the maximum number of Participants in a Room 4. Allow or disallow application users to create ad-hoc Rooms © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. Account-level
 Configuration
  179. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Production Check-list
  180. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Production Check-list 1. Room Type: P2P or Group?
  181. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Production Check-list 1. Room Type: P2P or Group? 2. Access Tokens & Room Security
  182. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Production Check-list 1. Room Type: P2P or Group? 2. Access Tokens & Room Security 3. Network Conditions
  183. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. © 2017 TWILIO,

    INC. ALL RIGHTS RESERVED. Production Check-list 1. Room Type: P2P or Group? 2. Access Tokens & Room Security 3. Network Conditions 4. Capture Dimensions
  184. © 2017 TWILIO, INC. ALL RIGHTS RESERVED. SPEAKER LINEUP HELLO,

    TWILIO Kat King 9:20 AM 9:50 AM 10:30 AM 11:00 AM 11:30 AM BREAK 1:00 PM 1:40 PM 2:20 PM 3:00 PM 3:40 PM 5:00 PM 5:15 PM CHAT FUNDAMENTALS Randy Beiter SYNC FUNDAMENTALS Andres Jaan Tack NOTIFY FUNDAMENTALS Ankita Bhosle VIDEO FUNDAMENTALS Mark Roberts SMS: BEYOND THE BASICS Kenny Hoxworth POWER UP WITH ADD-ONS Edward Kim & Hiral Patel CONTACT CENTER ARCHITECTURE Matthias Damm & Charles Oppenheimer TASKROUTER FUNDAMENTALS Jen Li & Justin Witz AUTHY FUNDAMENTALS Marcelo Jabali GROUP PHOTO (OUTSIDE) AWARD CEREMONY