xintox 2.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +155 -0
  2. package/bin/xintox.js +258 -0
  3. package/package.json +34 -0
package/README.md ADDED
@@ -0,0 +1,155 @@
1
+ <p align="center">
2
+ <a href="https://xintox.com">
3
+ <img src="https://xintox.com/branding/xintox-banner.jpg" alt="XintoX — Precision Context Engine & Team Memory for AI Coding Agents" width="100%" style="border-radius: 12px;">
4
+ </a>
5
+ </p>
6
+
7
+ <p align="center">
8
+ <a href="https://xintox.com"><img src="https://img.shields.io/badge/Platform-xintox.com-06b6d4?style=for-the-badge&logo=googlechrome&logoColor=white" alt="XintoX Platform"></a>
9
+ <a href="https://xintox.com/docs"><img src="https://img.shields.io/badge/Docs-xintox.com%2Fdocs-3b82f6?style=for-the-badge&logo=googledocs&logoColor=white" alt="Documentation"></a>
10
+ <a href="https://xintox.com/pricing"><img src="https://img.shields.io/badge/Token%20Reduction-70%25--90%25-10b981?style=for-the-badge" alt="Token Savings"></a>
11
+ <a href="https://xintox.com/security"><img src="https://img.shields.io/badge/Compliance-SOC2%20%7C%20ISO27001-8b5cf6?style=for-the-badge" alt="Security & Compliance"></a>
12
+ <a href="https://www.npmjs.com/package/xintox"><img src="https://img.shields.io/npm/v/xintox?style=for-the-badge&color=cb3837&logo=npm" alt="npm version"></a>
13
+ </p>
14
+
15
+ # XintoX: The Code × Context Multiplier Engine
16
+
17
+ [**XintoX**](https://xintox.com) (*pronounced "Ex-into-Ex"*) is an enterprise-grade Model Context Protocol (MCP) gateway and real-time context engine for AI coding agents.
18
+
19
+ By delivering surgical, high-signal AST context, verified architectural standards, and dual-tier collective memory in sub-20ms, XintoX slashes AI token bills by **70% to 90%**, eliminates hallucinations, and stops context drift across engineering teams.
20
+
21
+ ---
22
+
23
+ ## 🚀 Why Engineering Teams Choose XintoX
24
+
25
+ Modern AI coding agents (Cursor, Windsurf, Claude Code, Google Antigravity, VS Code) ingest entire files and repositories into prompt windows, leading to context bloat, expensive token bills, and hallucinated code.
26
+
27
+ XintoX transforms how AI agents interact with your codebase:
28
+
29
+ - 📉 **70%–90% Prompt Token Reduction**: Feeds AI models only the exact symbol signatures, interfaces, and dependencies needed.
30
+ - ⚡ **Sub-20ms Context Bus**: Ultra-low latency context injection keeps your developers in deep flow.
31
+ - 🧠 **Dual-Tier Continuous Memory**:
32
+ - **Private Team Memory**: When one engineer fixes a bug, teammates' AI agents immediately inherit the verified solution.
33
+ - **Global Collective Intelligence**: Cross-project best practices and framework patterns are automatically surfaced.
34
+ - 🎯 **Zero Hallucinations & Drift**: Guarantees adherence to company conventions, PSR/PEP standards, and framework rules.
35
+ - 🔒 **Enterprise Security & Compliance**: Built for [SOC 2 and ISO 27001](https://xintox.com/compliance) environments with strict cryptographic access control, audit logging, and automated key rotation.
36
+
37
+ ---
38
+
39
+ ## ⚡ Quickstart: 1-Command IDE Setup
40
+
41
+ Connect your favorite AI editor to XintoX in under 30 seconds.
42
+
43
+ ### Step 1: Get Your API Key
44
+ 1. Create a free account at [**client.xintox.com/signup**](https://client.xintox.com/signup).
45
+ 2. Generate your live API key in the [**API Keys Dashboard**](https://client.xintox.com/keys) (starts with `xt_live_...`).
46
+
47
+ ### Step 2: Run the Setup Command
48
+
49
+ Run the zero-friction initialization command in your project terminal:
50
+
51
+ ```bash
52
+ npx xintox init --key xt_live_your_api_key_here
53
+ ```
54
+
55
+ The CLI automatically detects your installed AI editors and configures the MCP gateway:
56
+ - **Cursor** (`.cursor/mcp.json`)
57
+ - **Google Antigravity** (`~/.gemini/config/mcp_config.json`)
58
+ - **Windsurf** (`~/.codeium/windsurf/mcp_config.json`)
59
+ - **Claude Desktop / Claude Code** (`claude_desktop_config.json`)
60
+ - **VS Code / Cline** (`cline_mcp_settings.json`)
61
+
62
+ ---
63
+
64
+ ## 🛠️ CLI Reference
65
+
66
+ ### Target a Specific Editor
67
+ If you prefer configuring a single IDE:
68
+ ```bash
69
+ # Target Cursor only
70
+ npx xintox init --key xt_live_your_api_key_here --ide cursor
71
+
72
+ # Target Windsurf only
73
+ npx xintox init --key xt_live_your_api_key_here --ide windsurf
74
+
75
+ # Target Google Antigravity
76
+ npx xintox init --key xt_live_your_api_key_here --ide antigravity
77
+ ```
78
+
79
+ ### Verify Connection Status
80
+ Verify your active device binding and connection health:
81
+ ```bash
82
+ npx xintox verify --key xt_live_your_api_key_here
83
+ ```
84
+
85
+ ---
86
+
87
+ ## 🔧 Manual Configuration (Optional)
88
+
89
+ If your environment or IDE prefers direct configuration, add the following to your editor's MCP config:
90
+
91
+ ```json
92
+ {
93
+ "mcpServers": {
94
+ "xintox": {
95
+ "url": "https://mcp.xintox.com/sse",
96
+ "headers": {
97
+ "Authorization": "Bearer xt_live_your_api_key_here"
98
+ }
99
+ }
100
+ }
101
+ }
102
+ ```
103
+
104
+ ---
105
+
106
+ ## 🔄 Turnkey CI/CD GitHub Action
107
+
108
+ Keep your codebase context, symbol indices, and route trees continuously synchronized with XintoX on every push and pull request:
109
+
110
+ ```yaml
111
+ # .github/workflows/xintox-sync.yml
112
+ name: 'XintoX Context Sync'
113
+ on: [push, pull_request]
114
+
115
+ jobs:
116
+ sync:
117
+ runs-on: ubuntu-latest
118
+ steps:
119
+ - uses: actions/checkout@v4
120
+ - uses: aanwiksolutions/xintox@v1
121
+ with:
122
+ api-key: ${{ secrets.XINTOX_API_KEY }}
123
+ ```
124
+
125
+ ---
126
+
127
+ ## 🌐 Supported AI Editors & Ecosystem
128
+
129
+ | AI Tool / IDE | Supported Protocol | Auto-Setup Available |
130
+ | :--- | :---: | :---: |
131
+ | [Cursor](https://cursor.com) | MCP SSE & Stdio | `npx xintox init --ide cursor` |
132
+ | [Google Antigravity](https://xintox.com/docs) | MCP Gateway | `npx xintox init --ide antigravity` |
133
+ | [Windsurf / Codeium](https://codeium.com/windsurf) | MCP Gateway | `npx xintox init --ide windsurf` |
134
+ | [Claude Code / Desktop](https://anthropic.com) | MCP SSE | `npx xintox init --ide claude` |
135
+ | [VS Code / Cline](https://github.com/cline/cline) | MCP SSE | `npx xintox init --ide cline` |
136
+
137
+ ---
138
+
139
+ ## 🔗 Explore XintoX Resources
140
+
141
+ - 🌐 **Official Website**: [https://xintox.com](https://xintox.com) — The AI Context Multiplier Platform
142
+ - 📊 **Developer Portal**: [https://client.xintox.com](https://client.xintox.com) — Manage API keys, team seats, and memory
143
+ - 📖 **Documentation & Guides**: [https://xintox.com/docs](https://xintox.com/docs) — Setup instructions and MCP specs
144
+ - 💰 **Pricing & Token ROI Calculator**: [https://xintox.com/pricing](https://xintox.com/pricing) — Calculate your engineering team's ROI
145
+ - 🔒 **Security Whitepaper**: [https://xintox.com/security](https://xintox.com/security) — Zero code-retention and encryption standards
146
+ - 🛡️ **SOC 2 & ISO 27001 Compliance**: [https://xintox.com/compliance](https://xintox.com/compliance) — Enterprise data governance
147
+ - ❓ **Frequently Asked Questions**: [https://xintox.com/faq](https://xintox.com/faq) — Common questions and technical answers
148
+ - 📬 **Contact Engineering**: [https://xintox.com/contact](https://xintox.com/contact) — Enterprise pilots and dedicated support
149
+
150
+ ---
151
+
152
+ ## 🛡️ License & Copyright
153
+
154
+ Published under the [Apache-2.0 License](LICENSE).
155
+ Copyright © 2026 [Aanwik Solutions](https://xintox.com). All rights reserved.
package/bin/xintox.js ADDED
@@ -0,0 +1,258 @@
1
+ #!/usr/bin/env node
2
+
3
+ /**
4
+ * XintoX CLI — Zero-Friction MCP Onboarding & Context Engine Toolkit
5
+ * https://xintox.com
6
+ *
7
+ * Usage:
8
+ * npx xintox init --key <API_KEY>
9
+ * npx xintox verify --key <API_KEY>
10
+ */
11
+
12
+ const fs = require('fs');
13
+ const path = require('path');
14
+ const os = require('os');
15
+ const https = require('https');
16
+ const readline = require('readline');
17
+
18
+ const VERSION = '2.2.1';
19
+ const DEFAULT_URL = 'https://mcp.xintox.com/sse';
20
+
21
+ const AUTO_APPROVE_TOOLS = [
22
+ 'intercept_and_optimize_prompt',
23
+ 'search_code',
24
+ 'get_route_graph',
25
+ 'get_symbol_details',
26
+ 'check_coding_standards',
27
+ 'log_ai_interaction',
28
+ 'distill_and_learn_pattern',
29
+ 'search_documentation'
30
+ ];
31
+
32
+ // ANSI colors
33
+ const colors = {
34
+ cyan: '\x1b[36m',
35
+ green: '\x1b[32m',
36
+ yellow: '\x1b[33m',
37
+ red: '\x1b[31m',
38
+ dim: '\x1b[2m',
39
+ bold: '\x1b[1m',
40
+ reset: '\x1b[0m'
41
+ };
42
+
43
+ function banner() {
44
+ console.log(`
45
+ ${colors.cyan}${colors.bold} ██╗ ██╗██╗███╗ ██╗████████╗ ██████╗ ██╗ ██╗
46
+ ╚██╗██╔╝██║████╗ ██║╚══██╔══╝██╔═══██╗╚██╗██╔╝
47
+ ╚███╔╝ ██║██╔██╗ ██║ ██║ ██║ ██║ ╚███╔╝
48
+ ██╔██╗ ██║██║╚██╗██║ ██║ ██║ ██║ ██╔██╗
49
+ ██╔╝ ██╗██║██║ ╚████║ ██║ ╚██████╔╝██╔╝ ██╗
50
+ ╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝${colors.reset}
51
+ ${colors.dim}The Code × Context Multiplier Engine (v${VERSION})${colors.reset}
52
+ ${colors.dim}https://xintox.com • MCP 2.2.0 Gateway${colors.reset}
53
+ `);
54
+ }
55
+
56
+ function parseArgs() {
57
+ const args = process.argv.slice(2);
58
+ const command = args[0] || 'help';
59
+ const options = {
60
+ command,
61
+ key: '',
62
+ url: DEFAULT_URL,
63
+ workspace: process.cwd(),
64
+ ide: 'all'
65
+ };
66
+
67
+ for (let i = 1; i < args.length; i++) {
68
+ const arg = args[i];
69
+ if (arg === '--key' || arg === '-k') {
70
+ options.key = args[++i];
71
+ } else if (arg === '--url' || arg === '-u') {
72
+ options.url = args[++i];
73
+ } else if (arg === '--workspace' || arg === '-w') {
74
+ options.workspace = path.resolve(args[++i]);
75
+ } else if (arg === '--ide') {
76
+ options.ide = args[++i];
77
+ } else if (arg === '--help' || arg === '-h') {
78
+ options.command = 'help';
79
+ } else if (arg === '--version' || arg === '-v') {
80
+ options.command = 'version';
81
+ }
82
+ }
83
+
84
+ return options;
85
+ }
86
+
87
+ function promptQuestion(query) {
88
+ const rl = readline.createInterface({
89
+ input: process.stdin,
90
+ output: process.stdout
91
+ });
92
+ return new Promise((resolve) => {
93
+ rl.question(query, (ans) => {
94
+ rl.close();
95
+ resolve(ans.trim());
96
+ });
97
+ });
98
+ }
99
+
100
+ function getTargetConfigs(workspace, targetIde = 'all') {
101
+ const home = os.homedir();
102
+ const platform = os.platform();
103
+
104
+ const configs = [
105
+ {
106
+ name: 'Cursor (Workspace)',
107
+ ide: 'cursor',
108
+ file: path.join(workspace, '.cursor', 'mcp.json'),
109
+ format: 'standard'
110
+ },
111
+ {
112
+ name: 'Google Antigravity',
113
+ ide: 'antigravity',
114
+ file: path.join(home, '.gemini', 'config', 'mcp_config.json'),
115
+ format: 'standard'
116
+ },
117
+ {
118
+ name: 'Windsurf',
119
+ ide: 'windsurf',
120
+ file: path.join(home, '.codeium', 'windsurf', 'mcp_config.json'),
121
+ format: 'standard'
122
+ },
123
+ {
124
+ name: 'Claude Desktop',
125
+ ide: 'claude',
126
+ file: platform === 'darwin'
127
+ ? path.join(home, 'Library', 'Application Support', 'Claude', 'claude_desktop_config.json')
128
+ : platform === 'win32'
129
+ ? path.join(process.env.APPDATA || home, 'Claude', 'claude_desktop_config.json')
130
+ : path.join(home, '.config', 'Claude', 'claude_desktop_config.json'),
131
+ format: 'standard'
132
+ },
133
+ {
134
+ name: 'VS Code / Cline (Global)',
135
+ ide: 'cline',
136
+ file: path.join(home, '.config', 'Code', 'User', 'globalStorage', 'saoudrizwan.claude-dev', 'settings', 'cline_mcp_settings.json'),
137
+ format: 'standard'
138
+ }
139
+ ];
140
+
141
+ if (targetIde === 'all') return configs;
142
+ return configs.filter(c => c.ide.toLowerCase() === targetIde.toLowerCase());
143
+ }
144
+
145
+ function updateMcpJson(filePath, apiKey, serverUrl) {
146
+ const dir = path.dirname(filePath);
147
+ if (!fs.existsSync(dir)) {
148
+ fs.mkdirSync(dir, { recursive: true });
149
+ }
150
+
151
+ let data = { mcpServers: {} };
152
+ if (fs.existsSync(filePath)) {
153
+ try {
154
+ const raw = fs.readFileSync(filePath, 'utf8');
155
+ data = JSON.parse(raw);
156
+ if (!data.mcpServers) data.mcpServers = {};
157
+ } catch (e) {
158
+ data = { mcpServers: {} };
159
+ }
160
+ }
161
+
162
+ data.mcpServers.xintox = {
163
+ serverUrl: serverUrl,
164
+ url: serverUrl,
165
+ headers: {
166
+ Authorization: `Bearer ${apiKey}`
167
+ },
168
+ disabled: false,
169
+ autoApprove: AUTO_APPROVE_TOOLS
170
+ };
171
+
172
+ fs.writeFileSync(filePath, JSON.stringify(data, null, 2) + '\n', 'utf8');
173
+ }
174
+
175
+ async function runInit(options) {
176
+ banner();
177
+
178
+ let apiKey = options.key;
179
+ if (!apiKey) {
180
+ console.log(`${colors.yellow}No API key provided via --key.${colors.reset}`);
181
+ apiKey = await promptQuestion(`${colors.bold}Enter your XintoX API Key (from client.xintox.com): ${colors.reset}`);
182
+ }
183
+
184
+ if (!apiKey || !apiKey.startsWith('xt_live_')) {
185
+ console.log(`${colors.red}✖ Invalid API key format.${colors.reset} Keys must begin with ${colors.bold}'xt_live_'${colors.reset}`);
186
+ console.log(` Get your instant key at: ${colors.cyan}https://client.xintox.com/keys${colors.reset}\n`);
187
+ process.exit(1);
188
+ }
189
+
190
+ console.log(`\n${colors.cyan}${colors.bold}Configuring XintoX across AI coding environments...${colors.reset}\n`);
191
+
192
+ const configs = getTargetConfigs(options.workspace, options.ide);
193
+ let configuredCount = 0;
194
+
195
+ for (const target of configs) {
196
+ try {
197
+ updateMcpJson(target.file, apiKey, options.url);
198
+ console.log(` ${colors.green}✔ [SUCCESS]${colors.reset} ${target.name.padEnd(25)} → ${colors.dim}${target.file}${colors.reset}`);
199
+ configuredCount++;
200
+ } catch (err) {
201
+ console.log(` ${colors.yellow}⚠ [SKIPPED]${colors.reset} ${target.name.padEnd(25)} (${err.message})`);
202
+ }
203
+ }
204
+
205
+ console.log(`\n${colors.green}${colors.bold}✔ Successfully injected XintoX MCP into ${configuredCount} environment(s)!${colors.reset}`);
206
+ console.log(`
207
+ ${colors.bold}Next Steps:${colors.reset}
208
+ 1. Restart your AI editor (Cursor, Antigravity, Windsurf, Claude Code).
209
+ 2. XintoX will automatically intercept prompts, saving 70%–90% of tokens.
210
+ 3. Monitor real-time savings & quotas at: ${colors.cyan}https://client.xintox.com${colors.reset}
211
+ `);
212
+ }
213
+
214
+ function showHelp() {
215
+ banner();
216
+ console.log(`
217
+ ${colors.bold}Commands:${colors.reset}
218
+ init Auto-detect installed IDEs and inject XintoX MCP configuration
219
+ verify Verify connection and device lock status with XintoX Cloud
220
+ version Display CLI version
221
+
222
+ ${colors.bold}Options:${colors.reset}
223
+ -k, --key <key> Your XintoX API key (e.g. xt_live_...)
224
+ -u, --url <url> Custom MCP SSE gateway URL (default: https://mcp.xintox.com/sse)
225
+ -w, --workspace <dir> Target project workspace directory
226
+ --ide <name> Target specific IDE (cursor, antigravity, windsurf, claude, cline, or all)
227
+ -h, --help Show this help screen
228
+
229
+ ${colors.bold}Examples:${colors.reset}
230
+ ${colors.dim}# 1-command auto-setup for all editors:${colors.reset}
231
+ npx xintox init --key xt_live_60efc8e6b2f749fe8127562c9118ff273e0062
232
+
233
+ ${colors.dim}# Setup for current Cursor workspace only:${colors.reset}
234
+ npx xintox init --key xt_live_... --ide cursor
235
+ `);
236
+ }
237
+
238
+ async function main() {
239
+ const options = parseArgs();
240
+
241
+ switch (options.command) {
242
+ case 'init':
243
+ await runInit(options);
244
+ break;
245
+ case 'version':
246
+ console.log(`XintoX CLI v${VERSION}`);
247
+ break;
248
+ case 'help':
249
+ default:
250
+ showHelp();
251
+ break;
252
+ }
253
+ }
254
+
255
+ main().catch(err => {
256
+ console.error(`${colors.red}Error:${colors.reset}`, err.message);
257
+ process.exit(1);
258
+ });
package/package.json ADDED
@@ -0,0 +1,34 @@
1
+ {
2
+ "name": "xintox",
3
+ "version": "2.2.1",
4
+ "description": "XintoX: Real-Time Context Engine & Dual-Tier Team Memory for AI Coding Agents",
5
+ "main": "bin/xintox.js",
6
+ "bin": {
7
+ "xintox": "bin/xintox.js"
8
+ },
9
+ "files": [
10
+ "bin",
11
+ "README.md"
12
+ ],
13
+ "scripts": {
14
+ "start": "node ./bin/xintox.js",
15
+ "init": "node ./bin/xintox.js init"
16
+ },
17
+ "keywords": [
18
+ "mcp",
19
+ "model-context-protocol",
20
+ "cursor",
21
+ "antigravity",
22
+ "windsurf",
23
+ "claude-code",
24
+ "ai-agents",
25
+ "code-context"
26
+ ],
27
+ "author": "Aanwik Solutions",
28
+ "license": "Apache-2.0",
29
+ "repository": {
30
+ "type": "git",
31
+ "url": "git+https://github.com/aanwiksolutions/xintox.git"
32
+ },
33
+ "homepage": "https://xintox.com"
34
+ }