121

The API Lifecycle

Embed Size (px)

Citation preview

Page 1: The API Lifecycle
Page 2: The API Lifecycle

The API LifecycleAn Agile Process For Managing the Life ofan API

Nordic APIs

©2015 Nordic APIs AB

Page 3: The API Lifecycle

Contents

Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . i

Envisioning The Entire API Lifecycle . . . . . . . . . iii#1: Analysis Stage . . . . . . . . . . . . . . . . . . v#2: Development Stage . . . . . . . . . . . . . . . vi#3: Operations Stage . . . . . . . . . . . . . . . . vii#4: Retirement Stage . . . . . . . . . . . . . . . . viiiChoose Your Adventure: . . . . . . . . . . . . . . ix

I Analysis Stage . . . . . . . . . . . . . . 1

1. Preparing Your API Business Strategy . . . . . 21.1 Basic Things to Consider . . . . . . . . . . . 31.2 Determine If An API Is Right For Your Spe-

cific Situation . . . . . . . . . . . . . . . . . . 41.3 Perform Market Research . . . . . . . . . . 41.4 Align Your API With Business Objectives . . 51.5 Select Your API Business Plan . . . . . . . . 7

2. Monetization Models . . . . . . . . . . . . . . . 102.1 How Can You Measure If Your API Is Prof-

itable? . . . . . . . . . . . . . . . . . . . . . . 112.2 API Monetization Trick #1: Charge Directly

for an API, by Call or Subscription . . . . . . 12

Page 4: The API Lifecycle

CONTENTS

2.3 API Monetization Trick #2: Using API Ac-cess As A Premium Upsell Opportunity . . . 13

2.4 API Monetization Trick #3: Drive Revenue-Generating Activities Through Your API . . 14

2.5 API Monetization Trick #4: Increase Distri-bution Through Strategic Partners . . . . . 14

2.6 API Monetization Trick #5: Improve Op-erational Efficiency and Decrease Time toMarket . . . . . . . . . . . . . . . . . . . . . . 15

2.7 Mix, Match, Measure Models of API Mone-tization . . . . . . . . . . . . . . . . . . . . . 17

2.8 Your API Monetization Checklist . . . . . . . 17

3. Understandig Your Target API Consumer . . . 193.1 A Response to Increased Consumer Diversity 193.2 Why Create a Developer “Persona”? . . . . 213.3 The Developer Brain . . . . . . . . . . . . . 223.4 But Plenty of Other People Are Interested

in APIs, Too! . . . . . . . . . . . . . . . . . . . 233.5 Expanding our Portal: End User Evangelism 243.6 Varying Industry Backgrounds . . . . . . . . 253.7 API Use Cases . . . . . . . . . . . . . . . . . 263.8 Lessen The Corporate Branding . . . . . . . 273.9 Developer Experience . . . . . . . . . . . . . 273.10 Build it And They Will _____ . . . . . . . . . . 28

II Development Stage . . . . . . . . 30

4. Constructing Your API . . . . . . . . . . . . . . . 314.1 Things to Consider During Implementation 314.2 API Management . . . . . . . . . . . . . . . 334.3 Maintenance . . . . . . . . . . . . . . . . . . 35

5. 12 Design Tips . . . . . . . . . . . . . . . . . . . . 39

Page 5: The API Lifecycle

CONTENTS

5.1 Summarizing API Design Tips . . . . . . . . 48

III Operations Stage . . . . . . . . . . 50

6. Marketing Your API . . . . . . . . . . . . . . . . 516.1 Running Your API As a Product . . . . . . . 516.2 Marketing Your API . . . . . . . . . . . . . . 546.3 Using Different Traction Channels . . . . . 566.4 Supporting Your API . . . . . . . . . . . . . . 58

7. The Importance of API Metrics . . . . . . . . . 607.1 What Is Metric Analysis? . . . . . . . . . . . 617.2 Metric Analysis Tools and Services . . . . . 627.3 Example — The Tokyo Traffic Problem . . . 637.4 The Traffic Problem Solution . . . . . . . . . 657.5 The Traffic Problem and APIs . . . . . . . . 667.6 Metrics Throughout the Lifecycle . . . . . . 667.7 A Real-World Failure - Heartbleed . . . . . . 687.8 A Real-World Success - The FedEx ShipAPI . 697.9 Security, Effectiveness, and Commerce . . 70

IV Retirement Stage . . . . . . . . . 72

8. A History of Major Public API Retirements . . 738.1 What Does Retirement Mean? . . . . . . . . 738.2 Retirement Reason #1: Lack of 3rd Party

Developer Innovation . . . . . . . . . . . . . 748.3 Retirement Reason #2: Opposing Financial

Incentive, Competition . . . . . . . . . . . . 758.4 Retirement Reason #3: Changes in Tech-

nology & Consolidating Internal Services . 768.5 Retirement Reason #4: Versioning . . . . . 778.6 Retirement Reason #5: Security Concern . 79

Page 6: The API Lifecycle

CONTENTS

9. Preparing For a Deprecation . . . . . . . . . . . 809.1 Rippling Effects . . . . . . . . . . . . . . . . . 819.2 Preparing For Developer Reaction . . . . . 81

V The Agile Mindset . . . . . . . . . . 85

10. What Makes an Agile API? . . . . . . . . . . . . 8710.1 What is Agile? . . . . . . . . . . . . . . . . . . 8810.2 Conclusion . . . . . . . . . . . . . . . . . . . 91

11. Case Study: PlanMill API . . . . . . . . . . . . . . 9311.1 What is an ERP? . . . . . . . . . . . . . . . . 9411.2 The Slow Initial Release . . . . . . . . . . . . 9411.3 API Usability Problems . . . . . . . . . . . . 9511.4 Improved Process for API 2.0 . . . . . . . . 9611.5 Specific ArchitectureDecisionsMadeAlong

the Way . . . . . . . . . . . . . . . . . . . . . 9711.6 Sharing Data Carefully and Securely . . . . 9911.7 Understanding the Lifecycle of an API . . . 10011.8 Additional Resources: . . . . . . . . . . . . . 100

12. Third Party Tools . . . . . . . . . . . . . . . . . . 101

Nordic APIs Resources . . . . . . . . . . . . . . . . . 104

Endnotes . . . . . . . . . . . . . . . . . . . . . . . . . 106

Page 7: The API Lifecycle

PrefaceNordic APIs has been in operation for about 2 years.Within that short time we’ve hosted hundreds of API-specific presentations featuring international experts -giving us the opportunity to take a peek into the innerworkings of leading web API-driven businesses.

Throughout our work we’ve discovered a recurring trend:unsuccessful APIs struggle both in fostering interest aswell as creating a sustainable service. In contrast, success-ful APIs are well-attended, treated as a product with amulti-iterative lifecycle. So we thought; what exactly arethe key ingredients to their successes?

Our fourth eBook, The API Lifecycle, presents an agile pro-cess for managing the life of an API - the secret sauce tohelp establish quality standards for all API and microser-vice providers. This handbook depicts a holistic modelthat treats a web API as a constantly evolving businessand product. From conception through deprecation, itoutlines instructions on market research, business strat-egy, development, operations, promotion, and other vitalcomponents for successfully creating and maintaining anAPI.

Inspired by experienced API consultants Andreas KrohnandTravis Spencer, theAPI Lifecycle diagram is composedof four distinct phases: Analysis, Development, Opera-tions, and Retirement. Our eBook expands theses con-cepts, grounding theories in knowledge collected duringour 2015 World Tour, events which brought API industryexperts together to discuss different stages of the API

i

Page 8: The API Lifecycle

Preface ii

Lifecycle. We also delved deeper into these ideas withinour blog, interviewing leading web API figures to performadditional research, and peppered it all with a bit ofour own insights to create a comprehensive overview ofwhat to consider during the entire product lifecycle of aprofitable web API.

Please enjoy The API Lifecycle, and let us know how wecan improve. Be sure to join the Nordic APIs newsletterfor updates, and follow us for news on upcoming events.

Thank you for reading!

– Bill Doerrfeld, Editor in Chief, Nordic APIs

Connect with Nordic APIs:

Facebook | Twitter | Linkedin | Google+ | YouTube

Blog | Home | Newsletter | Contact

Page 9: The API Lifecycle

Envisioning The Entire APILifecycle

From conception to deprecation, a Software-as-a-service(SaaS) is prone to constant evolution. Check the changelogfor a high-volumeplatform like Dropbox for proof. In suchlogs, you’ll find bug fixes and updates, with the latest likelymade within the past couple weeks.

The APIs that open these SaaS platforms are changing justas rapidly. So much so that API Changelog was created tonotify users of API documentation changes (22 updates inthe last 30 days in the case of the Dropbox API at the timeof this writing). This ongoing iterative process is not only

iii

Page 10: The API Lifecycle

Envisioning The Entire API Lifecycle iv

agile - it’s evolution is in symbiosis with many businessfactors that make up the organism that is the entire APIlifecycle.

As the main function of web APIs are to be consumed bythird party products, the API is a unique type of businessoffering. It’s peculiar condition as both a software andinternal asset makes its lifecycle special – highly fueledby ongoing feedback and market validation. Comparedwith standard SaaS products that may have the power tochange their UI or underlying construct, an API’s granularstate can make it even more elusive.

The State of Modern Software Development

Agile…Scrum…contemporary software development pushestoward quick releases and fluid responses. Response tochange needs to be rapidly executed, leveraging userfeedback, data, and statistics. These traits are becomingstandard practice throughout the software realm. But isproducing and maintaining an API the same – or is it adifferent animal entirely?

The API As a Living, Breathing Organism

Exactly how an API lifecycle looks depends on how the APIfunctions as well as the business strategy at it’s core. Weat Nordic APIs have boiled down the common API lifecycleto four main phases: Analysis, Development, Opera-tions, andRetirement. As seenmapped out above, theseelements work together and influence each-other. Oncethe cycle begins, open and simultaneous exchange be-tween each phase will help a practitioner stabilize the APIagainst internal and external factors. New informationthat arises within each stage may beckon a team to move

Page 11: The API Lifecycle

Envisioning The Entire API Lifecycle v

forward or backward in the lifecycle, encouraging smallrevisions or large pivoting to reach end project goals.In this introductory chapter we will introduce the mainphases of the cycle, each to be covered in depth in thefollowing chapters to come.

#1: Analysis Stage

This stage involves defin-ing overall API businessobjectives. Firms shouldcritically ask themselveswhether or not an APIis right for their partic-ular situation. Some in-dustries, such as social

networks, thrive off APIs as a natural extension of theirdigital ecosystem. On the other hand, traditionally non-digital companies must be creative in handling how APIsextend their business model.

An API should either boost pre-existing operations orwork toward overall company goals in some way. In oure-book Developing the API Mindset we defined 3 types ofAPIs:

• Private APIs streamline internal operations to de-crease expenses.

• Partner APIs work specifically with partner orga-nizations to expand a service’s reach to existingmarkets to generate revenue.

• Public APIs form new ecosystems by opening upa service to public access. If you intend to have apublic release, obtain feedback while you perform

Page 12: The API Lifecycle

Envisioning The Entire API Lifecycle vi

analysis to gauge interest and determine accesscontrol.

Whatever the chosen API strategy is, it’s mission state-ment, usage projections, model for growth, marketingstrategy, and estimated financial return should be clearlylaid out before production begins. If you’ve done the nec-essary preparation, it’s time tomove to theDevelopmentStage.

#2: Development Stage

With business proof andgoals laid out, the nextstep is defining technicalrequirements andoppor-tunities that are in co-operation with the APIstrategy. Development plansneed to consider the fol-

lowing:

• what operations the API will execute• management and hosting• the methods and protocols used• size and scalability• access and security control• usability and experience• the development team … among other factors

An intimate understanding of API processeswill help formtechnical requirements. For example, knowing whether

Page 13: The API Lifecycle

Envisioning The Entire API Lifecycle vii

your API will open your firms’ data, or act as a contentdistribution channel can impact overall design.

In general, the API development stage should mimic thebusiness objectives set forth within the Analysis phase.A methodical development phase considers design, con-struction and testing of API processes as well as security.Design your API with both human usability and machinestandards in mind. It is a good idea at this point to alsoimplement and evaluate API versioning strategies that willset the API in a good position for future updates.

During the Development Stage, a team may choose toreturn to the Analysis Stage to perform additional mar-ket research and general preparation. This can arise fromtechnical roadblocks, or the urge to revision an APIs’ pri-mary objectives. If the API feels polished, tested, secure,and ready for general use, you are ready to move to theOperations Stage.

#3: Operations Stage

If you’re team’s lean asflank steak, you may besprinting a minimum vi-able product straight tothe masses. With loosenuts and bolts, it’s nat-ural that the OperationsStage will involve a lot of

tweaking and bug-fixing in addition to marketing.

To spread awareness, API providers canhosthackathons,improve SEO for home page and documentation, have adedicated @Dev channel, and use popular discoverabil-itymethods and channels. If the resources are available,

Page 14: The API Lifecycle

Envisioning The Entire API Lifecycle viii

companies should also employ a dedicated API Evange-list to promote the API at physical events and throughoutthe blogosphere.

In the end,marketing an API largely depends on an inside-out approach. Having an easy-to-consume developmentportal, an embedded help desk, along with other DXdriven suggestions we’ve laid out in the past will helpboost conversion rates.

This part of the lifecycle will likely take the most energyand time.Monitor usage statistics, and engagewith users.Use any helpful data to aid in constant revising. Especiallyif an API program is in a closed beta, inbound tacticsto collect feedback will help tremendously to aid in thisiterative development process. Make sure that all APIchanges are well documented on your release notes.

