SlideShare a Scribd company logo
1 of 14
Download to read offline
Near-Real-Time, Simple awesomeness



Web Hooks

      nathan@pbwiki.com


                             coming soon!
Recall From SHDH 17
               Jeff Lindsay’s
               “Web hooks”
               lightning talk


             • RSS relies on polling.
             • Polling is lame.
             • Syndication and
             (re)publishing, not
             triggering
Recall From SHDH 17
                       Jeff Lindsay’s
                       “Web hooks”




NO
                       lightning talk

                     • Often n consumers.
                     • Not 1000n.
                     • Polling is still lame.
 (for some things)   • Are we there yet?
                     • Are we there yet?
                     • Are we there yet?
Recall From SHDH 17
              Jeff Lindsay’s
              “Web hooks”
              lightning talk

             • Event-driven.
             • Lightweight.
             • POST to a URL.
Recall From SHDH 17
              Jeff Lindsay’s
              “Web hooks”
OLD LOGO
              lightning talk

             • Event-driven.
             • Lightweight.
             • POST to a URL.
Web hooks in practice
//something ...
hook_trigger(‘viewpage’);
//more stuff..


  async


            async
  while(1) {
    while($queued = $q->get(‘async-queue’)) {
      post_to_url($queued[‘url’],$queued[‘postargs’]);
    }
  }
Web hooks in practice
             Example hooked events
             • login/logout
             • edit a page
             • revert a page
             • delete a page
             • comment on a page
             • tag/untag pages
             • join/unjoin wiki
             • return_after_absence
             • view_for_first_time
Web hooks in practice
Web hooks in practice
Web hooks in practice
Web hooks in practice
Web hooks in practice
I want this to exist:
    Trigger              Filter         Branch/Merge                 Transform               Route
                        $page =~              $to =                     $msg =
                                                                                        out_aim($to,$msg)
                        /deploy/i       [‘devel@’,ops@’]           fmt_to_aim($attrs)

                         $uid ==        $to = @all_sms;                 $msg =
                                                                                        out_sms($to,$msg)
                     da39a3ee5e6b4b     unset($to[$uid]);          fmt_to_sms($attrs)
incoming web hook
                                                                     $msg = “Wow
                    $viewcount == 100 $to = $emails[$uid]                              out_email($to,$msg)
                                                                  you’re a power user”

                                       $to = [‘http://my.com/’,
                      $op == ‘edit’                                  $msg = $attrs      out_hook($to,$msg);
                                        ‘http://twittr.com/me’]




                                  = awesome but only polling (RSS)
Web Hooks On Pbwiki

More Related Content

What's hot (8)

Ros eyes ros-robots
Ros eyes ros-robotsRos eyes ros-robots
Ros eyes ros-robots
 
Medical Tourism in Croatia - Information for Russian patients
Medical Tourism in Croatia - Information for Russian patientsMedical Tourism in Croatia - Information for Russian patients
Medical Tourism in Croatia - Information for Russian patients
 
062 aljuma
062 aljuma062 aljuma
062 aljuma
 
Transports terrestres
Transports terrestresTransports terrestres
Transports terrestres
 
HYVES - Let's Earn Some Media
HYVES - Let's Earn Some MediaHYVES - Let's Earn Some Media
HYVES - Let's Earn Some Media
 
Hot Wedding Bouguets
Hot Wedding BouguetsHot Wedding Bouguets
Hot Wedding Bouguets
 
Acrostics 2n
Acrostics 2nAcrostics 2n
Acrostics 2n
 
Beginning web programming with PHP [PHP 101-02]
Beginning web programming with PHP [PHP 101-02]Beginning web programming with PHP [PHP 101-02]
Beginning web programming with PHP [PHP 101-02]
 

Viewers also liked

Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)
Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)
Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)
Jeff Chu
 
Hack Party SHDH Lightning Talk
Hack Party SHDH Lightning TalkHack Party SHDH Lightning Talk
Hack Party SHDH Lightning Talk
Jeff Lindsay
 

Viewers also liked (20)

Web Hooks
Web HooksWeb Hooks
Web Hooks
 
APIs That Make Things Happen
APIs That Make Things HappenAPIs That Make Things Happen
APIs That Make Things Happen
 
WebHooks in 10 Minutes
WebHooks in 10 MinutesWebHooks in 10 Minutes
WebHooks in 10 Minutes
 
Building Event Driven API Services Using Webhooks
Building Event Driven API Services Using WebhooksBuilding Event Driven API Services Using Webhooks
Building Event Driven API Services Using Webhooks
 
Using Web Hooks
Using Web HooksUsing Web Hooks
Using Web Hooks
 
There's a Webhook for That
There's a Webhook for ThatThere's a Webhook for That
There's a Webhook for That
 
V1 of The Computer Scientist and The Cleaner
V1 of The Computer Scientist and The CleanerV1 of The Computer Scientist and The Cleaner
V1 of The Computer Scientist and The Cleaner
 
