Package Information
Available Nodes
Documentation generating…
Documentation
n8n-nodes-tokenlab
Use TokenLab chat models as the language model inside n8n AI Agent workflows.
This community node package contains two pieces:
- Credential TokenLab API (
tokenlabApi): a Base URL and an API key. - Sub-node TokenLab Chat Model (
tokenLabChatModel): emitsai_languageModel, so any AI Agent node can use it as its chat model. The model list is loaded from TokenLab'sGET /v1/models?category=chat.
Install
Community nodes have to be enabled on the instance first: Settings → Community Nodes → allow community nodes (N8N_COMMUNITY_PACKAGES_ENABLED=true).
Then open Settings → Community Nodes → Install, enter the package name and confirm:
n8n-nodes-tokenlab
For local development, run npm pack in this directory and install from the resulting tarball, or put the directory into ~/.n8n/custom/ and restart n8n.
Credential
- Create an API key in the TokenLab console: https://tokenlab.sh/dashboard/api?tab=keys&utm_source=npm-readme
- In n8n create a TokenLab API credential:
- Base URL:
https://api.tokenlab.shby default; point it at your own proxy if you use one. - API key: the key from step 1.
- Base URL:
- Save. The credential sends
Authorization: Bearer <API key>and tests the connection withGET /v1/models?category=chat.
Workflow example
An AI Agent node with a TokenLab Chat Model sub-node connected on the ai_languageModel slot:
{
"nodes": [
{
"parameters": {},
"id": "agent-1",
"name": "AI Agent",
"type": "@n8n/n8n-nodes-langchain.agent",
"typeVersion": 1.7,
"position": [0, 0]
},
{
"parameters": {
"model": "claude-sonnet-5-5",
"temperature": 0.7,
"maxTokens": -1
},
"id": "model-1",
"name": "TokenLab Chat Model",
"type": "n8n-nodes-tokenlab.tokenLabChatModel",
"typeVersion": 1,
"position": [-240, 0],
"credentials": {
"tokenlabApi": { "id": "REPLACE_WITH_CREDENTIAL_ID", "name": "TokenLab API" }
}
}
],
"connections": {
"TokenLab Chat Model": {
"ai_languageModel": [[{ "node": "AI Agent", "type": "ai_languageModel", "index": 0 }]]
}
}
}
Pick a model from the dropdown or type an ID directly, e.g. claude-sonnet-5-5, claude-haiku-4-5, qwen3.8-max. The full catalog and prices are on https://tokenlab.sh/en/models?utm_source=npm-readme
Step-by-step setup, the workflow example and cost notes are in the docs: https://tokenlab.sh/docs/en/integrations/n8n?utm_source=npm-readme
Notes
- Built on
@n8n/ai-node-sdk(supplyModel,type: 'openai'). That SDK is in preview and may change upstream; the usage is kept in one place (supplyData) and loaded lazily. - Chat models only; image, embedding and other capabilities are out of scope for this package.