CREATING A GREAT DEVELOPER EXPERIENCE THROUGH SDKS
Slide 2
TAYLOR BARNETT Developer Evangelist at Keen IO taylor@keen.io @taylor_atx
Slide 3
@taylor_atx
Slide 4
Collect & store data from users, websites, apps & smart devices.
Query instantly to share results with teams & customers, anywhere.
@taylor_atx
Slide 5
LET’S BE REAL ABOUT SDKS
@taylor_atx
Slide 6
Most API providers aren’t updating their SDKs enough
😞 @taylor_atx
Slide 7
Get the most attention when they are 🔥broken🔥
@taylor_atx
Slide 8
Many of SDKs are now open source, which is great, but…
@taylor_atx
Slide 9
There are a lot of great HTTP request libraries out there now
🎉 @taylor_atx
Slide 10
We could talk for a really long time about why using SDKs aren’t great
@taylor_atx
Slide 11
WHY SHOULD YOU PROVIDE SDKS?
@taylor_atx
Slide 12
Most of the time using an API is important, but peripheral to why the software is being written
@taylor_atx
Slide 13
Your SDKs are your API
@taylor_atx
Slide 14
SDKs give quick feedback on how your API works
@taylor_atx
Slide 15
There’s a business case for putting resources into SDKs
@taylor_atx
Slide 16
OTHER REASONS • When there’s no good built in HTTP request library • Error handling • Building clients with 100% API coverage • Helping users with authentication • Best practices with complex APIs @taylor_atx
Slide 17
CREATING A GREAT DEVELOPER EXPERIENCE
@taylor_atx
Slide 18
PRODUCT VS COMMUNITY SDKS • Clearly define the two to set better expectations • If you don’t build them, Community SDKs will appear •
Leads to a scattered developer experience
• Community SDK bugs will appear in your Support channels @taylor_atx
Slide 19
DOCUMENTATION
• Write the SDK documentation first •
Consistency
•
Helps evaluate the experience
@taylor_atx
Slide 20
DOCUMENTATION • Include sections for •
Troubleshooting, with common errors and issues users run into —> Your Support team will love you for this
•
Changelog or release notes
@taylor_atx
Slide 21
SCARY WORLD OF DEPENDENCIES
• Help your users navigate it
😱
• Users need to know changes between SDK versions • Survey your options
@taylor_atx
Slide 22
DANGERS OF NOT MAKING YOUR OWN SDKS
• Not eating your own dog food is dangerous • Helps you understand the cost of building with your own API • It’s also encouragement to add new API features into your SDK when they released, not later
@taylor_atx
Slide 23
NATIVE AS POSSIBLE • Please do not auto generate SDKs badly from your API • Example: Go find a Go developer to write your Go SDK • Start with the languages that are the most popular for your target audience and that your team is familiar with
@taylor_atx
Slide 24
COMMON DATA STRUCTURES • Avoid inconsistency in your users’ code •
Example: JSON is a great option for representing data
•
Want to map well to data structures in many different languages
@taylor_atx
Slide 25
USAGE TRACKING • Great opportunity to learn about your users
📊
• Critical statistics for developing, maintaining, and improving your SDKs
• Every popular API company today is tracking this: SendGrid, Twilio, Stripe, Dropbox, etc.
@taylor_atx
Slide 26
USAGE TRACKING # Example from the Twilio Python module # https://github.com/twilio/twilio-python user_agent = “twilio-python %s (python-%s)” % ( LIBRARY_VERSION, platform.python_version(), ) headers = { “User-Agent”: user_agent, “Accept-Charset”: “utf-8”, } @taylor_atx