Daily post-delivery review requests for AfterShip customers

By General Input

Every morning we find shipments delivered three days ago, pull the customer's name and order details, and email each one asking for a review.

Integrations

  • AfterShip
  • HubSpot
  • Gmail

Type

Agentic Task

Categories

  • Marketing
  • Customer Support

Every day at 10am, run a review-request pass over customers whose AfterShip shipments were delivered exactly three days ago. The goal is one personal, warm email per customer, sent from Gmail, asking them to leave a review of what they bought.

Step 1. Use AfterShip's List Trackings operation to pull every tracking whose delivery status is delivered and whose delivery date falls inside a window three days back from today (e.g. delivered_at between 72 and 96 hours ago). Page through all results — don't stop at the first page.

Step 2. For each tracking, skip it if it already carries a review_requested tag on the AfterShip record, or if the matched HubSpot contact has a note or property saying we've already asked. This is the idempotency guard so the workflow can run every day without double-asking.

Step 3. Read the customer's email address off the tracking. Then call HubSpot's Search Contacts operation with that email to look up the contact. Pull their first name, lifecycle stage, and any previous order or deal context you can see. If no contact is found, that's fine — fall back to the customer name on the AfterShip tracking and treat them as a first-time buyer.

Step 4. Draft a personalized review-request email for each customer. Reference what they ordered using the tracking's order_id and title fields (product name, order number). Thank them by first name. Ask them to leave a review with a link (leave the review URL as a placeholder the user fills in during setup). Vary the tone slightly for returning HubSpot contacts versus first-time buyers — repeat customers get a warmer, familiar note; first-timers get a friendly welcome-flavored ask.

Step 5. Send the drafted email via Gmail's Send a Message operation, from the connected account, to the customer's email address. Use a subject line that mentions the product or order so it doesn't look like a mass blast.

Step 6. After the email is sent successfully, call AfterShip's Update Tracking by ID operation to add a review_requested tag to that tracking. That tag is what step 2 checks on future runs, so this is what closes the loop and keeps the workflow idempotent.

At the end of the run, produce a short summary: how many trackings were in the window, how many emails were sent, how many were skipped because they were already tagged, and any failures (missing customer email, Gmail send error, HubSpot lookup timeout) so the operator can spot-check. Trigger: cron, every day at 10am in the workspace's time zone. Integrations: AfterShip (source of delivered shipments and dedupe tag), HubSpot (customer enrichment via Search Contacts), Gmail (Send a Message).

Related prompts

Explore more prompts
Win back LiveChat visitors whose chats went unansweredTurn Mailjet email clicks into ranked HubSpot follow-upsiMessage campaign console with pre-flight checks and delivery boardA searchable RFP answer library your bid team drafts fromSee which target accounts just started advertising on LinkedInAccount health board that puts product usage next to your CRMLook up a customer's full chat history mid conversationChase the paperwork every new client and vendor still owesLusha prospecting workbench with credit-safe revealsWhich companies your LinkedIn ads reach, matched to your CRM