SDK Auto-Discovery
The SDK discovers your database, codebase, and error logs. AI gets complete context without any integrations.
Checkout keeps failing. Help?
Hi John! Your Visa 4242 expired. Update at Settings → Billing.
John Davis
john@acme.com
Plan
Pro ($49/mo)
Since
Jan 2024
PaymentError at checkout.ts:247
card_declined: expired_cardNo API integrations to build or maintain — the SDK handles everything
You spend months connecting data sources. Your support team still lacks context.
Simple Installation
No weeks of integration work. Install our SDK and AI understands your entire system.
# Install the SDK
npm install @relay/embedded-sdk
# Set your API key
export RELAY_API_KEY=your_key_here
# Optional: Set OpenAI key
export OPENAI_API_KEY=your_openai_keyimport { RelayCRM } from '@relay/embedded-sdk'
// Initialize with optional config
await RelayCRM.init({
database: {
exclude: ['password_hashes']
},
siteUrl: 'https://docs.yourapp.com',
autoCrawl: true,
})
// SDK automatically:
// - Discovers database connections
// - Parses Prisma schema
// - Detects your framework
// - Connects via SSE
// - Indexes docs for AInpm install and add 10 lines of config. Works with any Node.js, Python, or Ruby app.
AI automatically discovers your database schema, codebase structure, and data relationships.
Support agents have complete, real-time context for every customer interaction.
Deep System Understanding
When a customer reaches out, your AI doesn't just see their message — it sees their subscription status, recent orders, error logs, and exactly what page they're stuck on.
Customer: My checkout keeps failing!
SYSTEM CONTEXT DETECTED:
AI Response:
Hi John! I can see your checkout is failing because your Visa ending in 4242 expired in December 2024. You can update your payment method at Settings → Billing, or I can send you a direct link to update it right now. Would you like me to do that?
Context: users, subscriptions, payments, error_logs
Under the Hood
A lightweight SDK that runs inside your application, with a secure real-time bridge to the CRM.
Your Application
SDK runs in your Node.js process
↓ SSE (Server-Sent Events) — real-time commands
↑ HTTP POST — query results, context updates
Relay CRM
AI agents query your data in real-time
Database Connections
Scans environment variables for DATABASE_URL,POSTGRES_URL,MONGODB_URI, and more.
Schema Extraction
Parses your prisma/schema.prisma file to understand tables, columns, types, and relationships.
Framework Detection
Identifies Next.js, Express, Fastify, NestJS, Koa, and other frameworks from your package.json and project structure.
RAG Knowledge Base
Crawls your docs site, extracts content, generates embeddings, and indexes for semantic search. AI can reference your product documentation.
Customer asks: "Why can't I checkout?"
CRM sends query to SDK via SSE connection
SDK queries your database, returns results
AI responds with full context: expired card on file
Always Up to Date
Add new database tables? Change your schema? Deploy new features? The CRM automatically discovers changes and updates its understanding.
Parses Prisma schemas, introspects databases, maps relationships automatically
Detects your framework, ORM, and project structure from package.json
SSE connection maintains real-time sync, heartbeats every 30 seconds
PostgreSQL, MySQL, MongoDB, Supabase, PlanetScale — all supported
database: {
include: {
tables: ['users', 'orders']
},
exclude: {
tables: ['api_keys'],
fields: ['*.password']
},
autoMask: ['email', 'phone']
}Enterprise-Grade Security
Granular permissions let you define exactly which tables and fields the CRM can access. Auto-masking protects PII. Complete audit logging shows every data access.
If you're building something new and moving fast, this is for you.
You're shipping fast. Your schema changes weekly. You don't have time to maintain integrations. Install once, get full context forever.
Complex subscription logic, usage metrics, feature flags. AI finally understands your entire customer lifecycle.
You want to fully automate support. That requires complete context. This is the only CRM that can deliver it.
Unified Communications
Voice, SMS, and email — all connected to your embedded system context. AI knows what customers are doing before they even explain.
Powered by Twilio
When a customer calls, AI instantly pulls their account data, recent errors, and session state from your live database.
Powered by Twilio
Two-way SMS with AI responses powered by your actual customer data. No guessing, no generic responses.
Native integration
Email threads enriched with full customer context. AI drafts know their subscription tier, recent activity, and open issues.
Whether they call, text, or email — AI sees their entire history plus live system data. No more "Can you describe the error?" when you already have the stack trace.
| Capability | Embedded CRM | Traditional CRM |
|---|---|---|
| Setup Time | 5 minutes | Weeks of integrations |
| Customer Data Access | Real-time, live DB | Synced copies, often stale |
| Error Visibility | Full stack traces | None |
| User Session Context | What page, what actions | None |
| Schema Changes | Auto-discovered | Manual re-integration |
| AI Context Quality | Complete system view | Partial, imported data only |
| Integration Maintenance | Zero — auto-adapts | Ongoing engineering work |
| Data Freshness | Real-time | Minutes to hours delayed |