Run prompts, chats and embeddings against your own Ollama server and manage its models.
Ollama ships in the w6w first-party pack. It declares 11 actions, 3 health checks, and the host runs its code in a sandbox that never sees the credential.
io.w6w.ollamaOllama runs open large language models on hardware you control, and this app talks to your own server: you give it the host, port and scheme when you connect, and it calls Ollama’s REST API directly. A workflow can generate text from a prompt, continue a chat conversation, produce embeddings, and ask for structured JSON that matches a schema, with images for vision models and sampling options such as temperature, seed and context size. It can also look after the server itself: list the installed and the currently loaded models, inspect one’s capabilities and context length, pull a new model, copy or delete one, and unload a model to free memory.
Because the server is yours, reachability is the part to get right. A LAN or localhost address works only when workflows run on the same network, through a self-hosted runner; hosted runs need a tunnel or a reverse proxy with a public hostname. Ollama listens on 127.0.0.1 unless started with OLLAMA_HOST=0.0.0.0, and has no authentication of its own, so the API key is optional and only sent when a proxy in front of the server needs one. Every call is non-streaming.
Three routes to the same 11 actions. The Workflow tab is generated from Ollama's own manifest and carries its real ids, so it is copy-pasteable; the Code and CLI examples are the same call for any action on any app, so every app-specific value in them is a blank you fill in.
chat Send a conversation (a messages array) to a model on your Ollama server and get the assistant's reply as one result (non-streaming). Supports images, tools, JSON or JSON-Schema structured output, and sampling options. Ollama keeps no history: send all of it every time.
embed Turn text into embedding vectors with an embedding model on your Ollama server. Takes one string or a JSON array of strings and always returns a list of vectors.
generate Send a prompt to a model on your Ollama server and get the full response back as one result (non-streaming). Supports a system prompt, images for vision models, JSON or JSON-Schema structured output, and sampling options.
model-copy Create a new name for an installed model on your Ollama server. The copy shares the original's data on disk, so it is nearly free. An existing destination name is overwritten.
model-delete Permanently remove a model from your Ollama server's disk. Getting it back means pulling it again. A model that is not installed is an error, not a silent success.
model-list The models installed on your Ollama server (what is on disk, not what is loaded in memory), with size, digest, family, parameter size, quantization and capabilities.
model-pull Download a model from the Ollama registry onto your server (non-streaming). The call does not return until the download finishes, which can take many minutes for a large model — a timeout does not necessarily stop the pull; check the model list before retrying.
model-running The models currently loaded in memory on your Ollama server, with how much of each is in GPU memory and when it will be unloaded. Empty is normal when nothing was used recently.
model-show Details of an installed model: its Modelfile, parameters, prompt template, family, quantization, capabilities (completion, tools, vision, embedding, thinking) and architecture info such as the maximum context length.
model-unload Free a loaded model's memory on your Ollama server immediately instead of waiting for its keep-alive to expire. The model stays installed. Works for text-generation models.
A workflow step names the app and the action, and the editor fills in the
connection when you pick one. This is the Step shape from the
workflow spec, carrying Ollama's real ids.
{
"manifestVersion": "2",
"name": "ollama-example",
"steps": [
{
"id": "chat",
"uses": {
"app": "io.w6w.ollama",
"action": "chat",
"connection": "conn_YOUR_CONNECTION_ID"
},
"with": {
"model": "<model>",
"messages": "<messages>"
}
}
]
}chat embed generate model-copy model-list +6 more actions available
Every app-specific value here is a blank you have to fill in. An
app action is reached through the connection that authenticates it, so the
address is a connection id, not the app id — and connections belong to your account,
so a public page cannot know yours. Create one for Ollama, then fill in
the three blanks: conn_YOUR_CONNECTION_ID, the action key, and the
parameters that action declares. The call itself is real — the shape is transcribed
from the studio's own snippet builder, which prints the same kind of blanks — but
nothing in it is specific to Ollama. The Workflow tab is where this app's
real ids are.
npm install @w6w/sdkyarn add @w6w/sdkpnpm add @w6w/sdkdeno add npm:@w6w/sdkimport { W6wClient, isActionRun } from "@w6w/sdk";
// Reads W6W_BASE_URL and W6W_TOKEN from the environment when omitted.
const client = new W6wClient();
const envelope = await client.run({
urn: "conn_YOUR_CONNECTION_ID",
action: "chat",
payload: {
model: "<value>",
messages: "<value>",
// format: "<value>",
// tools: "<value>",
// think: "<value>",
// temperature: "<value>",
// seed: "<value>",
// numPredict: "<value>",
// numCtx: "<value>",
// options: "<value>",
// keepAlive: "<value>",
},
});
if (isActionRun(envelope)) console.log(envelope.value); npm install -g @w6w/cli w6w run conn_YOUR_CONNECTION_ID --action chat --payload '{"model":"<value>","messages":"<value>"}' Give an AI agent Ollama — without giving it Ollama's credentials. One MCP endpoint exposes every app, function and workflow the caller is entitled to, as tools it can discover and run. Access is granted per team while we onboard.
One tool call{
"name": "w6w_invoke",
"arguments": {
"ref": "app:io.w6w.ollama#chat",
"input": {
"model": "<model>",
"messages": "<messages>"
}
}
}
Every tool names its target with a single ref. The
app: form above doesn't name a connection at all — the
host resolves which of the caller's Ollama connections to sign
with, and refuses rather than guesses when the answer is ambiguous.
The token is attached host-side, at the moment of the call. It is never a tool argument, never in the model's context, and never in a transcript — so a prompt injection has nothing to exfiltrate.
Tools are derived per end user from what that person has actually connected and is entitled to — not one shared bot identity carrying the union of everyone's access.
Multi-step work runs on the workflow engine and returns a run handle the agent can poll — retries, branching and state survive the conversation that started them.
Ollama's declared health checks are on the surface too, so an agent can tell "the vendor is down" from "your credential expired" before it burns a retry on either.
The MCP surface is part of the hosted platform. Ollama itself is MIT, and the runtime that executes it is source-available (FSL).
Ollama declares its own checks, so its health is a property of the app rather than something the host guesses at.
Whether this connection's Ollama server answers GET /api/version. A free call: no model is loaded to answer it.