Skip to main content

n8n Integration

Lucid provides n8n community nodes for visual workflow automation. Connect AI inference, passport management, and receipt verification into your n8n workflows.

Available Nodes

NodeDescription
Lucid InferenceRun chat completions via TrustGate
Lucid PassportCreate, read, update, delete passports
Lucid ReceiptGet and verify inference receipts
Lucid EpochQuery epoch status and on-chain anchoring
Lucid AgentTrigger agent orchestration pipelines

Setup

1. Install the Community Node

In your n8n instance, go to Settings → Community Nodes and install:
n8n-nodes-lucid
Or install via CLI:
cd ~/.n8n
npm install n8n-nodes-lucid

2. Configure Credentials

  1. Go to Credentials → Add Credential → Lucid API
  2. Enter your API key from the Dashboard
  3. Set the base URL (default: https://api.lucid.foundation)

3. Use in Workflows

Drag any Lucid node from the sidebar into your workflow canvas.

Example: Verified AI Chatbot

[Webhook Trigger] → [Lucid Inference] → [Lucid Receipt Verify] → [IF verified] → [Slack Post]
This workflow:
  1. Receives a webhook with a user question
  2. Runs inference through Lucid (with receipt)
  3. Verifies the receipt signature
  4. If valid, posts the verified answer to Slack

Example: Model Monitoring

[Cron (hourly)] → [Lucid Passport List] → [Loop] → [Lucid Inference (test)] → [IF latency > 2s] → [Email Alert]
This workflow:
  1. Runs hourly via cron trigger
  2. Lists all active passports
  3. Sends a test inference to each model
  4. Alerts if any model’s latency exceeds the threshold

Node Configuration

Each Lucid node exposes these common fields:
FieldDescription
OperationThe specific action (e.g., create, list, verify)
Passport IDTarget passport for the operation
ParametersOperation-specific parameters (JSON or individual fields)
Output data is available as JSON for downstream nodes via n8n expressions like {{ $json.receipt.id }}.