JSON (JavaScript Object Notation) is an open-standard, human-readable data serialization format. It converts application data into a standardized representation for storage or transmission, allowing software written in different languages to reconstruct and interpret it. REST APIs commonly use JSON. section 24.0 section 24.2
Recognize these JSON data types and syntax rules:
- A string is text enclosed in double quotes; quoted values such as "5", "true", and "null" remain strings. section 24.4
- A number is numeric data such as 5 or 101.25; a Boolean is exactly true or false in lowercase; null represents intentional absence of a value. section 24.4
- An object is an unordered collection of key-value pairs enclosed in curly braces. Each key is a string, and the key and value are separated by a colon. section 24.4
- An array organizes values in square brackets; objects and arrays can be nested, and whitespace is insignificant. section 24.4
- Separate multiple object pairs or array elements with commas, but do not add a trailing comma after the final item. section 24.2.3
Interpreting interface data
The object identifies GigabitEthernet1/1, reports is_up as the Boolean true, gives an IP address and netmask as strings, records speed as the number 1000, and uses null for a missing description. section 24.2
{
"interface_name": "GigabitEthernet1/1",
"is_up": true,
"ip_address": "192.168.1.1",
"netmask": "255.255.255.0",
"speed": 1000,
"description": null
}
Inspect a compact JSON object containing strings, a Boolean, a number, null, and named key-value pairs. section 24.2
Common invalid forms include uppercase TRUE or NULL, a missing comma, a hyphen instead of the colon between a key and value, a trailing comma, and unmatched object or array delimiters. JSON is defined in RFC 8259. section 24.2.3


































