1 / 27

API Design Principles for Accelerated Development

One of the largest issues in API architecture development is that the task is often driven by the pragmatic indoctrination of a specification into a product rather than designing around the speed and ease of development, usually due to a separation between the engineering teams and their core developer user base. Extending upon the ideas of API design around developer accelerated development delivered in the PayPal keynote, we will take a deeper look into some of the great techniques delivered to us through the RESTful specification, applying them to developer API consumption practices with the intention of creating efficient best practices for rapid development. Within this talk we will explore what we have learned through reconstructing our API backbone at PayPal for our developer community, including: - API automation practices for code reduction and application longevity - Open security standards that promote developer integration ease and maintain strict security practices - RESTful API architecture best practices for developer centric accelerated development

jcleblanc
Télécharger la présentation

API Design Principles for Accelerated Development

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. API Design Principles For Accelerated Development Jonathan LeBlanc Head of Developer Evangelism (North America) Github: http://github.com/jcleblanc Slides: http://slideshare.net/jcleblanc Twitter: @jcleblanc

  2. The Exploration of API Design Blank Slate Constraints

  3. Building APIs for Developers

  4. The Tradeoff Decision

  5. Developer efficiency task 1 Lower Perceived Latency Lowering perceived latency for developers

  6. What’s the Tradeoff? System Layering Result Caching

  7. Layering the System Encapsulates legacy systems Simplified components Better load balancing abilities Systems can evolve independantly

  8. Separation of Concerns

  9. Stateless System Latency Issues A + B A + C Data Duplication

  10. Caching for Latency Reduction

  11. Developer efficiency task 2 Use HTTP Properly Use HTTP properly – standard request and response types

  12. What’s the Tradeoff?

  13. Requests and Responses GET / PUT / POST / DELETE have specific actions Proper status codes and error responses

  14. Descriptive Messaging Don’t do This {"error": "error 10008"} Do This HTTP/1.1 400 Bad Request Content-Length: 35 {"message":"Problems parsing JSON"}

  15. Developer efficiency task 3 Building in automation – using HATEOAS Build in Automation

  16. What’s the Tradeoff? Payload Size Code Length

  17. How we Normally Consume APIs

  18. Using HATEOAS to Automate

  19. "links": [ { "href":"https://api.sandbox.paypal.com/v1/payments/ authorization/6H149011U8307001M", "rel":"self", "method":"GET" },{ "href":"https://api.sandbox.paypal.com/v1/payments/ authorization/6H149011U8307001M/capture", "rel":"capture", "method":"POST" },{ "href":"https://api.sandbox.paypal.com/v1/payments/ authorization/6H149011U8307001M/void", "rel":"void", "method":"POST" } ]

  20. Developer efficiency task 2 Secure Data Resources

  21. What’s the Tradeoff? Security Usability

  22. Some Security Models Proprietary Solution Basic Authentication OAuth 1.0a OAuth 2 / OpenID Connect

  23. Developer efficiency task 4 Offload complexity to the implementing provider Offload Complexity

  24. The Complexities Authentication / Authorization Legacy API support Working between versioning API changes that break implementations Reduction in latency

  25. Bringing it all Together API architecture is all about tradeoffs You are not making a perfect system, you are making a perfect system for your developers

  26. Thank You! http://bit.ly/api_design_for_devs Jonathan LeBlanc Head of Developer Evangelism (North America) Github: http://github.com/jcleblanc Slides: http://slideshare.net/jcleblanc Twitter: @jcleblanc

More Related