Shynk Documentation
Make AI agents smarter, safer, cheaper. One API for compression, routing, PII protection, and domain-specific boosts.
What is Shynk?
Shynk is AI middleware that sits between your application and LLM providers (Anthropic, OpenAI). It adds:
- Data Shield — automatic PII redaction (emails, SSNs, credit cards, phone numbers) before data reaches the LLM
- Boosts — domain-specific system prompts that dramatically improve output quality for specialized tasks
- Smart Routing — automatic model selection based on task complexity
- Token Savings — up to 35% reduction through compression and caching
Shynk works via MCP (Model Context Protocol) for AI agents or a REST API compatible with the OpenAI SDK.
Quick Start
Get running in under 2 minutes. Choose your integration method:
Claude Desktop / MCP Client config
{
"mcpServers": {
"shynk": {
"url": "https://api.shynk.io/mcp/sse",
"headers": {
"Authorization": "Bearer sh_your_api_key"
}
}
}
}
That's it. Your AI agent now has access to Shynk tools: boost application, PII compression, and the full boost catalog.
Python (OpenAI SDK compatible)
import openai
client = openai.OpenAI(
base_url="https://api.shynk.io/v1",
api_key="sh_your_api_key"
)
response = client.chat.completions.create(
model="claude-sonnet",
messages=[{"role": "user", "content": "Review this contract..."}],
extra_headers={"x-provider-api-key": "sk-ant-..."},
extra_body={"shynk": {"boost": "contract-analyzer"}}
)
print(response.choices[0].message.content)
Node.js
const response = await fetch("https://api.shynk.io/v1/chat/completions", {
method: "POST",
headers: {
"Authorization": "Bearer sh_your_api_key",
"x-provider-api-key": "sk-ant-...",
"Content-Type": "application/json"
},
body: JSON.stringify({
model: "claude-sonnet",
messages: [{ role: "user", content: "Review this contract..." }],
shynk: { boost: "contract-analyzer" }
})
});
const data = await response.json();
console.log(data.choices[0].message.content);
cURL
curl https://api.shynk.io/v1/chat/completions \
-H "Authorization: Bearer sh_your_api_key" \
-H "x-provider-api-key: sk-ant-..." \
-H "Content-Type: application/json" \
-d '{
"model": "claude-sonnet",
"messages": [{"role": "user", "content": "Analyze this NDA..."}],
"shynk": {"boost": "nda-review"}
}'
sh_ API key.
Authentication
All API requests require two keys:
| Header | Value | Purpose |
|---|---|---|
Authorization | Bearer sh_... | Your Shynk API key (identifies your account, plan, usage) |
x-provider-api-key | sk-ant-... or sk-... | Your LLM provider API key (Anthropic or OpenAI). Shynk never stores this. |
Shynk acts as a transparent proxy — your provider key is forwarded directly and never logged or stored.
MCP Integration
Shynk implements the Model Context Protocol (MCP), the open standard for connecting AI agents to external tools.
Endpoints
| Endpoint | Method | Transport |
|---|---|---|
https://api.shynk.io/mcp | POST | JSON-RPC 2.0 (stateless) |
https://api.shynk.io/mcp/sse | GET | Server-Sent Events (streaming) |
https://api.shynk.io/mcp/health | GET | Health check |
Claude Desktop Configuration
{
"mcpServers": {
"shynk": {
"url": "https://api.shynk.io/mcp/sse",
"headers": {
"Authorization": "Bearer sh_your_api_key"
}
}
}
}
Generic MCP Client
// Initialize handshake
POST https://api.shynk.io/mcp
Content-Type: application/json
{
"jsonrpc": "2.0",
"method": "initialize",
"params": { "capabilities": {} },
"id": 1
}
// Response:
{
"jsonrpc": "2.0",
"result": {
"protocolVersion": "2024-11-05",
"serverInfo": { "name": "shynk", "version": "0.2.0" },
"capabilities": { "tools": {}, "resources": {} }
},
"id": 1
}
MCP Tools
shynk.boost.list
Returns all available boosts with their name, category, and tier.
// Request
{ "jsonrpc": "2.0", "method": "tools/call",
"params": { "name": "shynk.boost.list", "arguments": {} }, "id": 2 }
// Response includes array of boosts:
[
{ "id": "contract-analyzer", "name": "Contract Analyzer", "category": "Legal", "tier": "premium" },
{ "id": "code-review-pro", "name": "Code Review Pro", "category": "Programming", "tier": "premium" },
...
]
shynk.boost.apply
Applies a domain-specific boost to your prompt. The boost injects an expert system prompt.
// Request
{ "jsonrpc": "2.0", "method": "tools/call",
"params": {
"name": "shynk.boost.apply",
"arguments": {
"boost_id": "contract-analyzer",
"prompt": "Review this software license agreement: ..."
}
}, "id": 3 }
shynk.compress
Applies Data Shield — redacts PII (emails, SSNs, IBANs, credit cards, phone numbers) and reports token savings.
// Request
{ "jsonrpc": "2.0", "method": "tools/call",
"params": {
"name": "shynk.compress",
"arguments": {
"prompt": "Contact john.doe@company.com or call +1-555-0123 for the contract signed by SSN 123-45-6789"
}
}, "id": 4 }
// Response:
{
"compressed": "Contact [EMAIL_REDACTED] or call [PHONE_REDACTED] for the contract signed by SSN [SSN_REDACTED]",
"pii_redacted": 3,
"tokens_saved": 8,
"actions": [
{ "type": "EMAIL", "field": "content" },
{ "type": "PHONE_US", "field": "content" },
{ "type": "SSN", "field": "content" }
]
}
shynk.health
Returns service status and version info.
MCP Resources
shynk://boost-catalog
Full boost catalog as a JSON resource. Useful for agents that want to browse available boosts.
{ "jsonrpc": "2.0", "method": "resources/read",
"params": { "uri": "shynk://boost-catalog" }, "id": 5 }
REST API — Chat Completions
OpenAI-compatible endpoint. Drop-in replacement for any OpenAI SDK usage.
POST /v1/chat/completions
| Field | Type | Required | Description |
|---|---|---|---|
model | string | Yes | Model ID: claude-sonnet, claude-opus, gpt-4o, etc. |
messages | array | Yes | OpenAI-format messages array |
stream | boolean | No | Enable SSE streaming |
shynk.boost | string | No | Boost ID to apply (e.g. "contract-analyzer") |
Response
Standard OpenAI-format response with additional shynk metadata:
{
"id": "chatcmpl-...",
"choices": [{ "message": { "role": "assistant", "content": "..." } }],
"usage": { "prompt_tokens": 150, "completion_tokens": 450 },
"shynk": {
"data_shield_actions": [{ "type": "EMAIL", "field": "content" }],
"boost_applied": "contract-analyzer",
"tokens_saved": 12
}
}
REST API — Boosts
GET /v1/boosts
List all active boosts. Requires authentication.
curl https://api.shynk.io/v1/boosts \
-H "Authorization: Bearer sh_your_api_key"
// Response:
{
"boosts": [
{ "id": "contract-analyzer", "name": "Contract Analyzer", "category": "Legal", "tier": "premium", "version": "7.2" },
{ "id": "tone-optimizer", "name": "Tone Optimizer", "category": "Productivity", "tier": "basic", "version": "1.2" },
...
]
}
Data Shield
Data Shield automatically runs on every request. It detects and redacts PII before your data reaches the LLM provider:
| Type | Pattern | Example |
|---|---|---|
| Email addresses | john@example.com → [EMAIL_REDACTED] | |
| SSN | Social Security Numbers | 123-45-6789 → [SSN_REDACTED] |
| IBAN | International Bank Account Numbers | DE89370400440532013000 → [IBAN_REDACTED] |
| CC | Credit Card Numbers | 4111-1111-1111-1111 → [CC_REDACTED] |
| PHONE_US | US Phone Numbers | +1-555-0123 → [PHONE_REDACTED] |
| PHONE_INTL | International Phone Numbers | +44 20 7946 0958 → [PHONE_REDACTED] |
Up to 35% token savings from PII redaction alone, depending on document type.
Boost Catalog
20 domain-specific boosts across 12 categories. All quality-verified by Cenek (AI architect, median score 9.0+).
Premium Tier
| Boost | Category | Version | Use Case |
|---|---|---|---|
| Contract Analyzer | Legal | 7.2 | Analyze contracts for key terms, obligations, risks, unusual clauses |
| NDA Review | Legal | 1.3 | Review NDAs for scope, duration, exclusions, one-sided terms |
| Contract Redliner | Legal | 1.0 | Mark up contracts with proposed changes, risk annotations |
| Code Review Pro | Programming | 1.3 | Find bugs, security issues, performance problems in code |
| Bug Detector | Programming | 1.0 | Deep static analysis for bugs, race conditions, edge cases |
| Data Privacy Analyzer | Compliance | 1.0 | GDPR/CCPA compliance analysis of data processing activities |
| Financial Report Analyzer | Finance | 1.0 | Analyze annual reports, financial statements, forensic flags |
Standard Tier
| Boost | Category | Version | Use Case |
|---|---|---|---|
| Listing Pro | Real Estate | 1.2 | Create compelling property listings |
| Gov Doc Analyzer | Public Admin | 1.3 | Summarize government documents and regulations |
| Auto Listing Optimizer | Automotive | 1.0 | Optimize car sale advertisements |
| Ad Copy Pro | Marketing | 1.0 | Generate high-converting ad copy |
| API Doc Generator | Programming | 1.0 | Generate comprehensive API documentation from code |
| Resume Optimizer | Career | 1.0 | Optimize resumes for ATS and human reviewers |
| Customer Support Enhancer | Customer Service | 1.0 | Improve support ticket responses, adaptive depth by severity |
| SEO Content Analyzer | Marketing | 1.0 | Analyze and optimize content for search engines |
| Proposal Writer | Sales | 1.0 | Write compelling business proposals from brief |
| Incident Report Analyzer | DevOps/SRE | 1.0 | Analyze post-mortems, extract root causes and action items |
Basic Tier
| Boost | Category | Version | Use Case |
|---|---|---|---|
| Tone Optimizer | Productivity | 1.2 | Rewrite text for professional tone |
| Email Rewriter Pro | Communication | 1.0 | Rewrite emails for clarity, personalization, impact |
| Meeting Notes Summarizer | Productivity | 1.0 | Summarize meeting notes with action items and decisions |
How to Use Boosts
Via MCP
// 1. List available boosts
{ "method": "tools/call", "params": { "name": "shynk.boost.list" } }
// 2. Apply a boost to your prompt
{ "method": "tools/call", "params": {
"name": "shynk.boost.apply",
"arguments": { "boost_id": "contract-analyzer", "prompt": "Review this contract..." }
}}
Via REST API
// Include boost in your chat completion request
{
"model": "claude-sonnet",
"messages": [{ "role": "user", "content": "Review this contract..." }],
"shynk": { "boost": "contract-analyzer" }
}
Before & After Example
Without boost (generic response)
User: "Review this NDA between Company A and Company B"
Assistant: "This NDA appears to be a standard mutual non-disclosure agreement..."
With nda-review boost
User: "Review this NDA between Company A and Company B"
Assistant:
## NDA Review Summary
**Type:** Mutual NDA | **Duration:** 3 years + 2-year survival
**Risk Level:** MODERATE
### Key Findings
1. **Scope (Section 2):** Overly broad definition of "Confidential Information"
includes publicly available data — recommend narrowing.
2. **Non-compete (Section 7):** 24-month non-compete is likely unenforceable
in California — flag for legal review.
3. **Remedies (Section 9):** One-sided injunctive relief favoring Company A...
...