Use n8n with a private API
Connect n8n to the private Morse API: set it up, pick a model, and check it works.
n8n is a workflow automation tool whose AI nodes can ask a model to write, sort, or summarize at any step. It speaks OpenAI's Responses API, which Morse serves too, so it works with Morse: give it the base URL https://inference.trymorse.ai/v1 and a Morse API key, and its requests run on Morse's private inference, where Morse keeps nothing and no provider learns who you are.
Before you start
In the console, open API keys and make a key for n8n alone, with a spend limit, so a runaway session can't spend all your credits. See Limit a key.
You'll paste the key into an n8n credential.
Set up n8n
Make an OpenAI credential for Morse
In n8n, create a credential and choose OpenAI. Paste your key in API Key, set Base URL to
https://inference.trymorse.ai/v1, and save it. n8n tests the credential by asking Morse for its models.Add the OpenAI Chat Model
In your workflow, give an AI node, such as AI Agent or Basic LLM Chain, an OpenAI Chat Model, and pick the Morse credential. Under Model, choose
moonshotai/kimi-k2.7-codeFrom List, or switch to ID and type it.Choose the API format
Use Responses API is on by default, and Morse serves it. Turn it off to send OpenAI's Chat Completions instead, which Morse serves too.
Which model to pick
| Model | Context | Input / output | Why |
|---|---|---|---|
moonshotai/kimi-k2.7-code | 262.1K | $0.95 / $4 | Kimi's coding model. It doesn't reason, so it starts writing sooner. |
moonshotai/kimi-k3.1-pro | 1M | $2 / $10 | Reasons, and reads images. |
z-ai/glm-5.3 | 1M | $1.40 / $4.40 | Reasons, and takes tools at TEE too. |
deepseek/deepseek-v4-pro-0813 | 1M | $1.32 / $3.96 | Reasons, at a lower price. |
z-ai/glm-5.3-flash | 1M | $0.15 / $0.50 | Cheap and fast for small edits, and takes tools at TEE too. |
Prices are in dollars per million tokens, on each model's default endpoint. Every model is on the models page.
Check it works
Run the workflow with Execute workflow. The AI node's output shows the model's reply, which shows that Morse took the request.
Keep it private
A request runs on its model's default privacy tier. To hold n8n to a tier, such as one where only attested hardware reads your prompts, set a privacy floor on its key. See Privacy tiers and Provider routing.
If something goes wrong
| What you see | What to do |
|---|---|
401 | The key is missing or wrong. Check that MORSE_API_KEY is set where n8n starts, and that the key isn't revoked. |
402 | Add credits, or raise the key's limit. Morse holds credit for a request's output limit before it starts. See Holds. |
404 | Use a model's id exactly as the table above writes it, lab and all. |
Every code is in Errors. For other tools, see Coding agents and editors.