{
  "openapi": "3.0.1",
  "info": {
    "title": "Chart Image Generator API: JSON to PNG, SVG, PDF Charts",
    "description": "[$2 / 1,000 charts] Turn JSON into PNG, SVG or PDF chart images: bar, line, area, pie, doughnut, gauge, radar, scatter, sparkline, with your theme, size, colors and logo. Chart.js configs accepted, bulk batches. No API key, MCP-ready for AI agents, errors are free. $2 per 1,000 charts.",
    "version": "0.1",
    "x-build-id": "aZ5ebtXJUhuhtlkXk"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/actose~chart-image-renderer/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-actose-chart-image-renderer",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/actose~chart-image-renderer/runs": {
      "post": {
        "operationId": "runs-sync-actose-chart-image-renderer",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/actose~chart-image-renderer/run-sync": {
      "post": {
        "operationId": "run-sync-actose-chart-image-renderer",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "type": {
            "title": "Chart type",
            "enum": [
              "bar",
              "horizontalBar",
              "stackedBar",
              "line",
              "area",
              "pie",
              "doughnut",
              "gauge",
              "radar",
              "scatter",
              "sparkline"
            ],
            "type": "string",
            "description": "Kind of chart. Chart.js names also work (e.g. \"doughnut\", \"horizontalBar\").",
            "default": "bar"
          },
          "title": {
            "title": "Title",
            "type": "string",
            "description": "Chart title shown at the top left."
          },
          "labels": {
            "title": "Labels (categories / x-axis)",
            "type": "array",
            "description": "One label per data point, e.g. months or product names.",
            "items": {
              "type": "string"
            }
          },
          "data": {
            "title": "Data (single series)",
            "type": "array",
            "description": "Numbers for a single series, e.g. [12, 19, 7]. For scatter use [{\"x\":1,\"y\":2}]. You may also paste a full Chart.js \"data\" object here via the batch list."
          },
          "datasets": {
            "title": "Datasets (multiple series)",
            "type": "array",
            "description": "Several series: [{\"label\": \"2025\", \"data\": [1,2,3], \"color\": \"#2a78d6\"}]. Overrides \"Data\" when filled. Max 8 series per chart."
          },
          "value": {
            "title": "Gauge value",
            "type": "number",
            "description": "Only for gauge charts: the value to display."
          },
          "charts": {
            "title": "Batch of charts",
            "type": "array",
            "description": "Render many charts in one run. Each item is a chart object with the same fields as this form (type, title, labels, data, datasets, value, chartId, plus any styling field to override). Chart.js-style configs ({\"type\":\"bar\",\"data\":{\"labels\":[],\"datasets\":[]}}) are accepted. When this list is filled, the single-chart data fields above are ignored."
          },
          "format": {
            "title": "File format",
            "enum": [
              "png",
              "svg",
              "pdf"
            ],
            "type": "string",
            "description": "PNG for e-mails and chat, SVG for the web (sharp at any size), PDF for printable reports.",
            "default": "png"
          },
          "width": {
            "title": "Width (px)",
            "minimum": 100,
            "maximum": 4000,
            "type": "integer",
            "description": "Chart width in pixels (100–4000).",
            "default": 800
          },
          "height": {
            "title": "Height (px)",
            "minimum": 100,
            "maximum": 4000,
            "type": "integer",
            "description": "Chart height in pixels (100–4000).",
            "default": 400
          },
          "scale": {
            "title": "PNG pixel ratio",
            "minimum": 0.5,
            "maximum": 4,
            "type": "number",
            "description": "Multiply PNG resolution (2 = retina-sharp). Ignored for SVG/PDF.",
            "default": 1
          },
          "theme": {
            "title": "Theme",
            "enum": [
              "light",
              "dark",
              "minimal",
              "corporate"
            ],
            "type": "string",
            "description": "Colors of background, text, grid and default series palette (color-blind-checked).",
            "default": "light"
          },
          "colors": {
            "title": "Series colors",
            "type": "array",
            "description": "Your brand palette, in order (hex or CSS names). Leave empty for the theme palette.",
            "items": {
              "type": "string"
            }
          },
          "backgroundColor": {
            "title": "Background color",
            "type": "string",
            "description": "Hex color, CSS name, or \"transparent\". Empty = theme background."
          },
          "subtitle": {
            "title": "Subtitle",
            "type": "string",
            "description": "Smaller text under the title."
          },
          "xAxisLabel": {
            "title": "X axis label",
            "type": "string",
            "description": "Text under the horizontal axis."
          },
          "yAxisLabel": {
            "title": "Y axis label",
            "type": "string",
            "description": "Text next to the vertical axis."
          },
          "showValues": {
            "title": "Show values on marks",
            "type": "boolean",
            "description": "Print each value on bars / points (percentages on pie charts, on by default there).",
            "default": false
          },
          "showLegend": {
            "title": "Show legend",
            "type": "boolean",
            "description": "Legend is shown when there are 2+ named series, and on pie/doughnut charts.",
            "default": true
          },
          "showGrid": {
            "title": "Show grid lines",
            "type": "boolean",
            "description": "Light horizontal grid lines behind the data.",
            "default": true
          },
          "yMin": {
            "title": "Value axis minimum",
            "type": "number",
            "description": "Force the value axis start (empty = automatic)."
          },
          "yMax": {
            "title": "Value axis maximum",
            "type": "number",
            "description": "Force the value axis end (empty = automatic)."
          },
          "valuePrefix": {
            "title": "Value prefix",
            "type": "string",
            "description": "Added before numbers, e.g. \"$\"."
          },
          "valueSuffix": {
            "title": "Value suffix",
            "type": "string",
            "description": "Added after numbers, e.g. \"%\" or \" kg\"."
          },
          "decimals": {
            "title": "Decimals",
            "minimum": 0,
            "maximum": 6,
            "type": "integer",
            "description": "Fixed number of decimals for value labels (empty = automatic)."
          },
          "fontScale": {
            "title": "Font size multiplier",
            "minimum": 0.5,
            "maximum": 3,
            "type": "number",
            "description": "1 = default; 1.5 for large dashboards or small thumbnails.",
            "default": 1
          },
          "brandText": {
            "title": "Footer / watermark text",
            "type": "string",
            "description": "Small text at the bottom right, e.g. \"Source: ACME analytics\"."
          },
          "logoUrl": {
            "title": "Logo URL",
            "type": "string",
            "description": "Public PNG or JPEG URL (max 5 MB), downloaded once per run. If it fails, the chart is still rendered without logo."
          },
          "logoHeight": {
            "title": "Logo height (px)",
            "minimum": 8,
            "maximum": 400,
            "type": "integer",
            "description": "Logo height in pixels.",
            "default": 40
          },
          "logoPosition": {
            "title": "Logo position",
            "enum": [
              "top-right",
              "top-left",
              "bottom-right",
              "bottom-left"
            ],
            "type": "string",
            "description": "Corner where the logo is placed.",
            "default": "top-right"
          },
          "gaugeMin": {
            "title": "Gauge minimum",
            "type": "number",
            "description": "Gauge start value (default 0)."
          },
          "gaugeMax": {
            "title": "Gauge maximum",
            "type": "number",
            "description": "Gauge end value (default 100)."
          },
          "gaugeThresholds": {
            "title": "Gauge color thresholds",
            "type": "array",
            "description": "Arc color by value: [{\"value\": 0, \"color\": \"critical\"}, {\"value\": 50, \"color\": \"warning\"}, {\"value\": 80, \"color\": \"good\"}]. Colors: good / warning / critical or any hex."
          },
          "centerLabel": {
            "title": "Doughnut center label",
            "type": "string",
            "description": "Text under the total in the doughnut hole (default \"Total\")."
          },
          "includeDataUri": {
            "title": "Include base64 data URI in output",
            "type": "boolean",
            "description": "Adds the image as a data: URI (files up to 1.5 MB) so n8n / Make / Zapier can embed it without a second download.",
            "default": false
          },
          "maxCharts": {
            "title": "Max charts per run",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Safety cap on the batch size (each rendered chart is billed).",
            "default": 1000
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}