Skip to content

Ask AI

Coming soon — ask questions about these docs in natural language.

Until then, use ⌘K to search the full docs set.

MCP Tools

MCP tool reference, code samples, and example workflows.

ToolDescription
parse_casParse a CAS PDF and return structured holdings and metadata.
enrichAdd returns and benchmark overlays to holdings.
request_upload_urlCreate a browser-upload session for file handoff.
compare_snapshotsCompare two portfolio snapshots.
generate_reportExport a snapshot as JSON or CSV.
list_skillsList available analysis skills (structured workflows with reasoning).
run_skillRun an analysis skill against a parsed snapshot — returns flagged holdings with severity and reasoning.

Skills are higher-order analysis workflows that chain tools and apply domain-specific evaluation criteria. Unlike raw tools, skills produce structured reports with severity ratings and plain-English reasoning. See the Skills page for details, available skills, and usage examples.

User asks an agent to parse a CAS and summarize the portfolio.
1. parse_cas → get snapshot_id and holdings
2. enrich → attach market context
3. agent summarizes current value, diversification, and available next actions
const fs = require('fs');
async function parseCAS(filePath, password) {
const pdfBase64 = fs.readFileSync(filePath).toString('base64');
const res = await fetch('https://api.portfoliointel.co.in/api/v1/parse', {
method: 'POST',
headers: {
Authorization: 'Bearer sk_live_YOUR_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({ pdf_base64: pdfBase64, password }),
});
const body = await res.json();
if (!body.success) throw new Error(body.error.message);
return body.data;
}
import base64
import requests
def parse_cas(file_path: str, password: str | None = None) -> dict:
with open(file_path, 'rb') as handle:
pdf_base64 = base64.b64encode(handle.read()).decode()
resp = requests.post(
'https://api.portfoliointel.co.in/api/v1/parse',
headers={'Authorization': 'Bearer sk_live_YOUR_KEY'},
json={'pdf_base64': pdf_base64, 'password': password},
)
resp.raise_for_status()
return resp.json()['data']
Terminal window
curl -X POST https://api.portfoliointel.co.in/api/v1/parse \
-H "Authorization: Bearer sk_test_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"pdf_ref":"sample_cams_2024"}'