Zindex Account API

One download of every diagram in the workspace with its whole history

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 2

GET /v1/workspace/export Download every diagram in the workspace with its whole history #
GET /v1/account/export Download every diagram in the workspace (same as /v1/workspace/export) #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/zindex-ai:zindex-ai-account-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

zindex-ai-account-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Zindex Account API
  description: 'Immutable diagrams for AI agents. Agents save diagrams to Zindex as structured scenes in the Diagram Scene Protocol (DSP), with stable element IDs, and change them with typed operations. Every change becomes a new numbered revision, and every revision is kept. Agents can read any revision by number or by date and diff any two. Zindex validates scenes, computes layout, and renders to SVG or PNG. No model runs inside Zindex. Validation, layout and rendering are deterministic code. ## Recommended Agent Workflow


    1. **Save** - `POST /v1/diagrams` with a DSP scene document, or Mermaid, and your own `key`. Returns the diagram''s ID and revision 1. 2. **Change incrementally** - `POST /v1/diagrams/{id}/revisions` with `baseRevision` and operations (or edited Mermaid). An edit that changes the diagram makes the next immutable revision; one that changes nothing returns `noop`. An edit whose operations fail, or whose revision would break a rule the diagram didn''t break, saves nothing. Every save returns `warnings` for the revision it made: the diagram family''s rules it breaks, what drawing it noticed, and notes on what an edit changed besides what its operations named. 3. **Render** - `GET /v1/images/{id}@{revision}.svg` (or `.png`) for one version''s image. The first REST version, `/v1/scenes`, is retired: every path answers 410 with `code: "MOVED"` and the `method` and `path` that replace it. This persistence-first workflow gives you revision history, incremental editing without regenerating the full scene, and visual diff between revisions - so agents edit one diagram over time instead of regenerating it from scratch on every prompt. ## Worked Examples


    Worked examples ship at https://zindex.ai/examples/ (er-diagram-from-migrations, pr-architecture-diff, aws-architecture-from-terraform, gcp-architecture-from-terraform, deploy-pipeline-from-github-actions, compliance-pii-flow, multi-agent-workflow, api-dependency-map, living-architecture-docs, layered-architecture-from-codebase, public-interfaces-for-security-review, request-flow-from-handler). Every example exposes `/examples/.scene.json` (canonical scene), `.ops.json` (typed-op envelope), `.workflow.json` (agent recipe), `.diff.json` (sample revision diff), `.svg` (rendered), and `.md` (markdown summary) - fetch directly. Showcase examples (er-diagram-from-migrations, pr-architecture-diff, aws-architecture-from-terraform, gcp-architecture-from-terraform, deploy-pipeline-from-github-actions, public-interfaces-for-security-review, request-flow-from-handler) additionally expose `.before.svg` for the revision diff''s before picture. The manifest at https://zindex.ai/examples/index.json lists them for programmatic discovery. ## Auto-Layout


    Auto-layout is the default: omit `layout` from nodes and the engine computes node positions, edge routing, and label placement. `diagramFamily` decides how it places nodes, and the optional `layoutStrategy` sets the direction and spacing of the layered layout that architecture, flowchart, workflow, entityRelationship and uiflow diagrams use. Put `diagramFamily`, `layoutStrategy` and `palette` at the scene-document root (alongside `schemaVersion`, `scene`, `elements` - NOT nested inside `scene.scene`). Nested inside `scene.scene`, they are moved to the root before the scene is checked, and stored there. Nodes keep their positions after the first save unless one of these applies, and the edit''s `changed.moved` lists each node that only moves or is saved at a new size:

    - A node that grows pushes the nodes in its way. - A new node whose edge label needs more room than the column it joins pushes that column along the flow too. - A node an edit inserts in a flowchart, between two placed nodes, goes on the first one''s line, and what lies past it moves along the flow. A new node on a decision''s no exit goes beside the decision instead. In a flowchart with a frame that has no `layout`, new nodes are placed as in other families.'
  version: 10.6.0+build.5202
  contact:
    name: Zindex
    url: https://zindex.ai
