// I need to

ModernizeUpgrade without breaking it RescueFix what someone else started Build NewTurn an idea into a product Reach More PeopleGet found, get used, include everyone

// Company

Case StudiesExpertiseAbout + CareersResourcesContact Book a call →

The Little Manual of API Design

A short, well-written PDF on API design from the Qt team at Trolltech: guidelines plus good and bad examples for designing any public or internal API.

Art+Logic Feb 28, 20131 min read

From the Art+Logic archive · written in 2013. The tools may have moved on; the thinking still holds.

This morning, a reference to a short and well written PDF written by an engineer at Trolltech/Nokia came through my feed reader. It’s only 33 pages long, and every one of those pages has solid guidelines, recommendations, and examples (both good and bad) of considerations you should keep in mind when developing an API of any kind:

This manual gathers together the key insights into API design that were discovered through many years of software development on the Qt application development framework at Trolltech (now part of Nokia). Whendesigning and implementing a library, you should also keep other factors in mind, such as efficiency and ease of implementation, in addition to pureAPI considerations. And although the focus is on public APIs, there is no harm in applying the principles described here when writing application code or internal library code.

I don’t think that anyone would disagree with the Apple Pie and Motherhood list of ‘Characteristics of Good APIs’ that are listed:

  1. Easy to learn and memorize
  2. Leads to readable code
  3. Hard to misuse
  4. Easy to extend
  5. Complete

(and reading that list makes me think back on my years of writing C and C++ code using the WIn32 APIs and cry a little), but this document goes past that to outline a well-considered process for designing an API, and guidelines to follow when designing an API, concluding with the very Zen  “The best API is no API”.

Do check it out.

The Little Manual of API Design

(image from http://sofa.projects.semwebcentral.org/doc/design/index.html)

keep going

More to explore in Reach More People.

All Reach More People resources →
let's talk

Got a problem like this one?

Tell us what's stuck. A real person replies within one business day.

Talk to our team →

Talk to people who know software, not a sales script.

Your first call is with Aja, our VP of Sales. He'll help make sure you're solving the right problem. Here's what you'll cover together:

  1. What you're trying to accomplish

    The business goal first, then the technology.

  2. Possible approaches

    And the tradeoffs of each, in plain language.

  3. Risks you may not have considered

    Technical and business, before they cost you.

  4. Whether AI changes the math

    What's practical, and what's just hype for your project.

  5. Sensible next steps

    Even if the right next step is not us.

book-a-call.ics

Loading the scheduler…

Open the booking page →

Some problems are easier to explain in writing. Send us a few lines about what you're working on, and we'll reply within one business day. Helpful to include:

  1. What the software does, or should do
  2. What's stuck, or what's worrying you
  3. Any deadline or budget you have in mind
note.md

Loading the form…