The old ways of creating software don’t match the reality we live in. Users want even more convenience in use and even more value for their money. To meet these expectations, companies use API-first design pattern. It enhances the application’s features and provides companies with a modular and reusable design that’s perfect for creating entire ecosystems. The approach also reduces development costs, optimizes delivery and operations.
The mid-2016 brought us an in-depth article by Gartner. In it, the company declared that we now all live in an “API economy”. The consequence was the career launch for the expression “API first”, which turns heads even now.
Table of contents
- What is the API-first design?
- Three levels of connectivity
- The benefits of the API-first design pattern
- How can you use API to build the best customer experience?
- How to properly design a system architecture?
- The impact of API-first approach on software
- Practitioners have the final say
- It’s about a tool and the way you use it
What is the API-first design?
Application programming interface or API is a middleman. You can think of it as a bridge between two applications. On some level, they communicate with each other to exchange user data, enable inter-connected functionalities and provide greater value for a user. API passes requests and responses between applications and uses only the code necessary to complete tasks. It doesn’t expose applications; it doesn’t generate a threat to a code. API uses only a must-have portion of a code. Nonetheless, API is a potential target for attacks and needs solid security.
You can also visualize it as a relationship between a client, a kitchen, and a waiter. A client doesn’t have to run to a kitchen with everything; he or she can place the order through a waiter. The kitchen, on the other hand, has the comfort of work – nobody pokes around at its secret recipes. The client here is a user, the kitchen is back-end, and the waiter, you’ve guessed it, is a waiter.
The API-first approach focuses on the API as the first and most important user of an application. Sounds weird, but it works in practice.
To be fully effective, an application must be conveniently structured. This helps API get to the data, process it, and use as indented. If we think about the previously mentioned analogy, imagine an owner who designs a restaurant to be easily navigated by a waiter. You don’t put tables in 10 cm proximity of each other, with three floors in the entire restaurant. That would be a crowded and extremely inefficient place.
The API-first design means that the software development team builds it ahead of the rest of an application. For example, the team designs API using GraphQL and Schema Definition Language (SDL). This definition becomes a single source of truth. Based on that, engineers generate fragments of application. They can also use OpenAPI/Swagger for the creation of the REST API.
When the API is ready, engineers can focus on the product itself, and connections between it and current, as well as future products. This requires thought-out API development.
With that mindset and established process, it’s much easier to not only create but also enhance the digital product. It’s also a lot easier to maintain it. Especially when it comes to cloud- and microservices-based applications. In a world where every functionality is a different microservice, all has to be glued together to assure performance, stability, security, and communication. Application programming interface delivers in spades.
Three levels of connectivity
The APIs used in the API-first design, fall into three categories:
- experience APIs
- process APIs
- system APIs
The first kind is used for the purpose of simply building application. The second one is used for orchestration, composable APIs, and microservices. The last one is utilized in cases of modernizing legacy applications, connectivity to software-as-a-service (SaaS) apps, web services, and RESTful APIs.
Experience APIs let you transform data and services to be consumed by an audience from one data source. Process APIs consume and coordinate (orchestrate) data exposed by Experience APIs. They represent common business processes interacting and shaping (changing, enriching) the data. System APIs work with and expose the data across various sources, such as customer relationship management (CRM) systems or legacy databases. This is highly beneficial, especially for geographically dispersed teams. They can access the same data pools without the need to write a duplicate code.
The benefits of the API-first design pattern
Some of them we have already mentioned. The nature of a digital product has changed. With a massive migration to a cloud and microservices running things, companies want software that’s easily scalable. They also want to quickly test products and assure customers’ feedback. That’s why many companies and software vendors create a minimum viable product (MVP). This is a proof of concept. Quickly released on a market shows potential. Minimum satisfactory features make users adopt the solution and send feedback, while the team prepares fully-baked product and API integrations.
That is, however, the tip of the iceberg. Aside from an accelerated development process, benefits of API-first design include:
- freedom from legacy code-generated issues
- quick validation of business assumptions
- reduced risk of failure
- optimized development costs
- faster time-to-market
- better control of a product roadmap
- access to the same data by dispersed teams
- improved developer experience
- parallel development processes
- agility unavailable in monolithic infrastructure
- ability to test various user experience (UX) options without jeopardizing the rest of the product
- opportunities to add different brand touchpoints (more on that later)
- quicker product monetization
- easier management of performance goals
- an option to quickly intervene and adapt the product to changing market conditions and demands
- ability to create more adaptable and innovative products
Your business goals and customer convenience are one thing. Although very important, they still don’t build the whole picture. We have them, but we also have developer’s experience. Because API design can be complicated (and you also have to think about backwards compatibility), there’s a need for a structured and valuable process. Starting with the design isn’t that hard. The difficulty increases with the type and size of the application.
That’s why developers should start with clean and immaculate documentation. This will help understand what they did, how, and why. The rest is basically an opportunity to work on the same API throughout different teams, working for various companies. Especially with available software development kits (SDKs) that make the process of integration even faster.
To make it possible, API should be consistent. Developers need to decrease the energy needed to understand and implement given tasks and functions. It should also be interactive, to provide live testing. That’s how developers interact directly with the system. It decreases both development and time-to-launch.
For the easier testing and learning of a given API, engineers can also use Postman.
How can you use API to build the best customer experience?
API is not a tool for its own sake. It has to benefit you and the customer alike. Except in the opposite order. Since the customer is the one that puts bread on the table, the product should serve his needs and fix real-life challenges. You can do that by implementing a set of solutions that redefines your product and makes it more flexible.
Here’s what you can do to increase market chances for your application:
1. Identify sources of user friction and go from there. Without knowing how users think, how they feel about the product, and what they really expect, every other tip will be significantly less effective.
There are three basic types of friction: emotional, interaction-wise, and cognitive. Let’s go through them with some examples.
If the design of the app is clean and there are no unnecessary distractions, connectivity prompts, etc. then the user’s response will be likely positive. Avoid the state when people become overwhelmed with what’s happening on the screen. That’s the emotional front.
An application that’s scalable to different smartphone sizes has easily changeable on-screen keyboards, and the ability to connect with the support at the touch of a button is a good one. These are examples of minimizing interaction friction.
Cognitive friction is pretty simple – minimize the steps people need to go through before they achieve the wanted result. If discovering a new product’s feature requires multiple taps in the menu, something went wrong.
2. Turn traditional front-end into Front-end as a Service (FaaS). When we think about the front-end, we often visualize a portion of the code that a user can see and use. That’s it. Graphics, buttons, texts, microcopy, etc. This is the old thinking. If something goes wrong or, more likely, the market expectations changes, you need to respond fast. That’s where agility comes in.
The FaaS model takes a monolithic front-end and makes it into a LEGO product, full of well-fitted blocks. You no longer have to rewrite the code to adjust it for users’ liking and in-app activities. You just have to change or replace an unsatisfactory block. With the FaaS approach, you can quickly get on the current UX trends and push out updates. Finally, you will be able to fast-track and implement user feedback, which is invaluable in the user-centric market.
3. Enable options for tailored communications. Every marketer knows that hyper-personalization impacts the ways in which companies deliver marketing messaging. The same goes for customers. People have different needs so they want not only tailored messages but also different ways to talk to companies.
With the API-first approach, you can enable various types and models. From the web- and mobile-based push notifications, to in-app messaging and external chatbot integrations.
4. Monitor customers’ behavior to deliver acceptable monetization models. The API economy is a part of an app economy. People like their smartphones and their entire worlds hidden in pockets. Apps can be used for everything and a large percentage offer an in-app purchase mechanism. The problem with that? Not every user is a whale (someone spending thousands of dollars on a product).
With API-driven monitoring, you can integrate solutions that allow you to track people’s activity. You can learn what makes them tick, what they spend their money on, what articles need a new form of promotion or a sale. It’s especially important for companies that use customer loyalty programs. Armed with the knowledge about behavior and perception of product-driven services, you can quickly adjust the offer to fit the needs and financial capabilities of the audience.
For example, you can do CRM profiling. Also, implement spending-based customer loyalty tiers for better rewards, use digital wallets, and a lot more. All you have to do is plan your product’s system architecture.
How to properly design a system architecture?
The short answer – in a way that allows maximum business agility. The longer answer:
- Start with a technology stack that enables advanced technologies used for your business requirements. A part of that stack can easily be a cloud. You can think about Amazon Web Services as an option. At Code&Pepper we use AWS AppSync and Amazon API Gateway.
- Implement a cloud-native, event-driven or serverless infrastructure. This will allow you to quickly deploy, test, and launch the product.
- Separate back-end logic from front-logic services and user interface (UI). That way your product can be easily enhanced and tested.
- Separate API design from its implementation. With that, a software architect has to think only about business logic and data model. He’s not limited by an already existing user interface or any kind of legacy frameworks that hold back the product.
- Implement a high degree of deployment automation solutions. Alongside automated testing, continuous delivery (CD), and continuous integration (CI), it can help with that.
The impact of API-first approach on software
By going with the API-first approach, you can secure two big areas for your product: consistent customer experiences and the ability to use data-driven offers. There is a lot of measurement and Big Data floating around, but you need more than buzzwords to connect with the audience. The way to do that is to go where they already are and offer them products they actually want.
It’s a huge part of social commerce, where people see a personalized advertisement. With social platforms like Facebook, Instagram, or TikTok, you’re losing an element of brand continuity. Customers don’t land on your company’s website to make the purchase. With a monolithic architecture, you’re losing an important brand touchpoint. Under normal circumstances, it extends a natural process of learning and connecting with the brand.
That’s why proper connectivity and integration are everything. You need a proper integration between different kinds of software. If this goes sideways, you get a spaghetti architecture that creates issues. Like improper data mining, which is crucial for any product. Especially e-commerce, for example, which heavily relies on user data.
What you need is a well-oiled machine that is full of cooperating and sometimes inter-penetrating mechanisms. Things like customer data and app security, pricing, inventory management, checkout and discount logic, cart calculation, order and return processes, customer help, and assistance. All have to be guaranteed. That means their uptime should be high. They should be reliable, accessible, and usable by anyone, anytime.
By starting with API design, you can make sure that everything looks and works as intended. It’s especially important for FinTech APIs, where the level of product complexity and third-party integration can be pretty high.
How can you plan your API-first approach?
Here are few things you can do to create and improve your plan:
- Identify key services your business offers and capabilities of the business
- Establish API stakeholders. Who are they in your organization? Allow stakeholders to weigh in on the design of the API.
- Design an API contract. The contract establishes a set of standards and best practices for designing APIs
- Implement API governance. An API governance process can help enforce established standards and reinforce desired outcomes.
- Automate processes. Tools like SwaggerHub to automate processes like generating API documentation, style validation, API mocking, and versioning.
These tips will help you establish a pipeline for effective processes in your organization.
Practitioners have the final say
Multiple companies already adopted the API-first approach. They had, and still have for that matter, a large pool of options to choose from. For example, they can use a gateway API, access and identity API, open banking API, and customer loyalty API solutions. The sky’s the limit.
Let’s go through some examples to underline what this article has been about all along – efficiency.
1. Prudential boosted customer engagement with the PRUrewards program. When you think about insurance, you immediately exclude the term “first-need product”. On average, customers buy insurance for a home, life, or car every three to six years. It’s hard to build trust and turn an occasional customer into a returning one when developed markets report one customer contact within 12 months. That’s a challenge.
2. Air France-KLM tamed the steps of customers’ travel journey. With many factors and variables of customers’ journey, the travel industry struggles to be fully customer-centric. Not all can be seen or even predicted.
With the API-first approach, Air France and KLM were able to gather all travel-related information within one app. That’s how customer journey became more legible, transparent, and accurate. With the app, the companies can now offer flight-change recommendations, seat upgrades, hotels, and transportation services to provide not only reliable but also personalized experiences.
3. With API-enabled marketing automation, Trulia never misses a lead. Trulia is a subsidiary of a massively-known Zillow. With its real estate listings and rental properties information, Trulia helps customers decide on a property.
When a prospect includes a phone number in a lead-enabled form, a click-to-call app immediately connects a real estate agent to a prospect. They can talk on the phone about the proposition.
A prospect can be uncomfortable leaving the number or he forgets to do that. The number can also be busy. In these cases, Trulia sends an agent a text message with information about the prospect. The call tracking solution generates numbers for people to call. This solution automatically reroutes conversations to the agent’s mainline and measures the time, date, and length of each conversation. That boosts efficiency and improves time management.
4. The ALDO Group improved customer retention and omnichannel presence. The ALDO Group, a well-known and global shoe retailer, wanted to create a unique shopping experience. The company was also looking to develop a long-term relationship with customers. They made it through the launch of the ALDO Crew, which is a data-driven, omnichannel loyalty program.
5. Costa Coffee reaches customers with tracked and highly optimized, promotional campaigns. Costa Coffee is the second-largest coffee chain in the world. With over 3800 stores across 32 international markets, the company could have used reach and quality in marketing campaigns. Not everything was perfect. With several legacy systems and SaaS applications, Costa was left in the cold with inefficient and fragmented data.
It’s about a tool and the way you use it
Today’s market is, among other things, about the data. Anyone can gather customer information but it’s useless if you can’t make a sense of it. That’s why data fragmentation and mitigating the risk of data management, security, and other forms of working with customer-related issues is so important.
The API-first approach can be implemented virtually anywhere and by anyone. The industry and device type doesn’t matter so much as the overall idea and the right tool. Choose the proven solution of end-to-end product development, and go ahead with your business goals.
If you need extra information, try this article on API developer experience. It will provide you additional, technical information on the subject.