servers:
- url: https://api.zindex.ai
  description: Production
tags:
- name: Account
  description: One download of every diagram in the workspace with its whole history
paths:
  /v1/workspace/export:
    get:
      tags:
      - Account
      summary: Download every diagram in the workspace with its whole history
      operationId: exportWorkspace
      description: 'Every diagram in the workspace the request acts in, with its whole history, in one JSON Lines file in the zindex-account-history/1 format. The first line is { format: "zindex-account-history/1", workspace: { id, name, kind }, exportedAt }, where kind is personal or team. Each diagram follows in ID order, exactly as GET /v1/diagrams/{id}/export writes it: a header line ({ format: "zindex-history/1", chain, id, key, title, revisions, note?, exportedAt }), then one line per version, oldest first. A line whose format is "zindex-history/1" starts the next diagram. The last line is { end: true, diagrams }, the number of diagrams in the file; a file without it was cut short. Deleted diagrams are left out, even while they can be restored. Each diagram''s lines check on their own, like a diagram''s export: https://zindex.ai/docs/concepts/#checking-an-export. A read key works too. In a team workspace only an owner can download it (403 OWNER_REQUIRED); everyone in it can still download one diagram''s history at GET /v1/diagrams/{id}/export. The file is sent as a download (Content-Disposition: attachment), a line at a time as Zindex writes it.'
      responses:
        '200':
          description: The workspace's diagrams as JSON Lines
          content:
            application/x-ndjson:
              schema:
                type: string
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: 'OWNER_REQUIRED: a team workspace''s export is for its owners'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DiagramError'
        '429':
          $ref: '#/components/responses/RateLimited'
      security:
      - bearerAuth: []
      - apiKeyHeader: []
  /v1/account/export:
    get:
      tags:
      - Account
      summary: Download every diagram in the workspace (same as /v1/workspace/export)
      operationId: exportAccount
      description: 'The same download as GET /v1/workspace/export, with the same format and rules: every diagram in the workspace the request acts in, with its whole history.'
      responses:
        '200':
          description: The workspace's diagrams as JSON Lines
          content:
            application/x-ndjson:
              schema:
                type: string
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: 'OWNER_REQUIRED: a team workspace''s export is for its owners'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DiagramError'
        '429':
          $ref: '#/components/responses/RateLimited'
      security:
      - bearerAuth: []
      - apiKeyHeader: []
