Two steps
1. Find the chart name
Run fetch with the id of the dashboard or note. In the result, metadata.charts holds the name, the aggregation (values) and the filters of each chart.If metadata.charts lists the name of each chart, you have the chart names.
2. Get the numbers
Pass a name to--chart and run chart get-data.
--offset to read on. One call returns at most 100 rows.
If the first 5 rows are in rows, you have the numbers.
Aggregate (optional)
For totals, rankings or the rows that match a condition, use chart query. It takes the same inputs as dataset query.If the aggregated result is in rows, the query worked.
See the shape of the chart (optional)
To see the trend or layout of a chart, get its image.--output. Read exact numbers with chart get-data, not from the image.
If result.image describes the image, you have it.
Troubleshooting
Every flag is described in chart get-data, how to aggregate in chart query, and getting the image in chart get-image.
