File size: 1,504 Bytes
1966985
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
openapi: 3.0.0
info:
  title: Document MCP Graph API
  version: 1.0.0
paths:
  /api/graph:
    get:
      summary: Retrieve graph visualization data
      operationId: getGraphData
      responses:
        '200':
          description: Successful graph data retrieval
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GraphData'
        '500':
          description: Server error
components:
  schemas:
    GraphNode:
      type: object
      required:
        - id
        - label
      properties:
        id:
          type: string
          description: Unique identifier (note path)
        label:
          type: string
          description: Note title
        val:
          type: integer
          default: 1
          description: Node size/weight based on connectivity
        group:
          type: string
          description: Categorical group (e.g. folder)
    GraphLink:
      type: object
      required:
        - source
        - target
      properties:
        source:
          type: string
          description: Source note ID
        target:
          type: string
          description: Target note ID
    GraphData:
      type: object
      required:
        - nodes
        - links
      properties:
        nodes:
          type: array
          items:
            $ref: '#/components/schemas/GraphNode'
        links:
          type: array
          items:
            $ref: '#/components/schemas/GraphLink'