SlideShare a Scribd company logo
PBS Interactive API Workshop
   Edgar Román, Senior Director, Application Development, PBS
                         April 8, 2011
Overview
•  TV Schedules API
•  COVE API
Agenda : TV Schedules API
•    Getting Started
•    Understanding the models
•    Typical usage walkthrough
•    What’s next?
WPT Example
http://wptschedule.org/schedulenow.php
Getting Started: TV Schedules
•  How do I get a key?
  Fill out this form:
  http://open.pbs.org/pbs-api-key-request/
•  What kind of data is returned?
  –  Read-only REST API or XML RPC
  –  Returns XML or JSON
•  How is it protected?
  –  Simple key based authentication
Understanding the models
                                   Provider
                                (e.g. Cable Vendor)




            Head End A                                Head End B               Station
        (e.g. Cable Operator)                                                  (e.g. KRWG)




              Feed 1                     Feed 2                Feed 3           Feed 4
              (Channel)




Listing X            Listing Y                                     Listing W        Listing Z
Typical usage walkthrough
                               Start with a Zip code (Optional)
getHeadEndsByZipTagged                                                      getStationsByZip




    Find a Head End (Cable Operator)                              Pick a Station


              getStationsByHeadend

                                                         Select a Feed (Channel)
                         getFeedsWithMetadata




                          getAirdatesByFeed
                                                                  Pull Listings
Complete Example
                       (using unreadable font)
http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getHeadendsByZipTagged?
zipcode=20818&apikey=YOUR-API-KEY

http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getStationsByHeadend?
headendID=324045&apikey=YOUR-API-KEY

http://tvschedules.pbs.org/tvschedules/api/rest/tvSchedules/getFeedsWithMetadata?
tvDataNames=WETA&headendID=324045&apikey=YOUR-API-KEY

http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getStationsByZip?
zipcode=20818&apikey=YOUR-API-KEY

http://tvschedules.pbs.org/tvschedules/api/rest/tvSchedules/getFeedsWithMetadata?
tvDataNames=WETA&apikey=YOUR-API-KEY

http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getAirdatesByFeed?
feedID=9854&startTime=2010-09-15T00:00:00&endTime=2010-09-15T02:00:00&apikey=YOUR-API-
KEY
getHeadendsByZipTagged?zipcode=20001
getStationsByZip?zipcode=20001
Agenda : COVE API
•    Getting Started
•    Understanding the models
•    Available Methods
•    Typical usage walkthrough
•    How to play video
•    Authentication
•    What’s next?
Getting Started: COVE API
•  How do I get a key?
  –  Tell you in a bit
•  What kind of data is returned?
  –  Read-only REST API
  –  COVE API only returns JSON
•  How is it protected?
  –  Hefty authentication mechanism (So no jQuery
     access)
•  How can I get video?
  –  Returns only RTMP links, so roll your own HTML
     player
Understanding the models
                                              WCFE
            Producer A                      (Mountain
                                            Lake PBS)


Program X                Program Y         Rustic Living



 Video 1          Video 2        Video 3   Camp Little
                                             Pine
Methods
•  Programs
  http://api.pbs.org/cove/v1/programs/
•  Videos
  http://api.pbs.org/cove/v1/videos/
/cove/v1/programs
•  Getting all the programs
  http://api.pbs.org/cove/v1/programs/


•  Getting metadata about one program
  http://api.pbs.org/cove/v1/programs/408/
/cove/v1/programs/408 - sample
/cove/v1/programs - filters
•  Getting all national programs
  http://api.pbs.org/cove/v1/programs/?filter_producer__name=PBS



•  Getting all station programs
  http://api.pbs.org/cove/v1/programs/?filter_producer__name=KRMA
/cove/v1/videos
•  Getting all the videos
  http://api.pbs.org/cove/v1/videos/


•  Getting metadata about one video
  http://api.pbs.org/cove/v1/videos/36032/
/cove/v1/videos - filters
•  Typical query filters
  –  Only Available Videos (not expired)
  –  Of type: Episode, Clip, Segment, Promotion
  –  That belong to a particular program
  –  In a compatible encoding format