This exciting stage will bestow on an API practitionerreal market requirements, and could potentially exposea business to entirely new opportunities. Statistics anddata collected here will impact tech requirements thatcould result in revisiting theDevelopment Stage tomakeincremental changes or new API versions, or consultingtheAnalysis Stage tomake larger pivots. If forecasts lookgrim, a team may consider moving to the RetirementStage at this point.

#4: Retirement Stage

Old age comes, and retirement is a part of life. It’s nodifferent in the API world. It’s good to know what factorscontribute to small revisions as well as large depreca-tions. In this stage, a provider may decide to retire an APIdue to limited use, outdated plugins, a lack of 3rd partyinnovations, opposing financial incentives, and more. A

Page 15: The API Lifecycle

Envisioning The Entire API Lifecycle ix

businessmay risk losing an advantage if an API decreasestraffic from native distribution channels.

Versioning, deprecation,or lassoing in an API intoa more internal stateare options to considerif your key performanceindicators are showing aflatline. At this point, theAnalysis Stage can be

reattempted, and the lifecycle repeated if viable. A PublicAPI may still prove profitable as a Partner offering, forexample. Retiring an API or API version is the best optionwhen the API no longer is the best solution to reach thegoals of the business. Whatever the solution is, we rec-ommend a transparent public announcement that offersa reasonable timeline.

Choose Your Adventure:

In this chapter we’ve given a 30,000 foot view of the some-what untraditional API lifecycle. Further chapterswill offerfine-grained perspectives on each stage in the lifecycle,bolstered by specific industry use cases that demonstrateeffective strategies for each. Here’s where we’re going:

1. Analysis Stage2. Development Stage3. Operations Stage4. Retirement Stage

Page 16: The API Lifecycle

I Analysis Stage

An API comes with an active product lifecycle that’s teth-ered between internal evolution and third party fluctua-tion. Within this part we’ll begin to take a deeper look intoour first step of the Lifecycle process to consider whatpreparation should be done within the Analysis Stage -before developing your API.

Page 17: The API Lifecycle

1. Preparing Your APIBusiness Strategy

Overlooked by some, the Analysis Stage should be thefirst stop on any API’s lifecycle. It involves research andcritical decision making that will impact all future designsof your API. The purpose is to validate why your organiza-tion needs an API and who is going to use it.

This crucial stage forms a business plan for an API init’s entirety. Within this pre-development API phase, youshould gauge interest fromyour target audience, performmarket research, forecast trends within your sector, andmake usage projections. To form a strategy, you’ll want todecide on your API’s business objective and what core API

2

Page 18: The API Lifecycle

Preparing Your API Business Strategy 3

functionalities can help achieve this result, and then pairthis knowledge with appropriate revenue models.

Defining the above points will help an organization allo-cate resources for development, operations, and market-ing, and should help in estimating your API’s ROI. Thispreparation will also supply a roadmap for decision-mak-ing throughout future API lifecycle stages.

1.1 Basic Things to Consider

Developing and releasing an API should be given thesame amount of preparation as a new product launch.Especially if the API is a main offering, or is being built asthe underlying construct for an entire platform, the endbusiness objective should be in the forefront throughoutthe entire lifecycle.

This early in the game, you’ll want to formulate answersto the following questions:

• Why does my organization need an API?• What functions will the API accomplish?• What is the API value proposition?• Who is my intended audience?• Does my audience want to consume my API?• If for public use, what sorts of third-party productsdo you imagine being built with your API?

• Will the API be a core business offering?• Does my organization possess the resources re-quired to successfully develop and maintain an API?

• What sort of metrics should I consider during analy-sis?

Page 19: The API Lifecycle

Preparing Your API Business Strategy 4

1.2 Determine If An API Is Right For YourSpecific Situation

For many companies, providing an API is seen as an ITmatter exclusive to internet giants like Twitter, Facebookand Google, startups like Algolia, Wit.ai and Context.io, orfor government agencies to open data to the public. Butare APIs really limited in that way?

It’s true that even traditionally non-digital companies,such as Bechtel, a construction and engineering firm,Dun & Bradstreet, a business information company, andMarvel comics have succeeded in creating awesome plat-forms. At the end of the day, every company shouldconsider how they can use APIs to excel their business.

Many organizations develop an API to extend their cur-rent functionalities. On the other hand, some businessesmove toward API platformitization, positioning the API asa core value. Many facial recognition, natural languageprocessing, and machine learning services do just that.

1.3 Perform Market Research

As with any business endeavor, it’s vital to take a look atwhat competitors are doing in your sector to gauge thecompetition. Market research is a critical component ofyour pre-launch strategy. Use existing API discoverabilitytools to bolster your research.

Depending on the success of other APIs in the field, it mayhelp promote alternative methods or protocols withinyour API. Create an account and perform test calls with acompetitor’s API, and imagine how the experience couldbe improved. This will help refine where there is room foryour product in the market.

Page 20: The API Lifecycle

Preparing Your API Business Strategy 5

1.4 Align Your API With BusinessObjectives

An API should either boost pre-existing operations orwork toward overall company goals in some way. In oureBook Developing the API Mindset we defined a taxon-omy of three types of APIs: Private, Partner, and Public.Each have their own benefits and potential drawbacks.API providers may consider using multiple strategies toleverage their API and justify their Return on Investment(ROI).

The Private API Strategy

Types of industries that flourish using aninternal API are ones that need their datasecured, or ones that wouldn’t profit fromdistributing their data. These businessesgreatly benefit from a method of stream-

lining internal operations. For example, banks commonlyuse internal APIs to transfer funds and achieve internalefficiency.

The benefits of a private API may be:

• Streamlines internal operations• Consolidates distribution channels• Data is not exposed publicly, boosting security

Potential drawbacksmay be:

• Potential revenue streams are not accessible• Not as many developers are aware that your APIexists

Page 21: The API Lifecycle

Preparing Your API Business Strategy 6

The Partner API Strategy

Many enterprise applications choose topartner their API with trusted partners inlarge data exchange dealings. Take theESPN sports API, for example. Their publicAPI was reigned in as it was decreasing the

value of their primary distribution channel. Now ESPN APIintegrations are being done partner organizations.

Benefits of opening up an API for B2B exchange:

• Data is not entirely exposed publicly, retaining secu-rity and data control

• B2B dealings could potentially produce large rev-enue and mutually beneficial data exchanges

• Spreads assets to reputable, established serviceswith pre-existing markets

Potential drawbacks of a sole partner strategy may be:

• Some revenue streams are not accessible via openmeans

• Noopendeveloper ecosystem is created, awarenessis still limited

The Public API Strategy

The Public API is what we often meanwhen we talk about web APIs. This is aservice opened to third-party developersto integrate into their apps. Anything fromsocial networks, rideshares, project man-

agement apps, data processing tools, and more are com-mon areas where a service is opened for third party

Page 22: The API Lifecycle

Preparing Your API Business Strategy 7

developers to consume in amutually beneficial exchange.With this strategy, the provider may charge usage fees,or create a free-to-consume platform to spread brandawareness.

Benefits:

• Extending a service’s brand to additional apps aidsmarketing and awareness

• Could produce a profitable ecosystem if developersare willing to pay for your service

• Potentially improves experience for more end users

Drawbacks:

• Select assets are exposed for public, losing dataprivatization

• With greater awareness comes greater risk of secu-rity threat

• Third-party apps may not be as reputable or estab-lished

• Timeline for ROI is increased

1.5 Select Your API Business Plan

Estimating financial returns from an API can be difficultto perceive. With Public APIs, for example, revenue gen-eration from third-party apps can take twice the normaltime, as you must wait for a second product’s lifecycle toreach sustainable operations and acquire end users. Infree-to-consume scenarios, the offering may not directlygenerate revenue, but may boost brand awareness thatcould ultimately lead to growth or even help leveragedeals within an acquisition.

Page 23: The API Lifecycle

Preparing Your API Business Strategy 8

John Musser, founder of API Science, believes that “APIbusiness models are not size fits all,” having identified atleast 20 variations in API business models throughout hiswork in the space.

Tiered subscription, pay as you go, freemium, unit based,revenue share - there are many monetization possibil-ities, and in the end, most APIs have a diversified ROIsystem that fits their service. In the next chapter, we’lldiscuss ways to monetize your API.

Page 24: The API Lifecycle

Preparing Your API Business Strategy 9

Formore on API business strategy check out Developing TheAPI Mindset

Page 25: The API Lifecycle

2. Monetization Models

Before development, it’s crucial to consider how your APIwill boost overall revenue. This last Analysis Stage chapterguides you to doing just that. We offer you the top 5 APImonetization models with the hope of helping you, asan API provider, bring value to developers and end users,and financially gain from hosting your API.

10

Page 26: The API Lifecycle

Monetization Models 11

2.1 How Can You Measure If Your API IsProfitable?

Rob Zazueta is the director of platform strategy at Intel.His team focuses on helping clients manage, market,and monetize APIs by identifying strategies to align withbusiness objectives. At his talk last October at the 2014Nordic Platform Summit in Stockholm, Zazueta focusedon the third tier of Intel’s approach: how to monetizeyour API.

According to Zazueta, “The success of an API programis measured by how well it moves a business towardits goals.” With everything your business does, you mustkeep an eye on your return on investment. To avoid anunsuccessful venture, before API development you needto consider common steps toward API monetization andif they apply to your situation.

In order to determine if something is going to be prof-itable you must measure it. Zazueta recommends using asimple Average Revenue Per User Model (ARPU) to helpdecide how to increase revenue, whether by increasingprice or attracting more users. With any API monetizationmodel, you want to compare the ARPU of your API-usingcustomers against the ARPU of those who don’t.

Page 27: The API Lifecycle

Monetization Models 12

2.2 API Monetization Trick #1: ChargeDirectly for an API, by Call orSubscription

This is the most obvious method of monetizing anything- directly charging for it. But just because it’s simple tomeasure doesn’t mean it’ll be successful. The strategyworks “if your data has the kind of value that people wantto pay for,” Zazueta says. Before jumping right in, youshould talk to your customers to see if they’d be willingto pay for these services and for how much.

Direct sales is perhaps the easiest way to sell your API,but Zazueta says it could also be the most challengingas it may be difficult for your developer audience to seethe value of it. He recommends to start with a Freemium

Page 28: The API Lifecycle

Monetization Models 13

Model to offer a taste of the data that developers wouldhave access to, and hope it leaves them wanting more.

2.3 API Monetization Trick #2: Using APIAccess As A Premium UpsellOpportunity

This is a trick used in the SaaS world a lot, like with thePOS giant Salesforce. Adding API access to a Premiumsubscription offers a strong motivator to upgrade to ahigher package, as it allows end users to customize theirexperience and workflow more easily. API access is usu-ally one of multiple added benefits that come along withsubscribing to a higher package, making this a trickermonetization model to measure. Zazueta offers theseattempts to measure this model:

1. Compare sale of packages with API included versusthose without.

2. Have your sales team mark “Level of Interest in API”in sales notes.

3. Measure the number of API calls from users on thatPremium package.

4. Measure ARPU or revenue generated by active APIusers versus non-active ones.

In addition, you can also measure the subscription re-newal rate of API users versus those that don’t use thispackage feature.

Page 29: The API Lifecycle

Monetization Models 14

2.4 API Monetization Trick #3: DriveRevenue-Generating ActivitiesThrough Your API

This model takes the most effort to track because it oftensupports indirect revenue. Depending on the situation, itcould be the API monetizationmethodmost applicable toyour overall business goals.

For example, email marketing software is often mone-tized by the email sent, but APIs are used to filter contactsautomatically from a customer relationship managementsoftware (CRM). Without the contacts, you can’t send theemails, which is why tracking the number of contacts thatcome in through the API is an excellent way to prove itsvalue. Plus you can compare if users with the API sendmore emails— which affects revenue— than those userswithout the API.

Another method is to track if your application is actuallydriving leads. If you sign a pay-per-lead (PPL) agreementwith a customer, you can track that lead via your CRM. Forboth of these, tracking can be complex if more than onethird-party application is integrated,meaning increasinglygranular measurements need to be made.

2.5 API Monetization Trick #4: IncreaseDistribution Through StrategicPartners

In the SaaS world, integrating your API with a strategicpartner has the potential to open your API to entire pre-established markets. This enables you to market yourbrand to a broader audience to attract more potential

Page 30: The API Lifecycle

Monetization Models 15

customers. For example, PayPal and Stripe allow servicesand sellers to use their API because it offers an easy wayto get paid, and, of course, the more transactions, themore money these popular payment services earn.

This strategy can also aid in user retention. If your cus-tomers also have a subscription with your strategic inte-gration partner, they are less likely to disrupt their work-flow by leaving either of you. There is no questioning thevalue of these strategic partnerships for the consistentlydemanding end user, who can now build a customizedworkflow out of the integrated cloud tools now available.Plus, these type of integrations are on the rise:

“We see the rise of best-in-breed solutions as the next nat-ural progression,” said senior vice president of productat Zendesk help desk software, Adrian McDermott. “If theInternet is the platform, then the need to be integratedby a single provider becomes obsolete - multiple best-in-breed solutions can run seamlessly via the Internet,without needing to be overseen by one organization.”

It’s important with strategic partnerships to create a mu-tually beneficial shared data agreement. You want toknow how much your API is helping their business, andsimilarly, they want to know the effect of their product onyours.

2.6 API Monetization Trick #5: ImproveOperational Efficiency and DecreaseTime to Market

“Well-built, well-designed APIs help you build applicationsfaster. It helps you innovate faster. More importantly, ithelps you fail faster,” Zazueta says. “If you build a well-

Page 31: The API Lifecycle

Monetization Models 16

built API that’s secure and properly managed… and youtreat that internally focused audience as your customers,you can actually get all kinds of great benefits.” Zazuetasays that he’s seen internal processes in companies speedup from a couple months to a couple hours, solely be-cause of the efficiency gained from an API.

Some additional benefits from using an internal API in-clude:

