devana

n8n node for Devana AI API

Package Information

Released: 10/23/2025
Downloads: 19 weeklyΒ /Β 59 monthly
Latest Version: 1.5.0
Author: Devana

Documentation

n8n-nodes-devana

Devana AI

Powerful AI workflows with Devana AI in n8n

npm version
License: MIT

Connect your n8n workflows to Devana AI's powerful RAG and Agentic AI capabilities. Build intelligent automation with access to your knowledge base, documents, and AI agents.

✨ Features

  • πŸ€– Dynamic Agent Selection - Dropdown list with searchable agent picker
  • πŸ“Š Rich Metadata Output - Separate outputs for response and metadata (tokens, sources, scores)
  • 🎯 JSON Mode Support - Get structured JSON responses automatically parsed
  • πŸ”„ Dual Outputs - Response on first output, metadata & sources on second output
  • 🌍 Multi-language Support - 10+ languages including EN, FR, ES, DE, IT, PT, ZH, AR, HI, ID
  • πŸ“ File Attachments - Upload and attach files to conversations
  • πŸ’¬ Conversation Management - Continue existing conversations with context
  • 🎨 Custom Parameters - Stop sequences, custom metadata, identity override, hidden mode

πŸš€ Installation

Via n8n Community Nodes (Recommended)

  1. Open your n8n instance
  2. Go to Settings β†’ Community Nodes
  3. Click Install
  4. Enter n8n-nodes-devana
  5. Click Install

Via npm

npm install n8n-nodes-devana

Then restart n8n.

πŸ”‘ Credentials Setup

  1. In n8n, go to Credentials β†’ New
  2. Search for "Devana API"
  3. Fill in:
    • API Key: Your Devana AI API key
    • Base URL: https://api.devana.ai (default)

Getting an API Key

  1. Log in to Devana AI
  2. Navigate to your agent settings
  3. Generate an API key in the "API Access" section

πŸ“– Resources

Chat

Chat Completion

Send messages to your Devana AI agents and get intelligent responses powered by RAG.

Required Parameters:

  • Agent ID (Model): Select from your agents list or enter manually
  • Messages: At least one message (role + content)

Optional Parameters:

  • Temperature (0-1): Control randomness. Higher = more creative
  • Max Tokens: Maximum tokens to generate
  • Top P (0-1): Nucleus sampling for diversity control
  • Stream: Enable streaming responses
  • Conversation ID: Continue an existing conversation
  • Language: Response language (en, fr, es, de, it, pt, zh, ar, hi, id)
  • Response Format:
    • text: Plain text response (default)
    • json_object: Structured JSON output (auto-parsed)
  • Files: Comma-separated file IDs to attach
  • Frequency Penalty (-2 to 2): Reduce repetition
  • Presence Penalty (-2 to 2): Encourage new topics
  • Stop Sequences: Comma-separated stop sequences
  • Metadata: Custom JSON metadata
  • Identity: Custom identity override
  • Hidden Mode: No tracking mode

Outputs:

  1. Response: The AI message content
  2. Metadata & Sources: Usage stats (tokens), sources with RAG scores, finish reason

Agent

Manage your Devana AI agents programmatically.

Operations:

  • List: Get all your agents
  • Get: Retrieve a specific agent by ID
  • Create: Create a new agent
  • Update: Update an existing agent
  • Delete: Delete an agent

Conversation

Manage conversation history.

Operations:

  • Get Messages: Retrieve all messages from a conversation
  • Delete: Delete a conversation

File

Upload files to your Devana knowledge base.

Operations:

  • Upload: Upload a file from binary data

πŸ’‘ Example Workflows

Simple Chat

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”      β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”      β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚   Webhook   │─────▢│    Devana    │─────▢│  Response   β”‚
β”‚   Trigger   β”‚      β”‚  Chat (GPT)  β”‚      β”‚   Format    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜      β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜      β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Advanced RAG Workflow

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”      β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”      β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”      β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚   Manual    │─────▢│    Devana    │─────▢│  Filter by   │─────▢│   Send to    β”‚
β”‚   Trigger   β”‚      β”‚  (RAG Mode)  β”‚      β”‚  RAG Score   β”‚      β”‚    Slack     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜      β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜      β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜      β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              β”‚
                              β”‚ (Metadata Output)
                              β–Ό
                      β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                      β”‚  Log Tokens  β”‚
                      β”‚   & Sources  β”‚
                      β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

JSON Mode Example

Set Response Format to "JSON Object" and prompt:

"Return a JSON object with fields: summary, sentiment (positive/negative/neutral), and key_points (array)"

The node will automatically parse the JSON response into an object you can use in subsequent nodes.

πŸ“Š Output Structure

Response Output (Output 1)

{
  "message": "The AI response text or parsed JSON object"
}

Metadata Output (Output 2)

{
  "usage": {
    "prompt_tokens": 150,
    "completion_tokens": 85,
    "total_tokens": 235
  },
  "finish_reason": "stop",
  "model": "agent_id",
  "response_format": "text",
  "sources": [
    {
      "content": "Source content...",
      "score": 0.95,
      "metadata": {...}
    }
  ],
  "score": 0.92
}

🎯 Use Cases

Customer Support Automation

Email β†’ Devana AI (RAG on knowledge base) β†’ Auto-reply or escalate to human

Content Generation

Trigger β†’ Devana AI (JSON mode) β†’ Parse structured data β†’ Save to database

Document Analysis

Upload file β†’ Devana AI (with file attachment) β†’ Extract insights β†’ Send report

Multi-language Support

Detect language β†’ Devana AI (with lang parameter) β†’ Translate & respond

πŸ”§ Advanced Features

Token Usage Tracking

Use the Metadata output to track token consumption:

// In a Code node after Devana
const tokens = $input.item.json.usage.total_tokens;
if (tokens > 1000) {
  // Alert or log high usage
}

RAG Score Filtering

Filter responses based on source confidence:

// In a Filter node on Metadata output
const score = $json.score;
return score > 0.8; // Only high-confidence responses

Conversation Threading

Build multi-turn conversations:

// Store conversation_id from first response
// Pass it back in subsequent Devana nodes

πŸ› οΈ Development

Build Commands

npm run build     # Compile TypeScript
npm run dev       # Watch mode for development
npm run format    # Format code with Prettier
npm run lint      # Check code with ESLint
npm run lintfix   # Auto-fix ESLint errors

Project Structure

n8n-nodes-devana/
β”œβ”€β”€ credentials/
β”‚   └── DevanaApi.credentials.ts    # API credentials configuration
β”œβ”€β”€ nodes/
β”‚   └── Devana/
β”‚       β”œβ”€β”€ Devana.node.ts          # Main node implementation
β”‚       └── devana.svg              # Node icon
β”œβ”€β”€ dist/                            # Compiled JavaScript (auto-generated)
β”œβ”€β”€ package.json                     # Package configuration
β”œβ”€β”€ tsconfig.json                    # TypeScript config
└── README.md                        # This file

πŸ“š Resources

🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

πŸ“„ License

MIT Β© Devana AI


Made with ❀️ by the Devana AI team

Discussion