Quick Answer
Write your system and user messages ({{PLACEHOLDER}} conventions welcome), set temperature and max tokens, pick the API — OpenAI, Anthropic, or OpenRouter — and copy the generated Python, JavaScript, or cURL snippet. Each snippet is a complete, runnable call with your parameters baked in and keys read from environment variables, in each API’s correct shape (Anthropic’s system field, OpenRouter’s base URL). It is the free substitute for the paid "deploy your prompt as an API endpoint" feature: your prompt, your provider account, no middleman.
How It Works
Pick the target API — OpenAI, Anthropic, or OpenRouter — and write your system and user messages
Set temperature and max tokens; keep any {{PLACEHOLDER}} conventions for app-side substitution
Copy the Python, JavaScript, or cURL snippet — parameters baked in, keys read from environment variables
Ship it: your prompt runs against your own provider account with no middleman
Key Facts
- Python (official SDKs), JavaScript (ESM), and cURL for every target
- OpenAI, Anthropic, and OpenRouter endpoints with correct request shapes
- System + user messages, temperature, and max tokens baked into the snippet
- Keys stay in environment variables — never pasted into code
- No key needed here; generation is fully local
Frequently Asked Questions
Which API shape does each target use?
Anthropic uses the native Messages API with the system prompt as a top-level field; OpenAI uses chat completions with a system message; OpenRouter uses the OpenAI-compatible shape on openrouter.ai with its key. The snippet comments note where keys are read from.
Can I keep {{variables}} in the prompt?
Yes — placeholders pass through verbatim, so you can substitute them in your application before the call. The snippets are yours to edit.
Is this the same as deploying the prompt as an API?
It is the free version of it: instead of paying a platform to host your prompt behind their endpoint, the snippet runs your prompt against your own provider account — no middleman, no per-request markup, no vendor lock-in.