Top Banner
More than the sum of its parts, the API’s whole Josep M. Pujol 3scale http://3scale.net/ [email protected] @solso at Twitter
24

More than the Sum of its parts, the API's whole

May 08, 2015

Download

Technology

3SCALE

This presentation will walk you through the importance of APIs and key considerations to have when creating one.
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: More than the Sum of its parts, the API's whole

More than the sum of its parts, the API’s whole

Josep M. Pujol

3scale – http://3scale.net/

[email protected] – @solso at Twitter

Page 2: More than the Sum of its parts, the API's whole

Why do we need API’s?

Page 3: More than the Sum of its parts, the API's whole

Source: Dion Hinchcliffe, http://blogs.zdnet.con/Hinchcliffe

Web Site

Your Digital Assets

Online Population

Page 4: More than the Sum of its parts, the API's whole

Source: Dion Hinchcliffe, http://blogs.zdnet.con/Hinchcliffe

Web Site

3rd Party Apps

WidgetsGadgetsBadges

Social Network (Facebook, Opensocial)

Mobile Apps.

APInon-visual services

Your Digital Assets

Online Population

Extended Reach

Page 5: More than the Sum of its parts, the API's whole

Source: Dion Hinchcliffe, http://blogs.zdnet.con/Hinchcliffe

Web Site

3rd Party Apps

WidgetsGadgetsBadges

Social Network (Facebook, Opensocial)

Mobile Apps.

APInon-visual services

Your Digital Assets

Online Population

Extended Reach

Is that all?

Page 6: More than the Sum of its parts, the API's whole

API is about Connectedness

• A bit of history,

API == Application Programming Interfaces

Page 7: More than the Sum of its parts, the API's whole

API is about Connectedness

• A bit of history,

API == Application Programming Interfaces

This is about code...

Page 8: More than the Sum of its parts, the API's whole

API is about Connectedness

Connected code == mechanism

Page 9: More than the Sum of its parts, the API's whole

API is about Connectedness

Connecting abilites == society

Page 10: More than the Sum of its parts, the API's whole

There is more than code

An API allows to open what your company does best...

... and to access the best of others

To result in something bigger than the sum of its parts

Page 11: More than the Sum of its parts, the API's whole

What do you glue with API’s?

DATA

Page 12: More than the Sum of its parts, the API's whole

What do you glue with API’s?

DATA

VISUALIZATION

Page 13: More than the Sum of its parts, the API's whole

What do you glue with API’s?

DATA

SERVICES

VISUALIZATION

Page 14: More than the Sum of its parts, the API's whole

What do you glue with API’s?

DATA

SERVICES

VISUALIZATION

Sounds familiar?

Page 15: More than the Sum of its parts, the API's whole

What do you glue with API’s?

DATA

SERVICES

VISUALIZATION

(M)ODEL

(C)ONTROLLER

(V)IEW

Yep! the MVC software architecure

Page 16: More than the Sum of its parts, the API's whole

What do you glue with API’s?

DATA

SERVICES

VISUALIZATION

(M)ODEL

(C)ONTROLLER

(V)IEWMVC connects components

API connects businesses

Page 17: More than the Sum of its parts, the API's whole

Disclaimer

If what you offer sucks, don’t bother to cover it up with an API

Page 18: More than the Sum of its parts, the API's whole

Writing a sucessful API

• If you are a programmer you know how to write an API

However, there are thingsthat can make it or break it

Page 19: More than the Sum of its parts, the API's whole

Writing a sucessful API

• The simpler the better

– REST >> SOAP, JSON > XML– Functionality should be clear and

consice• If you do not know how to name it,

you are doing it wrong

– Adding is much more difficult than removing• Still, consider versioning since day 1

– API needs to be implementation agnostic

– Names should be self-explanatory

Page 20: More than the Sum of its parts, the API's whole

Writing a sucessful API

• Implementation

– Watch out latencies• A human can wait 200ms, a

machine might not

– Machine generated traffic• Usage patterns and load can be

totally different than human generated traffic

– Handle errors beautifully• Don’t assume intelligence on the

other side

Page 21: More than the Sum of its parts, the API's whole

Writing a sucessful API

• Documentation

– Document well, not everything• code is not the best documentation,

your users – developers -- won’t see it

– Provide code examples for your API

– Write plugins for multiple languages• Will make your users life easier and

help getting your API generic

Page 22: More than the Sum of its parts, the API's whole

Writing a sucessful API

• Know your “users”

– They are developers like you, therefore “special”

– They are very comfortable with code examples and online docs

– Developers do not like talking to people, let alone sales• Remove hurdles like approval steps or

sales pitches to hook with your API

– Feedback is always good, in this case critical

Page 23: More than the Sum of its parts, the API's whole

Writing a sucessful API

• Be open• Focus

– Your API needs to offer your core business to be connected to

– For the overhead derived from having a public API such as:

– Access control– Analytics and reporting– Billing and payments– Developer portal

there are API solutions,

Page 24: More than the Sum of its parts, the API's whole

Writing a sucessful API

• Be open• Focus

– Your API needs to offer your core business to be connected to

– For the overhead derived from having a public API such as:

– Access control– Analytics and reporting– Billing and payments– Developer portal

there are API solutions, e.g.

Full Disclosure: I do work for 3scale