prelive-client
v1.0.0
Published
Typed HTTP client for the Prelive public API. Used by the official MCP server and CLI.
Downloads
150
Maintainers
Readme
prelive-client
Typed HTTP client for the Prelive public API. Powers the official prelive CLI and prelive-mcp MCP server, and is publishable on its own for any TypeScript/JavaScript integration.
Install
npm install prelive-clientUsage
import { PreliveClient } from 'prelive-client';
const client = new PreliveClient({
apiKey: process.env.PRELIVE_API_KEY!, // prl_live_…
// baseUrl: 'https://prelive.ai', // default
});
const me = await client.me();
console.log(`${me.user?.name} on ${me.credits.plan} (${me.credits.remaining} credits remaining)`);
const { titles, descriptions, hashtags } = await client.generateStreamInfo({
gameTitle: 'Elden Ring',
briefDescription: 'No-hit playthrough attempt #4',
});Methods
client.me()— identity + credit balanceclient.generateStreamInfo({ gameTitle, ... })— titles/descriptions/hashtagsclient.transcribe({ audioUrl | audioBase64, ... })— Deepgram transcriptionclient.schedulePost({ content, platforms, scheduledFor, ... })— schedule a social postclient.listPosts({ status?, limit?, offset? })— list scheduled posts
Get an API key at prelive.ai/settings/api-keys.
License
Apache-2.0
