HumanSurveyNotificationHandler keeps these operations associated with one hosted survey. Creating the handler does not send a message; the send, schedule, and callback methods below perform the corresponding action.
The survey must have an agent list with an email delivery channel configured before any notifications can be sent. Build a job with
survey.by(agents) and pass delivery_map to its .humanize() method. See Respondent lists for the construction workflow.Getting a handler
Coop client is created automatically. Pass one explicitly if you need a specific API key or base URL:
Statuses
A delivery can contain one email task per selected respondent. Its dispatch and delivery statuses describe the message; the respondent’s response status describes participation. A delivered invitation therefore does not mean a completed survey.Dispatch status
Controls whether the platform has attempted to hand off the message to the downstream channel (e.g. the email provider).Delivery status
Reflects what the email provider reports back after dispatch.Response status
Tracks whether a respondent has engaged with the survey itself.Quickstart examples
Send an email right now
Trigger an immediate delivery to all respondents.Schedule a one-time email
Schedule a single delivery at a specific time.run_at must be a timezone-aware datetime or an ISO 8601 string.
Schedule recurring emails (cron)
Send emails on a repeating schedule using standard cron syntax. Provide eithermax_jobs (fire at most N times) or deadline (stop firing after this datetime) as the termination condition. Use start_at to delay when the schedule begins firing; omit it to start immediately.
React when someone completes the survey (callback)
A respondent is a person with a corresponding entry in the survey’s agent list. Each respondent has a unique survey link and a tracked response status. Submissions from people outside the agent list (e.g. anonymous links) are not associated with a respondent.create_callback sends emails to respondents in your agent list. Two respondent event types are supported:
Notify the owner on every new response
Usecreate_owner_response_callback to email the survey owner each time a response is submitted. This fires for all responses, including anonymous ones — not just respondents in the agent list.
Send a transcript after each submission
Usecreate_transcript_callback to automatically email a transcript each time a response is submitted. Pass recipient to control who receives it:
"respondent"(default) — emails each respondent a copy of their own answers."owner"— emails the survey owner a copy of the answers. Fires for all submissions, including anonymous ones.
Filter which respondents receive a delivery
HumanizeRespondentFilter lets you compose conditions to target specific subsets of respondents. Conditions can be nested with and / or operators.
Check delivery status
List all delivery jobs for the survey:Route types
Each delivery or schedule sends email to survey respondents via aRespondentEmailRouteConfig route. A delivery template is always required; convenience methods like send_respondent_email default to the built-in invitation template when none is provided.
RespondentEmailRouteConfig options:
Template variables
Custom HTML templates support the following variables, which are filled in per-respondent at send time:
Example:
Find and revise schedules and callbacks
The handler keeps the human survey UUID, so these methods only need the identifier of the schedule, callback, or route:
Deactivating a schedule or callback pauses future triggers without deleting its configuration. Deletion removes it. Adding or changing active routes affects future deliveries, so review recipients and templates first. Listing methods return one page; use their pagination metadata to request subsequent pages.
list_deliveries(), list_delivery_tasks(), and get_respondents() also accept page and page_size.
