escentmachine / field notes
Uncategorized
-
How to Interpret application/problem+json API Errors
Read structured API errors by combining response metadata, the JSON body, and the API contract. Follow an invented validation response, distinguish problem-details members from extensions, and learn what…
-
What ~0 and ~1 Mean in JSON Pointer Paths
In JSON Pointer tokens, ~1 represents a slash and ~0 represents a tilde. Learn how to decode an API error location, trace it through objects and arrays, and…
-
Does Escaping a Forward Slash Change a JSON String?
Escaping a forward slash changes the JSON text while preserving the decoded slash character. Compare source text and parsed values separately, recognize when a backslash belongs to the…
-
How to Restore JSON Copied From a CSV Field
Restore copied JSON in separate stages: establish what was copied, extract the intended CSV field when needed, validate its JSON syntax and format it with preservation checks. Worked…
-
How to Extract and Format JSON From an HTTP Response With Headers
Start by identifying what your client has given you. Keep response metadata outside the JSON input, establish whether decoding work remains, and distinguish body-reading failures from JSON syntax…
-
encodeURI vs. encodeURIComponent: Choose the Right Boundary
Choose encodeURI for an already structured URL whose syntax should remain meaningful, and encodeURIComponent for individual data components. Learn how to preserve boundaries, inspect query values and report…
-
JSON Copied From HTML: Checking " and Intended Values
When copied JSON contains ", first determine whether it occupies required quotation-mark positions or belongs inside a valid string. Preserve the input, compare it with a confirmed original,…
-
Does Formatting JSON Change Array Element Order?
Changing indentation and line breaks preserves an array’s sequence, length, and repeated elements. Use a positional comparison and a runnable example to distinguish formatting from sorting, other transformations,…
-
Why JSON Requires Double Quotes Around Strings and Property Names
Double quotes are part of JSON’s grammar. Learn how to correct JavaScript-style object text, preserve apostrophes and quotation marks, serialize an existing object, and verify that syntax fixes…
-
Why Valid JSON Can Fail an API Schema Check
Compare an API’s schema error with the exact transmitted body and the correct request contract. Follow a fictional schema through missing fields, incorrect types, disallowed values, and unexpected…