• Faster customer onboarding• Deeper access into data• Tighter control over development• Faster application building• Faster testing of an application’s revenue potential

Internal APIs also suit the lean start-up model, whereyou produce and release to market as quickly as possi-ble. As this is the case, if the API isn’t so valuable, yourorganization hasn’t wasted a lot of time and resourcesimplementing it - you’re able to pivot rapidly.

Since this is an internal benefit, you don’t use the ARPUto measure it. You start by measuring the time it took tobuild and introduce a certain function before the API andafter. You can also turn that into dollars by way of themanpower needed. Of course, before making this move,you need to make sure that it won’t take excessive effortand resources to design and start using the API withinyour internal systems. Review the existing processes be-fore considering implementing this one.

Page 32: The API Lifecycle

Monetization Models 17

2.7 Mix, Match, Measure Models of APIMonetization

The reality is that your API monetization technique mayinvolve an assortment of thesemodels. Perhaps none areperfect for your particular situation, but it’s very likely thata couple of these API monetization tricks will work to helpgenerate revenue. As always, build what will work for you.

“The goal here is to build a successful API program thatmoves the business toward its goals,” Zazueta says. “Anda program that’s not gonna do that won’t be successful forlong.” You might be using one or more models already,but it won’t matter until you measure its success.

2.8 Your API Monetization Checklist

We created this checklist to make it easy for you to figureout if you are able to monetize your API quickly. A Yes ora Maybe is certainly worth considering:

1. Are you able to profit from charging for your APIdirectly?

2. Can giving access to your API be an upsell opportu-nity?

3. Are there ways to drive revenue indirectly throughyour API?

4. Do you have opportunities to make strategic APIpartnership?

5. Can an API improve operational efficiency and de-crease time to market?

Then, as you implement an API monetization strategythere are two questions to constantly keep on your mind:

Page 33: The API Lifecycle

Monetization Models 18

• Are youmeasuringAverageRevenuePerUser (APRU)throughout eachpossible API-related revenue source?

• Are you comparing this APRU with the APRU ofcustomers who don’t use your API?

As with anything, make sure that your API monetizationstrategy is directly in line with your business objectives. Ifit’s clearly not, don’t waste your time.

Page 34: The API Lifecycle

3. Understandig YourTarget API Consumer

Consumer profiling that is a necessary first step for anybusiness venture. For this chapter we cover strategiesthat help understand your target user within the specificcontext of APIs.

3.1 A Response to Increased ConsumerDiversity

Within any economy showing such exponential growth,the diversity of its players will naturally increase as the

19

Page 35: The API Lifecycle

Understandig Your Target API Consumer 20

market evolves. It’s a fact that the API space is becomingincreasingly diverse — it’s not the old days where a fewindependent developers created mashups for fun. APIshave entered large business dealings, gained the atten-tion of enterprise-level product designers, led to the cre-ation of multi-billion dollar startups, influenced creativemarketing campaigns, and more.

So, with all this new interest from varying audiences, APIproviders may be asking: who are we selling to?

At Nordic APIs, we’ve tracked the explosion of this innova-tion, watching as new players step up to play ball — eitherconnecting or striking out in deprecation. With more andmore consumers entering the API space, it’s now moreimportant than ever to consider the large breadth ofspecializations amongst third party developers. Thesefactors take the form of:

• varying technical understanding• different industry backgrounds• geographical location• online activity• API use cases• protocol preferences• programming language preferences• …and more.

Mike Kelly runs Stateless.co, an API strategy consultingfirm based in London. He describes the wide breadth ofdevelopers currently in the space:

“There are of course broad categories suchas system integrators, mobile, web, embed-ded systems. In reality there are innumerable

Page 36: The API Lifecycle

Understandig Your Target API Consumer 21

forms of developers each with their own setof constraints and requirements, which is whydeveloping a set of realistic developer per-sonas is important.”

3.2 Why Create a Developer “Persona”?

Traditional businessmodels necessitate a process of con-sumer profiling. The same can be done in a way thatmakes sense for this niche API sector. Intimately under-standing your target consumer is crucial as it will influ-ence the following:

• Market Fit: Knowing your consumer can help youdiscover unmet needs in the market your API couldpotentially satisfy.

• Functionality: Understanding use cases can helpdesign API functions around that need.

• Segmentation: Knowing your user can help seg-ment marketing efforts and decrease customer ac-quisition cost.

• Creative Marketing: Knowing what your audienceis interested in will help tailor your marketing to thisaudience, influencing your message, tone, appear-ance, design, style, and more to attract your targetaudience.

Kelly goes on to mention the importance of establishingdeveloper personas is that they establish an importantframe of reference:

“If you’re unable to clearly describe your tar-get customers and their use cases for your

Page 37: The API Lifecycle

Understandig Your Target API Consumer 22

API, that usually indicates that the underlyingproposition is not focused enough. Likewise,if you’re unable to clearly determine how aproposed feature provides immediate value toone of your personas, that is a strong indicatorthat it doesn’t belong on the roadmap yet…I’ma huge fan of any methodology that encour-ages approaching the strategy and design ofan API by focusing on the client side, ratherthan the server side.”

3.3 The Developer Brain

‘Know your demographic.’ ‘Under-stand the psychology of your con-sumer.’ We hear phrases like thisfrequently in general business dis-cussion. Is it possible to apply thesame philosophy tomarketing APIs?

Developers are not your averageconsumer. In a conversation with Nordic APIs, GeneralManager Jason Hilton of Catcy Agency, an internationaldeveloper program management outfit, pinpointed thefollowing attributes. The developer brain is naturally an-alytical. They appreciate authenticity. And in a sea ofcompeting tools with rampant overzealous marketing,they have the right to be skeptical. Awebdeveloper espe-cially wants to pick up and play with a product, expectingan instant proof that it behaves as advertised.

Take these generalizations as you will, but they’re worthto consider when developing a marketing message andstory applicable to this certain audience. Both contentand aesthetics can either incorporate or alienate depend-

Page 38: The API Lifecycle

Understandig Your Target API Consumer 23

ing on their execution. Creating a developer portal, forexample, should, in response to our brief psychologicalexamination, be intuitively designed, with transparentinformation, an attractive layout, and interactivemod-ules that allow one to test API calls.

3.4 But Plenty of Other People AreInterested in APIs, Too!

Andreas Krohn of Dopter urges us to consider a widerscope with API marketing and evangelism. Instead offocusing so heavily on developers, API providers shouldcreate more inclusionary customer personas.

“I strongly dislike howdevelopers areworshippedin marketing”

In his work at Dopter, an API strategy and consultingfirm, Krohn routinely encounters providers that want tocreate hackathons to reach out to developers to promotetheir APIs. Though that can be an effective strategy, aredevelopers really the sole audience that may be interestedin APIs? The truth is that designers, entrepreneurs, mar-keters, and other business leads are just as importantconstituents to consider when marketing an API.

Krohn believes we naturally target developers for thefollowing reasons:

1. APIs are technical.2. Developers relate to other developers.3. Influence of Silicon valley.4. Myth of the single developer.

Page 39: The API Lifecycle

Understandig Your Target API Consumer 24

Though many people that are aware of APIs are devel-opers, not everyone is a developer. We must rememberthat the world is bigger than the Silicon Valley. Just as theaverage smartphone user can brainstorm innovative appideas without needing to know how to code, there is asimilar low bar that allows anyone to understand the pos-sibilities APIs offer to then envision creative applications.In a company, products are developed by large teams —entrepreneurs, project managers, designers, etc. Devel-opers are crucial to any software process, but in reality,a diverse array of experiences contribute to innovation inthe space.

3.5 Expanding our Portal: End UserEvangelism

If we incorporate a wider audience into our understand-ing of their target API consumer, how does that changethe way an API is marketed?

Krohn encourages us to remember that real value isonly created when an end user uses the app that’s cre-ated with the API. And who creates that experience? En-trepreneurs may create the product, managers overseeproduction, designers envision the user experience, de-velopers connect the backend, and other domain expertsmay contribute. All these stakeholders intimately under-stand the value of API integrations, and thus all theirperspectives and needs should be considered.

Think of standard web API portals as they are now. Canentrepreneurs immediately discern the end user valuewhen they view API documentation? More often than not,their needs are excluded. There is a lack of high-level

Page 40: The API Lifecycle

Understandig Your Target API Consumer 25

summary and sample use cases to inspire non-technicalminds — this experience is often non-existent.

Krohn believes that developer evangelism should ratherbe end user evangelism. As Krohn says, “be aware of whoyou are including or excluding, and make it a consciousdecision.” Think you know your target audience? that maysoon change.

As the API space increases in diversity, more andmore attributesmake up the developers using them

3.6 Varying Industry Backgrounds

With the recent rise of B2B and enterprise interest, shouldAPI providers be selling to individual developers? Or is ita better idea to seek out business partnerships directly?The way APIs aremarketed and consumed varies tremen-dously on the industry. API providers may range from atwo person startup to an enterprise development teamspanning hundreds of employees. The same diversity ispresent on the consumer end, affecting the way APIs areacquired. The core value message also changes based on

Page 41: The API Lifecycle

Understandig Your Target API Consumer 26

whether the API is directed toward startups, engineers ina large organization, or toward convincing upper leader-ship. We can begin by separating the consumer side ofthe API space into two distinct groups:

• Enterprise Developers: Developers working withina large organization. The challenge faced here is thattheymay not be the decisionmaker. Working on theinside, means they must make the case upwards,involving multiple parties and potentially creating alonger decision making process.

• Freelance Dev Shop: These are small startup teamslooking for helpful API integrations to accell theirproduct.

According to Jason Hilton of Catchy Agency, industry vari-ancemean it’s “It’s worth applying specific techniques andstrategies. Just as much energy and consideration needsto be put intomarketing a developer program as with anyother product.”

3.7 API Use Cases

API providers must imagine the API’s use case in the wild.Why would someone want to use your API? Providersshould consider the possibilities the data offers andbrain-storm applications that could be created using the API.Kelly believes this process will help identify consumerneeds:

“The key to a good persona is in establishingconcrete user scenarios and stories…You needto understand the needs of your customerbefore deciding what to offer them.”

Page 42: The API Lifecycle

Understandig Your Target API Consumer 27

This process also involves considering thebusinessmodelof the product that will be created using the API. Hiltonnotes that “the business model of the API is important— we know that serious developers will monetize eitherthrough paid apps, or carrying ads. Trying to get the de-veloper of a paid app to implement an ad API is pointless.”

3.8 Lessen The Corporate Branding

Marketing, relations, outreach — typical B2B sales mo-tives, labels, and tactics may conjure up negative conno-tations. At times, enterprise clientele may need to lessenthe corporate branding to appeal to the tech community.Within the tech community the Evangelist job function isnow more commonplace than ever. Alternative roles like“evangelist” or “developer advocate” help communicate atrue passion, and having a passion, and a true convictionfor what you are promoting will win the day. The lessonof 2015, according to the Catchy team, is that “If you havea developer evangelist, you have a dev program.”

3.9 Developer Experience

Thepresentation of developer facingmaterial is paramountto success in the space. API providers can use tactics tohelp acquire developers, increase onboarding efficiency,and maintain user retention by appealing to the tastesand needs of the audience. Stellar reasoning behind cre-ating quality developer experience can be found in JohnMusser’s “10 Reasons Why Developers Hate Your API.”Harking back to Andreas Krohn’s stance on the need forincreased inclusion, API experience should also considerthe entrepreneur experience, the manager experience,

Page 43: The API Lifecycle

Understandig Your Target API Consumer 28

and the designer experience. In that spirit, embrace de-veloper language, but also cater content, appearance, UI,and UX to your audience. According to Kelly, “developerexperience is the most important metric of quality for anAPI. It’s vital.”

3.10 Build it And They Will _____

Simply opening a platform up without having a intimateknowledge of your consumer will not work in this sec-tor. Product teams within technology companies oftenassume the product will be used, but too often,marketingis either too slim or inefficient, leading to a low adoption.

Perform the necessary research to find who your con-sumer really is. Who is the key influencer that can commu-nicate the value of your API? It comes down to knowingthe needs of this audience, and this requires thoroughanalysis before development should begin.

Page 44: The API Lifecycle

Understandig Your Target API Consumer 29

Next Steps:The excitement surrounding APIs should notdiscourage critical examination into a smartand applicable strategy for your organization.Whatever the chosen API strategy is, it’s mis-sion statement, usage projections, model forgrowth, marketing strategy, and estimatedfinancial return should be clearly laid out be-fore production begins.

Large organizations may find the creation ofa whole department necessary to respond tonew customer concerns from an entirely newAPI-consumer base. Therefore, within theAnalysis Stage, you must allocate resourcesfor development, and anticipate creating sup-port lines for marketing, hosting, customersupport, andmaintenance. If you’ve done thenecessary preparation, it’s time to move tothe Development Stage.

1. Analysis Stage2. Development Stage3. Operations Stage4. Retirement Stage

Page 45: The API Lifecycle

II Development Stage

Arguably the most important action in the API lifecyclephase is implementing the API and bringing it to life. Readon to learn more about this process and to understandwhat factors contribute to choosing the best combinationof standards, designs, and programming languages foryour API.

Page 46: The API Lifecycle

4. Constructing Your APIThis chapter covers the actions to take as well as themostimportant challenges to address during an API’sDevelop-ment phase. We’ll consider what implementation optionsare available and explore API Management and why itmatters. We’ll define API Usability and why it’s important,and we’ll consider what immediate steps to take afteryour API is deployed.

4.1 Things to Consider DuringImplementation

At this point you should have a well-defined API businessstrategy and documentation. This includes defining whoyour main API stakeholders are going to be, and decidinghow the API will be consumed. By this point you shouldhave answers to the following questions:

