> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mosaic.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Agent

> Retrieve an agent template, agent nodes, and graph connections.

Returns the saved agent template with agent node instances (including embedded `node_type`) and connections.

## Request

```bash theme={null}
curl -X GET "https://api.mosaic.so/agent/[agent_id]" \
  -H "Authorization: Bearer mk_your_api_key"
```

## Response

```json theme={null}
{
  "agent": {
    "id": "123e4567-e89b-12d3-a456-789012345678",
    "name": "My Agent",
    "description": "",
    "visibility": "private",
    "created_at": "2026-03-01T12:00:00Z",
    "updated_at": "2026-03-02T08:00:00Z"
  },
  "agent_nodes": [
    {
      "agent_node_id": "bf750792-a2e9-48c2-9d39-24f892772f6a",
      "node_type": {
        "node_type_id": "3b281fb9-9eb2-40f6-b05b-4b6f909a3da9",
        "node_type_name": "AI Music",
        "docs_url": "https://docs.mosaic.so/tiles/ai-music",
        "params_docs_url": "https://docs.mosaic.so/tiles/ai-music#api-info"
      },
      "params_used": {
        "use_intelligent_analysis": true,
        "genre": "Cinematic"
      }
    },
    {
      "agent_node_id": "a1c2d3e4-5678-90ab-cdef-1234567890ab",
      "node_type": {
        "node_type_id": "ea1b2c3d-4e5f-6789-0abc-def123456789",
        "node_type_name": "Captions",
        "docs_url": "https://docs.mosaic.so/tiles/captions",
        "params_docs_url": "https://docs.mosaic.so/tiles/captions#api-info"
      },
      "params_used": {
        "caption_font": "Montserrat"
      }
    }
  ],
  "connections": [
    {
      "source_agent_node_id": "bf750792-a2e9-48c2-9d39-24f892772f6a",
      "target_agent_node_id": "a1c2d3e4-5678-90ab-cdef-1234567890ab"
    }
  ]
}
```

## Response Fields

| Field                                     | Type           | Description                                                                                           |
| ----------------------------------------- | -------------- | ----------------------------------------------------------------------------------------------------- |
| `agent.id`                                | string         | Agent ID.                                                                                             |
| `agent.name`                              | string         | Agent display name.                                                                                   |
| `agent.description`                       | string         | Agent description.                                                                                    |
| `agent.visibility`                        | string \| null | Visibility setting (`public` or `private`).                                                           |
| `agent.created_at`                        | string         | ISO timestamp.                                                                                        |
| `agent.updated_at`                        | string         | ISO timestamp.                                                                                        |
| `agent_nodes[].agent_node_id`             | string         | Agent node instance ID. Use this in `operations[].agent_node_id` for `update_node` and `delete_node`. |
| `agent_nodes[].node_type.node_type_id`    | string         | Node type ID for this agent node.                                                                     |
| `agent_nodes[].node_type.node_type_name`  | string \| null | Node type display name for this agent node.                                                           |
| `agent_nodes[].node_type.docs_url`        | string \| null | Canonical docs page URL (from `nodes.docs_path`).                                                     |
| `agent_nodes[].node_type.params_docs_url` | string \| null | Exact params/API section URL (from `nodes.docs_anchor`).                                              |
| `agent_nodes[].params_used`               | object         | Current parameter configuration for this node instance.                                               |
| `connections[]`                           | array          | Directed edges between `agent_node_id` values in this agent graph.                                    |
