← Infographic Maker
Your token

Infographic Maker API

The drawing and every export run free in the browser and need no API. The API is for the one metered step: send notes, get back an infographic in AntV Infographic syntax (infographic <template>, data, items), which this page or any AntV Infographic renderer draws.

Base URL: https://api.skillsafe.ai/v1/app-api. Every response is {"data": ...} or {"error": {"code", "message"}}; read error.code and error.message rather than the HTTP status alone.

The task field

This app has one task. Always send "task": "make".

taskWhat it doesReply
makeTurns notes, minutes or a report into an infographic with one of eleven templates: 3 to 7 items with short labels in the notes' language. Points and numbers come from the notes; group headings and the title may be the model's own words.One ```infographic block

Input fields

FieldTypeMeaning
taskstring"make"
textstringThe notes. The page sends at most 12,000 characters: longer notes keep their first and last lines and lose the middle, with a marker line.
layoutstring"auto", or one of steps, timeline, cards, checklist, funnel, pyramid, compare, swot, bar, pie, tree to force that template.
focusstringOptional, up to 200 characters: what the infographic is for.
factsstringJSON text of what the page read from the notes: lines, numbers, read_as, title, items, page_layout. Send "{}" if you have nothing.
clipped_notestringEmpty, or a sentence saying the middle of the notes was cut.

The reply

job.output.output is text: one fenced block. Line 1 is infographic and one of these templates: sequence-steps-simple, sequence-timeline-simple, list-grid-badge-card, list-column-done-list, sequence-funnel-simple, list-pyramid-badge-card, compare-binary-horizontal-simple-vs, compare-swot, chart-bar-plain-text, chart-pie-donut-plain-text, hierarchy-structure. Then data with title, optional desc and one collection of - label items (desc, value, time, done, children). If the balance ran low, truncated is true and the block may stop early; every whole item before the cut still draws.

Worked example

Input (input.json):

{
  "task": "make",
  "text": "Some history of the Elm Road community garden for the newsletter. It all started in spring 2019 when six neighbours cleared the empty lot behind the library. In 2020 the council gave us a five-year lease, which meant we could finally put up a shed and two water butts. 2021 was the year of the first harvest festival - about 200 people came. We got a lottery grant of 12,000 pounds in 2023 and spent it on raised beds that wheelchair users can reach. This year, 2025, we started a Saturday kids' club.",
  "layout": "timeline",
  "focus": "",
  "facts": "{\"lines\":1,\"numbers\":[\"2019\",\"2020\",\"2021\",\"200\",\"12000\",\"2023\",\"2025\"],\"read_as\":\"lines\",\"title\":\"\",\"items\":1,\"page_layout\":\"steps\"}",
  "clipped_note": ""
}

Reply:

```infographic
infographic sequence-timeline-simple
data
  title Elm Road Community Garden History
  desc Key moments from 2019 to 2025
  sequences
    - label Lot cleared
      time 2019
      desc Six neighbours cleared the empty lot behind the library
    - label Five-year lease
      time 2020
      desc Council lease let us put up a shed and two water butts
    - label First harvest festival
      time 2021
      desc About 200 people came
    - label Lottery grant
      time 2023
      desc 12000 pounds spent on raised beds wheelchair users can reach
    - label Saturday kids' club
      time 2025
      desc Started this year
```

Paste the reply into the page to draw it, check it against the notes and download it.

Errors

HTTPWhat to do
401The token is missing, expired or a guest token on a run. Get a personal token on the token page.
402The balance is below what the run reserves. Top up at skillsafe.ai/account/billing.
400The body is not a JSON object of the fields above.
429Wait and retry with the same Idempotency-Key.

Step 1 — a tiny client helper

One function that sends JSON and unwraps the {data, error} envelope.

BASE="https://api.skillsafe.ai/v1/app-api"
TOKEN="paste-your-token-here"   # from https://infographic-maker.skillsafe.ai/tokens.html
api() { # api METHOD PATH [JSON-BODY]
  curl -s -X "$1" "$BASE$2" -H "Content-Type: application/json" \
    ${TOKEN:+-H "Authorization: Bearer $TOKEN"} ${3:+--data "$3"}
}

Step 2 — a token

A guest token is enough for /me and /estimate. A run is metered, so it needs your personal token: sign in on the token page and copy it.

# a guest token (enough for /me and /estimate); a run needs your personal token from /tokens.html
TOKEN=$(curl -s -X POST "$BASE/guest" -H "Content-Type: application/json" -d '{"slug":"infographic-maker"}' | jq -r '.data.token')

Step 3 — who am I, and my balance

subject_type is guest or user; credits is the balance (1 credit = $0.0001).

api GET /me | jq '.data | {subject_type, credits}' 

Step 4 — price a run for free

/estimate charges nothing and starts no job. hold_credits is the amount reserved while a run is in flight, not the price; the run is charged what it uses.

# input.json: the run input object - {"task": "make", "text": "...", "layout": "auto", "focus": "", "facts": "{...}", "clipped_note": ""}
api POST /estimate "$(cat input.json)" | jq '.data | {hold_credits, min_credits, model, model_alias, markup_bps, warnings}' 

Step 5 — run it and wait for the job

Send an Idempotency-Key derived from the input: a retry with the same key is never billed twice.

KEY="infographic-maker:make:$(shasum -a 256 input.json | cut -c1-16):a1"
JOB=$(curl -s -X POST "$BASE/run" -H "Content-Type: application/json" -H "Authorization: Bearer $TOKEN" \
  -H "Idempotency-Key: $KEY" --data @input.json | jq -r '.data.job_id')
while :; do
  J=$(api GET "/jobs/$JOB"); S=$(echo "$J" | jq -r '.data.status')
  case "$S" in succeeded|failed|cancelled) break;; esac; sleep 2
done
echo "$J" | jq -r '.data.output.output' > reply.txt   # one ```infographic block
echo "$J" | jq '.data | {charged_credits, truncated}' 

Step 6 — or stream it

/run-stream sends Server-Sent Events while the job runs and the finished job at the end.

# Server-Sent Events: tick/delta events while the job runs, then a final event with the job
curl -N -s -X POST "$BASE/run-stream" -H "Content-Type: application/json" -H "Authorization: Bearer $TOKEN" \
  -H "Idempotency-Key: infographic-maker:make:$(shasum -a 256 input.json | cut -c1-16):a1" --data @input.json