REST API Monitoring Guide

"Did the endpoint return 200?" is the easiest API check to write and the least useful one on its own — a huge share of real API failures return a perfectly successful status code while the actual response is wrong, slow, or subtly broken in a way no status code captures.

Status code alone misses the failures that matter most

A 200 response with an empty array where results were expected, a paginated response missing its pagination metadata, or a JSON body that silently changed shape after a backend deploy — all pass a status-code- only check while being genuinely broken for whatever consumes the API. This is the single most common gap in API monitoring setups: checking that something answered, not that it answered correctly.

What a more complete check actually verifies

  • Response schema. Confirming the response has the expected fields, of the expected types, catches contract-breaking changes — often introduced accidentally by an unrelated backend deploy — long before every consumer of the API notices independently.
  • Response time, as a distribution, not an average. An average can look fine while a meaningful share of requests are much slower — tracking a high percentile (p95 or p99) surfaces the tail latency that an average quietly hides.
  • Rate-limit headers. Watching your own API's rate-limit response headers over time reveals usage trending toward a limit before consumers actually start hitting 429 responses.
  • Authentication and credential expiry. An API key, OAuth token, or certificate quietly expiring produces a sudden wave of 401/403 errors that looks like an outage but is really a credentials problem — worth checking expiry proactively rather than waiting for the failure.

CORS is a browser-only concern, and a common false alarm

A CORS-related failure only ever happens in a browser context — a server-side monitoring check calling the same endpoint will succeed even when a browser-based client is failing on a strict CORS policy, since CORS enforcement is a browser behavior, not a server-side check. This is why "the monitoring check passes but the frontend is broken" can legitimately both be true at once — the two are testing genuinely different things, and API monitoring needs an explicit CORS check if browser clients matter, not an assumption that a passing server-side check covers it.

Multi-step flows need chained checks

Many real API usage patterns aren't a single request — authenticate, then fetch a resource, then act on it using data from the first response. A monitoring setup limited to independent single-endpoint checks can't catch a break in that chain (a token that authenticates fine but doesn't carry the right scope for the next call, for example) — this needs a genuinely chained check that mirrors the real usage pattern, not just a battery of unrelated single-request checks.

Frequently Asked Questions

Is checking for a 200 status code enough for API monitoring?

It's a reasonable first layer but misses a large share of real failures — an endpoint can return 200 with an empty, malformed, or unexpectedly shaped body. Schema validation on top of the status code check catches what status-code-only monitoring misses.

Why does my API monitoring pass while browser clients report CORS errors?

CORS is enforced by browsers, not servers — a server-side monitoring check bypasses that enforcement entirely, so it can genuinely pass while a real browser-based client fails. This needs its own explicit check, not an assumption.

Should I monitor average response time or percentiles?

Percentiles (p95/p99) reveal tail latency — the slow outliers — that an average can hide entirely. A monitoring setup that only tracks the average can look healthy while a meaningful share of real requests are unacceptably slow.

Stop checking this by hand

NetTests runs this kind of check on a schedule, stores historical results, and alerts your team the moment something changes.

Start monitoring free →
No credit card required  ·  Free plan available