Altan
HomeDiscordStatus
HomeDiscordStatus
  1. Flows
  • What is Altan?
  • Support Options
  • Projects
    • Create Your First Project
    • App Navigation & Settings
    • Building Tips
    • The Art of Prompting
    • Publishing Your App
    • Rollback and Checkpoints
    • Instantly Resolve Errors
  • Databases
    • Introduction
    • Security
    • Technical Overview
  • AI Agents
    • What is an AI Agent?
    • Create your first AI Agent
    • Tools
    • Interacting with Your AI Agent
    • Technical Overview
    • Altan Frontend SDK
      • Altan Frontend SDK
  • Flows
    • Create your first Flow
    • Automation basics
    • Adding modules
    • Types of modules
    • Passing data
    • Filters
    • Debugging
    • Retrigger events
    • Version History
    • Overwrite connection
    • Task credits
  • Integration
    • Magic Link
    • Altan Integrator
    • Create your integration
  • Authentication
    • Authentication
  • Payments
    • Checkout Session
    • Object Storage
  • Media
    • Media
  • Partner Program
    • Who are our Partners?
    • Partner Program Benefits
    • How to import projects into Altan
    • How to export projects from Altan
    • Work collaboratively
    • How to start on Altan
    • Become an Altan Partner
  • API Reference
    • account
      • Create Account
      • Get Account Gq
      • Get Account Public
      • Get Account Usage
      • Patch Account
      • Delete Account
      • Get Account Users
      • Create Custom Webhook
      • Create Media
      • Create Media From Url
      • Create Multiple Media
      • Create Token
      • Create Agent
      • Upsert Flow
      • Fetch User Account Notifications
      • Create Altaner
      • Get Selected Template Version
      • Get Latest Template Version
      • Get Template Version
      • Invite User
      • Create Interface
      • Get Members
      • Get Account Connections
      • Get Apikey
      • Delete Apikey
    • project
      • Get Altaner
      • Create Project V2
      • Update Altaner
      • Delete Altaner
      • Get Altaner Flows
      • Clone Altaner
      • Update Altaner Positions
      • Create Altaner Component
      • Update Altaner Component
      • Get Altaner Component
      • Atomic Update Altaner Component
      • Delete Altaner Component
      • Duplicate Altaner
      • Create Idea
    • interface
      • Start Dev Server
      • Get Dev Status
      • Send Dev Error To Agent
      • Revise Interface
      • Get Dev Errors
      • Log Error
      • Create Or Overwrite File
      • Update File
      • Create Multiple Files
      • Read File
      • Read Multiple Files
      • Delete File
      • Rename File
      • Update Files Pattern
      • Search In Files
      • Search And Replace
      • Preview Updates
      • Install Libraries
      • List Tree
      • List Tree Json
      • Get Repo Status
      • List Branches
      • Create Branch
      • Delete Branch
      • Switch Branch
      • Clone Repo
      • Merge Branch
      • Commit Changes
      • Get Diff Changes
      • Accept Changes
      • Discard Changes
      • Push Changes
      • Pull Changes
      • Reset Repo
      • Get Repo Log
      • Restore Main
      • Get Public Interface
      • Get Interface By Name
      • Get Interface
      • Update Interface
      • Delete Interface
      • Get Interface Screenshot
      • Update Interface With Ai
      • Publish Interface
      • Vercel Webhook
      • Get Deployment Status
      • Add Collaborator
      • Get Deployment Logs
      • Fix Deployment With Ai
      • Add Domain
      • Get Domains
      • Remove Domain
      • Verify Domain
      • Add Env Variables
      • Get Env Variables
      • Delete Env Variable
      • Sync Env Variables
      • Rollback Deployment
      • Get Commit Details
      • Restore To Commit
    • flows
      • modules
        • Fetch Module
        • Update Flow Module
        • Delete Module
        • Fetch Graph Module
        • Rename Module
        • Update Position In Canvas
        • Update In Edge Filter
        • Update Route Condition Filter
        • Add Condition
        • Get Available Variables For Mappings
      • hooks
        • Get Webhook
        • Update Hook
      • executions
        • Get File Signed Url
        • Stream Execution
      • Fetch Flow Execution
      • Fetch Flow
      • Update Flow
      • Delete Flow
      • Get Latest Execution
      • Fetch Flow Schema
      • Get Flow From Hook
      • Get Flow Hook
      • Fetch Flow Executions
      • Fetch Flow Executions
      • Upsert Flow Module
      • Add Flow Module
      • Create Flow Duplicate
      • Clone Flow Modules
      • Paste Flow Modules
      • Delete Modules
      • Update Edge
    • media
      • Get Media Url
      • Delete Media
      • Get Multiple Media
      • Get 3D Media
      • Delete Model
      • Create 3D Model
    • agents
      • tools
        • Patch Tool
        • Patch Tool
      • authorizaiton requests
        • Create Authorization Request
        • List Authorization Requests
        • Get Authorization Request
        • Delete Authorization Request
        • Reject Authorization Request
      • Get Altan Agents
      • List Voices
      • Get Agent
      • Update Agent
      • Delete Agent
      • Get Agent
      • Create And Add Tool To Agent
      • Remove Tool And Space
      • Get User Agent Dm Room
      • Get Agent Gate
      • Get Agent Member Usage
  1. Flows

Overwrite connection

In some workflows, you may encounter scenarios where the connection for a module needs to change dynamically. For example, in a workflow designed to send emails, you might want to send the email using a different authenticated account each time based on user input from a webhook request or another trigger.
This guide will show you how to overwrite the connection of a module in your workflow.

Step 1: Access the Connection Settings#

1.
Navigate to the workflow containing the module you wish to modify.
2.
Click on the connection dropdown for the module. You’ll find a button on the right side of the selected connection (as shown below).
image.png

Step 2: Enable Connection Overwrite#

When you click on the button, the Connection Overwrite settings will expand. Here’s what you’ll see:
Override Connection:
This allows you to dynamically set a connection for this module using variables or inputs from your workflow (e.g., data from a webhook or database).
If Override Not Found:
This option determines what happens if the provided connection is invalid or missing. You can choose from:
Exception: Stop the workflow execution and raise an error.
Default: Use the main connection configured for this module.
image.png

Example Use Case: Dynamic Email Sending#

Imagine a scenario where your workflow sends an email based on data received from a webhook. The webhook payload contains the authenticated email connection you want to use.
1.
In the Send Mail module:
Enable Connection Overwrite.
Map the Override Connection field to the variable from the webhook payload containing the connection ID.
2.
Choose the appropriate fallback behavior:
Use Exception if the workflow must stop when the connection is invalid.
Use Default to send the email using the main connection instead.

Benefits of Connection Overwriting#

Dynamic Behavior: Adapt workflows to use different authenticated accounts dynamically without hardcoding multiple modules.
Error Handling: Control fallback behavior with precision, ensuring workflows run reliably.
Customizability: Tailor workflows to meet complex, user-specific scenarios like multi-user email handling, personalized communication, or account-specific actions.
By leveraging this feature, you can create more flexible and powerful workflows that adapt dynamically to input data and specific use cases. 🎉
Modified at 2024-11-29 20:47:20
Previous
Version History
Next
Task credits
Built with