X6 v3 Graph Editor
Overview
X6 v3 is AntV's diagram editing engine for flowcharts, DAGs, ER diagrams, org charts, and other interactive node-edge editors. Unlike G2/G6, X6 uses an imperative API — you create a Graph instance, then call graph.addNode(), graph.addEdge(), and register plugins via graph.use().
CDN Usage
Content Retrieval Service
When using AntV X6 for data visualization, if you need to understand the concepts, usage, API, examples, and other aspects of X6 v3, you can use the provided context retrieval service. When using the skill, content is retrieved via an antv HTTP API server using GET requests.
- Host:
https://sive.antv.antgroup.com - Endpoint:
/api/v1/context/retrieve - Method:
GET - Parameters:
query,library,topK,content,maxTokens
Retrieve skills by query (hybrid search = FTS + vector + RRF fusion). Constraints docs are indexed as regular skill documents and will appear in search results naturally.
Critical Rules
MUST: graph.render() does NOT exist in X6 v3
MUST: Use string literal container: 'container' — no variable declaration
MUST: Register plugins before using their methods
MUST: Only 11 plugin classes exist — NOT constructor options
MUST: All used classes MUST appear in import statement
MUST: Always call graph.centerContent() after adding nodes/edges
MUST: Always set background color, default node/edge style
MUST: mousewheel, panning, Selection.rubberband — use modifiers to avoid conflicts
MUST: Output pure JavaScript — NO TypeScript syntax
MUST: Shape.HTML.register for HTML nodes — NOT class extends Node
Quick Reference
Dependencies
@antv/x6— X6 v3 diagram editing engine (exportsGraph+ 11 plugin classes)