• What value is the API providing? Is it a means todistribute data or does it offer specific functionalitythat can be used to build apps?

• Who will consume the API? Are consumers inter-acting with your API to get access to data or are theyconsuming it on behalf of other users?

• How many consumers will the API have? Is it aprivate API consumed internally or is it going to beavailable to potentially millions of consumers?

31

Page 47: The API Lifecycle

Constructing Your API 32

Answering these questions will help you cut corners dur-ing the implementation process. Let’s start with under-standing what you are trying to enable with your API sothat you can define which methods and protocols you’regoing to use.

Methods and Protocols

The best way to define methods and endpoints for yourAPI is to follow the functionality you’d like to provide andchoose the most appropriate standards and protocols.Identify what type of data manipulation your main APIconsumers usually have available.

If your main consumers are mobile apps, consider of-fering endpoints that ask for and respond with as littleinformation as possible. This is to prevent large band-width consumption and speed up operations that involvecalls to your API. If, by contrast, you’re offering an APIthat will mostly be consumed by the financial market,carefully study what frameworks they’re using and howthey communicate with external APIs.

Whatever you do, we recommend not to follow the verylatest trends presented as “the future.” Trends can andwill change many times before they stabilize and becomewidely adopted, and your APIwill have to keepupwith thismarket fluctuation. Determine what 80% of your targetaudience is using and offer that.

SDK Programming Languages

Choosing how you’ll offer access to your API is directlyrelated to how your API will be consumed.Will it mainly beconsumed by mobile app developers? Then offer ready-to-usemobile SDKs. Brainstorming your potential API use

Page 48: The API Lifecycle

Constructing Your API 33

cases is the first step in choosing how your SDK will bepackaged.

If you’re not 100% sure about how your API will be usedyou can always offer an SDK in several popular program-ming languages. Algolia, a search engine API, is follow-ing this approach by offering an easy way to use theirservice in languages such as Ruby, Python, Node, PHPor Objective-C. Be aware though that maintaining a largenumber of SDKs is not an easy task as your API evolvesand methods change. APIMATIC and REST United are twoservices that offer automatic SDK generation. With thesetools, whenever your API changes you can rerun the SDKgeneration to make fresh code versions available to yourconsumers.

4.2 API Management

After you implement your API endpoints and decide howconsumers will interact with your API, you must considerongoing operations. The most important factors are con-trolling your API access conditions and determining howto behave in usage peaks. You can follow a DIY approachor use an API management service such as 3scale orApigee.

Whatever solution you choose, remember that you’ll be-come tied to the way it works. Carefully define long termobjectives as well as common scenarios you want toaddress. If you choose a solution that doesn’t offer whatmost of your API consumers use, then you’ll likely beforced to pivot in the long term.

Page 49: The API Lifecycle

Constructing Your API 34

Access Control

One of the most important aspects of API Management isdefining and automating the process of controlling whocan access your API and what measures are in place toenable access limitation, if needed.

Most API Management platforms provide some sort ofaccess control features, including API call limit rating andconsumer differentiation with the help of different paidplans. The very first access control feature to look for ishow your API will authenticate and authorize consumers.

There are several options depending on what kind ofconsumers you’ll have and what kind of usage will occur:

• API keys: The most simple way to control access toyour API. Usually you’ll have to issue one API key foreach consumer and identification will be providedthrough an HTTP header on each and every call.

• OAuth 2: Perhaps the most popular authorizationstandard used by Web APIs. OAuth 2 lets you com-bine token-based authentication with fine-grainedaccess control based on user scopes. This is the bestsolution whenever API consumers are making callson behalf of other users.

• Origin IP address: This can be combined with otheraccess control methods or used on its own. Using italone is done in cases where you’re providing an APIto a very limited audience. To achieve better resultsyou should also add origin information to your logsand usage analytics.

Whatever access control strategy you choose, always re-member that it must accommodate your API’s most pop-ular use cases. As an example, it doesn’t make sense to

Page 50: The API Lifecycle

Constructing Your API 35

use a simple API key based authentication if your mainAPI usage is through a mobile app. In this case it wouldmake sense to use OAuth and let the mobile app act onbehalf of its users.

4.3 Maintenance

While launching your API can be an exciting challenge,keeping it up and running is often seen as somethingboring. API maintenance is often delegated to a secondplan and only considered after things start to go wrong.Don’t follow this path; implement a good maintenanceplan from the start.

The usual activities around maintaining your API are re-lated to documentation, communication with consumersand proactively understanding if something is not work-ing as expected. As such, a big part of maintenance isdone by periodically testing your API to make sure thateverything is working as documented.

Testing

One way to proactively understand if your API is per-forming according to the documentation you provide andfollowing your quality-of-service is to run periodic testsagainst individual endpoints. With monitoring in place, ifany of the tests fail, you can hopefully fix the error beforeyour consumers experience problems. These types oftests can be performed on your API:

• Performance-oriented: These are tests that makeindividual calls to each and every method your APIprovides. If a response takes longer than a specified

Page 51: The API Lifecycle

Constructing Your API 36

time limit, it means that there’s a problem on thatspecific endpoint.

• Functional testing: This type of testing works bymaking singular calls to each API method to thor-oughly test every API function, using different kindsof payloads, or even sending data that will produceerrors. Responses are then compared to the ex-pected behavior to locate errors.

• Use case testing: This is a more sophisticated typeof test and can be achieved by combining calls to dif-ferent endpoints into a single test. Each test shouldexpect a specific response and execution time limit.

There are several tools that can help you run API testsperiodically in an automated fashion. POSTMAN, for ex-ample, is a Chrome app that lets you run all the testsmentioned above. There is also the SmartBear suite ofAPImonitoring tools. If you’re looking for somethingmoreSaaSy you can try Runscope, a service that periodicallyruns tests and reports on their results. Other helpful APImonitoring solutions include APImetrics and API Science.

Managing Changes

Even if everything is working as expected, sometimesyou’ll need to introduce changes to your API. When thishappens, consider the impact on your consumers andinternal systems by:

• Informing consumers about changes: Establish aclear communication channel between you and de-velopers using your API to inform them of changesin a transparent fashion.

Page 52: The API Lifecycle

Constructing Your API 37

• Keeping compatibilitywithprevious versions: En-sure that any introduced change doesn’t break whatwas already working. Remember that your API con-sumers may not be able to update their systemsimmediately.

• Minimizing downtime: Don’t bring systems to ahalt — even momentarily. Your build and deploy-ment processes should guarantee that API changeswon’t affect API calls and functionalities. API down-timemight create downtime or loss of quality on theconsumer side, so keep it to an absolute minimum.

Downtime can be minimized by following a ContinuousIntegration approach and testing your code thoroughlybefore deploying. Making sure that there are no break-ing changes can be achieved by following a sound APIversioning strategy. If you offer and maintain differentversions of your API, consumerswon’t feel the changes onthe version they’re using. A helpful solution that bridgesthe gap between API doc changes and the consumer isthe API Changelog, a tool that automatically discoverschanges to your API documentation and informs sub-scribers.

Page 53: The API Lifecycle

Constructing Your API 38

Check out our Winter Collection eBook as well - a collec-tion of our best advice from the 2014-2015 winter season

Page 54: The API Lifecycle

5. 12 Design Tips

During the Nordic APIs World Tour, expert API practi-tioners shared their insights with attendees at four in-ternational cities, touching on API development, security,design, operations, and more during intimate conferencesettings.

A recurring theme in many talks was API Design. So, inthis chapter, we’ll sum up important API design lessons

39

Page 55: The API Lifecycle

12 Design Tips 40

that were conveyed by our speakers and then add someof our own — both practical tips on technical implemen-tation, as well asmoremore philosophical considerationson how to hide (or not hide) complexity when designingan API.

1: Know Your API Require-ments

API design should not begin with technical documenta-tion, but should rather originate from your fundamentalgoals. Knowing what your API needs to accomplish is ofthe highest importance. This is defined in the analysisphase of the API lifecycle.

As Phillipp Schöne from Axway pointed out, API designersshould ask “how APIs can support the business function andnot how they can support the needs of IT.”

2: Think of APIs as BuildingBlocks

It’s important to remember the unique characteristicsof APIs. As a consumer, tying into a service’s underly-ing data or functionality is inherently a unique process.Though comparable to SaaS products, Andreas Krohnfrom Dopter highlights two key differences:

The first is that APIs are building blocks and not finishedproducts: “If somebody is using your API they are basicallyoutsourcing a part of their business to you”.

His second lesson is thatmachines are not flexible. If aSaaS product changes, a person can adapt, but if an API

Page 56: The API Lifecycle

12 Design Tips 41

changes, a machine is not as adaptable. This influencesthe design and the whole lifecycle of the API, and affectshow we prepare for parameter changes and versioning.

3: Learn From User Feedback

Theneed to understand your audience is applicable through-out the entire lifecycle. If you are updating, versioning, orperforming major redesigns on an existing API, you needto carefully respond to the feedback from your users tomake the new version as good as possible.

MarjukkaNiinioja, Senior Consultant andManager at Plan-Mill shares her experience with leveraging user feedbackduring a major redesign: developing PlanMill’s new REST-ful API, UI, and back-end architecture.

PlanMill payed close attention to the feedback they werereceiving internally, noticing three main recurring points:

1. The API was too complex for the developers to use.2. The documentation was not sufficient.3. The error handling needed work.

Using this feedback, and by testing and consuming theAPI themselves, the PlanMill team was able to hone inon important aspects to consider during redeployment.The takeaway is that if you are redesigning an API, youare poised to release killer API improvements — as youalready have real world data on how API functionalityis used, which can be repurposed to improve efficiencyand overall API user experience.

Page 57: The API Lifecycle

12 Design Tips 42

4: Decrease Confusion ForThe User, Let Provider Han-dle Complexity

Who pays the price for complexity? Nordic APIs veteranRonnie Mitra of API Academy argues that complexity isnecessary—what should be avoided instead is confusion.Mitra contends “it is a designers job to reduce confusion andembrace complexity in their business domain.”

There has been a move toward simpler products andsimpler interface designs. Mitra, an expert in developerexperience and API design, advocates for smartly de-signed software and APIs that retain simplicity but alsocater to complex requirements. Quoting John Maeda’sLaws of Simplicity, Mitra notes that “Simplicity is aboutsubtracting the obvious and adding the meaningful.”

A steering wheel in a F1 car is very complex comparedto the steering wheel of a normal car, “designed and

Page 58: The API Lifecycle

12 Design Tips 43

optimised for its user and the situation”. Ronnie makes agreat point that “every design decision is a decision of ifyou [as an API provider] or client app developers will paythe price of complexity”. As an example, OAuth is complexto implement by the service provider but easy to use bythe client developer. We cannot avoid complexity, butwe can architect our APIs so that the user-facing side isdeceptively simple.

Ross Garrett from Axway also talks about what applyingan API-first strategy means for enterprise organizations.In dealing with legacy systems, he notes that a missmashof tangled infrastructure can be masked by using properAPI management tactics.

“Your old architecture [may not have] usefulAPIs, or may be older SOAP services that don’tperformwell in the context ofmobility or cloudintegration. Some legacy things need to re-main, but API management can extend andreuse by translating all old interfaces.” What’simportant is having a clean business appear-ance for the end user.

5: Use Hypermedia For Evolv-ability

It is impossible to talk about API design without men-tioning Hypermedia, a subject that came up in severalpresentations during the Nordic APIs World Tour 2015.Pedro Felix of Lisbon Polytechnic Institute, offers a deepdive intoHTTP. He summarizes his presentation about APIdesign this way:

Page 59: The API Lifecycle

12 Design Tips 44

“If you have a problem, keep calm and look foran HTTP RFC”

Pedro considers hypermedia as the key factor for evolv-ability, allowing API providers to react to new business re-quirements quickly without breaking client applications.Related to Mitra’s theory on the distribution of complex-ity, using hypermedia means more initial complexity forclient app developers, but an overall reduced complexityconsidering the ease of future changes.

6: Learn From Real World In-formation Design

Brian Mulloy from Apigee demoes a hypermedia API forthe Internet of Things. By using hypermedia it is easyto introduce new devices into the IoT since all possiblestates, actions and feeds are described in the API itself.

Page 60: The API Lifecycle

12 Design Tips 45

Mulloy describes API design for the Internet of Things asusing information design for physical objects. He com-pared this to the early days of mass car production in hishometown Detroit. Suddenly the city had lots of cars, butinfrastructure was not prepared for a large automobileinflux. The resulting confusion lead to chaos and even alarge number of traffic related deaths.

The solution was to use information design that resultedin standard designs used all over the world today. Pedes-trian crossings, traffic lights, stop signs, and lane markersmake it clear how to behave in traffic. Akin to the earlydays of cars, we are still working on how to organize anddesign today’s APIs for the IoT.

7: API Design Needs To Con-vince the Architect

Having a shared vision within an organization is key forAPI interconnectivity to be accepted. To help convince APInaysayers, whether they be architects or engineers, in histalk, Adam Duvander of Orchestrate walks through fourways API providers can frame their API product to fosterconfident adoption. These factors should be consideredwhen designing an API in order to respond to commonstigma associated with API integrations.

1. The architect wants control: Accustomed to tradi-tional methods of infrastructure — data storage onlocal servers — the architect may be opposed tocloud operations, desiring to ‘touch’ the software.To workaround this stigma, API providers can offerthe ability to download and store data sets locally,or even offer an on premise, dedicated, managedoption the API.

Page 61: The API Lifecycle

12 Design Tips 46

2. The architect wants zero downtime: To foster reli-ability in the service, having transparent developer-facing logs that communicate API uptime is critical.

3. The architect wants to see responsibility: API sys-tems need to be designed as secure systems usingmodern approaches.

4. The architect requires an integration that guaran-tees longevity

8: Develop With a Long-TermMindset

