SmartLead icon

SmartLead

Comprehensive SmartLead API integration for email marketing automation

Overview

This node integrates with the SmartLead API to manage leads and their subscriptions within email marketing campaigns. Specifically, the "Unsubscribe from Campaign" operation allows you to unsubscribe a lead (identified by their email address) from a particular campaign using its campaign ID.

This functionality is useful in scenarios where you want to respect user preferences or comply with regulations by removing leads from ongoing email campaigns. For example, if a lead requests to stop receiving emails from a specific campaign, this operation can be used to update their subscription status accordingly.

Practical examples:

  • Automatically unsubscribe users who click an unsubscribe link in your emails.
  • Remove leads from a campaign after they have converted or opted out.
  • Manage lead preferences dynamically based on interactions or external triggers.

Properties

Name Meaning
Campaign ID The unique identifier of the campaign from which the lead will be unsubscribed.
Email Address The email address of the lead to unsubscribe from the specified campaign.
Additional Fields (Not applicable for this operation; present in other operations)

Output

The node outputs JSON data representing the response from the SmartLead API after attempting to unsubscribe the lead from the campaign. This typically includes confirmation of the unsubscription or details about the updated lead status.

The output structure is an array of JSON objects, each corresponding to an input item processed. Each object contains the API response data under the json field.

No binary data output is involved in this operation.

Dependencies

  • Requires an API key credential for authenticating with the SmartLead API.
  • The node makes HTTP POST requests to the endpoint:
    https://server.smartlead.ai/api/v1/campaigns/{campaignId}/leads/unsubscribe
  • Proper configuration of the API authentication credential in n8n is necessary.

Troubleshooting

  • Invalid JSON Errors: Not applicable directly for this operation since inputs are simple strings, but ensure that the Campaign ID and Email Address are correctly provided.
  • API Authentication Failures: Ensure the API key credential is valid and has sufficient permissions.
  • Lead Not Found or Already Unsubscribed: The API may return errors if the lead email does not exist in the campaign or is already unsubscribed. Verify the lead's presence before unsubscribing.
  • Network Issues: Check connectivity to the SmartLead API endpoint.
  • Missing Required Parameters: Both Campaign ID and Email Address are required; missing either will cause errors.

Links and References

Discussion