# pub.chive.graph.getNode

> Published by [chive.pub](https://lexicon.garden/identity/did:plc:7natp5xae72bddaqlkef2t4e)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.graph.getNode)
- [Documentation](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.graph.getNode/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.graph.getNode/examples)

## Definitions

### `pub.chive.graph.getNode`

**Type**: `query`

Retrieve a unified knowledge graph node by ID

#### Parameters

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `id` | `string` | Yes | Node ID (UUID or rkey) |
| `includeEdges` | `boolean` | No | Include connected edges in the response |

#### Output

**Encoding**: `application/json`

#### Errors

- **NotFound**

### `pub.chive.graph.getNode#graphEdge`

**Type**: `object`

Graph edge response

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `id` | `string` | Yes | Edge UUID identifier |
| `cid` | `string` | No | Content identifier |
| `uri` | `string` (at-uri) | Yes | AT-URI of the edge |
| `status` | `string` | Yes | Edge lifecycle status |
| `weight` | `integer` | No | Edge weight (scaled by 1000 for 0.0-1.0 range) |
| `metadata` | `ref` → `pub.chive.graph.edge#edgeMetadata` | No | Edge-specific metadata |
| `createdAt` | `string` (datetime) | Yes | Creation timestamp |
| `createdBy` | `string` (did) | No | DID of creator |
| `sourceUri` | `string` (at-uri) | Yes | AT-URI of source node |
| `targetUri` | `string` (at-uri) | Yes | AT-URI of target node |
| `updatedAt` | `string` (datetime) | No | Last update timestamp |
| `proposalUri` | `string` (at-uri) | No | AT-URI of creating proposal |
| `relationUri` | `string` (at-uri) | No | AT-URI of relation type node |
| `relationSlug` | `string` | Yes | Relation slug (broader, narrower, related, etc.) |

### `pub.chive.graph.getNode#nodeWithEdges`

**Type**: `object`

Graph node with optional connected edges

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `id` | `string` | Yes | Node UUID identifier |
| `cid` | `string` | No | Content identifier |
| `uri` | `string` (at-uri) | Yes | AT-URI of the node |
| `kind` | `string` | Yes | Node kind: type or object |
| `edges` | `array` | No | Connected edges (when includeEdges=true) |
| `label` | `string` | Yes | Primary display label |
| `status` | `string` | Yes | Lifecycle status |
| `subkind` | `string` | No | Subkind slug (e.g., field, institution) |
| `metadata` | `ref` → `pub.chive.graph.node#nodeMetadata` | No | Subkind-specific metadata |
| `createdAt` | `string` (datetime) | Yes | Creation timestamp |
| `createdBy` | `string` (did) | No | DID of creator |
| `updatedAt` | `string` (datetime) | No | Last update timestamp |
| `subkindUri` | `string` (at-uri) | No | AT-URI of the subkind type node |
| `description` | `string` | No | Detailed description |
| `externalIds` | `array` | No | External identifier mappings |
| `proposalUri` | `string` (at-uri) | No | AT-URI of creating proposal |
| `deprecatedBy` | `string` (at-uri) | No | AT-URI of superseding node |
| `alternateLabels` | `array` | No | Alternate labels/synonyms |

## Raw Schema

```json
{
  "id": "pub.chive.graph.getNode",
  "defs": {
    "main": {
      "type": "query",
      "errors": [
        {
          "name": "NotFound"
        }
      ],
      "output": {
        "schema": {
          "ref": "#nodeWithEdges",
          "type": "ref"
        },
        "encoding": "application/json"
      },
      "parameters": {
        "type": "params",
        "required": [
          "id"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "Node ID (UUID or rkey)"
          },
          "includeEdges": {
            "type": "boolean",
            "default": false,
            "description": "Include connected edges in the response"
          }
        }
      },
      "description": "Retrieve a unified knowledge graph node by ID"
    },
    "graphEdge": {
      "type": "object",
      "required": [
        "id",
        "uri",
        "sourceUri",
        "targetUri",
        "relationSlug",
        "status",
        "createdAt"
      ],
      "properties": {
        "id": {
          "type": "string",
          "description": "Edge UUID identifier"
        },
        "cid": {
          "type": "string",
          "description": "Content identifier"
        },
        "uri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of the edge"
        },
        "status": {
          "type": "string",
          "description": "Edge lifecycle status",
          "knownValues": [
            "proposed",
            "established",
            "deprecated"
          ]
        },
        "weight": {
          "type": "integer",
          "maximum": 1000,
          "minimum": 0,
          "description": "Edge weight (scaled by 1000 for 0.0-1.0 range)"
        },
        "metadata": {
          "ref": "pub.chive.graph.edge#edgeMetadata",
          "type": "ref",
          "description": "Edge-specific metadata"
        },
        "createdAt": {
          "type": "string",
          "format": "datetime",
          "description": "Creation timestamp"
        },
        "createdBy": {
          "type": "string",
          "format": "did",
          "description": "DID of creator"
        },
        "sourceUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of source node"
        },
        "targetUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of target node"
        },
        "updatedAt": {
          "type": "string",
          "format": "datetime",
          "description": "Last update timestamp"
        },
        "proposalUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of creating proposal"
        },
        "relationUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of relation type node"
        },
        "relationSlug": {
          "type": "string",
          "description": "Relation slug (broader, narrower, related, etc.)"
        }
      },
      "description": "Graph edge response"
    },
    "nodeWithEdges": {
      "type": "object",
      "required": [
        "id",
        "uri",
        "kind",
        "label",
        "status",
        "createdAt"
      ],
      "properties": {
        "id": {
          "type": "string",
          "description": "Node UUID identifier"
        },
        "cid": {
          "type": "string",
          "description": "Content identifier"
        },
        "uri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of the node"
        },
        "kind": {
          "type": "string",
          "description": "Node kind: type or object",
          "knownValues": [
            "type",
            "object"
          ]
        },
        "edges": {
          "type": "array",
          "items": {
            "ref": "#graphEdge",
            "type": "ref"
          },
          "description": "Connected edges (when includeEdges=true)"
        },
        "label": {
          "type": "string",
          "description": "Primary display label"
        },
        "status": {
          "type": "string",
          "description": "Lifecycle status",
          "knownValues": [
            "proposed",
            "provisional",
            "established",
            "deprecated"
          ]
        },
        "subkind": {
          "type": "string",
          "description": "Subkind slug (e.g., field, institution)"
        },
        "metadata": {
          "ref": "pub.chive.graph.node#nodeMetadata",
          "type": "ref",
          "description": "Subkind-specific metadata"
        },
        "createdAt": {
          "type": "string",
          "format": "datetime",
          "description": "Creation timestamp"
        },
        "createdBy": {
          "type": "string",
          "format": "did",
          "description": "DID of creator"
        },
        "updatedAt": {
          "type": "string",
          "format": "datetime",
          "description": "Last update timestamp"
        },
        "subkindUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of the subkind type node"
        },
        "description": {
          "type": "string",
          "description": "Detailed description"
        },
        "externalIds": {
          "type": "array",
          "items": {
            "ref": "pub.chive.graph.node#externalId",
            "type": "ref"
          },
          "description": "External identifier mappings"
        },
        "proposalUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of creating proposal"
        },
        "deprecatedBy": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of superseding node"
        },
        "alternateLabels": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Alternate labels/synonyms"
        }
      },
      "description": "Graph node with optional connected edges"
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1,
  "revision": 1
}
```
