Simulate the payroll connection breaking (sandbox only)
Certification scenario 2: the donor changes jobs and the payroll deduction stops. This simulator plays the payroll vendor reporting a new monitoring status through the same production webhook path. The three breaking statuses pause the enrollment, arm the 60-day reconnection grace and emit enrollment.paused with reason: "payroll_connection_broken" on your feed. If the grace ends without a reconnection, GET /v1/enrollments/{id} reads terminated; today no event announces that ending, so read the enrollment to see it. degraded and active are the two statuses that deliberately do NOT pause — send them to prove the alarm does not fire on a vendor hiccup. Prerequisite, checked before anything is sent: an active enrollment; otherwise 400. Nothing in the hosted flow breaks a connection, so this simulator is how you test scenario 2, by hand or in CI.
Headers
- Type: stringIdempotency
- Key min length:1max length:255requiredRequired on every POST, before any effect: 1–255 visible ASCII characters, no spaces. The key belongs to the first body sent with it on this operation for 30 days from the moment that request arrives, including while that request is running and after a
5xxor a timeout. On an operation that creates a resource (POST /v1/churches,POST /v1/churches/import,POST /v1/church_consents,POST /v1/donor_sessions,POST /v1/manage_sessions,POST /v1/refundsandPOST /v1/webhook_endpoints), a key whose request succeeded keeps its body for as long as the resource it created exists. A creation replayed with the same key and body returns the original resource with200and changes nothing; a4xxreleases the key.
Body
- Type: stringchurch
_id requiredRoster identifier of the church this record belongs to.
- Type: stringenrollment
_id requiredIdentifier of the recurring giving arrangement; links its individual donations over time.
- Type: stringenumstatus
Payroll-connection state to simulate in the sandbox.
valuesuser_action_requiredunavailablecustomer_disableddegradedactive
Responses
- application/json
- application/problem+json
- application/problem+json
- application/problem+json
- application/problem+json
- application/problem+json
curl https://api.sandbox.rostergiving.com/sandbox/simulate/connection-broken \
--request POST \
--header 'Idempotency-Key: ' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--data '{
"enrollment_id": "",
"church_id": "",
"status": "user_action_required"
}'
{
"status_code": 1,
"expected_event": null
}