Automate new customer onboarding after a closed deal
When a HubSpot deal closes won, set up the Stripe customer, update your billing trackers, and walk the customer through payment to production access.
Build me an agent workflow that runs our full new-customer onboarding sequence the moment a deal closes. Today this is a 10-step manual checklist that I run; I want the agent to do as much of it as possible and keep the Linear onboarding ticket as the running source of truth.
Trigger: HubSpot deal moves to Closed Won (use the HubSpot deals updated / stage changed trigger and filter to closed-won).
When that fires, the agent should:
1. Read the deal in HubSpot. Pull the customer / company name, primary contact name and email, deal amount (ARR), plan type (month-to-month vs annual, configurable property), deal owner, customer domain, and the contract close date.
2. Find the signed contract in our Google Drive contracts folder. List files in that folder, match on customer name. If no match yet, retry on a backoff for up to a few hours; if still missing, comment in the Linear onboarding ticket pinging the deal owner and stop, do not proceed without a contract.
3. Find the Linear onboarding ticket for this customer. The ticket is created automatically by Zapier when the deal hits closed-won, so it should already exist. Match by customer name in the ticket title. From here on, every step the agent completes should be added as a comment on this Linear ticket so I have one place to read the audit trail.
4. Create the customer in Stripe. Use Search Customers first to dedupe by email and domain; if not found, Create Customer with name, email, address pulled from HubSpot, and metadata containing the HubSpot deal id, ARR, plan type, and signed contract Drive link. Then Create Subscription for that customer using the Stripe price that maps to the plan type (configurable mapping; ask me for the price id per plan during setup).
5. Update our trackers in Google Sheets. Append a row to the ARR tracking sheet (customer, ARR, plan type, close date, deal owner, Stripe customer id, Stripe subscription id) and a row to the billing sheet (same fields plus contract link). The exact sheet ids and column orders should be configurable.
6. Branch on plan type.
6a. If plan is month-to-month: create an issue in Pylon for this customer using the body of our existing credit-card-required macro (the macro template text should be configurable; agent should reuse it verbatim). Then poll Stripe List Payment Methods for that customer on a schedule (default every 30 minutes for up to 10 days). As soon as a payment method shows up, post a comment in Linear that payment is on file and continue to step 7. If we time out without one, ping the deal owner in Linear and stop.
6b. If plan is annual, or month-to-month with a payment method already attached: continue straight to step 7.
7. Production access checkpoint. We control production tenant access in our feature flag system, which is not yet integrated. Post a comment on the Linear ticket assigned to me (Conner) saying "ready to enable production access" with the customer name and domain, and pause the workflow until that step on the ticket is marked done (either via a checkbox state on the Linear ticket, or by me commenting "done" on that thread, agent's choice on the cleanest signal). Once flipped, continue.
8. Send the welcome ticket through Pylon. Reply on the Pylon thread (or create a new issue if there isn't one yet) using our existing production-access-granted macro template. Include the customer's domain so they know what's live.
9. Final Linear comment: post a summary on the onboarding ticket listing every step completed with timestamps, the Stripe customer + subscription ids, the Drive contract link, and a row link in each Sheet. Mark the ticket done.
Defaults / behavior: be idempotent (if rerun on the same deal, do not duplicate the Stripe customer, the sheet rows, or the Pylon ticket). On any failure, comment the error on the Linear ticket with enough detail that I can intervene, and stop, do not silently retry destructive steps. Keep the prompt configurable enough that I can swap the Drive folder, Sheet ids, plan-to-price mapping, macro templates, and timeout windows without editing the agent.
Additional information
What does this prompt do?
- Watches HubSpot for deals moving to Closed Won and kicks off a full onboarding sequence end to end.
- Pulls the signed contract out of your Drive folder, creates the Stripe customer and subscription, and appends a row to your ARR and billing Google Sheets.
- Branches on plan type: month-to-month customers get a Pylon message asking for a credit card, and the workflow waits to confirm payment is on file before moving on.
- Keeps the Linear onboarding ticket up to date at every step, and sends the customer their welcome message in Pylon once production access is enabled.
What do I need to use this?
- A HubSpot account where you mark deals Closed Won, with deal owner and customer contact filled in.
- A Google Drive folder where signed contracts land, plus your ARR and billing Google Sheets.
- A Stripe account with the products and prices you sell already set up.
- A Linear workspace where onboarding tickets are created (today via Zapier, or directly).
- A Pylon workspace with the macros you use for credit card requests and welcome messages.
How can I customize it?
- Tell it which HubSpot deal property to read for plan type (month-to-month vs annual) and which Stripe price each plan maps to.
- Point it at your specific Drive folder, your ARR sheet, and your billing sheet, and tell it which columns to fill in.
- Adjust the wait behavior for month-to-month customers: how often to check for a payment method, when to give up, and who to ping if it stalls.
- Decide where the production access step lives: keep it as a human checkpoint that pings you in Linear, or hand it off to whoever runs your feature flag tool.
Frequently asked questions
Does my AE still have to do anything manually after closing the deal?
What happens when a customer is on a month-to-month plan?
We control production access through a separate feature flag tool. Can the workflow handle that?
Will it work if our onboarding ticket is created by Zapier instead of by the workflow itself?
What if the contract is not in the Drive folder yet when the deal closes?
Stop running new customer setup out of your head.
Connect HubSpot, Stripe, Drive, Sheets, Linear, and Pylon once, and Geni runs the whole onboarding sequence the moment a deal closes.