Latenode

Scenario for sending an email to a travel agency client who has just booked a tour

This template receives a booking on a webhook, asks ChatGPT for a sightseeing email from the traveler's name, age, origin city, and destination city, then sends that message with Mailgun. Connect Mailgun and put the Mailgun API key on that connection. ChatGPT is a Latenode AI step, so you do not paste an OpenAI key.

Updated Sep 16, 2026Est. run: 15sEst. cost: $0.0009
How Latenode estimates time and cost

Latenode bills workflow runtime in CPU seconds. The first 10,000 CPU seconds are free each month, then usage follows pay-as-you-go CPU-second pricing. Plug-and-Play (PnP) AI nodes are billed separately—each PnP token is $1 USD, charged pay-as-you-go at vendor cost plus a small processing fee, with no API keys required.

Full pricing — how CPU seconds work →

Workflow preview

What this template does

  • Writes a sightseeing email from the booking details
  • Sends through Mailgun to the traveler
  • Uses ChatGPT as a Latenode AI step
  • Keeps the Mailgun API key on the Mailgun connection

How it works

1
Trigger

Receive the booking

A webhook starts the scenario when your booking tool posts the traveler record.

2
Logic

Build the briefing

JavaScript reads name, age, origin city, and destination city into a ChatGPT prompt.

3
AI

Write the sightseeing email

ChatGPT returns the subject and body. ChatGPT is Latenode AI, so you do not paste an OpenAI key.

4
Action

Send with Mailgun

Mailgun delivers the email to the traveler. Put the Mailgun API key on the Mailgun connection.

Setup guide

1

Add the webhook

Add a webhook trigger and copy its URL. Send JSON with name, age, origin city, destination city, and the traveler email.

2

Connect Mailgun

Add a Mailgun connection and paste your Mailgun API key there. Choose the sending domain.

3

Wire ChatGPT and send

In JavaScript, build the prompt from the booking fields. Ask ChatGPT for subject and body, then send with Mailgun to the traveler email. ChatGPT is a Latenode AI step. Post a test booking and confirm the email arrives.

Requirements

A webhook caller that posts the booking payload
A Mailgun domain and API key stored on the Mailgun connection
ChatGPT available as a Latenode AI step

FAQ

Common questions about this template

Each run uses credits on your Latenode plan. We charge for processing time (1 credit = 30 seconds). Your actual cost depends on your plan and how long the run takes. See pricing plans for plans and how credits work. Plug-and-Play AI nodes are billed separately.

More templates

You might also like

Browse all templates →

123FormBuilder to Insightly: Create leads from form submissions

Manually copying form responses into your CRM wastes time and risks errors. This integration captures each New Submission event from 123FormBuilder and uses it to Create a Lead in Insightly, mapping the respondent's name, email, and custom fields directly into a new lead record. Marketing managers and sales teams can eliminate data entry and get leads into Insightly instantly for follow-up. By connecting 123FormBuilder's form capture with Insightly's CRM, you keep your sales pipeline fed without manual work.

8s~$0.002

Create a Pipeline deal from a new Discord channel message

Sales teams often miss leads buried in Discord conversations. This scenario captures every new message in a chosen Discord channel and creates a corresponding deal in Pipeline, using the message text as the deal description and the author's username as part of the deal name. Sales managers and business development reps can log inbound signals from team discussions directly into Pipeline CRM without manual data entry. The connection turns Discord into a lead source, so no opportunity slips through the cracks.

8s~$0.002

Create a Pipeline deal when a new HubSpot deal is added

Manually copying deal data from HubSpot to Pipeline wastes time and risks errors. This automation triggers on the New Deal event in HubSpot and then runs the Create Deal action in Pipeline, mapping the deal name, amount, and associated contact email and name. Sales operations teams and CRM administrators who use both HubSpot and Pipeline can eliminate duplicate data entry. HubSpot captures the initial deal, and Pipeline receives a matching record immediately, so both systems stay aligned without manual work.

8s~$0.002