Designing .NET Class Libraries: API Usability

Learn to understand your target audience, profile users with personas, and develop APIs that are easy to use and understand.


Notes from CLR Program Manager Joe Duffy...

Lots of people think of UIs when they hear the word usability. If you're among this camp, hopefully this talk will show you how usability is a crucial component to designing great APIs...

Slide 2: Do you have any APIs in the Framework today that stick out as being "Magic?" I.e. not predictable, hard to understand, can't or had a difficult time figuring out what's going on underneath the covers?

Slide 4: How much time do you typically spend analyzing your users and scenarios? Too much? Too little? Do you obtain feedback early and often? Or do you find that important feedback often flows in just a little too late. We have a structured API review process at Microsoft which encourages teams to think about these things and engage with the usability team as early as possible.

Slide 5: Check out Steven's blog (https://blogs.msdn.com/stevencl/), where he details aspects of the Cognitive Dimensions (CD) framework he discusses in the video. Notice that the CD framework provides a common vocabulary for usability, very similar to how design patterns provide a common vocabulary for discussing object models.

Slide 8: This is a fun exercise to go through. Just throw a rough approximation up on the whiteboard... how close did you come?

Slide 10: As I mentioned above, every team who ships code in the .NET Framework goes through a rigorous API review process very much like the one described here. The core review team meets at least twice a week for 2 hour sessions... We rate each API as red, yellow, or green, and work with teams to ensure that all APIs are rated green before we ship them to customers. It’s amazing how receptive folks are to feedback... everyone genuinely wants to build the best API possible.

Slide 11: Most teams writing code for the Framework do this, too. We call it "AppBuilding," and some teams even set aside entire days on regular intervals to go off and write applications. This is how some of the meatiest design issues come up, as it provides the teams designing the APIs a first chance to step into the shoes of their customers.

Slide 12: Steven and his team run usability studies almost nonstop. We just finished up a "cross pillar" WinFX study where we wanted to see how certain pieces of "Avalon" and "Indigo" work together. The exercise helped us find some great areas for improvement. Many times people have a hard time predicting and testing how their own components work together, never mind worrying about components coming from entirely different teams!

Slide 13: A common story is that of people who were initially skeptical of usability studies... when they finally decide to stop by and check out a study for their own APIs, they immediately see their product from an entirely different perspective. Once they go through this, they swear by usability studies as a great way to get early feedback on their ideas.

Slide 14: We'd love to hear your list of APIs in the Framework that are guilty of these bullets!

Download The Video