Catch Gusto payroll blockers before the deadline hits

By General Input

Every weekday morning, check whether payroll is due soon and post a countdown to Slack with every blocker that still needs clearing.

Integrations

  • Gusto
  • Slack Bot
  • Gmail

Type

Agentic Task

Categories

  • HR & People
  • Finance

Every weekday at 7am, check Gusto for the next payroll that has not been processed yet, and warn me in Slack only when its submission deadline is close. The goal is that we never miss a payroll deadline because a blocker sat unnoticed.

Start by listing the company's payrolls and finding the next unprocessed one. Do not assume a payroll is unprocessed just because it is recent or upcoming. Read the processing state directly from the data: the top level processed flag, the calculated_at field, and processing_request.status. Then fetch that payroll's full detail to read its payroll deadline and its check date. Confirm which pay period is actually open by listing the company's pay schedules, and if the period is ambiguous, preview the pay schedule dates to see which pay period and check date the schedule generates next.

Compare the payroll deadline against right now, measured in business days and skipping weekends. If the deadline is more than three business days away, stop and send nothing at all. Silence is the correct output on most mornings, and a message should always mean something needs attention. Make the three business day lead time easy to change.

When the deadline does fall inside that window, gather everything that could block it. Pull the list of payroll blockers for the company. List employees filtered to those still in onboarding, because an employee who has not finished onboarding cannot be paid in this run. List the time sheets for the open pay period and flag hourly people whose submitted hours are missing or zero.

Two data details matter here. Gusto returns hour and money values as decimal strings rather than numbers, so parse them as decimals before comparing and treat a value like 0.00 as zero rather than as a truthy string. The list endpoints paginate using page and per, where per maxes out at 100, so page through until you have the complete set instead of reading only the first page and under reporting the gaps.

Then post a short countdown briefing to Slack as the bot. Lead with the hours remaining until the deadline and the check date, so the urgency is the first thing anyone reads. Next, list the payroll blockers grouped by the person who has to clear each one, so nobody has to work out whose job it is. After that, list the employees stuck in onboarding and the hourly employees with missing or zero hours. Keep it scannable rather than a wall of text. If the deadline is near but nothing is actually outstanding, post a single line all clear instead of a series of empty sections.

If the deadline is inside 24 hours and blockers are still open, also send an email to the payroll admin and to finance, so the warning does not sit unread in Slack overnight. Only escalate by email when both of those conditions are true. A near deadline with everything already clear does not warrant an email.

One nuance worth building in: companies with auto-pilot enabled on their pay schedule still fail to run payroll when blockers exist. Do not skip the blocker check just because auto-pilot is switched on, since those are exactly the teams least likely to notice a silent failure.

Make the lead time, the Slack channel, and the recipients of the 24 hour escalation email straightforward to configure.

Related prompts

Explore more prompts
Win back LiveChat visitors whose chats went unansweredA brand asset library your marketing team actually searchesTurn Mailjet email clicks into ranked HubSpot follow-upsClean out the Looker dashboards and Looks nobody opensLiveKit live operations console for room moderationWake up dormant Keap leads with a researched reasonLiveChat coverage board for planning next week's shiftsPhone routing control panel for LiveKit voice agentsLinkedIn Ads budget pacing dashboard for every client accountGive your team Looker numbers without buying more seats