HttpRequest Automate

For Fastmail, this automated workflow manages masked email addresses efficiently. It retrieves all masked emails, creates new masked emails with specified states, and updates their status (pending, enabled, disabled, or deleted). The workflow generates a user-friendly HTML table to display the masked emails, enhancing visibility and management. By integrating with webhooks, it provides real-time updates and responses, streamlining email management tasks and improving user experience.

7/8/2025
11 nodes
Medium
webhookmediumrespondtowebhooksticky noteadvancedapiintegrationlogicrouting
Categories:
Webhook TriggeredMedium Workflow
Integrations:
RespondToWebhookSticky Note

Target Audience

This workflow is ideal for:
- Developers: Those who need to manage masked email addresses through Fastmail's API.
- Businesses: Companies that require privacy in email communications and want to automate the process of creating and managing masked emails.
- Marketers: Professionals looking to protect their identities when interacting with clients or users.
- IT Administrators: Individuals responsible for managing email security and privacy within an organization.
- Automation Enthusiasts: Anyone interested in using n8n for automating webhooks and API interactions.

Problem Solved

This workflow addresses the challenge of managing masked email addresses effectively through Fastmail's API. It automates the process of:
- Retrieving all masked emails associated with a Fastmail account.
- Creating new masked email addresses with specific states (e.g., pending, enabled).
- Updating the state of existing masked emails, allowing for easy management of their lifecycle.
- Deleting masked emails when they are no longer needed, ensuring that users can maintain control over their email privacy.

Workflow Steps

  • Webhook Node: Listens for incoming requests to manage masked emails, requiring Basic Authentication for security.
    2. Session Node: Sends a request to Fastmail's API to obtain session information, necessitating an HTTP Header Auth credential with a Fastmail API token.
    3. Switch Node: Routes the workflow based on the state of the incoming masked email request, handling various outcomes such as pending, enabled, disabled, and deleted.
    4. HTTP Request Nodes: Execute API calls to Fastmail for masked emails, including retrieving, creating, updating, and deleting operations, all requiring the appropriate authentication.
    5. Set Node: Gathers the retrieved masked email list into an array for further processing.
    6. HTML Node: Generates an HTML template to display the masked email addresses in a user-friendly table format.
    7. Respond to Webhook Node: Sends back the generated HTML table to the client in response to the webhook request.
  • Customization Guide

    Users can customize this workflow by:
    - Modifying the API Endpoints: Change the Fastmail API URLs in the HTTP Request nodes to accommodate any updates or different functionalities.
    - Adjusting States: Alter the states handled in the Switch Node to include additional conditions or states that are relevant to their specific use case.
    - Customizing HTML Template: Modify the HTML Node to change the appearance of the output, including styles and layout, to better match their branding or preferences.
    - Adding New Functionality: Integrate additional nodes for more complex processing or to connect with other services, enhancing the workflow’s capabilities.
    - Configuring Authentication: Ensure that the authentication credentials used in the workflow are updated and secured according to organizational policies.