Status grid
1 good · 1 bad
Docs · Visuals
One cell per item, coloured good, warn or bad, with a count of each above.
Edit the example and the visual redraws. Mistakes show the same messages the API returns.
1 good · 1 bad
Change any number or label. The chart follows.
| Field | Type | Rule |
|---|---|---|
nameKeyRequired | string | The key in each row that holds the item's name. Up to 80 characters. |
statusKeyRequired | string | The key in each row that holds the item's status. Up to 80 characters. Must differ from nameKey. |
statusesOptional | object | Maps your own status words to good, warn or bad, 1 to 20 entries, words of 1 to 200 characters. With it a status can be any word, and a word not in the map shows grey, as no status. Without it a status must be good, warn, bad or empty. For example, "statuses": { "Patched": "good", "Not patched": "bad" }. |
noteKeyOptional | string | The key in each row that holds a short second line, such as a version. Up to 80 characters. Must differ from nameKey and statusKey. |
hrefKeyOptional | string | The key in each row that holds a link; the whole cell opens it. Up to 80 characters. Must differ from nameKey, statusKey and noteKey. |
dataRequired | array | Up to 200 rows, drawn in the order you list them; may be empty. |
| Field | Type | Rule |
|---|---|---|
<nameKey>Required | string | The item's name. Up to 80 characters. Names must be unique. |
<statusKey>Required | string | The status: good, warn, bad or an empty string; with statuses, any string up to 200 characters. |
<noteKey>Optional | string or null | A note of up to 80 characters; may be empty or null. |
<hrefKey>Optional | string or null | An http or https link of up to 2048 characters; null or an empty string means no link. |
{
"nameKey": "site",
"statusKey": "patch",
"statuses": { "Patched": "good", "Pending": "warn", "Not patched": "bad" },
"noteKey": "version",
"hrefKey": "admin",
"data": [
{
"site": "shop.example.com",
"patch": "Patched",
"version": "6.4.2",
"admin": "https://shop.example.com/wp-admin"
},
{
"site": "blog.example.com",
"patch": "Not patched",
"version": "6.1.0",
"admin": "https://blog.example.com/wp-admin"
}
]
}Paste the document in the editor, or replace it with a PUT to the visual's push URL. The push API page has the details and examples.
Next: Heatmap JSON format