Lines 3-43javascript
3import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
4import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
5import { z } from 'zod';
6import { searchSkills } from './skill/search.js';
7import { readSkillFile } from './skill/store.js';
8import { replayEndpoint } from './replay/engine.js';
9import { capEnvelope } from './replay/envelope.js';
10import { AuthManager, getMachineId } from './auth/manager.js';
11import { deriveSigningKey } from './auth/crypto.js';
12import { requestAuth } from './auth/handoff.js';
13import { CaptureSession } from './capture/session.js';
14import { discover } from './discovery/index.js';
15import { readIndexEntry } from './index/reader.js';
16import { SessionCache } from './orchestration/cache.js';
17import { peek } from './read/peek.js';
18import { read } from './read/index.js';
19import { resolveAndValidateUrl } from './skill/ssrf.js';
20import { createRequire } from 'node:module';
21import { homedir } from 'node:os';
22import { join } from 'node:path';
23const APITAP_DIR = join(homedir(), '.apitap');
24const require = createRequire(import.meta.url);
25const { version: PACKAGE_VERSION } = require('../package.json');
MediumDynamic Require
Package source references dynamic require/import behavior.
dist/mcp.jsView on unpkg · L23 27 * Wrap response data with external content metadata.
28 * MCP clients that respect this can apply security wrappers (e.g., SECURITY NOTICE).
29 * Tier classification is about replay success, not content trustworthiness —
30 * all external API data should be marked as untrusted.
32function wrapExternalContent(data, source) {
36 text: JSON.stringify(data),
38 // MCP extension: mark as external untrusted content