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-1.covia.ai/mcp
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "hitl_respond",
"arguments": {
"input": "your input here"
}
}
}
cURL Example:
curl -X POST https://venue-1.covia.ai/mcp \\
-H "Content-Type: application/json" \\
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "hitl_respond",
"arguments": {
"input": "your input here"
}
}
}'
Python Example:
import requests
import json
url = "https://venue-1.covia.ai/mcp"
payload = {
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "hitl_respond",
"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-1.covia.ai/mcp';
const payload = {
jsonrpc: '2.0',
id: 1,
method: 'tools/call',
params: {
name: 'hitl_respond',
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": "HITL Respond",
"description": "Resolve a HITL request in YOUR OWN h/ inbox: answer it or reject it. Answering completes the requester's Job with your answers; rejecting fails it with your comment as the reason. If the request offered capability grants, echo the ones you approve in 'grants' — the venue issues exactly the intersection of what you echo and what your choices actually triggered (approved approval asks, selected options); echoing anything else fails the response. Answer forms: text → string, approval → boolean, choice → option id, checkboxes → array of option ids.",
"creator": "Covia",
"operation": {
"adapter": "hitl:respond",
"toolName": "hitl_respond",
"input": {
"type": "object",
"properties": {
"id": { "type": "string", "description": "Request id (from your h/ inbox — list with hitl_list or covia_list path=h/)." },
"outcome": { "type": "string", "enum": ["answer", "reject"], "description": "'answer' resolves the request with your answers; 'reject' refuses it." },
"answers": { "type": "object", "description": "Map of ask id → answer, in the form the ask type requires. Required asks must be answered for 'answer'." },
"comments": { "type": "object", "description": "Optional map of ask id → free-text comment." },
"comment": { "type": "string", "description": "Overall comment; for 'reject' this is the rejection reason the requester sees." },
"grants": { "type": "array", "description": "The offered grants you explicitly approve, echoed as {with, can}. Omit to confer nothing.", "items": { "type": "object" } }
},
"required": ["id", "outcome"]
},
"output": {
"type": "object",
"properties": {
"id": { "type": "string" },
"status": { "type": "string", "description": "'answered' or 'rejected'" }
}
}
}
}