create_edge
Create a directed edge between two existing nodes, specifying the relationship type and optional properties.
Instructions
Create a directed edge (relationship) between two existing nodes.
Use this tool when: you need to connect two nodes with a typed relationship. Do NOT use this for: creating nodes (use create_node) or querying relationships (use execute_gql).
Args: source_id: The source node ID (integer). target_id: The target node ID (integer). edge_type: Relationship type string (e.g. "KNOWS", "WORKS_AT"). properties: Optional edge properties (e.g. {"since": 2020, "weight": 1.5}).
Returns: JSON with the created edge's id, source_id, target_id, edge_type, and properties.
Examples: create_edge(1, 2, "KNOWS") create_edge(1, 3, "WORKS_AT", {"since": 2020})
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| source_id | Yes | ||
| target_id | Yes | ||
| edge_type | Yes | ||
| properties | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |