{
  "schema_version": "1.0.0",
  "id": "demo-request-instant-email",
  "title": "Answer a HubSpot demo request with a booking link",
  "category": "speed-to-lead",
  "difficulty": "beginner",
  "featured": false,
  "description": "A HubSpot demo form submission gets a personal-sounding email with a booking link at once, a Slack heads-up, and a follow-up task in HubSpot.",
  "tags": [
    "speed-to-lead",
    "hubspot",
    "gmail",
    "demos",
    "slack"
  ],
  "apps": [
    "HubSpot",
    "Code by Zapier",
    "Gmail",
    "Slack"
  ],
  "plan": {
    "minimum": "Professional",
    "reasons": [
      "multi-step Zap: 4 steps after the trigger"
    ]
  },
  "tasks": {
    "typical": 4,
    "max": 4
  },
  "trigger": {
    "app": "HubSpot",
    "event": "New Form Submission",
    "kind": "polling",
    "title": "Demo form submitted",
    "why": "Fires for each submission of the demo form.",
    "config": {
      "Form": "Book a demo"
    },
    "outputs": [
      "submitted_at",
      "contact_id",
      "full_name",
      "email",
      "company",
      "team_size",
      "use_case"
    ],
    "sample": "sample-trigger.json"
  },
  "steps": [
    {
      "key": "name",
      "kind": "code",
      "app": "Code by Zapier",
      "event": "Run JavaScript",
      "title": "Split the name",
      "why": "The form asks for one name field; the email greets by first name.",
      "code": {
        "language": "javascript",
        "module": "split-name",
        "file": "code/split-name.js"
      },
      "input_data": {
        "full_name": "{{trigger.full_name}}"
      },
      "outputs": [
        "first_name",
        "last_name",
        "display_name"
      ]
    },
    {
      "key": "reply",
      "kind": "action",
      "app": "Gmail",
      "event": "Send Email",
      "title": "Send the booking link",
      "why": "Sent from the rep's own Gmail, plain text, so it reads like a person wrote it.",
      "fields": {
        "To": "{{trigger.email}}",
        "Subject": "Your demo of YOUR_PRODUCT_NAME",
        "Body Type": "plain",
        "Body": "Hi {{name.first_name}},\n\nThanks for asking for a demo for {{trigger.company}}. You mentioned: \"{{trigger.use_case}}\". I will tailor the 30 minutes to that.\n\nPick any slot that suits you here: YOUR_BOOKING_LINK\n\nTalk soon,\nYOUR_NAME",
        "From Name": "YOUR_NAME"
      },
      "outputs": [
        "id",
        "thread_id"
      ]
    },
    {
      "key": "heads_up",
      "kind": "action",
      "app": "Slack",
      "event": "Send Channel Message",
      "title": "Tell the sales channel",
      "why": "So nobody else emails the same prospect.",
      "fields": {
        "Channel": "#demo-requests",
        "Message Text": "Demo request from {{name.display_name}} at {{trigger.company}} ({{trigger.team_size}} people). Booking link sent. Use case: {{trigger.use_case}}",
        "Send as a bot?": "Yes",
        "Bot Name": "Zap alerts",
        "Include a link to this Zap?": "No"
      },
      "outputs": [
        "ts",
        "permalink"
      ]
    },
    {
      "key": "task",
      "kind": "action",
      "app": "HubSpot",
      "event": "Create Engagement",
      "title": "Add a follow-up task",
      "why": "A HubSpot task due in two days to chase prospects who have not booked.",
      "fields": {
        "Type": "Task",
        "Associated Contact ID": "{{trigger.contact_id}}",
        "Subject": "Chase demo booking: {{name.display_name}}",
        "Body": "Booking link sent automatically. If no meeting is booked, follow up personally.",
        "Due Date": "{{meta.human_now}} +2 days",
        "Status": "Not started"
      },
      "outputs": [
        "id"
      ]
    }
  ]
}
