How to debug API JSON responses
A developer workflow for inspecting API JSON responses, status fields, error objects, timestamps, IDs, and nested payloads.
Start with the response shape
When an API response looks wrong, do not jump straight to business logic. First inspect the response shape. Format the JSON, identify the top-level status or error object, and find the nested area that changed. Many bugs become obvious once the response is readable.
Check whether the response contains an error code, message, trace ID, validation details, pagination metadata, or an empty data array. These fields often explain the failure before you need server logs.
Compare headers, body, and status
A JSON body does not tell the whole story. The HTTP status code, content type, cache headers, authorization behavior, and correlation ID are part of the same debugging picture. A 200 response with an error object is different from a 401, 403, 409, or 500 response.
If a response works in one client but fails in another, compare request headers and query parameters. Authentication, content negotiation, locale, tenant, and cache headers are frequent causes of inconsistent results.
Turn the response into a useful note
A good bug note includes the endpoint, method, status code, sanitized request input, formatted response, timestamp, environment, and correlation ID if available. Remove tokens, personal data, account numbers, and internal URLs before sharing.
For repeatable cases, save a compact fixture for tests and a formatted version for review. The fixture helps automation, while the formatted version helps humans understand the failure quickly.
Related tools
Formatters
OpenJSON Formatter
Pretty-print raw JSON, minify payloads, and inspect syntax errors with clear feedback.
API & Auth
OpenHeader Parser
Parse raw HTTP headers into readable key and value pairs for request and response debugging.
API & Auth
OpenHTTP Status Code Explorer
Search HTTP status codes by number or meaning and see common developer use cases fast.
Converters
OpenTimestamp Converter
Convert Unix seconds, Unix milliseconds, and ISO date strings with readable UTC and local output.
Related workflows
JSON Tools
Format, validate, convert, and inspect JSON payloads without setting up a scratch project.
Formatter Tools
Clean up dense developer text so payloads, queries, markup, and logs are easier to inspect.
API Debugging Tools
Inspect the pieces that usually explain API failures: JSON, JWTs, headers, query params, cURL, and status codes.
Log Tools
Clean noisy logs, extract trace and correlation IDs, and connect log output to payload debugging tools.