Slide 1

Slide 1 text

E WEB IN THE NOT JUST ON IT IN GREAT APIS

Slide 2

Slide 2 text

@ammeep note: may not be a shark horse in real life

Slide 3

Slide 3 text

apis ’ suck

Slide 4

Slide 4 text

that’s not R

Slide 5

Slide 5 text

that’s notH p

Slide 6

Slide 6 text

ACCESSIBLE Gourmet Apis

Slide 7

Slide 7 text

Premium APIs CONSISTENCY teed an

Slide 8

Slide 8 text

DESCRIPTIVE E for the premium user

Slide 9

Slide 9 text

HEAVY DUTY For apis that stand the test of time F b APIS

Slide 10

Slide 10 text

the web go with the grain of

Slide 11

Slide 11 text

SOAP APIS

Slide 12

Slide 12 text

CENTRIC DESIGN ACTION

Slide 13

Slide 13 text

wsdl/"targetNamespace="http://ws.c

Slide 14

Slide 14 text

100% b

Slide 15

Slide 15 text

Super F b

Slide 16

Slide 16 text

No content

Slide 17

Slide 17 text

H T TP doesn't leverage

Slide 18

Slide 18 text

THE BODY CRAM EVERY} } STUFF pack THING possiblE IN

Slide 19

Slide 19 text

codes Error In the body > <

Slide 20

Slide 20 text

