What are APIs and How Do They Work?

What are APIs and How Do They Work
What are APIs and How Do They Work

An important question to answer early in your software engineering career is “What are APIs?” The IBM Institute for Business Value traced API growth from 20,000 in 2016 to one million in 2020 (source). Answering “What are APIs?” helps you understand why companies jumped on board with this critical tool. 

Application programming interfaces (APIs) facilitate communications between applications. We interact with APIs daily that manage our finances, map our destinations, and connect via social media. Responding to “What are APIs?” quickly reveals how commonplace they are in modern life. 

In your career, you may develop APIs for internal use by a startup or externally for millions of consumers. Baylor University’s Online Masters in Computer Science trains students in the advanced skills necessary to advance API use. The Software Engineering track is ideal if you want to write the next chapter in API history. 

What Are APIs: Basics and Background

The simple answer to “What are APIs?” is that they are intermediaries between applications. The apps on your phone or computer are not developed with the same architecture or language. APIs accept and convert requests into usable outputs.

A real-world answer to “How do APIs work?” happens with every online airfare purchase. When you purchase plane tickets online, the following steps are necessary (source): 

  1. User searches for specific dates, destinations, airlines, and add-on features
  2. Airline API communicates with the airline or third-party search tool to retrieve up-to-date information from the airline’s database
  3. The search tool returns current data transmitted by the airline’s API

Throughout this request, the API focuses on four essential commands. HTTP-based APIs deploy the following commands in their requests (source): 

  • Get: Retrieving existing information 
  • Post: Creating new information
  • Patch: Editing existing information
  • Delete: Eliminating existing information

Billions of similar API transactions are completed each day. API developers and owners use transactions per second to measure performance. Evaluating the question, “How do APIs work?” requires a balance of user experience, performance, and long-term needs. 

Evolution of APIs Explained

Any answer to “What are APIs?” is incomplete without discussing why APIs were created and how they became commonplace. In the early decades of computing, applications and servers were closed systems that struggled to interact with each other. Public access to the World Wide Web placed a premium on quick responses to system queries. 

The Common Object Request Broker Architecture (CORBA) standard released in 1991 allowed system communications across multiple languages (source). Computer scientist Roy Fielding brought us closer to API architecture with his 2000 doctoral dissertation. 

Fielding’s Representational State Transfer (REST) architecture allows APIs to facilitate stateless transactions. Architectural Styles and the Design of Network-based Software Architectures explains an important benefit of REST (source): 

“REST does not restrict communication to a particular protocol, but it does constrain the interface between components, and hence the scope of interaction and implementation assumptions that might otherwise be made between components...The generic interface makes it possible to access a multitude of services through a single proxy. If an application needs the additional capabilities of another architecture, it can implement and invoke those capabilities as a separate system running in parallel, similar to how the Web architecture interfaces with "telnet" and "mailto" resources.”

Fielding’s REST works with a broad range of programming languages and designs by establishing specific interaction types. He noted the following benefits of REST to improved communications between systems (source): 

  • Improve scalability to facilitate simultaneous app interactions
  • Generalize interfaces to accommodate multiple system generations
  • Improve user experience by reducing latency

What Are APIs: Types

The rush to API architecture began with major players in the tech world. Notable API rollouts included (source): 

  • eBay’s API license for partners released on November 20, 2000
  • Amazon Web Services API published on July 16, 2002
  • Flickr’s REST-based API unveiled in February 2004
  • Facebook and Twitter APIs released in 2006
  • Launch of API-enabled Foursquare in March 2009

RESTful APIs based in HTTP are not the only API protocols on the market today. The main competitors to REST are JSON-RPC, XML-RPC, and SOAP. 

The Remote Procedural Call (RPC) protocols use JSON and XML languages to request server responses. REST APIs interact with applications via document transfers, while RPC APIs interact via programming queries. Google notes that learning REST is similar to learning databases and learning RPC is comparable to understanding programming languages (source). 

Simple Object Access Protocol (SOAP) differs from REST in its functionality outside of HTTP environments. SOAP APIs provide effective communications in distributed systems thanks to standardized language. REST is often preferred over SOAP due to its speed, efficiency, and small bandwidth (source).

Access to APIs Explained

API protocols are only one of several distinguishing factors when answering “What are APIs?” The level of access to a particular API is important when creating and using APIs (source). 

Developers, designers, and amateurs alike can access all features of open APIs. An open API does not use a password or access code to restrict features. Open APIs encourage experimentation and transparency in the developer community. 

Companies of all sizes deploy internal and partner APIs to protect intellectual property along with proprietary knowledge. Internal APIs allow employees to share data and collaborate over company systems. Partner APIs grant permission to third parties for select features using passwords or other access restrictions. 

RapidAPI’s 2019-2020 survey of API developers found a focus on internal APIs by most companies. The survey found (source):

  • 74.3% of respondents worked for companies that used more internal than external APIs
  • Companies with 5,000 to 10,000 employees used an average of 307 internal APIs
  • 66.% of participants expected year-to-year growth in overall API use

What Are APIs: Present Use

As we answer, “What are APIs?”, it’s useful to evaluate how APIs are used today. We can draw on data from SmartBear’s 2019 State of API Report to show how APIs are used. The software company surveyed 3,372 developers on their views of API consumption (source). 

What Are APIs: Early Days for API Development

