{ type, ...fields, at }, where type selects the kind of content, the remaining fields configure that content, and at is the bounding box that places it on the canvas. There are ten layer types in total, covering text, lists, charts, tables, images, shapes, and icons. Every layer type is fully schema-validated, so your editor can autocomplete all valid fields and flag any invalid values at call time.
The geometry field: at
Every layer, regardless of type, requires an at field that positions it on the 1920 × 1080 slide canvas (or whatever size preset you’ve chosen). All coordinates and dimensions are in pixels.
Optional common fields
Beyondat, every layer type also accepts these optional fields:
| Field | Type | Purpose |
|---|---|---|
z | number (integer) | Stacking order — higher values appear in front |
prompt | string | AI brief: plain-language instruction for what the AI should generate in this slot |
examples | string[] | Sample outputs that guide AI generation for this layer |
effects | object | Visual effects — opacity, corner radius, drop shadows, filters |
All ten layer types
text
Display text, headings, and body copy. Supports all eight theme text styles.
bullets
Unordered bulleted list. Accepts bullet marker styling — icon, color, size, spacing.
numbered
Ordered (numbered) list. Supports decimal, alpha, and roman numeral markers.
bar
Bar or horizontal-bar chart shorthand. Pass
data: [{ label, value }] and you’re done.donut
Donut (ring) chart shorthand. Best for part-to-whole comparisons.
chart
Full chart structure — every family and feature via
document.table
Data table with columns, rows, header styling, alternating rows, and borders.
image
Image from a public HTTPS URL. Compiled to a rectangle shape with
imageFill.shape
Vector shape:
rectangle, circle, ellipse, triangle, or line.icon
Named icon from the Ablo icon library, referenced by key string.
Layer type reference
text — styled text block
Renders a block of text. The style field maps to one of eight theme-controlled text styles, but you can override individual properties like fontSize, color, fontFamily, or bold inline.
bullets — bulleted list
Renders an unordered list. Pass items as an array of strings. Bullet marker style, color, size, and spacing are all configurable.
numbered — ordered list
Renders a numbered list. The listStyle field controls the marker format.
bar — bar chart (shorthand)
The bar type is a shorthand for a vertical or horizontal bar chart. Pass data as an array of { label, value } objects.
donut — donut chart (shorthand)
The donut type is a shorthand for a donut (ring) chart. Like bar, it compiles to the full chart layer.
chart — full chart structure
When you need a chart family beyond bar or donut — or you want full control over datasets, scales, axes, and affordances — use the chart type and supply a document object directly. Supported families include bar, stacked-bar, line, combo, pie, donut, waterfall, funnel, scatter, bubble, mekko, gantt, and range.
table — data table
Renders a styled data table. Columns can carry alignment, width, and per-column style. Cells can be plain strings/numbers, or rich objects with colSpan, rowSpan, and custom styling. The styles field controls header appearance, alternating row colors, and border presets.
image — image from URL
Renders an image sourced from a public HTTPS URL. The image is automatically re-hosted to the Ablo CDN server-side. The image type is persisted as a shape layer carrying an image fill — there is no separate image layer type in the persistence model.
The
image layer is persisted as a shape layer with an imageFill. The LayerResource.type returned after creation will be 'shape', not 'image'. This is expected — image is an authoring shorthand that the SDK maps to a rectangle shape with an image fill.shape — vector shape
Renders a filled vector shape. Use fill for a hex color, gradient for a CSS gradient string, or the structured fills array for advanced multi-stop fills. Rectangles support a radius for rounded corners. The line shape supports endpoint coordinates (x1, y1, x2, y2) and optional arrowheads.
icon — named icon
Renders a named icon from the Ablo icon library. Pass the icon key as a string, plus an optional color.
Shorthand types vs. persisted types
Two of the ten authoring types compile to a different persisted type. This is transparent in use — you write the friendly authoring type and the SDK handles the translation.| Authoring type | Persisted as | Notes |
|---|---|---|
bar | chart | Bar chart shorthand — pass data: [{ label, value }] |
donut | chart | Donut chart shorthand — pass data: [{ label, value }] |
image | shape | Rectangle shape carrying an image fill |
ablo.layers.create() or read back a layer via ablo.layers.retrieve(), the type field reflects the persisted type, not the authoring shorthand.