ZAppwrite icon

ZAppwrite

Use Appwrite's API from inside N8N, updated by @ZachHandley

Overview

The node integrates with Appwrite's Messaging API to create an SMTP provider configuration. This allows users to set up and manage SMTP email sending capabilities within their Appwrite project via n8n workflows. It is useful for automating the creation of SMTP providers that can be used to send emails through custom SMTP servers.

Typical use cases include:

  • Automating the setup of new SMTP providers when onboarding new email services.
  • Managing multiple SMTP configurations programmatically.
  • Integrating email sending capabilities into larger automated workflows.

For example, a user could automate creating an SMTP provider with specific host, port, username, and password details, enabling email sending from their application without manual configuration in the Appwrite console.

Properties

Name Meaning
Provider ID Unique identifier for the SMTP provider. Can be generated automatically or provided manually.
Provider Name Human-readable name for the SMTP provider.
Host SMTP server hostname (e.g., smtp.example.com).
Port Port number for the SMTP server (default is 587).
Username Username for authenticating with the SMTP server.
Password Password for authenticating with the SMTP server.
Encryption Type of encryption used by the SMTP server. Options: None, SSL, TLS.
Auto TLS Boolean flag to enable automatic TLS negotiation.
Mailer Optional mailer name string identifying the mailer.
From Name Sender's display name for outgoing emails.
From Email Sender's email address for outgoing emails.
Reply To Name Name to use for reply-to field in emails.
Reply To Email Email address to use for reply-to field in emails.
Enabled Boolean flag indicating whether the SMTP provider is enabled.
Additional Fields Collection of optional fields such as BCC, CC, draft status, HTML content flag, scheduled time, and target/topic/user IDs for message routing.

Note: The properties with suffix Direct (e.g., hostDirect, portDirect) are specifically used in the "Create SMTP Provider" operation.

Output

The node outputs a JSON object representing the created SMTP provider resource as returned by the Appwrite API. This typically includes details such as the provider ID, name, host, port, authentication credentials (masked or omitted), encryption settings, and enabled status.

No binary data output is involved.

Dependencies

  • Requires an active Appwrite project with Messaging service enabled.
  • Needs an API key credential configured in n8n to authenticate requests to the Appwrite API.
  • The node uses the official Appwrite SDK internally to communicate with the Appwrite backend.

Troubleshooting

  • Authentication errors: Ensure the API key credential has sufficient permissions and is correctly configured.
  • Invalid SMTP details: Verify the host, port, username, and password are correct and that the SMTP server is reachable.
  • Encryption mismatch: If emails fail to send, check that the encryption type matches the SMTP server requirements.
  • Provider ID conflicts: Using a non-unique provider ID may cause errors; use the unique() function to generate unique IDs.
  • Missing required fields: All required fields like Provider ID, Provider Name, Host, and Port must be provided; missing these will cause validation errors.

Links and References

Discussion