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

APIs are Interfaces Too

Alex Koppel
September 25, 2014

APIs are Interfaces Too

APIs are not just hooks for one machine to connect to another — they’re interfaces, just like the user interface of your website or app. Your users are the developers who write code against your service, and a lot of the same interface design principles that we use for UI design hold for APIs as well.

In this talk, I take a deep dive into one corner of the Facebook API to illuminate how API consistency is critically important during the design process.

Alex Koppel

September 25, 2014
Tweet

More Decks by Alex Koppel

Other Decks in Technology

Transcript

  1. Me • Ruby/iOS/JS since 2008 • Senior Developer at eSpark

    • Previously: Wunderlist, 
 Facebook marketing, 
 healthcare IT
  2. ???

  3. WAT

  4. Thing is... • The FB API is actually quite well

    designed • Strong fundamental pattern • Not amateurs
  5. Principle of Least Surprise http://en.wikipedia.org/wiki/Principle_of_least_astonishment "People are part of the

    system. The design should match the user's experience, expectations, and mental models." What is least surprising may however depend on the expected audience, e.g. end users, programmers or system administrators.
  6. Perspective • Put yourself in another developer's shoes • Even

    for an internal API • Extra effort, but it pays off over time
  7. Consideration • Make decisions about your API early on •

    Or right now! • Define how it should behave
  8. Building an SDK • Consuming your own API is the

    best test • Can you build simple, consistent methods?