ZBrain Documentation
  • ZBrain Documentation
    • Components of ZBrain
    • Getting started with ZBrain
    • 📚Knowledge base
      • How to create a knowledge base?
      • Knowledge source
      • Information schema
      • File summary
      • Automated reasoning
      • Retrieval testing
      • Knowledge base settings
    • 📱APP
      • How to create a new app?
      • How to set up and customize your app?
      • How to access the app reporting dashboard?
    • 🤖ZBrain AI agents
      • Get started with agents on ZBrain
      • Deploying pre-built agents
      • Creating custom AI agents
        • Agent setup
        • Define input sources
        • Define Flow
          • Key elements of a Flow
          • Flow Components
            • Activepieces Platform
            • AITable
            • Airtable
            • Amazon S3
            • Amazon SNS
            • Amazon SQS
            • Amazon Textract
            • Apify
            • Apollo
            • Approval
            • Asana
            • Azure Communication Services
            • Azure Cosmos DB
            • Azure Document Intelligence
            • Azure OpenAI
            • Azure Translation
            • Bannerbear
            • Baserow
            • Beamer
            • Bedrock Claude
            • Bettermode
            • Binance
            • Bing Search
            • Blackbaud
            • Bonjoro
            • Box
            • Brevo
            • Brilliant Directories
            • Bubble
            • CSV
            • Calendly
            • Certopus
            • Clearout
            • Clockodo
            • Code
            • Confluence
            • Connections
            • Constant Contact
            • Contiguity
            • Contentful
            • Customer.io
            • Crypto
            • Databricks
            • Data Mapper
            • Date Helper
            • DeepL
            • Delay
            • Discord
            • Discourse
            • Drip
            • Dropbox
            • Dust
            • Facebook Pages
            • Figma
            • Files Helper
            • Flowise
            • Flowlu
            • Formbricks
            • Frame
            • Freshdesk
            • Freshsales
            • GCloud Pub/Sub
            • GenerateBanners
            • GhostCMS
            • GitHub
            • GitLab
            • Gmail
            • Google Calendar
            • Google Contacts
            • Google Docs
            • Google Drive
            • Google Forms
            • Google Gemini
            • Google My Business
            • Google Search
            • Google Search Console
            • Google Sheets
            • Google Tasks
            • Groq
            • Hacker News
            • Heartbeat
            • HubSpot
            • HTTP
            • Image Helper
            • Inputs
            • Instagram for Business
            • Intercom
            • Invoice Ninja
            • Jira Cloud
            • Jotform
            • Kimai
            • Kizeo Forms
            • LeadConnector
            • Line Bot
            • Linear
            • LinkedIn
            • LinkedIn Actions
            • LLMRails
            • Lusha
            • MailerLite
            • Mailchimp
            • Mautic
            • Microsoft Dynamics 365 Business Central
            • Microsoft Dynamics CRM
            • Microsoft Excel 365
            • Microsoft OneDrive
            • Microsoft Outlook Calendar
            • Microsoft Teams
            • Mixpanel
            • MongoDB
            • Notion
            • Odoo
            • OpenAI
            • OpenRouter
            • Pastebin
            • PDF
            • Postgres
            • PostHog
            • Pushover
            • Qdrant
            • Queue
            • Razorpay
            • Router
            • Salesforce
            • SendGrid
            • ServiceNow
            • SFTP
            • SharePoint
            • Slack
            • SMTP
            • Snowflake
            • SOAP
            • Spotify
            • Stability AI
            • Stable Diffusion Web UI
            • Storage
            • Stripe
            • SurrealDB
            • SurveyMonkey
            • Taskade
            • Telegram Bot
            • Text Helper
            • Trello
            • Twilio
            • Twitter
            • Utilities
            • WhatsApp Business
            • WordPress
            • XML
            • YouTube
            • ZBrain
            • Zendesk
            • ZeroBounce
            • Zoho Books
            • Zoho CRM
            • Zoho Invoice
            • Zoom
          • How to Define a Flow?
          • How to Test Each Step in the Flow?
        • Configure Additional Settings
        • Test and Deploy Agents
        • How to access, monitor, and manage agent performance and tasks?
    • Settings
    • 📖API Tutorials
      • 📚Knowledge base
        • Automated Reasoning
      • 📱APP
      • 🤖Agents
Powered by GitBook
On this page
  1. ZBrain Documentation
  2. ZBrain AI agents
  3. Creating custom AI agents
  4. Define Flow
  5. Flow Components

OpenRouter

OpenRouter is a powerful piece in ZBrain Flow that provides seamless access to a wide range of AI language models through a unified interface. This component enables users to interact with multiple AI models supported by the OpenRouter platform, offering unprecedented flexibility in choosing and utilizing different AI capabilities within your workflow.

How to Use OpenRouter in ZBrain Flow?

Step 1: Select OpenRouter as Your Connection

  • Click on the '+' button in the Flow and search for OpenRouter.

  • Select OpenRouter.

  • Decide on the action you need, then select it. ZBrain Flow provides several options:

    • Ask LLM – Generate text, code, or other content using AI models from OpenRouter.

    • Custom API Call – Send a custom API request to a specific OpenRouter endpoint.

How to Ask LLM with OpenRouter

Step 1: Connect to OpenRouter

  • From the 'Connection' dropdown, click on 'Create connection'.

  • In the popup window that appears, enter:

    • A unique 'Connection Name' to identify this OpenRouter connection.

    • Your OpenRouter API key, which authenticates your connection to the platform.

  • Click 'Save' to create the connection.

Step 2: Configure LLM Request

  • From the 'Model' dropdown, select the AI model you want to use.

  • In the 'Prompt' field, enter the instruction or query you want the AI to process.

Step 3: Configure Advanced Parameters:

  • Adjust 'Temperature' to control response randomness.

  • Set 'Maximum Tokens' to limit response length.

  • Configure 'Top P' to fine-tune token selection.

How to Use OpenRouter in ZBrain Flow?

Step 1: Connect to OpenRouter

  • To connect to your OpenRouter account, follow the first step in the "How to Ask LLM with OpenRouter."

Step 2: Enter API Endpoint

  • In the 'URL' field, enter the full OpenRouter API endpoint you want to call.

Step 3: Select Request Method

  • From the 'Method' dropdown, choose the appropriate HTTP method.

Step 4: Configure Headers

  • Click 'Add Item' in the 'Headers' section to add any additional custom headers required for your specific API request. Note that authorization headers are automatically included in your connection.

Step 5: Add Query Parameters

  • Click 'Add Item' in the 'Query Parameters' section. Enter any required URL parameters for your API call.

Step 6: Specify Request Body

  • For POST or PUT requests, enter the JSON body content according to the OpenRouter API documentation.

Step 7: Configure Request Options

  • Enable 'No Error on Failure' if you want the flow to treat error responses as valid.

  • Set a 'Timeout' value (in seconds) to limit how long to wait for a response.

PreviousOpenAINextPastebin

Last updated 1 month ago

🤖