Within a “develop for now” approach, developers arecreating an API for immediate use, focusing entirely onintegrating existing feature sets and supporting specificsets of queries. The downside of this approach, however,is that they are only robust at what they are designed for,and nothing more. Designing for the immediate needsand requirements of a service or system is all well andgood, but it does little for long term support.

9: Be Consistent

Maintain consistency. If your API uses calls that don’trun in the same environments, bug hunting becomesa chore. If your documentation is inconsistent with ac-tual functionally, you risk confusing and segmenting youruserbase. If you have a methodology to refer to outsidesources, use this methodology on every reference. If youcover a request by another multipart request, make surethere’s no needless redundancy.

Page 62: The API Lifecycle

12 Design Tips 47

10: Allow for Manipulation ofData

Data is only as valuable as it is understandable. Whenusers receive data from your API, consider the method-ology of how it’s delivered. Delineate data by type, andallow sortingwithin certain limitations. Powerful, dynamicservices that allow for far more usefulness of API data isa common requirement amongst many developers.

11: Effectively Validate andReport

Returning useless errors that state the obvious (some-thing went wrong), the useless (ERROR), or the downrightconfusing (error code:9442394) is a losing proposition— if your users can’t find out what went wrong duringbasic errors, they’ll stop using the API entirely. Similarly,failing to return a valid JSON, and refusing to effectivelydocument what error codes actually mean can make apotential API development partner second-guess integra-tion with your services, further killing potential user basegrowth. Make sure all error returns are understand-able

12: Support Uptime

Uptime is our fifth and final tip as it is a wonderful metricby which we can holistically judge an API. It representseverything working in concert — if a single element of anAPI is poorly managed, uptime will likely be influenced. At

Page 63: The API Lifecycle

12 Design Tips 48

the time of this writing, Bit.ly reports 100% uptime overthe past 24 hours, with a yearly uptime rating of 99.9%.Likewise, the Twitter API reports 100% uptime with anaverage uptime of 99.9%. The proof, as they say, is in thepudding (or in this case, the uptime).

5.1 Summarizing API Design Tips

Considering the development of your API is a seriousendeavor. The choices made now will impact your futuresuccess in a big way. While these solutions can be imple-mented after the fact, it is far easier to implement themat the start of the development cycle. Not only will thisdeliver a more completely integrated feature set, it willalso give you a product with simpler end-documentationand user experience.

These 12 design and development concepts may be sim-ple, but the implications of their applications are decep-tively huge — implementing them can lead to explosivegrowth, high user adoption, and long-term use statistics.Design an API that allows an API provider to handle mostof the complexity, and simplify processes for your clientapplication developers. Above all, do not forget that theAPI design should serve your overall business require-ments.

Page 64: The API Lifecycle

12 Design Tips 49

Next Steps:As you now understand, developing an API isnot limited to writing the code and makingit available. Understanding your API use caseplays a major role in building the founda-tion of your offering. Maintaining proper APIhealthmeans never leaving it unattended —as you risk a decrease in consumer retentionand a damage to your brand.

This stage of the API lifecycle is so critical thatnumerous services have been launched andmany startups created just to help companiesdeal with all that’s involved. These toolswill help you understand what you have to donext. If you are motivated to introduce majorchanges to your API we recommend you visitthe Analysis Stage to treat those iterationsas a brand new API launch or version. Oth-erwise, jump into the Operations Stage andrun your API like a product, fostering its userbase.

1. Analysis Stage2. Development Stage3. Operations Stage4. Retirement Stage

Page 65: The API Lifecycle

III Operations Stage

In this part we discuss what factors make up the Opera-tions Stage, and how they should be addressed. Trans-forming your API into something developers will wantto consume, and learning what impact this will have onyour business are thingswe’ll consider at this stage. Othercritical actions involve maintaining a positive relationshipwith your API audience and offering them appropriatesupport channels.

Page 66: The API Lifecycle

6. Marketing Your APITo start, let’s take a look at your API from a different angle— one that presents your API as not just a developer-oriented tool but as a full product that solves a realproblem. In this chapter we’ll see how this angle can finetune the promotion of your API to focus more on youraudience’s perspective and needs.

6.1 Running Your API As a Product

Why should you treat your API as if it were a full-fledgedproduct? Isn’t the API something that’s supporting yourexisting product? Though it may sound strange, runningan API as you would with any other product actuallymakes a lot of sense.

By definition, a product is something that exists to satisfythe needs of a group of consumers. Usually, during prod-uct development, you research what consumers need sothat you can design your product accordingly. You alsoconduct research to understand how consumers will usethe product that you’re designing. The results of theseactivities will eventually lead to the creation of your newproduct.

By applying the same strategy to your API, you’ll not onlyhave an API that developers reallywant to use, but you’llalso fully understand your target audience—a vital aspectof attracting developers to your API. The second activityis not any less important, as it will greatly inform the APIdesign process. By learning how developers will consume

51

Page 67: The API Lifecycle

Marketing Your API 52

your API you’ll be able to adapt the following items, ifneeded:

• Access Control: Are developers building applica-tions that act on behalf of several users? Does itmake sense to use API Keys, OAuth or somethingelse?

• MethodsandProtocols: Dodevelopers prefer REST,SOAP, Thrift, or something else? What makes moresense from a consumer point of view?

• SDK Programming Languages: Are developers us-ing Ruby, Python or other languages? What SDKsshould you offer and support?

• Asynchronous Operations: Is your API mostly con-sumed by Web browsers, mobile devices, or back-end code? Are API calls made from behind firewalls?Can your API use webhooks?

Page 68: The API Lifecycle

Marketing Your API 53

If you don’t conduct product-oriented research then you’llnever understand how your API should be offered, and itwill be much harder to pivot or gain traction in the longterm. If you follow this strategy you’ll have the equivalentof product/market fit: API/market fit. Next, you’ll wantto fuel your API usage growth by employing various mar-keting tactics to attract more and more developers overtime.

Page 69: The API Lifecycle

Marketing Your API 54

6.2 Marketing Your API

Marketing an API is very similar in concept to any otherkind of marketing. You’ll want to produce material thatwill promote your API in a variety of ways. This startswith launching your developer portal, which will act asthe official point of contact between your API and itsconsumers.

As your developer portal will be central to all your API-related activities, it should offer an easy access to all thefollowing resources:

• API Documentation: Probably the most importantresource, documentation should always be up-to-date and provide all information needed to quicklybegin consuming your API.

Page 70: The API Lifecycle

Marketing Your API 55

• Application Registration: Offer an easy-to-followregistration process that any developer can under-stand. The output of this process should be an APIKey or a Client ID and Secret if you’re using OAuth.

• API Console: Developers usually want to test yourAPI without having to write any code. Either offer anAPI Console or provide ready-to-use code that canbe copied and pasted. This first impression of APIfunctionality should be succinct and powerful.

• SDKs: After testing, your developers will want toconsume the API from within their existing appli-cations. Offer the appropriate SDKs and follow thepackaging and installation standards for each pro-gramming language. For example, if you’re offeringa Ruby SDK, offer it as a Ruby gem.

• Announcements: Keep your audience up-to-datewith anything you do related to your API. Announceall upcoming API changes and other relevant activi-ties.

• Use Cases: Provide comprehensive use cases thatyour audience can identify with. Complement themwith sample code that uses your SDKs. It’s mucheasier to understand how your API works by readinga story than by going through the full reference.

• Support: Offer a simple support channel directlyfrom your developer portal. Whenever developershave a question they should be able to contact yoursupport team from within the portal. Provide quickfeedback on support requests and always follow up.

• Links to External Resources: Link to external re-sources that could help developers use your API.Have your documentation link to the standards thatyou’re following and provide relevant social medialinks so developers can follow your announcements.

Page 71: The API Lifecycle

Marketing Your API 56

If you implement all these suggestions you’ll have a su-perior API Developer Portal, but you still have to attractdevelopers to it. Site activity should be combined with apermanent instrumentation of your API and DeveloperPortal usage so that you can correctly measure traction.

6.3 Using Different Traction Channels

In order to obtain the best possible results, fosteringyour API user base should be done across a number ofdifferent channels. Along the way you should measureactivity on each channel and adjust accordingly. As you’reabout to see,marketing channels have different costs andyou should understand howmuch, on average, each newdeveloper is costing you to acquire.

In the Product world, this value is often called CustomerAcquisition Cost or CAC, and can be used as a model todetermine if any of your channels should be abandoned.To append this, you should also estimate the total futurerevenue obtained from each new developer using yourAPI. The Customer Lifetime Value or CLTV is what de-fines howmuch revenue, on average, each developer willgenerate.

Page 72: The API Lifecycle

Marketing Your API 57

Tomake a profit, you should always aim for a CAC smallerthan the CLTV. Otherwise, you’ll end up paying more fordevelopers than the potential future revenue that you’llobtain from them. With this in mind, let’s look at somepossible traction channels.

Evangelizing Your API

Evangelizing is one of the methods used by most of thepopular APIs. Evangelizing is usually done by meetingdeveloper groups in person to share stories about howyour API can be used. So-called “API Evangelists” are usedto promote APIs using online media, and in person byattending developer-oriented meetups, conferences, andother related events.

Naturally, this type of promotion can have a cost range ofnearly nothing — especially if you’re doing it by yourselfonline — but can be more costly if you employ a group ofdedicated evangelists to attend every possible developerconference. Be pragmatic by starting small and measur-ing your results along the way.

Page 73: The API Lifecycle

Marketing Your API 58

Hackathons, Events, Conferences

Another popular tractionmethodis promoting your API is byhosting a hackathon or de-veloper oriented event. Hackathonsmay be geared toward a spe-cific industry or theme and areoften location-based — allow-ing you to target specific demographics and discover andpromote new use cases that can be showcased on otherchannels.

Integrations and Partnerships

An interesting way to gain traction is to attach your APIto the growth of other products and APIs. This can bedone by creating integrations that will make your APIeasily available and consumable by developers who useother products. Integrations often address specific usecases, so carefully study which one will attract the largestnumber of developers. Some integrations might be aseasy — such as writing the code and publishing a guide— but in some cases you might need to engage intopartnership development.

Here, the cost will mostly be associated with softwaredevelopment activities — but don’t forget that you’ll alsohave tomaintain and support the integration after it goeslive.

6.4 Supporting Your API

Support always works better the closer you are to youraudience. Understand where your API consumers usually

Page 74: The API Lifecycle

Marketing Your API 59

ask for help and have a saying in those places. Don’t forceyour developers to use specific tools and processes thatdon’t make sense from their point view or you’ll startto see them abandoning your API after an unsuccessfulusage.

A simple way to grow your support channel is to keepthings open. KeepingAPI-related activities as publicly trans-parent as possible means your support team will spendless time replying to the same requests.

Use GitHub

GitHub is considered themost popular developer-friendlyservice andAPI providers should take it seriously. By usingtheir free plan you can create a repository to providean easy-to-use support channel. GitHub offers a way tomanage issues related with code changes and openlyinteract with developers. An example company followingthis approach is Spotify, who has been very open aboutall their API-related issues through GitHub.

Other Developer-oriented Support Tools

Research your developer audience to understand whichother web services they use the most. It’s important tohave a presence on them aswell. Popular services includeStack Overflow, specific subreddits, Twitter or Facebook.Although social media isn’t specifically a support channel,you can use it to quickly give feedback to any questionsdevelopers might have about your API. Remember toalways be open and to provide helpful responses.

Page 75: The API Lifecycle

7. The Importance of APIMetrics

Success and failure are relatively subjective terms—whatdefines success for one business might be considered afailure for another, and the relative of success in certainareas of performance can change from industry to indus-try, department to department, and even on a case tocase basis. This volatility in expectations, outcomes, andimpacts can make API documentation, implementation,and support a difficult undertaking.

Luckily, those who work with APIs have a secret tool thatcan make sense of the hectic world of performance eval-uation — metric analysis. Proper use of metric analysiscan allow businesses to understand their consumers and

60

Page 76: The API Lifecycle

The Importance of API Metrics 61

aid in further development and implementation of user-friendly and effective APIs.

In this piece, we’ll take a look at metric analysis to demon-strate how it can be used to amplify success within the APIspace. We’ll suggest types of metrics to analyze, demon-strate a theoretical application of metric analysis, anddiscuss two real-life examples of success and failure aris-ing from differing metric analysis methodologies. By theend of this piece, you should have a firm grasp on thedefinition, application, and impact of proper API metricanalysis.

7.1 What Is Metric Analysis?

According to theOxfordDictionary,metrics are “method[s]of measuring something, or the results obtained fromthis”. Metrics are the way we measure the values of atargeted part of a system, measuring an event from in-ception to completion, including the effects caused by itsimplementation.

So now that we know what a metric is, why is it soimportant to APIs? Metrics, and by extension API-centricMetric Analysis, are invaluable tools for the modernbusiness. Metrics can be used to develop new processes,create a fundamental understanding of the product andtargeted consumer, drive a holistic understanding of yourmanufacturing process andmethodology of delivery, andcreate opportunity to monetize and optimize your API.Using metrics can bring you to a bird’s-eye view of anentire API process, following the age old saying — “youcan’t see the forest from the trees.”

Page 77: The API Lifecycle

The Importance of API Metrics 62

7.2 Metric Analysis Tools and Services

There are many types of metrics that can be captured,analysed, and used to develop more effective API sys-tems. Metrics can largely be grouped into two categories:internal metrics and external metrics.

Internal Metrics

Internal Metrics are those that are derived from datacaptured by internal web servers, user feedback forms,and trends observable through internal systems. Theseinclude:

• User type: Is the consumer a repeat user or newuser?

• Days since last session: How long ago was the APIlast used by repeat users?

• Traffic sources: Are functions within the API beingcalled through your own web application or a thirdparty application?

