From capsa-cookbook
Surface upcoming Capsa visits a team flags as sensitive (e.g. chemical application) by division and service type, draft per-visit customer pre-notices for user review, and send via a connected email provider. Use for recurring sensitive-visit notice runs.
How this skill is triggered — by the user, by Claude, or both
Slash command
/capsa-cookbook:sensitive-visit-noticeThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Surface upcoming Capsa visits a team flags as sensitive (e.g. chemical application,
Surface upcoming Capsa visits a team flags as sensitive (e.g. chemical application, pest treatments) and draft per-visit customer pre-notices the user reviews and sends through a connected email provider.
New to the Capsa connector? Start with the capsa-orientation skill (or https://github.com/capsa-analytics/capsa-agent-cookbook).
Teams usually define "sensitive" visits by division name and service type name in Capsa — divisions like "Chemical Treatments" or "Pest Control," service types like "Herbicide Application" or "Fungicide Application." This skill uses Capsa's upcoming-visits capability to find those scheduled visits with property and contact context, then walks the user through drafting and sending pre-notices.
The steps are the same whether this runs as an installed skill, is pasted into another agent, or is run ad-hoc. The "Configuration" section is the contract; persist those inputs in the Team specifics block below, a system message, or a wrapper script.
Use it when all of the following are true:
Skip it for one-off questions about upcoming visits, or when no email provider is connected — ask the user to connect one first.
capsa_list_upcoming_visit_filter_options to see the
branches, divisions, account owners, service types, and services available.
Identify with the user which division IDs and service type IDs count as
sensitive — matching is by name, and the user is the source of truth.If you haven't used the upcoming-visits capability recently, call
capsa_describe_capability with upcoming_visits once to confirm shape and
freshness. Skip on later runs in the same session.
Call capsa_find_upcoming_visits with the configured division_ids,
service_type_ids, and lookahead_days. Expect visits each with date/time window,
property and work-ticket context, service and route context, primary and fallback
customer contact candidates, and freshness notes.
If Capsa flags that data may be up to 24 hours old, surface that warning when the visit is same-day or imminent.
Summarize what came back — one line per visit. The user decides which to act on, which to skip, and (where more than one is offered) which contact candidate to use.
If the user configured an internal flag destination outside chat, prepare that summary but do not post it until the user approves it like any other outbound.
For each visit the user wants to act on, draft a short notice using only the Capsa context and the user's configured body template. Keep drafts short (three to five sentences), specific to the visit date and service type, addressed to the chosen contact, and free of invented facts (no addresses, names, dates, or regulatory text not in the context or template).
Present each draft with recipient, subject, and visit reference. The user can approve, edit-and-approve, skip, or defer per visit. Don't send until the user approves the specific draft.
Send each approved notice through the connected provider. Capture the result — message ID, sent timestamp, or an error. If a send fails, surface it and move on to the next visit.
The upcoming-visits capability has no completion-write tool. Do not invent one. The run ends after the user-approved sends. If the user wants an external "notice sent" record (a doc, a Slack thread, a calendar event), produce it from the captured send results — never from intent, drafts, or approvals alone.
"We just brought you online for our chemical-application visits. Can you find the ones coming up in the next week and walk me through drafting a heads-up email to each property contact?"
After running capsa_find_upcoming_visits with the configured filters:
I found 4 upcoming sensitive visits in the next 7 days (Capsa data may be up to
24 hours old):
1. Mon 2026-05-25, morning window — Greenleaf Landscaping
Service: Herbicide Application
Contact: Jamie Doe <[email protected]>
2. Tue 2026-05-26, afternoon window — Cedar Creek Lawn Care
Service: Fungicide Application
Contact: Pat Roe <[email protected]>
3. Wed 2026-05-27, morning window — Stoneridge Grounds
Service: Herbicide Application
Contact candidates: Sam Lee <[email protected]>, Alex Park <[email protected]>
4. Thu 2026-05-28, afternoon window — Maple Ridge HOA
Service: Pesticide Application
Contact: Riley Tran <[email protected]>
Which should I draft notices for? For Stoneridge, which contact should I use?
After the user replies, the agent drafts the chosen notices using the configured template, presents them for approval, and sends only after explicit per-visit approval.
All names, emails, and dates above are fictional.
npx claudepluginhub capsa-analytics/capsa-agent-cookbook --plugin capsa-cookbookGuides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.