•  Typical output adjustments
  –  Give me associated images
  –  Sort by most recent airdate
  –  Give me 20 at a time
/cove/v1/videos – sample query
http://api.pbs.org/cove/v1/videos/
?filter_availability_status=Available
&exclude_type=Chapter
&filter_program=455
&filter_mediafile_set__video_encoding__eeid=
MPEG-4 500kbps
&fields=associated_images
&order_by=-airdate
&limit_start=0&limit_stop=20
Typical usage walkthrough
•  App starts and pulls a list of all relevant
   programs
•  Once user selects a program, the app
   should query for a short list of relevant
   videos
•  If a user selects a video, the app
   generates the html needed to stream
How to play video
•  The COVE API doesn’t provide HTML to
   play the video (yet)
•  Your app has to construct the HTML based
   on guidelines at:
  http://projects.pbs.org/confluence/display/coveapi/How+to+Render+Videos
Sample HTML – Simple link
•  From the video JSON, extract:
   tp_media_object_id
•  Use:
  http://video.pbs.org/videos/<tp_media_object_id>
  Or
  http://video.weta.org/videos/<tp_media_object_id>
Sample HTML – Partner Player
•  From the video JSON, extract: tp_media_object_id

<iframe id="partnerPlayer" frameborder="0"
marginwidth="0" marginheight="0" scrolling="no"
style="width:512px; height:328px;" src="http://
video.pbs.org/widget/partnerplayer/
<tp_media_object_id>/?player=<player
string>w=512&h=288&chapterbar=true&autoplay=false">
</iframe>
Sample HTML – Partner Player
          Result
Authentication
•  Every call to the endpoints must be
   authenticated
•  Based on OAuth, but is not Oauth
  –  Two-legged OAuth actually
•  Sample implementations provided on the
   documentation site
•  Front-end a jQuery app using AJAX calls
•  Active station collaborative efforts to improve existing
   products and knowledgebase
    –  Share ideas
    –  Compare tricks of the trade
    –  Solve common problems
    –  Early product access
•  April: COVE API Collaborative Competition
    –  Participants: KLRU, KPBS, Iowa PTV, TPT, KET,
       KCTS, WGBH, Maine PBN, CET, NHPTV
•  Coordinated product building activities with openPBS
   community
•  Visit spiblog.pbs.org to learn more and find out about
   future collaborative opportunities
How to get COVE API keys
•  Fill out this form:
   http://open.pbs.org/pbs-api-key-request/
•  Will start giving out keys after incubation
   lab (early May)
•  Check back often in the incubation labs for
   new API features and functionality
What’s next?
•  Easy authentication
  –  Supporting jQuery
•  Provided HTML for video playback
•  More exciting queries
  –  Tell me what you want!
Links from this presentation
•  This presentation
  http://open.pbs.org/post/2011-techcon-slides/
•  COVE API Docs
  http://projects.pbs.org/confluence/display/coveapi/Welcome

•  COVE API url
  http://api.pbs.org/cove/v1
Questions and Comments
•  Edgar Román
     emroman@pbs.org

More Related Content

Viewers also liked

The Evolution of Ragheb
The Evolution of RaghebThe Evolution of Ragheb
The Evolution of Ragheb
cuebal
 
Simplified Localization+ Presentation
Simplified Localization+ PresentationSimplified Localization+ Presentation
Simplified Localization+ Presentation
Public Broadcasting Service
 
past simple regular verbs
past simple regular verbspast simple regular verbs
past simple regular verbscryseyde
 
Cloud Orchestration is Broken
Cloud Orchestration is BrokenCloud Orchestration is Broken
Cloud Orchestration is Broken
Public Broadcasting Service
 
IBM Connect 2016 - Break out of the Box
IBM Connect 2016 - Break out of the BoxIBM Connect 2016 - Break out of the Box
IBM Connect 2016 - Break out of the Box
Karl-Henry Martinsson
 
I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...
I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...
I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...
Public Broadcasting Service
 