• Function grouping: How often a user calls a certainfunction along with other functions.

• Types of data requested: Is your server servingmedia requests, plain text requests, or other typesof requests more often than others?

• Access speeds: Howquickly is your system respond-ing to requests? Where is the bottleneck?

• Service requests: How often are some services be-ing requested? Are there any services that are neverrequested?

• Error reporting: How often does a user report anerror with the system, andwhat is the specific error?

Page 78: The API Lifecycle

The Importance of API Metrics 63

External Metrics

These metrics are derived through the use of processesand applications that originate outside of the API devel-oper. While internal metrics are concernedmore with thefunctioning of the actual API and overall system, externalmetrics focus more on the community and potential userbases. These metrics may involve third-party systems:

• API and service adoption rates - WebTrends• Redirection and publicly facing data - Google Analyt-ics

• Market trends and behaviors - Adobe

7.3 Example — The Tokyo TrafficProblem

Away to understand the importance of metric analysis is toshow a situation in which it is applied properly against a

Page 79: The API Lifecycle

The Importance of API Metrics 64

situation where it is not, comparing the results of bothapproaches. Let’s imagine that we are engineers for theroadways of Tokyo, Japan, one of the largest cities in theworld. We are tasked with solving a congestion problemin one of the most congested intersections in the entirecity.

Let’s first approach this problem without using MetricAnalysis. We will use an observational approach. Bystanding on an overpass straddling the most congestedarea of the road, we mark down our observations inour notebook, noting both the number of cars and thenumber of lanes provided. Using these observations, asolution is designed to expand the roadway by an extratwo lanes. The time budgeted for construction is set ona 24-hour schedule. You assume the congestion will easedue to your solution, and you step away. Some monthslater, the congestion you observed has only spilled intothe new roadways, worsening the problem. The obser-vational approach has resulted in more problems than itfixed, and is considered an abject failure.

Now let us approach the problem in a metric-based ap-proach. After being assigned the project, you first look atthe city road maps. You observe that the congested roadis likely facing issues arising from a stoplight intersectionsome miles ahead of the congested area; because thehighway empties into a city thoroughfare before con-tinuing onto another highway, this area functions as a“bottleneck”, increasing congestion by constraining thethroughput of the system as a whole. Using this data,you decide to add a three-lane highway that bypassesthe city thoroughfare, allowing traffic to flow both intoand around the intersection, dependent on the driver’sneeds. You also decide to implement a roundabout asopposed to a stoplight, thinking the flow of traffic should

Page 80: The API Lifecycle

The Importance of API Metrics 65

be eased in this manner. This plan is placed on a con-struction schedule over a handful of weeks, avoidingworkduring the rush hour. After implementing this solution,you collect data over an entire week, making notes ofpoints of failure or issues at certain times of the day.Congestion has eased considerably, and themetric-basedsolution is considered a success.

7.4 The Traffic Problem Solution

What was the difference between the two approaches?Both aimed to ease congestion, and while the first ap-proach was different than the second, on paper they bothshould have worked. The difference is the fundamentaluse of data in implementation.

• In the observational approach, the global issue ofcongestion was attacked by a specific solution. In themetric-based approach, the global issue of conges-tion was attacked with a global solution.

• Issues arose within the first approach from fail-ure to understand the end consumer (expanding theintercity thoroughfare, and using a 24-hour buildschedule interfering with rush hour). The secondapproach understood the requirements of the endconsumer, creating a highway bypass and avoidingconstruction during the most congested periods ofthe day.

• The observational approach eschewed data anal-ysis, assuming a localized solution would fix theproblem, while the metric-based solution observedthe measurable results of the solution, tweaking andadjusting to any new requirements that arose dur-ing construction.

Page 81: The API Lifecycle

The Importance of API Metrics 66

7.5 The Traffic Problem and APIs

So what does Tokyo congestion issues have to do withAPI development? The two approaches above are perfectanalogies for the development and implementation cycleof APIs, and show the measurable need for Metric Anal-ysis. When developing an API, one must monitor internaland external metrics to ensure their API is effective in thelong-term. When an API is developed and implemented,the following vital factors must be considered:

• The needs of the end-consumer, that is, the user whowill interact with the API and its front-facing systems

• The method and timescale of implementation, i.e.whether or not the API will be implemented imme-diately or over time

• The type of implementation, i.e. whether or not theAPI is specific (defining a single use or purpose) orglobal (completely overhauling the already existentstructures and systems)

• Themeasurable solution, or the effects caused by theimplementation of your API on your end-consumer

7.6 Metrics Throughout the Lifecycle

To better understand this concept, let’s break down theAPI Lifecycle point by point, examining the role of metricanalysis in each stage.

In the first stage of the API Lifecycle, the Analysis Stage,metric analysis is perhaps most effectively and exten-sively used. While determining the usefulness of an API,the demand for its implementation, and the decisionsbetween Private APIs, Partner APIs, and Public APIs (a

Page 82: The API Lifecycle

The Importance of API Metrics 67

subject covered more fully in our eBook Developing theAPI Mindset), the use of metric analysis is specificallydesigned to help you understand your client base, theirneeds, and the relative importance of ease of accessibil-ity and extensibility. By analyzing market trends, review-ing web server data, and polling prospective clients andusers, metrics can help effectively narrow and define theobjective of an API system.

During the second stage of the API Lifecycle, the Devel-opment Stage, metric analysis switches from an externalrole to an internal role. By analyzing the systems avail-able to your developers, tracking the management andimplementation of features, and using varied methodsof rigorous testing and bug-tracking, quality is supportedand the product is refined into its best possible initialstate. Failure to perform proper analysis on the variedmetrics in this stage can result in massive hidden failures,missing feature-sets, and an overall displeased user base.