components:
  schemas:
    FeedbackPreview:
      type: object
      description: A feedback item exactly as Zindex staff will see it
      properties:
        kind:
          type: string
          enum:
          - bug
          - docs
          - request
          - other
        summary:
          type: string
        expected:
          type:
          - string
          - 'null'
        observed:
          type:
          - string
          - 'null'
        confidence:
          type:
          - string
          - 'null'
          enum:
          - seen
          - likely
          - unsure
          - null
        engine:
          type: string
          description: The Zindex build that took the item
        client:
          type:
          - string
          - 'null'
          description: The app that sent it, or dashboard
        diagram:
          description: The attached diagram version, or null
          oneOf:
          - type: object
            required:
            - id
            - revision
            properties:
              id:
                type: string
              revision:
                type: integer
                minimum: 1
          - type: 'null'
        anonymized:
          type:
          - boolean
          - 'null'
          description: Whether the attached document is anonymized; null with nothing attached
        snippet:
          description: 'The attached document as staff see it: a scene object or Mermaid text; null with nothing attached'
    DiagramError:
      type: object
      properties:
        error:
          type: string
        code:
          type: string
          description: 'INVALID_REQUEST, CONFIRMATION_REQUIRED (400); AUTH_REQUIRED, API_KEY_INVALID, API_KEY_REVOKED, API_KEY_EXPIRED (401); LIMIT_REACHED, FEATURE_UNAVAILABLE, EMAIL_NOT_VERIFIED, LINK_INVALID, READ_ONLY, SHARING_DISABLED, OWNER_REQUIRED, SESSION_REQUIRED (403); NOT_FOUND (404; also a path with no endpoint), NO_REVISION_AS_OF (404); KEY_EXISTS, REVISION_CONFLICT, STORAGE_HOLD, and INVALID_REQUEST from PUT sharing (409); MOVED (410, /v1/scenes); INPUT_TOO_LARGE (413); VALIDATION_FAILED, REQUEST_ID_REUSED, PARSE_ERROR, UNSUPPORTED_DIAGRAM_TYPE, IMPORT_TIMEOUT, IMPORT_FAILED, MERMAID_FAMILY_MISMATCH, DRAW_TIMEOUT (422); RATE_LIMITED (429: a rate limit, or feedback); INTERNAL_ERROR (500); UNSUPPORTED (501); UNAVAILABLE, BUSY, STORAGE_UNAVAILABLE (503). STORAGE_UNAVAILABLE and STORAGE_HOLD come only from a workspace that keeps its diagrams in its own GitHub repository, with bring your own storage (https://zindex.ai/docs/storage/); Zindex''s own storage, the default, never answers them.'
        errors:
          type: array
          items:
            $ref: '#/components/schemas/DiagramWarning'
          description: 'With VALIDATION_FAILED: each problem, with a code, the element when there is one, and a one-line fix. The codes: https://zindex.ai/docs/reference/validation-rules/'
        revision:
          type: integer
          description: 'With REVISION_CONFLICT: the current revision. With KEY_EXISTS: the existing diagram''s revision'
        changes:
          type: string
          description: 'With REVISION_CONFLICT: what changed since baseRevision, one element per line, then, when any element only moved, one moved: line naming them'
        id:
          type: string
          description: 'With KEY_EXISTS: the diagram that holds the key'
        method:
          type: string
          description: 'With MOVED: the method of the request to send instead'
        path:
          type: string
          description: 'With MOVED: the path of the request to send instead'
        limit:
          type: string
          enum:
          - scenes
          - updatesPerMonth
          - rendersPerMonth
          description: 'With LIMIT_REACHED: which plan limit'
        maximum:
          type: integer
          description: 'With LIMIT_REACHED: the workspace''s limit'
        current:
          type: integer
          description: 'With LIMIT_REACHED: the workspace''s count now'
        feature:
          type: string
          enum:
          - privateShareLinks
          - longShareLinks
          description: 'With FEATURE_UNAVAILABLE: the feature the workspace''s plan doesn''t include. privateShareLinks: links to the latest version or to every version. longShareLinks: links that end later than maxDays days away, or never'
        maxDays:
          type: integer
          description: 'With FEATURE_UNAVAILABLE and longShareLinks: the latest end date allowed, in days after today (UTC)'
        reason:
          type: string
          enum:
          - credential
          - role
          - installation_missing
          - installation_suspended
          - repository_missing
          - repository_public
          - branch_missing
          - push_refused
          - external_change
          - credentials
          - disconnected
          description: 'With READ_ONLY: `credential` when the key or connected app can only read, `role` when the person is a viewer in the workspace. With STORAGE_HOLD: why a workspace owner is needed, one of installation_missing, installation_suspended, repository_missing, repository_public (the repository was made public; the hold lifts once it is private or internal), branch_missing, push_refused, credentials, external_change (the storage changed outside Zindex) or disconnected (an owner disconnected the workspace''s storage; saves resume when it is reconnected or the diagrams are moved back)'
        line:
          type: integer
          description: 'With PARSE_ERROR, when Mermaid names a place: the line of the Mermaid text sent where the parser stopped, counted from 1'
        column:
          type: integer
          description: 'With PARSE_ERROR, when Mermaid names one: the column on that line, counted from 0. The sentence in `error` counts it from 1'
        retryAfter:
          type: integer
          description: 'With RATE_LIMITED: the seconds until the next feedback item can go. With BUSY: the seconds to wait before trying again, half the budget of the drawing refused. With STORAGE_UNAVAILABLE: the seconds to wait before trying again, also sent as the Retry-After header'
        detail:
          type: string
          description: 'With STORAGE_UNAVAILABLE and STORAGE_HOLD: what the workspace''s storage answered, naming the cause'
        confirm:
          type: string
          description: 'With CONFIRMATION_REQUIRED from POST /v1/feedback: the token to send the item with, once the person agrees'
        preview:
          $ref: '#/components/schemas/FeedbackPreview'
          description: 'With CONFIRMATION_REQUIRED from POST /v1/feedback: the item as staff will see it'
      required:
      - error
      - code
    DiagramWarning:
      type: object
      properties:
        code:
          type: string
          description: The warning's code
        element:
          type: string
          description: The element it concerns, when there is one
        fix:
          type: string
          description: One line on what to change
      required:
      - code
      - fix
      description: 'A problem that doesn''t block a save: a rule of the scene or its diagram family, what laying out and drawing it noticed (TEXT_OVERFLOW, ICON_NOT_FOUND, NODE_OVERLAP_DETECTED, NODE_OUTSIDE_FRAME, FRAME_OVERLAP_DETECTED, NODE_IN_WRONG_FRAME, LABEL_DUPLICATION_DETECTED, EDGE_CROSSES_NODE, SPAN_COVERS_NODE, CHARACTER_NOT_DRAWN), a note from converting Mermaid, a note on a field it dropped from what it was sent (PORTS_REMOVED), or a note on what a deleteElement changed besides the element it named: a constraint it removed (CONSTRAINT_REMOVED), an element placed relative to the deleted one (RELATIVE_LAYOUT_FIXED), a spanning frame it left spanning nothing and removed (SPAN_REMOVED), or a sequence diagram''s operand or activation bar it left with nothing and removed (FRAGMENT_OPERAND_REMOVED, ACTIVATION_REMOVED; a move with after or before can remove an operand too). Or a plan limit near at hand (LIMIT_NEAR: fix gives the count, the limit and what stops there). Other changes an edit makes on its own get no note; changed lists every element it added, updated or removed, and every element it only moved or resized. At most 10 per response. Every other code: https://zindex.ai/docs/reference/validation-rules/'
  responses:
    RateLimited:
      description: 'RATE_LIMITED: over the request rate limit (see Rate Limiting). Wait retryAfter seconds (also the Retry-After header), then try again.'
      headers:
        Retry-After:
          description: Seconds until the rate limit resets
          schema:
            type: integer
        X-RateLimit-Remaining:
          description: Requests remaining in the current window
          schema:
            type: integer
        X-RateLimit-Reset:
          description: Unix timestamp when the limit resets
          schema:
            type: integer
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
              code:
                type: string
                enum:
                - RATE_LIMITED
              retryAfter:
                type: integer
                description: Seconds to wait, as in Retry-After
            required:
            - error
            - code
            - retryAfter
    Unauthorized:
      description: 'Missing or invalid API key. Response includes a `code` field that distinguishes the failure mode so clients (dashboard, MCP server) can render actionable copy: `AUTH_REQUIRED` (no key or session was sent), `API_KEY_INVALID` (key not found), `API_KEY_REVOKED` (key was revoked, or its person is no longer in its workspace), `API_KEY_EXPIRED` (key passed its expires_at), and for the site''s session cookie `SESSION_EXPIRED` (past its 24 hours), `SESSION_REVOKED` (the account''s sessions were ended, for example by a password reset) and `SESSION_INVALID` (not a session this server signed).'
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                description: Human-readable error message.
              code:
                type: string
                enum:
                - AUTH_REQUIRED
                - API_KEY_INVALID
                - API_KEY_REVOKED
                - API_KEY_EXPIRED
                - SESSION_EXPIRED
                - SESSION_REVOKED
                - SESSION_INVALID
                description: Machine-readable failure reason. Clients should branch on this rather than parsing `error`.
            required:
            - error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'API key as Bearer token: `Authorization: Bearer dsp_sk_...`'
    apiKeyHeader:
      type: apiKey
      in: header
      name: X-API-Key
      description: 'API key via header: `X-API-Key: dsp_sk_...`'