Appearance
Within SDK
Capture privacy-safe MCP activity, understand agent workflows, and identify SDK leads.
The within-sdk package adds workflow intelligence to vendor-owned MCP servers. It tracks MCP activity, redacts sensitive data, and reports pseudonymous workflow signals to Within without changing MCP client behavior.
Non-invasive by defaultNo auth ownership, no quota enforcement, and no client-facing UX changes.
MCP-native captureCaptures meaningful lifecycle, catalog, tool activity, result status, duration, and runtime metadata.
Privacy-first identityHashes vendor-provided user IDs locally and removes raw names, identity fields, and secrets before send.
Get started
- Create a Within dashboard account and verify your email.
- Create a vendor and generate its SDK API key.
- Install and configure the SDK in the server process that owns your MCP server.
bash
npm install within-sdk @modelcontextprotocol/sdkbash
pip install within-sdkts
import { track } from 'within-sdk';
import { server } from './mcp-server.js';
track(server, process.env.WITHIN_VENDOR_SLUG!, {
apiKey: process.env.WITHIN_SDK_API_KEY!,
});python
import os
from within_sdk import track, WithinOptions
from mcp_server import server
track(server, os.environ["WITHIN_VENDOR_SLUG"], WithinOptions())Open Overview in the Within dashboard after a meaningful MCP tool call to verify that SDK activity is arriving.
Key features
- Tracks a vendor MCP server instance without changing tool results or errors.
- Keeps the default capture behavior: tracing on, context-parameter injection on, and
get_more_toolsenabled. - Captures lifecycle, catalog, and tool-call events with redacted arguments and responses.
- Supports stable vendor-local
userIdinputs while creating subjects locally and droppinguserName. - Sends SDK activity only to the Within API and vendor-configured exporters after privacy sanitization.
- Creates or updates SDK leads after subject activity reaches the scoring threshold.
- Powers Session Replay, Agent Journey Map, Context Explorer, and Missing Tool Demand in the Within dashboard.
- Supports CRM outcomes such as conversions, upgrades, and churn without sending raw CRM identities; the Salesforce connector is upcoming.
What the SDK does not do
- It does not call external diagnostics endpoints.
- It does not send SDK activity anywhere except the Within API and vendor-configured exporters.
- It does not perform auth, token validation, billing, quota enforcement, or trial gating.
- It does not require email, name, org domain, or contact details.
- It does not claim revenue attribution.
Next steps
- Start with the Quickstart.
- Review the MCP Integration guide for server wiring.
- Use the API Reference for SDK functions, exported types, and CRM outcome endpoints.