SmartBear conducted a similar survey in 2016 and asked how long participating organizations developed APIs. Fifty-nine percent of respondents began API development within the past five years. We can compare development ranges to confirm this trend (source): 

  • 8% began developing APIs in the past year (4% in 2016)
  • 20% began developing APIs in the past 1-2 years (14% in 2016)
  • 31% began developing APIs in the past 3-5 years (27% in 2016)
  • 18% began developing APIs in the past 6-10 years (31% in 2016)
  • 19% began developing APIs 10 or more years ago (19% in 2016)

The rising wave of API development presents an opportunity for skilled software engineers. You can use your programming and development knowledge to revolutionize API design. 

What Are APIs: Reasons for API Adoption

API development is driven by an increasing emphasis on interdepartmental collaboration. SmartBear found 60% of respondents identified easy interactions between systems and teams as drivers for API use. The remaining top responses respond to the question, “What are APIs used for?” (source): 

  • Reducing development time (54%)
  • Expanding product or service functionality (50%)
  • Partnering with outside organizations (48%)
  • Reducing the costs of development (48%) 

As these questions are addressed, API developers can look further down the list to see future needs. Your work may lead you to develop APIs for lead generation, social media engagement, and mobile app support. 

What Does an API Do: Characteristics of Successful APIs

As an API developer, knowing what makes an API successful is essential to exceeding expectations. The State of API Report reveals the most important features as (source): 

  • Simplicity of use
  • Responsiveness and efficiency
  • Top-notch documentation
  • Reliability
  • Availability

Overlaying these features on the aforementioned reasons for adoption is enlightening. APIs need to be simple and reliable to save time, money, and resources for companies and clients. 

What Are APIs: Tools in Use

We can separate tools into API formats and API management categories. Seventy-nine percent of respondents used REST API architecture with OpenAPI Specification (OAS) for development. Respondents also used the following formats (source):

  • SOAP (54%)
  • Non-OAS REST (39%)
  • XML RPC (15%) 

SmartBear’s survey concluded that 34% of companies did not use API management tools. In time, API development will be aided by new products from established tech companies. Respondents reported using the following management tools (source):

  • Amazon Web Services API Gateway (28%)
  • Microsoft Azure (23%)
  • Google Apigee (12%)
  • Oracle (10%)

Your experiences with APIs will likely mean using multiple protocols and management tools. Possessing a broad knowledge base makes it easy to answer, “What are APIs used for?”

What Are APIs: Challenges

Exploring the question, “What are APIs?” goes beyond benefits to the challenges of the present and future. APIs — like any digital asset — are not perfect and require ongoing evaluation. We can look at the most pressing challenges to API development to find opportunities for growth. 

How Do APIs Work: Maintenance Frequency

Statista surveyed developers and software engineers around the world to evaluate API maintenance requirements in 2019. Forty-nine percent of respondents were fortunate enough to leave APIs alone with minimal maintenance. The remaining 51 percent maintain APIs at least once every month (source). 

Advancements in API management tools might not be enough to offset the increasing complexity of apps. Your knowledge, skills, and creativity can unlock APIs that surmount obstacles in the future. 

How Do APIs Work: Shifting App Landscape

Returning to SmartBear’s 2019 survey, we find additional concerns about how APIs relate to endpoints. Respondents identified the following challenges that require solutions (source): 

  • Standardization (58%)
  • Versioning (44%)
  • Composability (43%)
  • Security (42%)
  • Scalability (40%) 

APIs are designed to facilitate app exchanges but competing protocols can lead to inefficient or ineffective designs. The increased reliance of banks, retailers, and governments on APIs make streamlined APIs critical. The API Standardization Industry Group (ASIG) is among the industry groups looking for solutions to this issue (source). 

The next generation of API designers will need to resolve all of these issues on the go. New and updated APIs must handle requests in quick and secure ways without costly maintenance or downtimes. 

What Are APIs: Developing the Right Skills

With APIs explained, your next thought might be how to incorporate APIs into your professional life. Job titles like API developer and API writer are niche positions that are growing more important in the tech field. Software engineers and developers are often tasked with designing APIs. 

The Bureau of Labor Statistics (BLS) makes a strong case for pursuing software developer positions. Developers earned a median income of $105,590 in 2018. Projected job growth of 21% from 2018 to 2028 shows high ceilings for developers and engineers (source). 

With a keen interest in answering questions like “What are APIs?”, you show the curiosity necessary for software careers. Baylor University can turn this curiosity and your foundational knowledge into an API-centric career. 

APIs Explained at Baylor University

Attending Baylor University as an online student leads to a challenging and innovative education. U.S. News and World Report lauded the university in its 2020 rankings. Baylor University received rankings including (source): 

  • No. 42 in Most Innovative Schools
  • No. 48 in Best Colleges for Veterans
  • No. 75 in Best Value Schools
  • No. 79 in National Universities

Tech professionals know that one data point is not good enough for a sound conclusion. Baylor University also fared well in Niche’s 2020 grades including (source): 

  • An overall grade of A
  • No. 105 out of 958 in Top Private Universities in America
  • No. 120 out of 1,579 in Colleges with the Best Academics in America
  • No. 147 out of 1,626 in Best Colleges in America

Learning more about APIs and their role in modern life likely sparked your imagination. Baylor’s Online Masters in Computer Science helps you turn this spark into real-world solutions. You can build API development skills within a design perspective through the Software Engineering track. 

Get in touch with an enrollment advisor today to learn more about Baylor’s innovative computer science program.