Safeguard
Security Guides•

What is an API security testing checklist I can actually run?

Test every API operation with no token, a valid token and a wrong-role token. This per-operation matrix is the core of an API security testing checklist.

Safeguard Security Team
3 min read

An API security testing checklist is clearest as a matrix: for every operation, call it with no credentials, with a valid token and with a token that lacks the needed role, then record what comes back. Around that matrix, test token handling, object access, extra fields and limits.

Build the surface map first

You cannot test what you have not listed. Pull the OpenAPI file if one exists, capture real traffic through a proxy, and look for operations the description omits. OWASP's REST assessment guidance suggests checking common paths for machine-readable descriptions, and treating differences between spec and behavior as leads, not automatic bugs.

The matrix

OperationNo tokenValid tokenWrong role or scope
GET /orders/IDExpect 401Expect 200 for own objectExpect 403
DELETE /orders/IDExpect 401Own object onlyExpect 403
GET /admin/usersExpect 401Expect 403Expect 403

Record the status code, body and whether the operation changed data. A denial should use the documented status, and should not return a server error.

Checklist

  1. Authentication: tamper with token claims, strip the signature, and send expired and wrong-audience tokens.
  2. Object access: use two accounts and swap identifiers across read, update and delete.
  3. Function access: call owner-only or admin-only operations with a low-privilege token.
  4. Property handling: add fields such as roles or verification flags, then read the object back to see if they stuck.
  5. Limits: check that throttling applies to login, token and recovery endpoints, and find out what one expensive request costs.
  6. Errors: confirm failures do not leak stack traces or internal hostnames.
  7. Inventory: look for old versions and undocumented hosts still reachable.

Notes on the matrix

An operation level security declaration in OpenAPI replaces the root level one rather than combining with it, so check every operation individually. Per-IP rate limits can be bypassed, and an authenticated session should not switch limits off.

Where automation helps

Scanners fuzz and replay well, but they do not know which user owns which object. The object and function access rows usually need scripted tests with two real test accounts.

Try it yourself

Run the API scan and compare which operations returned the unexpected status.

Click through it at your own pace, or open it full screen.

Quick check

How many test accounts do I need?

At least two normal users in different tenants, plus one admin. Two users are what make object access tests possible.

Is a clean scanner run enough?

No. Scanners rarely understand ownership, so access control still needs targeted tests.

Where Safeguard fits

Safeguard offers dependency and SBOM scanning, reachability analysis and policies and gates that can block a pull request, so the libraries behind your app are checked alongside the app itself. You can try a free scan at gold.safeguard.sh/scan.

Sources

Last reviewed: 19 October 2026.

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.