Official TypeScript/JavaScript SDK for Blackman AI - The AI API proxy that optimizes token usage to reduce costs.
- 🚀 Drop-in replacement for OpenAI, Anthropic, and other LLM APIs
- 💰 Automatic token optimization (save 20-40% on costs)
- 📊 Built-in analytics and cost tracking
- 🔒 Enterprise-grade security with SSO support
- ⚡ Low latency overhead (<50ms)
- 🎯 Semantic caching for repeated queries
npm install @blackman-ai/sdkimport { Configuration, CompletionsApi } from '@blackman-ai/sdk';
const config = new Configuration({
basePath: 'https://app.useblackman.ai',
accessToken: 'sk_your_blackman_api_key' // Get from https://app.useblackman.ai
});
const api = new CompletionsApi(config);
const response = await api.completions({
provider: 'OpenAI',
model: 'gpt-4o',
messages: [
{ role: 'user', content: 'Explain quantum computing in simple terms' }
]
});
console.log(response.choices[0].message.content);
console.log(`Tokens saved: ${response.usage.prompt_tokens}`);Get your API key from the Blackman AI Dashboard.
- 📧 Email: support@blackman.ai
- 💬 Discord: Join our community
- 🐛 Issues: GitHub Issues
MIT © Blackman AI