SignalR & SQL Dependency
SignalR & SQL DependencySignalR & SQL Dependency
SignalR & SQL Dependency
 
Webhooks - glue for the web
Webhooks - glue for the webWebhooks - glue for the web
Webhooks - glue for the web
 
Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)
Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)
Microsoft Azure 虛擬機器與虛擬網路 (2014-4-2 雲端達人班)
 
From an idea to a Startup
From an idea to a StartupFrom an idea to a Startup
From an idea to a Startup
 
危機管理のリーダーシップ自己効力感尺度日本語版(C-LEAD-J)
危機管理のリーダーシップ自己効力感尺度日本語版(C-LEAD-J)危機管理のリーダーシップ自己効力感尺度日本語版(C-LEAD-J)
危機管理のリーダーシップ自己効力感尺度日本語版(C-LEAD-J)
 
How WebHooks Will Make Us All Programmers
How WebHooks Will Make Us All ProgrammersHow WebHooks Will Make Us All Programmers
How WebHooks Will Make Us All Programmers
 
Webhooks, Asynchronous Web Applications and Push Notifications
Webhooks, Asynchronous Web Applications and Push NotificationsWebhooks, Asynchronous Web Applications and Push Notifications
Webhooks, Asynchronous Web Applications and Push Notifications
 
Hack Party SHDH Lightning Talk
Hack Party SHDH Lightning TalkHack Party SHDH Lightning Talk
Hack Party SHDH Lightning Talk
 
How to Get Started with Google Voice
How to Get Started with Google VoiceHow to Get Started with Google Voice
How to Get Started with Google Voice
 
Digital tech and consumer behaviour
Digital tech and consumer behaviourDigital tech and consumer behaviour
Digital tech and consumer behaviour
 
Get Hooked on Integrations with GitHub
Get Hooked on Integrations with GitHubGet Hooked on Integrations with GitHub
Get Hooked on Integrations with GitHub
 
Real Time Connected Vehicle Networking with HDInsight and Apache Storm
Real Time Connected Vehicle Networking with HDInsight and Apache StormReal Time Connected Vehicle Networking with HDInsight and Apache Storm
Real Time Connected Vehicle Networking with HDInsight and Apache Storm
 
Chatbot for kintone Apps on Facebook Messenger
Chatbot for kintone Apps on Facebook MessengerChatbot for kintone Apps on Facebook Messenger
Chatbot for kintone Apps on Facebook Messenger
 

Similar to Web Hooks On Pbwiki

Remy Sharp The DOM scripting toolkit jQuery
Remy Sharp The DOM scripting toolkit jQueryRemy Sharp The DOM scripting toolkit jQuery
Remy Sharp The DOM scripting toolkit jQuery
deimos
 
The Dom Scripting Toolkit J Query
The Dom Scripting Toolkit J QueryThe Dom Scripting Toolkit J Query
The Dom Scripting Toolkit J Query
QConLondon2008
 
Interface de Voz con Rails
Interface de Voz con RailsInterface de Voz con Rails
Interface de Voz con Rails
Svet Ivantchev
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applications
elliando dias
 
Building an e:commerce site with PHP
Building an e:commerce site with PHPBuilding an e:commerce site with PHP
Building an e:commerce site with PHP
webhostingguy
 
Perl.Hacks.On.Vim
Perl.Hacks.On.VimPerl.Hacks.On.Vim
Perl.Hacks.On.Vim
Lin Yo-An
 
Run an Easy to Use Help Desk with Spiceworks
Run an Easy to Use Help Desk with SpiceworksRun an Easy to Use Help Desk with Spiceworks
Run an Easy to Use Help Desk with Spiceworks
Spiceworks
 
Your own (little) gem: building an online business with Ruby
Your own (little) gem: building an online business with RubyYour own (little) gem: building an online business with Ruby
Your own (little) gem: building an online business with Ruby
Lindsay Holmwood
 

Similar to Web Hooks On Pbwiki (20)

Writing Modular Command-line Apps with App::Cmd
Writing Modular Command-line Apps with App::CmdWriting Modular Command-line Apps with App::Cmd
Writing Modular Command-line Apps with App::Cmd
 
Remy Sharp The DOM scripting toolkit jQuery
Remy Sharp The DOM scripting toolkit jQueryRemy Sharp The DOM scripting toolkit jQuery
Remy Sharp The DOM scripting toolkit jQuery
 
The Dom Scripting Toolkit J Query
The Dom Scripting Toolkit J QueryThe Dom Scripting Toolkit J Query
The Dom Scripting Toolkit J Query
 
Vidoop CouchDB Talk
Vidoop CouchDB TalkVidoop CouchDB Talk
Vidoop CouchDB Talk
 