Nearing the end of the API Lifecycle, the [OperationsStage(#Operations) is nearly as heavy in metric analysisas the first, as it is concerned with the public usage,reception, and internal response through iteration andpatching. Monitoring user statistics, including the meth-ods and durations of use, general feedback concerningusability and extensibility, and the overall impression ofthe API system can not only help you further refine yourproduct, build a confident, strong user base, and quicklyrespond to bugs and issues, it can also help you preparefor future development projects and make the first stageof your next endeavor that much smoother.

Finally, the fourth stage of the API Lifecycle is the Retire-ment Stage. This stage is often the direct result of effec-tive analysis throughout the previous four stages. When

Page 83: The API Lifecycle

The Importance of API Metrics 68

retiring and deprecating APIs, metrics concerning usagerates, operating system and browser support, financialresponse, and user base confidence can all inform thedecision to retire, continue, or reiterate an API.

Failure to conduct API metric analysis could result in aproduct undergoing an expensive and lengthy develop-ment cycle only to find little demand upon release, mak-ing the API financially impractical. Effective metric analy-sis, however, can help create a stellar product, producedquickly andwith less expense, resulting in higher demandwith a longer lifespan. This is the raw power of metricanalysis.

7.7 A Real-World Failure - Heartbleed

API security is a huge issue, and is becoming a moreprominent concern as more companies adopt the API-centric design concept. One of the most well-known ex-amples of security failure arising from poor metric anal-ysis is the infamous Heartbleed bug. This bug, whichaffected users implementing OpenSSL, a widely used se-curity protocol, had a vulnerability in its data input val-idation algorithm, which allowed for excess data in itsbuffer overflow (a system meant to allow data exceedingthe maximum buffer size to “overflow” into a secondarybuffer registry) to be read in its entirety without beingvalidated or checked for malicious code. Due to this bug,data could be forced through the overflow systemwithoutvalidation, executing commands that made internal data,systems, and services vulnerable to external, maliciousattacks.

This bug is directly a result of improper metric analysis.During the initial construction of the OpenSSL system and

Page 84: The API Lifecycle

The Importance of API Metrics 69

API, “negative testing”, or the testing of failure scenarios,was not properly conducted against the buffer overflow;if it had been, the issue would likely have been foundearly on and patched before it was abused. The needsof a secure system for end-consumers was not properlyidentified, as the vulnerabilities of the system itself werenot properly tested against common validation failureandmalicious attack scenarios. By not acknowledging therate of buffer overflow incidents and the type of datathat failed validation during such scenarios in the metricanalysis process, an entire class of vulnerabilities wasessentially ignored until it was too late.

7.8 A Real-World Success - The FedExShipAPI

When FedEx set out to develop an API for their shippingand freight systems, they had one issue in mind — effi-ciency. By eschewing the “established is better” mantraand focusing on an agile mode of API and business de-velopment, FedEx’s API, known as ShipAPI, is about asimpressive a success story as one could hope for.

At one time, FedExwas floodedwithwhat they call “WISMO”(Where IS My Order?) calls — customers dealing with ex-treme variations in ship times, inaccurate delivery dates,and a lack of updates from FedEx to the customer. To rec-tify this problem, FedEx analyzed the frequency of thesecalls, the locations from which they were made, the typesof packages being sent, and the shipping services used.Additionally, FedEx examined their own internal practices,the rate of adherence to electronic scanning of barcodesupon receipt at a FedEx facility, and the effectiveness oftheir long-distance package tracking system.

Page 85: The API Lifecycle

The Importance of API Metrics 70

By identifying theweaknesses in their own system throughthe use of internal metrics (utilizing both anecdotal met-rics from users and operators as well as hard metricsderived fromservers, scanning systems, and internal sort-ing reports), FedEx was able to pinpoint their points offailure, decreasing the time it took to deliver a product,increasing customer satisfaction and confidence, and cre-ating a channel of communication that could update thecustomer faster and more accurately than any systempreviously used by the customer. Almost overnight, theFedEx brand became synonymous with quick, efficientshipping, and that is greatly due to their effective devel-opment and implementation of an API utilizing propermetric analysis.

7.9 Security, Effectiveness, andCommerce

Fundamentally, the process of metric analysis is not justone focused on security. Commerce, effectiveness of so-lutions, and more can all be determined through theproper derivation, analysis, and application of solutionsderiving frommetrics. By determining your end-consumer,their needs, the needs of your process, and the total resultof the application of an API, you can dramatically increaserevenue, security, and even your consumer-base.

The lesson of it all? Understand your consumer base.Understand the API you are developing. And,most impor-tantly,measure your success and learn fromyour failures.

Page 86: The API Lifecycle

The Importance of API Metrics 71

Next Steps:By now you should know that in order togrow your developer audience in a sustain-able fashion, an API should be treated justas if it were it’s own product. Your Oper-ations activities will then consist mostly ofmarketing your API by implementing the bestpossible Developer Portal and by following acombination of different traction channels.

TheOperations Stagewill inform you onwhatexactly it takes to push your API into high-growth mode. You’ll also discover market-ing expenses related to developer attraction,aiming to have that value bemuch lower thanyour revenue — otherwise you won’t have abusiness.

As you learn and your API experiences realworld consumption, you’ll likely have to refineyour offering. If you’re not obtaining the de-sired traction, consider revisiting the AnalysisStage to refine your business objectives. If,during Operations, you find that there’s amissing feature or change needed you shouldrevisit the Development Stage. Finally, if youracquisition costs are so high that you can’tpossibly maintain a flow of incoming devel-opers you should consider jumping to theRetirement Stage of the API Lifecycle.

1. Analysis Stage2. Development Stage3. Operations Stage4. Retirement Stage

Page 87: The API Lifecycle

IV Retirement Stage

Why would a web API be retired? what business factorscontribute to this decision? In this part we examine theRetirement Stage of the API lifecycle, taking an in-depthlook at example API deprecations to attempt to answerthese tough questions and examining how to successfullyretire your API while saving face with your developercommunity.

Page 88: The API Lifecycle

8. A History of Major PublicAPI Retirements

Old age comes, and retirement is a part of life. It’s nodifferent in the API world. The retirement of the Netflix,Google Earth, LinkedIn, and ESPN APIs are examples ofsome recent large public API deprecations. Every majorAPI retirement tends to spawnworrywithin the developercommunity; are public APIs doomed?

We don’t think so — don’t forget there’s currently anestimated 13,000 web APIs in operation, and the sectorhas shown exponential growth and is slated to increasewith the IoT (which isn’t just a fad). However, all thingscome to an end. As conditions change, technologies mustevolve tomeet newmarket conditions. A public-facing APImay prove successful for some organizations, whereasfor others, open environments may not be viable andlucrative.

8.1 What Does Retirement Mean?

Retirement canmeanmany things. An API versionmay bescheduled for complete deprecation, or the API could stillexist in a limited format with increased access controls.An API may simply slim down it’s excess functionality tobecome more consolidated and lean, or be fully replacedby an internal technology or outside competitor.

In order to fully understand the conditions that beckonmajor API changes, we’ll lay out 5 common causes that

73

Page 89: The API Lifecycle

A History of Major Public API Retirements 74

beckon API retirements. Using large API deprecationsfrom recent years as examples, we’ll explore the reason-ing behind each one that we’ve been able to surmisethrough our research. Sound fun? We think it’s prettyfascinating what can be learned from hindsight…

8.2 Retirement Reason #1: Lack of 3rdParty Developer Innovation

A common scenario that may cause an API shutdownis if the API is receiving limited or unsolicited use bydevelopers and end users. Though this could be due toinadequate marketing, it could also be proof that the APIis not offering a true value to it’s consumers.

Netflix

Netflix proudly unleashed their API program in 2009,citing the possibilities for newapp creations by third-partydevelopers. Eventually they stopped issuing new API keysto developers, and by 2014 this was shut down to allusers aside from select partner integrations. According toDaniel Jacobson, Director of Engineering at Netflix, theirreasoning was “to better focus our efforts and to alignthem with the needs of our global member base.”

In the end, all of Netflix’s public API requests equated toabout one day of private API requests. The user base forthe public API was too miniscule to warrant it’s existence.

The result was to eliminate their Public API program toembrace a single private/partner Java API. Nowadays, ev-ery Netflix app on any device taps into the Netflix privateAPI, which performs data gathering, data formatting, and

Page 90: The API Lifecycle

A History of Major Public API Retirements 75

data delivery for all consumers. Netflix has also elimi-nated versioning within their API to embrace imperma-nence and constant change.

We learn from this case that when a brand name andnative platform is so powerful, creating an ecosystemwith a public perhaps not necessary. Also, according totechnologist Andy Thurai, it “becomes very expensive andtime-consuming tomaintain” both a Public and a Private/-Partner API.

8.3 Retirement Reason #2: OpposingFinancial Incentive, Competition

A Public API may be retired if the interface interfereswith primary business objectives. In exposing their datafor anyone to consume, providers run the risk of losinga market advantage, especially if this is taking businessaway from native distribution channels.

ESPN

In the case of ESPN, their reasoning to retire their sportsdata platform was “to better align engineering resourceswith the growing demand to develop core ESPN prod-ucts on our API platform.” Today, if you visit the ESPNDeveloper Center, you’ll notice that all APIs are open for“strategic partners” like IFTT, Pulse, and foursquare.

Discussion on Hacker News suggested that it was be-cause developers were monetizing their apps. Andy Thu-rai agrees, positing that “the actual reason seems to bethat they want better control over their unique and li-censed content, and better monetization, which publicAPIs may not offer.” We learn that by exposing internal

Page 91: The API Lifecycle

A History of Major Public API Retirements 76

assets, a business may risk losing an advantage if doingso decreases traffic from native distribution channels.

Strava

Strava offers fitness software for wearables with a devel-oper API to extend their applications. Starting with StravaAPI v3, they began to curate their developer consumerswith a limited access program. These new requirementsprohibit “applications that encourage competition” aswellas ones that “[Replicate] Strava functionality.” A largeAPI retirement can occur when developer consumers areincorporating monetization techniques into third-partyapps that break the original terms of agreement.

8.4 Retirement Reason #3: Changes inTechnology & Consolidating InternalServices

The tech sphere is constantly evolving. As such, advance-ments in these technologies have the potential to makean API obsolete. This happens often during internal re-designs, acquisitions, or external industry advancements.API retirement could arise from evolving protocol trends,such as replacing SOAP with REST, or changes in end userexperiences, such as Netflix shiting it’s primary businessmodel from DVD distribution to video streaming.

Skype

Skype’s reason to decommission their Desktop API was,according to them, that it didn’t support new mobile de-velopment trends. The Skype Public API, first introduced

Page 92: The API Lifecycle

A History of Major Public API Retirements 77

in 2004, was taken over by Microsoft in the 2011 aquisi-tion. The Microsoft-owned Skype Desktop API was shutdown in order to embrace Skype URIs and the Microsoftclient. The termination irritated some developers as iterased income for third-party applications consuming theAPI as well as lessened functionality through the SkypeURIs.

Google Maps Data API

At the same rate Google releases new APIs, it also dep-recates older versions. In 2010 Google announced theywould discontinue the Google Maps Data API, a servicemade to store geospatial data. The main reason was thata superior feature was launched with v3 of the GoogleMaps API, offering an improved method of query andstorage that made the Google Maps Data API obsolete.

Other Google APIs scheduled for deprecation due to out-dated technology:

• Google Webmaster Tools• Google SOAP Search API

Fedex

At the time of this writing, Fedex is in the process ofupdating its APIs to Fedex Web Services, replacing XML-based tracking applications with a large redesign.

8.5 Retirement Reason #4: Versioning

Versioning is by far most common reason to retire anAPI. Since APIs are a relatively new technology for most

Page 93: The API Lifecycle

A History of Major Public API Retirements 78

businesses, you’ll often see v1, v2, or v3, still in use today.Similar to OS upgrades on devices, it’s often easier toscrape and replace an entire version when instigatinglarge change. Versioning can arise when major edits tothe API parameters or new usage controls are required.

Some alarming changes that dramatically affect develop-ers and end users may be quietly hidden within new APIversion documentation. Functionalities may be erased,permissions limited, classes altered, etc. As versioning isa common component to many API’s lifecycles, we don’tintend to create an exhaustive list of them all. Rather,these two examples of version updates came with thema few surprises for developers and end users…

YouTube

YouTube, in the process ofmigrating to the YouTube DataAPI v3, surprised users when it was found that Data v3would no longer support the YouTube app on expensiveSmart TVs.

Twitter v1

Twitter’s v1 was finally retired in 2013. Being the 3rdmostpopular API in use today, the announcement sparkedworry throughout the developer community that sim-plistic integration was a thing of the past. The updateadded OAuth, requiring client keys and the creation ofan app with Twitter. According to MathewMombra, thesechanges were likely instigated to:

• enforce call rate limiting with less liberal access• reduce their system load• decrease API vulnerability• promote their embeddable tweet program

Page 94: The API Lifecycle

A History of Major Public API Retirements 79

8.6 Retirement Reason #5: SecurityConcern

A consideration ofmany large-scale retirements, API providersmay choose to discontinue a public API specifically be-cause of the security concerns associated with makinginternal data and processes public.

Google Earth API

The API was shutdown because it relied on NPAPI Frame-work, an outdated technology Google mentioned hadbecome a security concern.

SnapChat

Though SnapChat never technically has released a publicAPI, the popular app has spawned a variety of mashupson various platforms that all tap into their “private” API.This went unchecked, until early 2015 when SnapChatpartneredwith theWindows store to crack down on theserogue applications.

Page 95: The API Lifecycle

9. Preparing For aDeprecation

Entire software ecosystems can quickly emerge that de-pend upon APIs to survive. And just as quickly, they canbe destroyed. As these third-party developers have de-pended on your service to support their own products,complete shutdowns can inherently cause very negativereactions. This is why any change to your API requiresthe proper preparation and communication, whether itbe small edits, versioning, or complete deprecation.

80

Page 96: The API Lifecycle

Preparing For a Deprecation 81

9.1 Rippling Effects

Though most clients are quick to adapt, some may beunaware of API changes. This means they won’t respondquickly to update their system to be compatible withnew versions. Stagnancy, freezed dependencies, forgot-ten forks, and inactive projects can be common with APIsthat have been active for a while.

Mircea F. Lungu, a computer science researcher at Bern inSwitzerland, found that when deprecating APImethods orclasses, the total adaptation time within an ecosystemcan vary tremendously. The amount of time between thefirst reaction and the last reaction can bemonths, or evenyears.

In his study on the case of the SmallTalk ecosystem of2,000 consumers, Lungu found that 14% of deprecatedmethods inducednegative rippling effectswithin the ecosys-tem, and 7% of deprecated classes triggered ripple ef-fects. Only 16% of deprecations had a systematic replace-ment, which meant that most edits were done manually.Thus, any changes to an API induces ripples that can havefar-reaching results.

9.2 Preparing For Developer Reaction

In order to keep good face with your community, we rec-ommended transparency using the following techniquesto prepare for an API’s retirement.

• Schedule a retirement plan: Offer at least a 6month time frame for complete deprecation. Thiswill hopefully give teams sufficient time to seek newintegrations or partnerships. Consider extending this

Page 97: The API Lifecycle

Preparing For a Deprecation 82

time frame if certain teams are struggling. GoogleMaps and Youtube follow a one year announcementto deprecation policy.

• Make changes in stages: Tier your retirement planin a way that aligns with past promises for supportand versioning. If still running, shut down older ver-sions that receive limited use earlier in the process.Twitter has created handy retirement timelines inthe past that display when each version will be re-tired.

• Public announcements:Write and promote a blogpost that explicitly outlines API changes, when theywill go into effect, whowill be effected, and any othervital information your community needs to know.Disseminate this information to your dedicated de-veloper social accounts.

• Ease the transition: If your API is being consoli-dated, versioned, or merged into a separate service,ease the process with a migration guide and FAQ.For example, when Google Maps Data transferredover to Google Maps, they created a Maps Data Lib-eration Tool to offer a complete download of data ortransfer to their new console. Awkward transitionscan especially be a headache during acquisitions.

• Use blackout testing: Blackout testing is a plannedshutdown of all API functions for a short window oftime. This is helpful for developers to see how theabsence of the API is going to affect their systems,and also acts as a call to action for developers toupdate their code. The Youtube API, Twitter API,Mendely API, and many others have used blackouttesting in the past.

• Don’t violate your own terms of service: Reviewyour Terms of Service to ensure that you have no

Page 98: The API Lifecycle

Preparing For a Deprecation 83

binding contracts for continuing support before youpull the plug. A smart way to plan ahead is to writea deprecation policy whenever a new API version iscreated.

Page 99: The API Lifecycle

Preparing For a Deprecation 84

Next Steps:We’ve highlighted the major concerns thatwould usher a large-scale API deprecation,but many retirements occur for a combina-tion of many these reasons. Other reasonsto consider large-scale API depreciation orredesign may include:

• Overwhelming competition with otherAPIs in niche sector

• Inability to structure data to be re-ceived effectively

• Not generating a revenue to supportoperations with current offering

• and many others

Scheduling the retirement of an API versionmay be a great advance toward restructur-ing how your data will be received by yourconsumers. In this case, revisit the AnalysisStage to consider your primary business ob-jectives.

1. Analysis Stage2. Development Stage3. Operations Stage4. Retirement Stage

Page 100: The API Lifecycle

V The Agile Mindset

Each phase of the API Lifecycle should not be consideredstatic. Progression is often non-linear, meaning informa-tion garnered in a phase should simultaneously affectother ends. Iterative communication between stages iscritical for influencing smart progression and arriving ata sustainable internal ecosystem.

For example, if you receive multiple feedback complaintsfrom customers not satisfied with a certain operation,alterations should be induced that only effect Develop-

Page 101: The API Lifecycle

86

ment, but inform Analysis, and perhaps even Retire-ment.

Now that your API hastravelled through all stagesof it’s life, it may be en-tirely changed, or mighthave kept most of it’soriginal form. Now thatwe have a good grasp oneach stage, in this partwe consider what adopt-ing an ‘agile’ mindset means for developing andmaintain-ing an API, and offer helpful resources to expedite theprocess.

Page 102: The API Lifecycle

10. What Makes an AgileAPI?

Agile. API. API. Agile. It has a nice ring to it, but is it neces-sarily so? Having become a buzzword, ‘agile’ often comesloaded with misconceptions. At a Nordic APIs conference,Christian Nilsson of Beepsend SMS messaging solutionsexplores the concept of what it means to be truly agile in

87

Page 103: The API Lifecycle

What Makes an Agile API? 88

the context of APIs, offering 6 tips to help an API providerdetermine what ‘agile’ really means for them.

10.1 What is Agile?

Agile can be defined as an approach to problems, a soft-ware development process, and a business process. Likeit’s name literally suggests, agile is lean, nimble, and filledwith passion, with the ability to react to change rapidly.

To Nilsson, agile has three common themes:

1. Agile is breaking things down—but not to the pointthat they break.

2. Agile means you can quickly shift business strategy.3. Agile cannot be burdened by previous decisions.

Agile API Misconception #1: If You’re Not Agile,You’re Not Successful.

In general, the closer a service is to the end consumer, themore agile it needs to be in responding to problems. AsNilsson says, “Internet users are fickle and promiscuous.They’re curious. They’ll leave your service in a heartbeat.”

However, some businesses are naturally inflexible. Whenthese businesses increase their distance from the endconsumer, they become less agile and more stable. Thisgives the business a stronger reputation for reliability,which is a highlymarketable trait to less flexible industrieslike banking.

Services should ask themselves: Why do we need thisAPI? What does ‘agile’ mean to us and our businessmodel? Is it right for us? Is it right for our customers? In

Page 104: The API Lifecycle

What Makes an Agile API? 89

the end, according to Nilsson, “you’re not automaticallysuccessful just because you’re agile, you’re successfulbecause you’re passionate about your core model.”

Agile API Misconception #2: There is Only OnePerfect Software Development Process.

So often, project management tools are thrown at soft-ware developers in order to make them work faster ina more transparent environment. But software develop-ment processes vary by needs, and corresponding toolsshould support – not enforce – your software develop-ment process.

Project managers for APIs should start by assessing thesize and makeup of their development team, along withcritically analyzing the problem the team is trying to solvetogether. Considering these factors, the right strategiesfor development will naturally arise, often straight fromgroup discussion on the topic.

Agile API Misconception #3: Your System IsSecure.

Security doesn’t start and end with outsmarting hackers.Nowadays, no matter how secure your system is, you areconstantly battling against an infinite number of scripts,human errors and stealthy passwords. In this constantlyunstable and insecure world, one shouldn’t relax andassume that all will remain stable.

Bugs such as Heartbleed roam the web, and system de-pendencies can be altered at any time— such as re-cent MySQL changes enforced by AWS. A way to over-come these obstacles is through centralized configura-tions, which make sure that keeping your systems up to

Page 105: The API Lifecycle

What Makes an Agile API? 90

date is not labor intensive. You must be vigilant for anyholes in the technology and to make sure that all devel-opers are taking active steps to avoid cross-site scripting(XSS flaws).

For an in-depth study on implementing API security check out:API Security: Deep Dive into OAuth and OpenID Connect

Agile API Misconception #4: Your Extensive SLAand EULA Will Save You.

Paypal includes 97 pages in their SLA. The reality of aService Level Agreement (SLA) or End-User License Agree-ment (EULA) is that it is a best-case scenario. Some userswill inevitably use a service improperly. How often willyour team or the customer have the money and patienceto bring a side to court on a trivial matter? You may likethat your SLA or a EULA creates a sense of fear, butNilsson argues that API providers should bemore invitingto consumers instead of scaring them away with lengthyuser agreements.

Agile API Misconception #5: Your API is ‘Special.’Keep That Secret Sauce a Secret.

According to Nilsson, there are no secrets in coding any-more. The “secret sauce” of a business truly lies withinexecution. The secret sauce is how a you can adapt andtransform to fluctuating markets. It’s how you practiceagility. And it’s also how you provide fantastic customerservice.

“If your secret is that no one has figured outwhat technology youuse, you’re screwed, you’redoomed, you’re beyond saving. Your secret

Page 106: The API Lifecycle

What Makes an Agile API? 91

must be your staff, your DNA, your businessmodel, your ability to change…”

Technology is just one more conduit with which you cansupport your employees and help them strive for great-ness. Plus, if you keep your tech a secret, when thingsgo wrong, who will you be able to lean on? Communitiesestablished around open code and collaboration can helpAPIs dramatically increase in value; that’s what smartcities all over the world are realizing by opening up theirdata silos and API source code.

Agile API Misconception #6: NoSQL is the FutureThat Will Power All APIs.

Nilsson argues that the NoSQL database for storing andretrieving data just isn’t all it’s hyped up to be. He con-cedes that NoSQL has the ability to solve many problems,but argues that it cannot solve not all of them. Like withall things in the programming and development world,solutions need to be agile. Problems need to be criticallyassessed and paired with the best solutions. Often timesthis means pairing NoSQL in combination with other so-lutions like a relational database.

10.2 Conclusion

API providers must incorporate creative combined solu-tions for development that are tailored to their uniqueposition. When building an agile API, you must keep allthese facets in mind without falling victim to miscon-ceptions of what it means to be agile. Following theseconsiderations, and the four stages outlined in previouschapters, you should be prepared to react properly to

Page 107: The API Lifecycle

What Makes an Agile API? 92

your team’s needs, your business’s needs, and the endconsumer’s needs.

Page 108: The API Lifecycle

11. Case Study: PlanMill API

It’s true that APIs are accelerating normal B2B communi-cations and ERP technologies, but masking a 10+ year oldsystem with a clean interface is no easy task.

Tuning into design lessons learned throughout research,development, and implementation stages, in this postwe study a case that epitomizes the mullet in the backphilosophy. Read on to learn what processes created afully functional and partnership critical API as we studythe history of the PlanMill API. From simultaneous UIdevelopment, Eating your own dog food, to reasoningbehind specific architecture decisions, Senior Consultant&ManagerMarjukka Niinioja describes to Nordic APIs the

93

Page 109: The API Lifecycle

Case Study: PlanMill API 94

nitty gritty details of developing an enterprise level APIfrom scratch.

11.1 What is an ERP?

PlanMill is an Enterprise Resource Planning (ERP) andCustomer RelationshipManagement (CRM) application— a real time front and back end project managementplatform for professional services. The PlanMill API ex-poses the Planmill ERP platform, allowing for the com-mercial exchange between various business applicationsto expedite processes like accounting and CMS. Maybedue to it’s sheer weight and business-oriented subjectmatter, ERPs are often seen as pretty boring. Accordingto Niinioja:

APIs, on the other hand, are the wave of the future— theyare fast and nimble. So how can you combine the boringand the agile?

11.2 The Slow Initial Release

The PlanMill API went through a painful birthing process— a 12 month period of stress and test. Pretty earlyto the game, the PlanMill API 1.0 was born in 2009. Avery quiet launch worked well, as it gave the team timeto create usable developer documentation, envision apricingmodel, speak with consultants, garner a potentialcustomer user base.

Eventually, some of the first real use cases occurred inter-nally, with larger projects and time reporting integrations.This was followed by a first big API use case within a largerapplication, including massive improvements to the API.

Page 110: The API Lifecycle

Case Study: PlanMill API 95

The first partnership was eventuallymade possible (Atlas-sian Confluence with Ambientia) using the PlanMill API.According to Niinioja, the presence of an API became animmediate selling point compared to competitors in theERP space.

11.3 API Usability Problems

So, what did the PlanMill team learn along the path toversion 1.0? Developer experience is a critical compo-nent to your API strategy, and designing documentationand API functionality in a way that mimics the user’sdesires is pertinent to success in the API space. Thoughcertain standards and API design guides do exist, actualimplementation is almost always unique. What PlanMilldid correctly was listen to their customer’s responses toimprove the overall experience to increase usability.

As the system originally intermingled much functionalitywith a backend system that was 10+ years old, the follow-ing usability concerns arose in the initial use of the API:

• Calls: “Why should this take 5 requests, can’t I con-solidate into a single call?”

• Rate limits: Some users would send in 10 requestsper ms, crashing the system.

• Backend exposure: There was too much initial re-liance on old JavaScript. Lesson learned is that notall ideas are compatible from front and back endperspectives.

• Documentation: Not every granular function wasinitially documented.

• Error Messages: The users were receiving stacktraces as error messages in the API responses.

Page 111: The API Lifecycle

Case Study: PlanMill API 96

• Response ID: The ID wasn’t in the response of what-ever had just been created with the API.

11.4 Improved Process for API 2.0

For the API v 2.0, a new, improved process for devel-opment was necessary. Gearing up for a new productlifecycle, the PlanMill team performed impressive cus-tomer research to dial into what their customers desired.The PlanMill team stressed iterative changes bolsteredby continuous stages of modeling the product both in-ternally and externally to receive feedback from thedeveloper community by demoing and attending APIrelated events.

1. Research Project: The team created a thesis-drivenformal research project to investigate the needs oftheir customers, asking partners to share their ownexperiences using the API and thoughts on howto improve the API. They found, in general, thatcustomers were eager to share if it meant helpingto improve the system.

2. Pilot technologies and first service: Using the re-search, the team brainstormed what could they dodifferently if they could start from scratch. Theyredesigned their technology stack, and masked oldthings that weren’t a well designed to offer a cleaninterface to their clients. Sleek front, mullet in back.

3. Demos:What followedwas internal discussion, knowl-edge sharing, attending seminars, and demoing theAPI.

4. Further Research: The team read Nordic APIs, re-searched the community, tried new approaches, de-cided on architecture and technologies, attended

Page 112: The API Lifecycle

Case Study: PlanMill API 97

additional seminars, and researched monetizationstrategies.

5. Internal Beta : Operational version developed forinternal testing.

6. Ate own Dogfood w/ New UI: A new user interfacewas designed simultaneously with backend devel-opment. The team found that insights from a UXperspective were critical for creating an intuitivelydesigned API.

7. Public Beta 1.5: This staged involveddeveloper com-munity testing, and opening the API for third partydevelopers to use. They held a usage seminar, reacheda version 1.5, and made incremental updates.

8. Feedback from Developer Community: Currentlythe team is at this stage.

9. Publish 2.0: Plans to publish full platform soon. Theteam aims to use their research, feedback, new UI,architecture decisions, monetization strategy, andmore to culminate in a well-informed and well-pre-pared version 2.0 release.

11.5 Specific Architecture DecisionsMade Along the Way

Let’s take a peek under the hood. In response to theirresearch phase, the PlanMill team decided to go with thefollowing architecture choices:

Authentication: HMAC and API keys

PlanMill went with HMAC as an authentication scheme asit allows Business-to-Business communication (B2B) viasystem level integration capabilities. For PlanMill services,

Page 113: The API Lifecycle

Case Study: PlanMill API 98

server-to-server file sharing is preferred for the transferof payrolls, for example. Though PlanMill acknowledgesthey still need to improve their unified identity man-agement process with additional technologies, HMAC isadequate for their current situation involving one userand one set of credentials to talk with another single userand single set of credentials.

Data Format : JSON (and more) over XML

The PlanMill team chose slick JSON, a format that’s sim-pler to understand and requires less configuration over-head than XML. Some might scoff when they hear thatin addition to returning JSON, the PlanMill API producesformats like CSV and… PDF. In their case, this return typeactuallymakes sense as certain business intelligence soft-ware receives PDF or CSV formats for their operations.

HTTP Verbs Properly Used

The PlanMill API utilizes standard HTTP verbs (GET, POST,PUT, DELETE). Though not implemented in PlanMill APIv1.5, Niinioja advocates the use of PATCH, for the rea-son being that it can elleviate headaches and bloat thatcan occur when trying to update delta records. Minutechanges in large datasets, such as a minor user infoedit, can be made heavyweight with redundant GET andPOST requests. The teamplans to embrace proper PATCHstandards with the 2.0 release.

RAML Documentation

PlanMill decided to go with RAML over Swagger, BlueprintAPI, or other specification formats for REST APIs.

Page 114: The API Lifecycle

Case Study: PlanMill API 99

PlanMill also leverages APImatic to generate SDKs in var-ious languages.

REST or SOAP?

Is REST really better than SOAP? Is SOAP better for criti-cal business transactions? There’s an argument for bothsides. For PlanMill, SOAP and WSDL have a place in theirplatform for invoice, account, and payroll. However, asNiinioja describes:

11.6 Sharing Data Carefully and Securely

It’s important to note that in the B2B environment somecritical level data or company secrets cannot escape thesystem, but still must be shared via API across partnerchannels.

Things like bank account numbers, sick leaves, payrolldata, etc, need to be shared with systems, but cannot es-cape out of those boundaries. You also have governmentand trade treaty control, such as in Finland, PlanMill’sbase, where personal data laws place strict confines onwhat can legally be shared. Also a company may have aninternal policy controlling shared data. All this can inhibitopen integration with platforms like Zapier or IFTT.

In the end, Niinioja recognizes that a business needs tosupport both opennness, for basic contact information orother such data that can share freely, and point-to-pointroutes, for sharing API data between partner systemsthrough secure connections.

Page 115: The API Lifecycle

Case Study: PlanMill API 100

11.7 Understanding the Lifecycle of anAPI

PlanMill understood the lifecycle of their API, bringingan agile mindset to enterprise API platformitization. Eachstage in this process plays an important role in advanc-ing the project as a whole. From analysis, development,operations, and throughout versioning.

Though PlanMill still has their work cut out for them,hopefully this case study can give insight into what mis-takes were made early on in the process, and how theywere rectified, with the hopes that new API practitionerscan have a successful release armed with this knowledge.We wish PlanMill a successful 2.0 release, and hope theirproduction saga can help as a model for others to havesimilar success in the API space.

11.8 Additional Resources:

• PlanMill API v1.5 Documentation• Accidental API Developer: Slideshow

[PlanMill has participated in Nordic APIs past events but didnot sponsor this post]

Page 116: The API Lifecycle

12. Third Party ToolsSo, you’re confident and ready to hit the ground running,but still could use guidance in managing your API. Well,we’ve assembled the following list of popular third-partytools built to assist API providers - from documentation,monitoring, to security solutions - that we’ve mentionedthroughout this e-book or otherwise recommend for use.This list is not meant to be exhaustive at all, but rather isa curated list of what services we are attracted to.

Documentation

Frameworks that ease the process of generating API doc-umentation.

• Apiary• API Blueprint• Swagger

SDK Generation

• APIMATIC• REST United

101

Page 117: The API Lifecycle

Third Party Tools 102

API Management

• 3Scale• Apigee• Axway• Mashery• Mulesoft• SmartBear

Performance Monitoring andTesting

Services that allow a provider to monitor the activity andstatus of their API or API dependencies.

• SmartBear• API Changelog• APIMetrics• APIScience• POSTMAN• Runscope

Security

Services and tools to assist in embedding proper identitycontrol, access management, and more with authoriza-tion, authentication, delegation, etc.

Page 118: The API Lifecycle

Third Party Tools 103

• OAuth 2.0• OpenID Connect• Ping Identity• Stormpath• Twobo Technologies

Discoverability

API directory services, hubs, marketplaces, andmore thatassist in making your API discoverable by third partydevelopers:

• APIs.io• Mashape• ProgrammableWeb

Developer Support

In addition to using social media channels and internalblog for updates, these developer-oriented channels canbe used to grow your audience:

• Certain sub-Reddits: API, Programming• GitHub• Stack Overflow

Page 119: The API Lifecycle

Nordic APIs Resources

API Lifecycle Talks

In May 2015 Nordic APIs went on a World Tour in thetheme of the API lifecycle, visiting London, Copenhagen,Munich, and Seattle. If you missed out, you can still watchsessions here:

• Introducing The API Lifecycle, Andreas Krohn• You Need An API For That Gadget, Brian Mulloy• Pass On Access: User to User Data Sharing WithOAuth, Jacob Ideskog

• APIfying an ERP, Marjukka Niinioja• Integrating API Security Into A Comprehensive Iden-tity Platform

• A Simpler Time: Balancing Simplicity and Complex-ity, Ronnie Mitra

• The Nuts and Bolts of API Security: Protecting YourData at All Times

104

Page 120: The API Lifecycle

Nordic APIs Resources 105

More eBooks by Nordic APIs:

Securing the API Stronghold: The most comprehensivefreely available deep dive into the core tenants ofmodernweb API security, identity control, and access manage-ment.

Developing The API Mindset: Distinguishes Public, Pri-vate, and Partner API business strategies with use casesfrom Nordic APIs events.

Nordic APIs Winter Collection: Our best 11 blog postspublished in the 2014 - 2015 winter season.

Nordic APIs Summer Collection: A handful of NordicAPIs content offering best practice tips with a focus onbecoming an API platform.

Page 121: The API Lifecycle

EndnotesNordic APIs is an independent blog and this publica-tion has not been authorized, sponsored, or otherwiseapproved by any company mentioned in it. All trade-marks, servicemarks, registered trademarks, and regis-tered servicemarks are the property of their respectiveowners.

• Select icons made by Freepik and are licensed by CCBY 3.0

• Select images are copyright Twobo Technologiesand used by permission.

Nordic APIs AB Box 133 447 24 Vargarda, Sweden

Facebook | Twitter | Linkedin | Google+ | YouTube

Blog | Home | Newsletter | Contact

106