VitalRix use case
API monitoring from the outside and the inside
Synthetic checks confirm your API answers correctly. APM shows which endpoint is slow, which query is to blame and which deploy started it. Together they turn "the API is slow" into a specific fix.
7 min read7 sectionsUpdated
On this page
At a glance
Who this is for: backend and platform engineers, SaaS teams whose product is an API, and mobile teams whose app is only as good as the API behind it.
The idea: use two different views of the same API and compare them.
- Outside-in (synthetic checks): a checker calls your public endpoint on a schedule, as a customer would, and asserts on the answer. It tells you the API is broken even when nobody is calling it.
- Inside-out (APM): your services send OpenTelemetry traces. VitalRix turns them into throughput, latency percentiles, errors and database time per endpoint. It tells you where the time goes.
If the outside check fails and APM looks healthy, the problem is in front of your service: DNS, a load balancer, a certificate, a firewall. If APM shows errors and the check still passes, the problem is on a path the check does not exercise. That comparison alone saves hours.
| Feature | Synthetic check | APM |
|---|---|---|
| Runs when nobody calls the API | Yes | No, it needs real requests |
| Catches DNS, TLS or load balancer failures | Yes | No, the request never reached your code |
| Shows which endpoint is slow | Only the ones you check | Every route, grouped automatically |
| Shows the failing query or stack trace | No | Yes, with traces and issues |
| Needs code changes | No | OpenTelemetry instrumentation |
| Works for third-party APIs you depend on | Yes | Only as outgoing calls you make |
| Best alert | Consecutive failures, response time | p95 latency, error rate, traffic drop |
Start with the endpoints a customer or your own front end depends on, not every route you have. A good first set is five checks:
- Health endpoint. A cheap route that touches the database or cache you depend on. Assert status 200 and a JSON field such as $.status equals ok.
- One read endpoint. A public, cacheable GET that returns real data. Assert on a field you know exists.
- Authentication. A call that exchanges credentials for a token. This is where expired secrets and clock problems show up first.
- One write path, in a multi-step monitor. Log in, create something, read it back, optionally clean up. Variables captured in one step are available in the next.
- One dependency. The third-party API you cannot work without, such as payments or email. When it fails you want to know before your own error rate shows it.
Assertions that mean something
Status code or range, body contains or does not contain, a JSON path equals a value, and a maximum response time in milliseconds. A response that is fast and wrong still fails.
Multi-step API monitors
Chain calls in order: authenticate, act, verify. Capture a value such as a token or an id from one step and use it in the next, with an assertion on every step. This tests a whole flow, not one URL.
Timing breakdown
Each check records DNS, connect, TLS and time to first byte, so you can tell a slow network path from a slow handler without opening another tool.
Multi-region confirmation
HTTP, API and multi-step monitors can run from several locations. The monitor is down only when all selected locations agree, so a regional network problem does not page you.
Safe credentials
Request headers such as Authorization are write-only. After saving, VitalRix shows only a masked hint. Create a separate read-only token for monitoring so a leaked header can do nothing else.
Heartbeats for background work
Queue consumers and cron jobs have no URL to call. A heartbeat monitor gives the job a unique ping URL and a deadline: if the job does not check in on time, the monitor fires.
APM is built from OpenTelemetry traces, so there is no proprietary agent. Node.js, Python, Go, Ruby and PHP have a VitalRix package that sets up the official OpenTelemetry SDK in one call, and Java and .NET use the OpenTelemetry agent, all sending straight to VitalRix. Use the service's application slug as the service name and APM links it to the application automatically.
Open the Endpoints page and you get the view that matters for an API:
- Normalized routes. /users/123 and /users/456 become /users/:id. IDs, UUIDs, tokens, dates and emails are replaced, and query strings are never part of the name.
- p50, p95 and p99 per route, computed from merged histograms, never averages of averages.
- Degraded endpoints. A route is flagged when its p95 is at least 1.5 times, and at least 50 ms, above its own 7-day baseline. That catches a slow regression on a route that is still "fast enough" in absolute terms.
- Failed requests. A request with an error status or an HTTP 5xx answer. 4xx answers are client errors and are counted separately, so a wave of bad requests does not look like an outage.
Can I monitor a protected API?
Yes. Add an Authorization or API-key header to the check. It is stored write-only and never shown again, only as a masked hint. Use a separate read-only credential for monitoring.
Can I monitor GraphQL?
Yes, as an HTTP or API check with the POST method, a JSON body containing your query and assertions on the response. Keep the query small and stable so the check measures availability, not query cost.
Which languages does APM support?
Any language with OpenTelemetry. Node.js (@vitalrix/node), Python (pip install vitalrix), Go, Ruby (gem vitalrix) and PHP (composer require vitalrix/vitalrix) have VitalRix packages; Java and .NET use the OpenTelemetry agent or SDK. All send straight to VitalRix. VitalRix accepts OTLP over HTTP with protobuf or JSON.
Can I alert on p95 latency?
Yes. APM alert rules can watch p95 or p99 latency, error rate, failed request count, request count, traffic change, heartbeat age and database p95, narrowed to a service, an environment or one endpoint.
How is a failed request defined?
A request with an error status or an HTTP 5xx answer. HTTP 4xx answers are client errors and are counted separately.
Do I need both synthetic checks and APM?
You can start with either. Checks need no code changes and work when nobody calls the API. APM explains why. Most teams end up wanting both.
How do I monitor a cron job or queue worker?
Use a heartbeat monitor. The job calls its unique ping URL as the last step of each run, and the monitor fires if the ping is late.
Will monitoring calls count as customer traffic?
Synthetic checks are real requests to your API, so they appear in your own logs. Use a recognisable path or header for them and exclude it from business dashboards if needed.
Does VitalRix store my request data?
Secrets are removed before anything is stored: authorization headers, tokens, passwords, query-string values and SQL values.
Is there a public OpenAPI file for the VitalRix API?
No public OpenAPI specification is published today. The docs describe the endpoints you need for ingestion and automation.
Check it now, free
- Response time checker: Measure TTFB with DNS, connect, TLS and server time.
- Downtime cost calculator: What an outage costs per minute, hour and year.
Related reading
- How to monitor Render: How to monitor apps on Render: web service uptime and health checks, background workers, cron jobs with heartbeats, managed Postgres and Redis, and alerts.
- What is API testing?: API testing explained: functional, contract, load and security tests, what to assert on, tools, and running API checks continuously in production as monitoring.
- What is synthetic monitoring?: Synthetic monitoring explained: scheduled, scripted checks that test your site, APIs and jobs before users do. Types, assertions, a checkout example, pitfalls.
- What is URL monitoring?: URL monitoring explained: scheduled checks of a URL for status code, content, response time, redirects and SSL, with sensible settings.
- What is uptime monitoring?: Uptime monitoring explained: how website and API checks work, what 99.9% uptime means, check intervals, avoiding false alarms, status pages and an example.
- VitalRix and Opsgenie: Connect VitalRix to Opsgenie with the Alert API: create alerts from uptime, APM and SLO rules, acknowledge and close them on recovery, in the US or EU region.
Know about API problems before your customers do
Add your first API check and send traces from one service. The free tier is enough to try both.