Knowledge Refresh: JSON (JavaScript Object Notation)

SE Tech Summit - HA Fundamentals Session

Knowledge Refresh 3 of 5

JSON is the primary data format used for API communication.

{
  "penguins": [
    {"name": "Emperor", "id": 1, "roles": [1, 3, 4]},
    {"name": "King", "id": 2, "roles": [ ]},
    {"name": "Gentoo", "id": 3, "roles": null}
  ]
}

A key consideration when working with JSON is distinguishing between an **empty array** (`[]`) and a **null** value.