Triage inbound iMessage conversations into Slack

When a customer texts in, pull the thread, look them up in HubSpot, and post a triage card to Slack with a suggested next action.

Agentic Task
LoopMessageHubSpotSlackCustomer SupportSalesFeedback TriageNotifications & AlertsLead Enrichment

Build me an inbound iMessage triage agent that runs every time a customer sends us a new message. The trigger is a LoopMessage webhook fired on inbound messages.

When the webhook fires, the agent should:

1. Read the inbound payload to get the sender's contact (phone number or email) and the message text.

2. Call LoopMessage Get Message History for Contact for that sender to load the recent thread so it has conversation context (last ~10 messages, both directions).

3. Call HubSpot Search Contacts using the sender's phone number or email to identify who they are. If a contact match is found, also run HubSpot Search Deals and HubSpot Search Tickets filtered by that contact's associated id to see any open deals or tickets. If no match is found, treat them as an unknown lead.

4. Classify the intent of the latest inbound message into one of: support question, sales interest, scheduling, spam, or simple acknowledgment (things like 'thanks', 'got it', 'ok').

5. Post a structured triage summary to a Slack channel via Slack Send a Message. The Slack post should include: the contact's name (or 'Unknown' if not in HubSpot), the last 2 or 3 messages from the thread, the suggested category, any open HubSpot deal or ticket titles with links to the HubSpot record, and a one-line recommended next action.

6. If the intent is a simple acknowledgment, reply automatically via LoopMessage Send Message with a short confirmation back to the customer (something brief and human, like 'You got it, talk soon!'). Skip the auto-reply for spam. For every other category, do not auto-reply, leave the human to respond from the Slack thread.

Configurable inputs I want to set when I install this: the Slack channel id to post into, the LoopMessage sender id to reply from, and the HubSpot owner or pipeline filter to scope deal lookups (optional).

Keep the Slack message compact and skimmable. Use bold for the contact name and category, and quote the recent messages so the on-call person can decide in five seconds whether to jump in.

Additional information

What does this prompt do?
  • Listens for every inbound iMessage, SMS, or WhatsApp that hits your LoopMessage number
  • Pulls the recent thread and looks the sender up in HubSpot so the on-call person sees who is messaging and what is open
  • Classifies the message as support, sales, scheduling, spam, or a quick acknowledgment
  • Posts a tidy triage card to a Slack channel with the last few messages, the open HubSpot record, and a one-line suggested next step
  • Auto-replies with a brief confirmation when the customer just says thanks, so your team only sees messages that actually need attention
What do I need to use this?
  • A LoopMessage account with an active sender and inbound webhooks enabled
  • A HubSpot login with access to contacts, deals, and tickets
  • A Slack workspace and the channel you want triage cards posted into
  • A General Input account to host the agent
How can I customize it?
  • Change which Slack channel the triage card lands in, or route different categories to different channels
  • Adjust the auto-reply text, or turn the auto-reply off entirely so a human always responds
  • Tighten or loosen the intent categories to match how your team labels conversations
  • Change which HubSpot fields appear on the Slack card, such as deal stage, owner, or last activity date

Frequently asked questions

What happens if the sender is not in HubSpot yet?
The triage card still posts to Slack and is labeled as an unknown contact. The on-call person can decide whether to create the contact in HubSpot from there.
Will customers get auto-replied to every time?
No. The agent only auto-replies when the message is a short acknowledgment like 'thanks' or 'got it'. Anything that needs a real answer is left for a human to respond from Slack.
Can I use this with SMS or WhatsApp instead of iMessage?
Yes. LoopMessage handles iMessage, SMS, RCS, and WhatsApp on the same number, and the agent will triage inbound messages from any of those channels.
Do I need a paid HubSpot plan?
You need a HubSpot account that lets you search contacts, deals, and tickets. Most paid tiers cover this. On HubSpot Free, contact lookup will still work but deal and ticket context may be limited.
Can the agent open a HubSpot ticket automatically for support questions?
Yes, you can extend it. Once you have this prompt running, ask the agent to also create a HubSpot ticket whenever the category is 'support question' and link it back in the Slack card.

Turn your shared text inbox into a Slack triage channel.

Connect LoopMessage, HubSpot, and Slack once, and Geni will route every inbound text through your CRM and into Slack with a suggested next action.