Peformance Comparison For Large Dsp(For Distribution)
Peformance Comparison For Large Dsp(For Distribution)Peformance Comparison For Large Dsp(For Distribution)
Peformance Comparison For Large Dsp(For Distribution)cahyadi prasetya
 
72219130 sondir
72219130 sondir72219130 sondir
72219130 sondir
Bunz Lynch
 
Architecture at PBS
Architecture at PBSArchitecture at PBS
Architecture at PBS
Public Broadcasting Service
 
AD102 - Break out of the Box
AD102 - Break out of the BoxAD102 - Break out of the Box
AD102 - Break out of the Box
Karl-Henry Martinsson
 
Teori bronfenbrenner
Teori bronfenbrennerTeori bronfenbrenner
Teori bronfenbrenner
Badriyatun Kamar
 
Break out of The Box - Part 2
Break out of The Box - Part 2Break out of The Box - Part 2
Break out of The Box - Part 2
Karl-Henry Martinsson
 

Viewers also liked (19)

The Evolution of Ragheb
The Evolution of RaghebThe Evolution of Ragheb
The Evolution of Ragheb
 
Punto gt power
Punto gt powerPunto gt power
Punto gt power
 
PBS Presentation at AWS Summit 2012
PBS Presentation at AWS Summit 2012PBS Presentation at AWS Summit 2012
PBS Presentation at AWS Summit 2012
 
Simplified Localization+ Presentation
Simplified Localization+ PresentationSimplified Localization+ Presentation
Simplified Localization+ Presentation
 
past simple regular verbs
past simple regular verbspast simple regular verbs
past simple regular verbs
 
Bebicon
BebiconBebicon
Bebicon
 
Cloud Orchestration is Broken
Cloud Orchestration is BrokenCloud Orchestration is Broken
Cloud Orchestration is Broken
 
Pycon2013
Pycon2013Pycon2013
Pycon2013
 
Mobile Presentation at PBS TECH CON 2011
Mobile Presentation at PBS TECH CON 2011Mobile Presentation at PBS TECH CON 2011
Mobile Presentation at PBS TECH CON 2011
 
IBM Connect 2016 - Break out of the Box
IBM Connect 2016 - Break out of the BoxIBM Connect 2016 - Break out of the Box
IBM Connect 2016 - Break out of the Box
 
I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...
I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...
I've Got a Key to Your API, Now What? (Joint PBS and NPR API Presentation Giv...
 
Peformance Comparison For Large Dsp(For Distribution)
Peformance Comparison For Large Dsp(For Distribution)Peformance Comparison For Large Dsp(For Distribution)
Peformance Comparison For Large Dsp(For Distribution)
 
Câu hỏi phong van
Câu hỏi phong vanCâu hỏi phong van
Câu hỏi phong van
 
72219130 sondir
72219130 sondir72219130 sondir
72219130 sondir
 
Hitachi Oil Free
Hitachi Oil FreeHitachi Oil Free
Hitachi Oil Free
 
Architecture at PBS
Architecture at PBSArchitecture at PBS
Architecture at PBS
 
AD102 - Break out of the Box
AD102 - Break out of the BoxAD102 - Break out of the Box
AD102 - Break out of the Box
 
Teori bronfenbrenner
Teori bronfenbrennerTeori bronfenbrenner
Teori bronfenbrenner
 
Break out of The Box - Part 2
Break out of The Box - Part 2Break out of The Box - Part 2
Break out of The Box - Part 2
 

Similar to PBS Tech Con 2011 API Workshop

WHIP and Janus @ IIT-RTC 2021
WHIP and Janus @ IIT-RTC 2021WHIP and Janus @ IIT-RTC 2021
WHIP and Janus @ IIT-RTC 2021
Lorenzo Miniero
 
Kubernetes Workshop
Kubernetes WorkshopKubernetes Workshop
Kubernetes Workshop
loodse
 
IoT Aquarium 2
IoT Aquarium 2IoT Aquarium 2
IoT Aquarium 2
Benjamin Chodroff
 
AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...
AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...
AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...
Amazon Web Services
 
AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...
AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...
AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...Amazon Web Services
 
Route service-pcf-techmeetup
Route service-pcf-techmeetupRoute service-pcf-techmeetup
Route service-pcf-techmeetup
Gwenn Etourneau
 
Build and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API GatewayBuild and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API Gateway
Amazon Web Services
 
A Brief History of OWIN
A Brief History of OWINA Brief History of OWIN
A Brief History of OWIN
Ryan Riley
 
Pywps a tutorial for beginners and developers
Pywps a tutorial for beginners and developersPywps a tutorial for beginners and developers
Pywps a tutorial for beginners and developers
Jorge Mendes
 
Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...
Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...
Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...
Provectus
 
Going FaaSter, Functions as a Service at Netflix
Going FaaSter, Functions as a Service at NetflixGoing FaaSter, Functions as a Service at Netflix
Going FaaSter, Functions as a Service at Netflix
Yunong Xiao
 
System Testing and Integration: Test Strategy for Brahmaputra
System Testing and Integration: Test Strategy for BrahmaputraSystem Testing and Integration: Test Strategy for Brahmaputra
System Testing and Integration: Test Strategy for Brahmaputra
OPNFV
 
Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)
Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)
Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)
Chris Adamson
 
Hands on with CoAP and Californium
Hands on with CoAP and CaliforniumHands on with CoAP and Californium
Hands on with CoAP and Californium
Julien Vermillard
 
Storage Is Not Virtualized Enough - part 1
Storage Is Not Virtualized Enough - part 1Storage Is Not Virtualized Enough - part 1
Storage Is Not Virtualized Enough - part 1
Zhipeng Huang
 
Server Side Swift
Server Side SwiftServer Side Swift
Server Side Swift
Chad Moone
 
Getting Started With Aura
Getting Started With AuraGetting Started With Aura
Getting Started With Aura
Chris Tankersley
 
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Robert Nelson
 
VoLTE Testing Solution in NFV ecosystem
VoLTE Testing Solution in NFV ecosystemVoLTE Testing Solution in NFV ecosystem
VoLTE Testing Solution in NFV ecosystem
Debayan Chaudhuri
 

Similar to PBS Tech Con 2011 API Workshop (20)

WHIP and Janus @ IIT-RTC 2021
WHIP and Janus @ IIT-RTC 2021WHIP and Janus @ IIT-RTC 2021
WHIP and Janus @ IIT-RTC 2021
 
Kubernetes Workshop
Kubernetes WorkshopKubernetes Workshop
Kubernetes Workshop
 
Sword Crig 2007 12 06
Sword Crig 2007 12 06Sword Crig 2007 12 06
Sword Crig 2007 12 06
 
IoT Aquarium 2
IoT Aquarium 2IoT Aquarium 2
IoT Aquarium 2
 
AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...
AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...
AWS July Webinar Series: Overview: Build and Manage your APIs with Amazon API...
 
AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...
AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...
AWS July Webinar Series - Overview Build and Manage your APs with amazon api ...
 
Route service-pcf-techmeetup
Route service-pcf-techmeetupRoute service-pcf-techmeetup
Route service-pcf-techmeetup
 
Build and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API GatewayBuild and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API Gateway
 
A Brief History of OWIN
A Brief History of OWINA Brief History of OWIN
A Brief History of OWIN
 
Pywps a tutorial for beginners and developers
Pywps a tutorial for beginners and developersPywps a tutorial for beginners and developers
Pywps a tutorial for beginners and developers
 
Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...
Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...
Data Summer Conf 2018, “Building unified Batch and Stream processing pipeline...
 
Going FaaSter, Functions as a Service at Netflix
Going FaaSter, Functions as a Service at NetflixGoing FaaSter, Functions as a Service at Netflix
Going FaaSter, Functions as a Service at Netflix
 
System Testing and Integration: Test Strategy for Brahmaputra
System Testing and Integration: Test Strategy for BrahmaputraSystem Testing and Integration: Test Strategy for Brahmaputra
System Testing and Integration: Test Strategy for Brahmaputra
 
Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)
Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)
Building A Streaming Apple TV App (CocoaConf San Jose, Nov 2016)
 
