Grammar
Valid JSON uses a small data model and strict string syntax
Objects, arrays, strings, numbers, true, false, and null are valid values. Object names and strings require double quotes; comments, trailing commas, NaN, Infinity, undefined, and functions are not part of standard JSON. A syntax error position is a starting point; the actual missing quote or comma can be earlier.
Data meaning
Sorting keys and escaping Unicode can change representation even when values parse similarly
Object member order is not a dependable business contract, though some signing or diff workflows use canonical serialization. Escaped Unicode and literal characters can represent the same string, while numbers beyond a runtime's safe integer range may lose precision during parsing. Store large identifiers as strings when the producer and consumer require exact digits.
Validation scope
A valid document can still violate the API or application's schema
Grammar validation does not prove required fields exist, enum values are allowed, URLs are safe, or nested shapes match the contract. Use JSON Schema or application validation, protect secrets before pasting payloads, and minify only when compact transport is actually useful.