Explore our new Cybersecurity Terms Glossary, explained by our experts.

View the Glossary View the Glossary
PRIVIA

Cybersecurity Terms Glossary

What Is API Security?

API security is the practice of protecting application programming interfaces from abuse, covering discovery, authentication, authorisation, input validation, rate limiting, and monitoring.

Illustration for the cybersecurity term API Security
Home / Blog / Cybersecurity Terms / What Is API Security?
17 November 2026

What Is API Security?

What Is API Security?

API security is the set of practices and controls that protect application programming interfaces—the endpoints that mobile apps, web front ends, partners, and internal services use to exchange data. Because an API exposes business logic and data directly, with no user interface in the way, a single missing check can let an attacker pull millions of records with a simple script. Securing APIs means knowing which ones you have, verifying who calls them, limiting what each caller can do, and watching how they are used.

Why APIs Are a Prime Target

Modern applications are thin front ends sitting on dozens or hundreds of APIs. Each endpoint is an entry point, and many are undocumented: old versions left running after a migration (“zombie” APIs), or endpoints built quickly for a single partner and never registered (“shadow” APIs). APIs also tend to return more data than the screen displays, trusting the client to filter it—an assumption attackers exploit by calling the endpoint directly with tools such as Burp Suite or Postman.

Traditional perimeter controls help less than you might expect. A web application firewall recognises an SQL injection payload, but a request for /api/v2/accounts/88213 made by the wrong customer looks entirely legitimate. Most serious API breaches exploit logic, not malformed input.

The OWASP API Security Top 10 (2023)

  1. API1 – Broken Object Level Authorization
  2. API2 – Broken Authentication
  3. API3 – Broken Object Property Level Authorization
  4. API4 – Unrestricted Resource Consumption
  5. API5 – Broken Function Level Authorization
  6. API6 – Unrestricted Access to Sensitive Business Flows
  7. API7 – Server Side Request Forgery
  8. API8 – Security Misconfiguration
  9. API9 – Improper Inventory Management
  10. API10 – Unsafe Consumption of APIs

Three of the top five are authorisation failures, which is why API testing overlaps heavily with broken access control. Inventory management (API9) deserves equal attention: you cannot protect an endpoint you do not know exists.

Lessons From Real Breaches

In September 2022, the Australian telecoms provider Optus disclosed a breach affecting around 9.8 million current and former customers. Public reporting attributed it to an internet-facing API that did not require authentication and used predictable customer identifiers. In January 2023, T-Mobile in the US disclosed that an attacker had abused one of its APIs to obtain data relating to around 37 million accounts over several weeks. Neither case needed an exploit in the traditional sense—just requests the APIs were happy to answer.

Core Controls

Know What You Expose

Maintain a living inventory of every API, version, and environment, ideally generated from OpenAPI specifications and confirmed by traffic analysis. Retire old versions deliberately rather than leaving them running. External attack surface discovery helps catch forgotten hosts and test environments exposed to the internet.

Authenticate and Authorise Every Call

Use established standards—OAuth 2.0 and OpenID Connect for users, mutual TLS or signed tokens for service-to-service traffic—and never invent your own scheme. Validate token signatures, audience, and expiry on every request. Then check, in server-side code, that the caller may access that specific object and that specific field. The UK Open Banking standard, built on the OpenID Foundation’s FAPI security profile, is a good example of how strict this can be made for high-value data.

Limit and Validate

Monitor Behaviour

An API gateway gives you a single place to enforce policy and collect logs. Feed those logs into your monitoring platform and alert on patterns such as one token enumerating sequential IDs, sudden spikes in error rates, or a client requesting far more records than normal.

Testing APIs Properly

Automated scanners can find misconfigurations and known vulnerabilities, but authorisation flaws require testers who understand the business rules and who test with multiple accounts and roles. A good assessment starts from the API specification, adds endpoints found in mobile apps and JavaScript bundles, and then attempts object, property, and function-level bypasses. Our web application security services include REST, SOAP, and GraphQL API testing performed this way.

FAQ – Frequently Asked Questions

Is an API Gateway Enough to Secure My APIs?

No. A gateway is valuable for authentication, rate limiting, logging, and blocking obviously malicious traffic, but it usually cannot decide whether user A may read record B. That decision depends on business logic inside the application. Treat the gateway as one layer and keep object-level and function-level authorisation checks in the backend code.

What Are Shadow and Zombie APIs?

Shadow APIs are endpoints running in production that the security team does not know about, often created for a quick integration or a test. Zombie APIs are deprecated versions that were never switched off after a newer version launched. Both tend to lack current security controls and monitoring, which makes them attractive targets for attackers.

How Is GraphQL Security Different From REST?

GraphQL exposes a single endpoint with a flexible query language, so controls move from the URL level to the field and resolver level. Specific risks include introspection revealing the whole schema, deeply nested queries that exhaust server resources, and batching that bypasses rate limits. Authorisation must be enforced in each resolver, not only at the endpoint.

How Often Should APIs Be Penetration Tested?

At least annually, and whenever you release significant new endpoints, change authentication, or onboard a major partner integration. For fast-moving teams, combine periodic manual testing with automated security tests in the CI/CD pipeline and continuous discovery, so new or changed endpoints are caught between formal assessments.

Related Terms

You May Be Interested In These

What Is Gitleaks?

Cybersecurity Terms

17 November 2026

What Is Gitleaks?

Read More
What Is Packet Capture?

Cybersecurity Terms

17 November 2026

What Is Packet Capture?

Read More
What Is Steganography Detection?

Cybersecurity Terms

17 November 2026

What Is Steganography Detection?

Read More