Skip to content

Tables

Slides that use the TABLE layout can render exact cell data when you send a table object alongside the slide definition. Use this layout for KPI matrices, feature comparisons, pricing grids, or any structured dataset that benefits from clear columns and rows.

Using Tables with /presentation/generate/slide-by-slide

Section titled “Using Tables with /presentation/generate/slide-by-slide”

  • Set layout to TABLE
  • Set item_amount to 0
  • Keep content as a short textual description of the table (used for context)
  • Provide the table data via the table field described below
  • Always place the header row first; only the top row is styled as headers

The table field is an array of rows, and each row is an array of string cell values. The first row becomes the header. All subsequent rows render as body rows.

"table": [
["Column 1", "Column 2", "Column 3"],
["Row 1 Value 1", "Row 1 Value 2", "Row 1 Value 3"],
["Row 2 Value 1", "Row 2 Value 2", "Row 2 Value 3"]
]

In this example the ["Column 1", "Column 2", "Column 3"] entry is the header row. Always keep it at the top to ensure the slide renders headers correctly.


Terminal window
curl -X POST https://api.slidespeak.co/api/v1/presentation/generate/slide-by-slide -H "Content-Type: application/json" -H "X-API-Key: <YOUR_API_KEY>" -d '{
"template": "DEFAULT",
"slides": [
{
"title": "Regional KPIs",
"layout": "TABLE",
"item_amount": 0,
"content": "Quarterly metrics by region",
"table": [
["Region", "Q1", "Q2", "Q3"],
["North America", "$2.1M", "$2.4M", "$2.7M"],
["Europe", "$1.8M", "$1.9M", "$2.0M"],
["Asia Pacific", "$1.2M", "$1.4M", "$1.6M"]
]
}
]
}'

The first nested array in every snippet defines the headers (Region, Q1, Q2, Q3). Subsequent arrays supply the body rows.


  • Keep headers concise (2–4 words) for best visual results
  • Ensure every row has the same number of cells as the header row
  • Use strings for all values; formatting (currency symbols, percentages, etc.) is preserved
  • Order rows exactly how you expect them to appear on the slide