Tool Details: agent_session_read

Basic Information

Tool Name:agent_session_read
Asset Name:Read Past Agent Session
Description:Legacy: use agent_history instead. Reads a bounded, model-safe transcript projection. An agent may omit agentId to inspect itself; an owner or authorised caller supplies agentId. Omit sessionId for the newest visible session. Compacted history is retained and can be opened to a bounded depth; a summary is marked compacted, with the turns it stands for. Set current to read back the session you are in: after a compaction, the turns your summary stands for, when you need their exact words; a summary names its turns, so pass them as from and to. Page back with skip while older is true. Otherwise the caller's current session, missing sessions and sessions hidden by venue policy all return exactly {found:false}. Tool scratch, diagnostics and unanswered turns are omitted.
Adapter:agent
Asset Hash:0x880956b77d8f3dcceb3a3fbb732e8f544dd5810903cf65d90310fc95ac3c7f53
Input
PropertyTypeDescription
currentbooleanRead the session you are in, from your own execution context: only what is no longer in your context, the turns behind its compaction summaries. Omit sessionId and agentId. Empty when the session was never compacted.
skipintegerNewest projected messages to pass over, to page further back. Default 0.
maxTurnsintegerMaximum newest projected turns. Default 20.
sessionIdstringOptional 16-byte hex session id, with or without a 0x prefix. Omit to read the newest visible session.
fromintegerWith current: the first of the turns a compaction summary names ("Compacted: turns 1020–1075" is from 1020 to 1075), to read exactly those turns. A summary among them names its own turns, read the same way.
tointegerWith current and from: the last turn to read, included.
maxCharsintegerMaximum total content characters. A single oversized turn is truncated. Default 8000.
archiveDepthintegerCompacted archive levels to open before applying the safe bounded projection. Default 0 returns compacted summaries only.
agentIdstringOptional target agent: an id, g/<id>, <ownerDID>/g/<id>, or the agent's DID <ownerDID>:g:<id>. Omit only from that agent's own execution context. Reading an explicit target requires agent read access.
Output
PropertyTypeDescription
messagesarray-
createdinteger-
updatedinteger-
olderbooleanOlder messages remain before this page: read them with a larger skip.
titlestring-
sessionIdstring-
currentbooleanTrue when this is the caller's own current session, read with current.
turnCountintegerTotal turns in the safe projection, before response bounds.
truncatedboolean-
found*boolean-

MCP Tool Usage Examples

This tool can be called via the MCP (Model Context Protocol) endpoint. Here are examples of how to use it:

JSON-RPC Call Example:

POST to https://venue-3.covia.ai/mcp

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "agent_session_read",
    "arguments": {
      "input": "your input here"
    }
  }
}
cURL Example:
curl -X POST https://venue-3.covia.ai/mcp \\
  -H "Content-Type: application/json" \\
  -d '{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "tools/call",
    "params": {
      "name": "agent_session_read",
      "arguments": {
        "input": "your input here"
      }
    }
  }'
Python Example:
import requests
import json

url = "https://venue-3.covia.ai/mcp"
payload = {
    "jsonrpc": "2.0",
    "id": 1,
    "method": "tools/call",
    "params": {
        "name": "agent_session_read",
        "arguments": {
            "input": "your input here"
        }
    }
}

response = requests.post(url, json=payload)
result = response.json()
print(result)
JavaScript/Node.js Example:
const fetch = require('node-fetch');

const url = 'https://venue-3.covia.ai/mcp';
const payload = {
    jsonrpc: '2.0',
    id: 1,
    method: 'tools/call',
    params: {
        name: 'agent_session_read',
        arguments: {
            input: 'your input here'
        }
    }
};

fetch(url, {
    method: 'POST',
    headers: {
        'Content-Type': 'application/json'
    },
    body: JSON.stringify(payload)
})
.then(response => response.json())
.then(data => console.log(data));

Asset Metadata

{
	"name": "Read Past Agent Session",
	"description": "Legacy: use agent_history instead. Reads a bounded, model-safe transcript projection. An agent may omit agentId to inspect itself; an owner or authorised caller supplies agentId. Omit sessionId for the newest visible session. Compacted history is retained and can be opened to a bounded depth; a summary is marked compacted, with the turns it stands for. Set current to read back the session you are in: after a compaction, the turns your summary stands for, when you need their exact words; a summary names its turns, so pass them as from and to. Page back with skip while older is true. Otherwise the caller's current session, missing sessions and sessions hidden by venue policy all return exactly {found:false}. Tool scratch, diagnostics and unanswered turns are omitted.",
	"dateCreated": "2026-08-24T00:00:00Z",
	"operation": {
		"adapter": "agent:sessionRead",
		"readOnly": true,
		"toolName": "agent_session_read",
		"default": {
			"maxTurns": 20,
			"maxChars": 8000
		},
		"input": {
			"type": "object",
			"properties": {
				"agentId": { "type": "string", "description": "Optional target agent: an id, g/<id>, <ownerDID>/g/<id>, or the agent's DID <ownerDID>:g:<id>. Omit only from that agent's own execution context. Reading an explicit target requires agent read access." },
				"sessionId": { "type": "string", "description": "Optional 16-byte hex session id, with or without a 0x prefix. Omit to read the newest visible session." },
				"maxTurns": { "type": "integer", "minimum": 1, "maximum": 100, "description": "Maximum newest projected turns. Default 20." },
				"maxChars": { "type": "integer", "minimum": 1, "maximum": 100000, "description": "Maximum total content characters. A single oversized turn is truncated. Default 8000." },
				"archiveDepth": { "type": "integer", "minimum": 0, "maximum": 8, "description": "Compacted archive levels to open before applying the safe bounded projection. Default 0 returns compacted summaries only." },
				"skip": { "type": "integer", "minimum": 0, "description": "Newest projected messages to pass over, to page further back. Default 0." },
				"from": { "type": "integer", "minimum": 0, "description": "With current: the first of the turns a compaction summary names (\"Compacted: turns 1020–1075\" is from 1020 to 1075), to read exactly those turns. A summary among them names its own turns, read the same way." },
				"to": { "type": "integer", "minimum": 0, "description": "With current and from: the last turn to read, included." },
				"current": { "type": "boolean", "description": "Read the session you are in, from your own execution context: only what is no longer in your context, the turns behind its compaction summaries. Omit sessionId and agentId. Empty when the session was never compacted." }
			}
		},
		"output": {
			"type": "object",
			"required": ["found"],
			"properties": {
				"found": { "type": "boolean" },
				"sessionId": { "type": "string" },
				"title": { "type": "string" },
				"created": { "type": "integer" },
				"updated": { "type": "integer" },
				"turnCount": { "type": "integer", "description": "Total turns in the safe projection, before response bounds." },
				"messages": { "type": "array", "items": { "type": "object" } },
				"truncated": { "type": "boolean" },
				"older": { "type": "boolean", "description": "Older messages remain before this page: read them with a larger skip." },
				"current": { "type": "boolean", "description": "True when this is the caller's own current session, read with current." }
			}
		}
	}
}

Navigation

Back to adapter details

Back to all adapters

Back to index