e o C Sis t t n $.ajax({ url: '/music/catalog', success: function(){ // Parse the body and check for errors! }, error: function(){ // An error code would have been nice! } });

Slide 21

Slide 21 text

SOAP & RPC for public APIs Is not a good fit

Slide 22

Slide 22 text

not on it in the web EXIST

Slide 23

Slide 23 text

R r

Slide 24

Slide 24 text

defined by a uri Resources api.com/thing

Slide 25

Slide 25 text

defined by a uri Resources api.com/thing/123

Slide 26

Slide 26 text

HOW to resources? do we do stuff

Slide 27

Slide 27 text

resources interact with via http verbs } }

Slide 28

Slide 28 text

HOW? VERB => NOUN

Slide 29

Slide 29 text

HOW? VERB => URI

Slide 30

Slide 30 text

GET POST PUT DELETE L b /music/album

Slide 31

Slide 31 text

GET POST PUT DELETE G b /music/album/123

Slide 32

Slide 32 text

GET POST PUT DELETE b /music/album

Slide 33

Slide 33 text

GET POST PUT DELETE E b /music/album/123

Slide 34

Slide 34 text

GET POST PUT DELETE Cr & N /music/song/epic.mp3

Slide 35

Slide 35 text

GET POST PUT DELETE N p w .../song/epic.mp3

Slide 36

Slide 36 text

OPTIONS HEAD PATCH COPY LINK UNLINK PURGE O r

Slide 37

Slide 37 text

status Im 200 ok - honest codes

Slide 38

Slide 38 text

ENOUGH FOR HEADERS GENERIC

Slide 39

Slide 39 text

1XX 3XX 4XX 2XX 5XX SEND MORE NOW!

Slide 40

Slide 40 text

1XX 3XX 4XX 2XX 5XX \o/ 1XX

Slide 41

Slide 41 text

1XX 3XX 4XX 2XX 5XX 1XX These guys? they moved

Slide 42

Slide 42 text

1XX 3XX 4XX 2XX 5XX 1XX I have no idea what you just said

Slide 43

Slide 43 text

1XX 3XX 4XX 2XX 5XX 1XX The server is exploding

Slide 44

Slide 44 text

P P Use THEM

Slide 45

Slide 45 text

r p

Slide 46

Slide 46 text

am azing ap i's DOMAIN concepts expose

Slide 47

Slide 47 text

ACCESSIBLE Gourmet Apis

Slide 48

Slide 48 text

Premium APIs CONSISTENCY teed an

Slide 49

Slide 49 text

CAN WE GO FURTHER ?

Slide 50

Slide 50 text

ALL /music/album LISTEN /music/album/123 BUY /music/album/123 /song/epic.mp3 UPLOAD DELETE /song/epic.mp3

Slide 51

Slide 51 text

M r R r manipulated via Http verbs

Slide 52

Slide 52 text

? How the do we use this api HECK

Slide 53

Slide 53 text

READ THE DOCS

Slide 54

Slide 54 text

THEN BAKE IT IN

Slide 55

Slide 55 text

what if the relationships between resources changes w

Slide 56

Slide 56 text

REDEPLOY ALL THE CLIENTS

Slide 57

Slide 57 text

How does the internet work?

Slide 58

Slide 58 text

REDEPLOY ALL THE CLIENTS BROWSERS

Slide 59

Slide 59 text

JUST CHANGE THE SERVER

Slide 60

Slide 60 text

HTTP GET ACCEPT : /catalog : text/html VIEW ALBUMS ABBA Their ‘gift’ to the world can be still be found today, in karaoke bars world wide. MEAT LOAF Meat Loaf’s father was an alcoholic who would go on drinking binges for days at a time. VIEW ALBUMS VIEW ALBUMS DAVID BOWIE He challenged the core belief of the rock music of its day & created perhaps the biggest cult in popular culture. THE PIXIES An unorthodox marriage of surf music and punk rock. Some of the most compelling music of the 80s VIEW ALBUMS http://musicstore.com/catalog

Slide 61

Slide 61 text

PRE ORDER “Heroes” The twelfth studio album by David Bowie, released in 1977. The second instalment of his Berlin Trilogy. Ziggy Stardust & the Spiders from Mars Aladdin Sane Riding the wave of Ziggy Stardust, there's a wealth of classic material here, but not enough focus to make this album itself a classic. A rock star acts as a messenger for extraterrestrial beings BUY ALBUM http://musicstore.com/albums/bowie Young Americans David recorded the music for this album first. Mid session he would stop, write an idea down. He wrote the lyrics only after the music was recorded BUY ALBUM HTTP GET ACCEPT : /albums/bowie : text/html BUY ALBUM

Slide 62

Slide 62 text

BUY ALBUM “Heroes” The twelfth studio album by David Bowie, released in 1977. The second instalment of his Berlin Trilogy. Ziggy Stardust & the Spiders from Mars Aladdin Sane Riding the wave of Ziggy Stardust, there's a wealth of classic material here, but not enough focus to make this album itself a classic. A rock star acts as a messenger for extraterrestrial beings BUY ALBUM http://musicstore.com/albums/bowie Young Americans David recorded the music for this album first. Mid session he would stop, write an idea down. He wrote the lyrics only after the music was recorded BUY ALBUM BUY ALBUM HTTP GET ACCEPT : /albums/bowie : text/html

Slide 63

Slide 63 text

HTTP POST ACCEPT : /checkout : text/html Checkout “Heroes” The twelfth studio album by David Bowie, released in 1977. The second instalment of his Berlin Trilogy. http://musicstore.com/checkout Total: $10.00 You are purchasing... Name on card Credit Card # Verification Code

Slide 64

Slide 64 text

LISTEN “Heroes” The twelfth studio album by David Bowie, released in 1977. The second instalment of his Berlin Trilogy. Ziggy Stardust & the Spiders from Mars Aladdin Sane Riding the wave of Ziggy Stardust, there's a wealth of classic material here, but not enough focus to make this album itself a classic. A rock star acts as a messenger for extraterrestrial beings BUY ALBUM http://musicstore.com/albums/bowie Young Americans David recorded the music for this album first. Mid session he would stop, write an idea down. He wrote the lyrics only after the music was recorded BUY ALBUM BUY ALBUM HTTP GET ACCEPT : /albums/bowie : text/html

Slide 65

Slide 65 text

link to documents actions POSSIBLE HTML

Slide 66

Slide 66 text

The client is the v r

Slide 67

Slide 67 text

CAN WE DO THIS WITH APIS

Slide 68

Slide 68 text

Hypermedia

Slide 69

Slide 69 text

think LINKS

Slide 70

Slide 70 text

HTML LINKS

Slide 71

Slide 71 text

JSON LINKS "link": { "rel":"catalog", "title":"Catalog", "href":"/music/catalog" } HTML LINKS

Slide 72

Slide 72 text

XML LINKS HTML LINKS catalog Catalog /music/catalog

Slide 73

Slide 73 text

LOL LINKS HTML LINKS

Slide 74

Slide 74 text

HTML JSON XML HAL S r f r

Slide 75

Slide 75 text

HTML JSON XML HAL M T

Slide 76

Slide 76 text

HTTP GET ACCEPT : /catalog : application/xml David Bowie ..... Albums List Albums /albums/bowie ...... .......

Slide 77

Slide 77 text

Aladdin Sane ..... Purchase Buy Now /checkout Album Preview Preview Tracks /albums/bowie/aladdinsane/preview ...... HTTP GET ACCEPT : /albums/bowie : application/xml

Slide 78

Slide 78 text

Aladdin Sane ..... Stream Listen /albums/bowie/aladdinsane/listen Related Artists Other Albums You Might Like /albums/similar/bowie ...... HTTP GET ACCEPT : /albums/bowie : application/xml

Slide 79

Slide 79 text

no out of band f r

Slide 80

Slide 80 text

show how resources & actions are related

Slide 81

Slide 81 text

to interact with the problem space show how

Slide 82

Slide 82 text

changes within the problem space enable

Slide 83

Slide 83 text

Look Mum No hands

Slide 84

Slide 84 text

Look Mum No hands KINDA

Slide 85

Slide 85 text

HYPERMEDIA APIS NEED HYPERMEDIA CLIENTS

Slide 86

Slide 86 text

A LINK W

Slide 87

Slide 87 text

r representation

Slide 88

Slide 88 text

generic clients interpret representations rpr {representations}

Slide 89

Slide 89 text

ACtion Specific APIS

Slide 90

Slide 90 text

ACtion Specific APIS Resource Driven APis

Slide 91

Slide 91 text

ACtion Specific APIS Hypermedia Driven APIS Resource Driven APis

Slide 92

Slide 92 text

EVOLV ABLE Generic CLIENTS ACtion Specific Clients

Slide 93

Slide 93 text

WHY LINK

Slide 94

Slide 94 text

OVERHEAD R OF UPDATES

Slide 95

Slide 95 text

DISCOVERABILITY R is a big deal for you

Slide 96

Slide 96 text

HYPERMEDIA DRIVEN APIs Resource Oriented APIS

Slide 97

Slide 97 text

Hypermedia even if you choose not to use it. DESIGN for

Slide 98

Slide 98 text

As API providers, our E1 Priority is building apis that don't suck

Slide 99

Slide 99 text

ACCESSIBLE Gourmet Apis

Slide 100

Slide 100 text

Premium APIs CONSISTENCY teed an

Slide 101

Slide 101 text

DESCRIPTIVE E for the premium user

Slide 102

Slide 102 text

HEAVY DUTY For apis that stand the test of time F b APIS

Slide 103

Slide 103 text

BUILD APIS IN THE WEB

Slide 104

Slide 104 text

Thank you! @ammeep amy.palamounta.in internet related activities: greenbutton.com google: hypermedia apis bizcoder.com stateless.co/hal_specification.html @alliebrosh for the hyperboleandahalf character