非エンジニア系起業家のためのWebサービス開発授業 先生:森田 昌宏
非エンジニア系起業家のためのWebサービス開発授業 先生:森田 昌宏非エンジニア系起業家のためのWebサービス開発授業 先生:森田 昌宏
非エンジニア系起業家のためのWebサービス開発授業 先生:森田 昌宏
 
React PHP: the NodeJS challenger
React PHP: the NodeJS challengerReact PHP: the NodeJS challenger
React PHP: the NodeJS challenger
 
Interface de Voz con Rails
Interface de Voz con RailsInterface de Voz con Rails
Interface de Voz con Rails
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applications
 
Be Afraid. Be Very Afraid. Javascript security, XSS & CSRF
Be Afraid. Be Very Afraid. Javascript security, XSS & CSRFBe Afraid. Be Very Afraid. Javascript security, XSS & CSRF
Be Afraid. Be Very Afraid. Javascript security, XSS & CSRF
 
The promise of asynchronous php
The promise of asynchronous phpThe promise of asynchronous php
The promise of asynchronous php
 
Building an e:commerce site with PHP
Building an e:commerce site with PHPBuilding an e:commerce site with PHP
Building an e:commerce site with PHP
 
A reviravolta do desenvolvimento web
A reviravolta do desenvolvimento webA reviravolta do desenvolvimento web
A reviravolta do desenvolvimento web
 
Perl.Hacks.On.Vim
Perl.Hacks.On.VimPerl.Hacks.On.Vim
Perl.Hacks.On.Vim
 
When To Use Ruby On Rails
When To Use Ruby On RailsWhen To Use Ruby On Rails
When To Use Ruby On Rails
 
Run an Easy to Use Help Desk with Spiceworks
Run an Easy to Use Help Desk with SpiceworksRun an Easy to Use Help Desk with Spiceworks
Run an Easy to Use Help Desk with Spiceworks
 
"Coffee Script" in Brief
"Coffee Script" in Brief"Coffee Script" in Brief
"Coffee Script" in Brief
 
An in-depth look at jQuery
An in-depth look at jQueryAn in-depth look at jQuery
An in-depth look at jQuery
 
Your own (little) gem: building an online business with Ruby
Your own (little) gem: building an online business with RubyYour own (little) gem: building an online business with Ruby
Your own (little) gem: building an online business with Ruby
 
Why async and functional programming in PHP7 suck and how to get overr it?
Why async and functional programming in PHP7 suck and how to get overr it?Why async and functional programming in PHP7 suck and how to get overr it?
Why async and functional programming in PHP7 suck and how to get overr it?
 
Ruby 1.9
Ruby 1.9Ruby 1.9
Ruby 1.9
 

Recently uploaded

Recently uploaded (20)

Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 

Web Hooks On Pbwiki

  • 1. Near-Real-Time, Simple awesomeness Web Hooks nathan@pbwiki.com coming soon!
  • 2. Recall From SHDH 17 Jeff Lindsay’s “Web hooks” lightning talk • RSS relies on polling. • Polling is lame. • Syndication and (re)publishing, not triggering
  • 3. Recall From SHDH 17 Jeff Lindsay’s “Web hooks” NO lightning talk • Often n consumers. • Not 1000n. • Polling is still lame. (for some things) • Are we there yet? • Are we there yet? • Are we there yet?
  • 4. Recall From SHDH 17 Jeff Lindsay’s “Web hooks” lightning talk • Event-driven. • Lightweight. • POST to a URL.
  • 5. Recall From SHDH 17 Jeff Lindsay’s “Web hooks” OLD LOGO lightning talk • Event-driven. • Lightweight. • POST to a URL.
  • 6. Web hooks in practice //something ... hook_trigger(‘viewpage’); //more stuff.. async async while(1) { while($queued = $q->get(‘async-queue’)) { post_to_url($queued[‘url’],$queued[‘postargs’]); } }
  • 7. Web hooks in practice Example hooked events • login/logout • edit a page • revert a page • delete a page • comment on a page • tag/untag pages • join/unjoin wiki • return_after_absence • view_for_first_time
  • 8. Web hooks in practice
  • 9. Web hooks in practice
  • 10. Web hooks in practice
  • 11. Web hooks in practice
  • 12. Web hooks in practice
  • 13. I want this to exist: Trigger Filter Branch/Merge Transform Route $page =~ $to = $msg = out_aim($to,$msg) /deploy/i [‘devel@’,ops@’] fmt_to_aim($attrs) $uid == $to = @all_sms; $msg = out_sms($to,$msg) da39a3ee5e6b4b unset($to[$uid]); fmt_to_sms($attrs) incoming web hook $msg = “Wow $viewcount == 100 $to = $emails[$uid] out_email($to,$msg) you’re a power user” $to = [‘http://my.com/’, $op == ‘edit’ $msg = $attrs out_hook($to,$msg); ‘http://twittr.com/me’] = awesome but only polling (RSS)