Hands on with CoAP and Californium
Hands on with CoAP and CaliforniumHands on with CoAP and Californium
Hands on with CoAP and Californium
 
Storage Is Not Virtualized Enough - part 1
Storage Is Not Virtualized Enough - part 1Storage Is Not Virtualized Enough - part 1
Storage Is Not Virtualized Enough - part 1
 
Server Side Swift
Server Side SwiftServer Side Swift
Server Side Swift
 
Getting Started With Aura
Getting Started With AuraGetting Started With Aura
Getting Started With Aura
 
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
 
VoLTE Testing Solution in NFV ecosystem
VoLTE Testing Solution in NFV ecosystemVoLTE Testing Solution in NFV ecosystem
VoLTE Testing Solution in NFV ecosystem
 

Recently uploaded

Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Product School
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
Frank van Harmelen
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
Laura Byrne
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi
Fwdays
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
Alison B. Lowndes
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
Elena Simperl
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
Product School
 
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMsTo Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
Paul Groth
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Product School
 
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
Product School
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Tobias Schneck
 

Recently uploaded (20)

Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi"Impact of front-end architecture on development cost", Viktor Turskyi
"Impact of front-end architecture on development cost", Viktor Turskyi
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
 
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMsTo Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
 
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
 

PBS Tech Con 2011 API Workshop

  • 1. PBS Interactive API Workshop Edgar Román, Senior Director, Application Development, PBS April 8, 2011
  • 2. Overview •  TV Schedules API •  COVE API
  • 3. Agenda : TV Schedules API •  Getting Started •  Understanding the models •  Typical usage walkthrough •  What’s next?
  • 5. Getting Started: TV Schedules •  How do I get a key? Fill out this form: http://open.pbs.org/pbs-api-key-request/ •  What kind of data is returned? –  Read-only REST API or XML RPC –  Returns XML or JSON •  How is it protected? –  Simple key based authentication
  • 6. Understanding the models Provider (e.g. Cable Vendor) Head End A Head End B Station (e.g. Cable Operator) (e.g. KRWG) Feed 1 Feed 2 Feed 3 Feed 4 (Channel) Listing X Listing Y Listing W Listing Z
  • 7. Typical usage walkthrough Start with a Zip code (Optional) getHeadEndsByZipTagged getStationsByZip Find a Head End (Cable Operator) Pick a Station getStationsByHeadend Select a Feed (Channel) getFeedsWithMetadata getAirdatesByFeed Pull Listings
  • 8. Complete Example (using unreadable font) http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getHeadendsByZipTagged? zipcode=20818&apikey=YOUR-API-KEY http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getStationsByHeadend? headendID=324045&apikey=YOUR-API-KEY http://tvschedules.pbs.org/tvschedules/api/rest/tvSchedules/getFeedsWithMetadata? tvDataNames=WETA&headendID=324045&apikey=YOUR-API-KEY http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getStationsByZip? zipcode=20818&apikey=YOUR-API-KEY http://tvschedules.pbs.org/tvschedules/api/rest/tvSchedules/getFeedsWithMetadata? tvDataNames=WETA&apikey=YOUR-API-KEY http://tvschedules.pbs.org/tvschedules/api/rest/stationFinder/getAirdatesByFeed? feedID=9854&startTime=2010-09-15T00:00:00&endTime=2010-09-15T02:00:00&apikey=YOUR-API- KEY
  • 11. Agenda : COVE API •  Getting Started •  Understanding the models •  Available Methods •  Typical usage walkthrough •  How to play video •  Authentication •  What’s next?
  • 12. Getting Started: COVE API •  How do I get a key? –  Tell you in a bit •  What kind of data is returned? –  Read-only REST API –  COVE API only returns JSON •  How is it protected? –  Hefty authentication mechanism (So no jQuery access) •  How can I get video? –  Returns only RTMP links, so roll your own HTML player
  • 13. Understanding the models WCFE Producer A (Mountain Lake PBS) Program X Program Y Rustic Living Video 1 Video 2 Video 3 Camp Little Pine
  • 14. Methods •  Programs http://api.pbs.org/cove/v1/programs/ •  Videos http://api.pbs.org/cove/v1/videos/
  • 15. /cove/v1/programs •  Getting all the programs http://api.pbs.org/cove/v1/programs/ •  Getting metadata about one program http://api.pbs.org/cove/v1/programs/408/
  • 17. /cove/v1/programs - filters •  Getting all national programs http://api.pbs.org/cove/v1/programs/?filter_producer__name=PBS •  Getting all station programs http://api.pbs.org/cove/v1/programs/?filter_producer__name=KRMA
  • 18. /cove/v1/videos •  Getting all the videos http://api.pbs.org/cove/v1/videos/ •  Getting metadata about one video http://api.pbs.org/cove/v1/videos/36032/
  • 19.
  • 20. /cove/v1/videos - filters •  Typical query filters –  Only Available Videos (not expired) –  Of type: Episode, Clip, Segment, Promotion –  That belong to a particular program –  In a compatible encoding format •  Typical output adjustments –  Give me associated images –  Sort by most recent airdate –  Give me 20 at a time
  • 21. /cove/v1/videos – sample query http://api.pbs.org/cove/v1/videos/ ?filter_availability_status=Available &exclude_type=Chapter &filter_program=455 &filter_mediafile_set__video_encoding__eeid= MPEG-4 500kbps &fields=associated_images &order_by=-airdate &limit_start=0&limit_stop=20
  • 22.
  • 23. Typical usage walkthrough •  App starts and pulls a list of all relevant programs •  Once user selects a program, the app should query for a short list of relevant videos •  If a user selects a video, the app generates the html needed to stream
  • 24. How to play video •  The COVE API doesn’t provide HTML to play the video (yet) •  Your app has to construct the HTML based on guidelines at: http://projects.pbs.org/confluence/display/coveapi/How+to+Render+Videos
  • 25. Sample HTML – Simple link •  From the video JSON, extract: tp_media_object_id •  Use: http://video.pbs.org/videos/<tp_media_object_id> Or http://video.weta.org/videos/<tp_media_object_id>
  • 26. Sample HTML – Partner Player •  From the video JSON, extract: tp_media_object_id <iframe id="partnerPlayer" frameborder="0" marginwidth="0" marginheight="0" scrolling="no" style="width:512px; height:328px;" src="http:// video.pbs.org/widget/partnerplayer/ <tp_media_object_id>/?player=<player string>w=512&h=288&chapterbar=true&autoplay=false"> </iframe>
  • 27. Sample HTML – Partner Player Result
  • 28. Authentication •  Every call to the endpoints must be authenticated •  Based on OAuth, but is not Oauth –  Two-legged OAuth actually •  Sample implementations provided on the documentation site •  Front-end a jQuery app using AJAX calls
  • 29. •  Active station collaborative efforts to improve existing products and knowledgebase –  Share ideas –  Compare tricks of the trade –  Solve common problems –  Early product access •  April: COVE API Collaborative Competition –  Participants: KLRU, KPBS, Iowa PTV, TPT, KET, KCTS, WGBH, Maine PBN, CET, NHPTV •  Coordinated product building activities with openPBS community •  Visit spiblog.pbs.org to learn more and find out about future collaborative opportunities
  • 30. How to get COVE API keys •  Fill out this form: http://open.pbs.org/pbs-api-key-request/ •  Will start giving out keys after incubation lab (early May) •  Check back often in the incubation labs for new API features and functionality
  • 31. What’s next? •  Easy authentication –  Supporting jQuery •  Provided HTML for video playback •  More exciting queries –  Tell me what you want!
  • 32. Links from this presentation •  This presentation http://open.pbs.org/post/2011-techcon-slides/ •  COVE API Docs http://projects.pbs.org/confluence/display/coveapi/Welcome •  COVE API url http://api.pbs.org/cove/v1
  • 33. Questions and Comments •  Edgar Román emroman@pbs.org