Integration Guide
This guide covers how to connect your local development tools to deployed Lucid agents, enabling observability, TEE verification, and secure model access from your terminal.
Alpha Access Required
Lucid is in private alpha. Some integrations described here may not yet be available. Request access to get started.
Looking for deployment instructions?
See the Deployment Guide to deploy agents first, then return here to connect your tools.
Overview
Lucid supports integrating with popular development tools so you can:
- Route requests through your deployed agent's auditor chain
- Verify TEE attestation from your local environment
- Get observability into your coding sessions via AI Passport
| Tool | Type | Best For |
|---|---|---|
| OpenCode | Terminal AI | Fast, lightweight coding assistance |
| Aider | AI Pair Programming | Git-aware code editing |
| Claude Code | CLI | Anthropic's official Claude CLI |
OpenCode
OpenCode is a Go-based terminal AI assistant optimized for speed and low resource usage. Connect it to your Lucid agent for audited, TEE-verified coding assistance.
Installation
Or via Homebrew:
brew install opencode-ai/tap/opencode
Connect to Your Agent
Get your agent's endpoint from the Observer UI or CLI:
my-agent running https://my-agent.env-abc123.lucid.ai
lucid credentials my-agentAPI Key: sk-lucid-xxxxxxxxxxxx
Configure OpenCode to use your agent:
opencode config set --api-key sk-lucid-xxxxxxxxxxxxAPI key configured (hidden)
Verify Connection
Endpoint: https://my-agent.env-abc123.lucid.ai
Model: Qwen/Qwen2.5-Coder-32B-Instruct
TEE: AMD SEV-SNP (verified)
Auditors: injection, eval
Usage
Once configured, use OpenCode as normal. All requests route through your Lucid agent:
[Lucid] Request audited: injection=pass, eval=pass
Here's the refactored version:
...
Configuration Reference
| Setting | Command | Description |
|---|---|---|
| Endpoint | opencode config set --endpoint <url> |
Lucid agent URL |
| API Key | opencode config set --api-key <key> |
Agent API key |
| Model | opencode config set --model <id> |
Override model (optional) |
| Verify TEE | opencode config set --verify-tee true |
Require TEE attestation |
Aider
Aider is an AI pair programming tool that works with your git repository. Connect it to your Lucid agent for audited code editing.
Installation
Connect to Your Agent
Set environment variables to route through Lucid:
export OPENAI_API_BASE=https://my-agent.env-abc123.lucid.ai/v1
export OPENAI_API_KEY=sk-lucid-xxxxxxxxxxxx
Or create a .env file in your project:
OPENAI_API_BASE=https://my-agent.env-abc123.lucid.ai/v1
OPENAI_API_KEY=sk-lucid-xxxxxxxxxxxx
Usage
Model: Qwen/Qwen2.5-Coder-32B-Instruct (via Lucid)
> Add input validation to the user registration endpoint
I'll add validation to the registration endpoint...
Claude Code
Claude Code is Anthropic's official CLI for Claude. Connect it to Lucid for observability and passport verification.
Installation
Connect to a Lucid Agent
Claude Code supports OpenAI-compatible API endpoints. Configure it to route through your Lucid agent:
# Set environment variables to point Claude Code at your agent
export OPENAI_API_BASE=https://my-agent.env-abc123.lucid.ai/v1
export OPENAI_API_KEY=sk-lucid-xxxxxxxxxxxx
Usage
With these environment variables set, requests route through your Lucid agent's auditor chain, providing TEE-verified AI Passport tracking in the Observer dashboard.
Lucid Browser Extension
For browser-based AI agents, install the Lucid Browser Extension to verify AI Passport authenticity.
Installation
Coming Soon
The browser extension is under development. Request access for early availability.
- Click the Lucid extension icon
- Go to Settings → Agent Connection
- Configure your agent URL and API key
Features
| Feature | Description |
|---|---|
| Passport Verification | Validates AI agent passports on visited pages |
| TEE Badges | Shows TEE status for verified agents |
| Action Approval | Human-in-the-loop for Browser Use agents |
Troubleshooting
Connection Issues
Error: "Connection refused"
lucid status my-agentNAME STATUS ENDPOINT
my-agent stopped -
lucid start my-agentAgent 'my-agent' started.
Error: "TEE verification failed"
Ensure your agent is running in a TEE-enabled environment:
Check that your agent is deployed with TEE enabled:
lucid apply -f my-env.yaml # Ensure teeMode is set
Authentication Issues
Error: "Invalid API key"
Regenerate your API key:
Update your tool configuration with the new key.
Next Steps
- Deployment Guide - Deploy your first agent
- AI Passports - Understand passport verification
- Auditor Development - Create custom auditors