Connect
Establishes a connection to Google's Gemini API using an API key.
Common Properties
- Name - The custom name of the node.
- Color - The custom color of the node.
- Delay Before (sec) - Waits in seconds before executing the node.
- Delay After (sec) - Waits in seconds after executing node.
- Continue On Error - Automation will continue regardless of any error. The default value is false.
info
If the ContinueOnError property is true, no error is caught when the project is executed, even if a Catch node is used.
Options
- API Key - The Google Gemini API key credential used to authenticate with the service.
Output
- Connection Id - A unique identifier for the established connection, used by other Gemini nodes.
How It Works
The Connect node establishes a connection to Google's Gemini API using the provided API key. When executed, the node:
- Retrieves the API key from the credentials
- Creates a client configuration with the API key
- Initializes a new Gemini client with the configuration
- Generates a unique connection ID
- Stores the client for use by other nodes
- Returns the connection ID as output
Requirements
- A valid Google Gemini API key with appropriate permissions
Error Handling
The node will return specific errors in the following cases:
- Empty or invalid API key credential
- Failed to create client due to API key issues
- Client initialization failure
Usage Notes
- The connection ID output is required by all other Google Gemini nodes
- The API key should be stored as a credential for security
- Each connection creates a unique client instance
- The connection remains active until the workflow ends or an explicit disconnect