canopy-renewals API Reference
For a service integrator (the BFF, canopy-reporting, canopy-applications, canopy-enrollment): canopy-renewals owns the SNAP certification period — its creation, the renewal-due and federal-universe feeds, mid-certification interim contacts and change reports, the PAMMS 3730 periodic-report cycle, and the daily scheduler that publishes the notice triggers. Non-SNAP programs own their certification lifecycles in their own services (ADR-001); the program-parameterized routes here only record events. Tables: the data-models page; design history: snap-renewals-certification, adverse-action-pipeline (periodic reports), snap-recert-interview-reinstatement, snap-intake-completion (the expedited, continuation and NOE-dispatch consumers), materiality.
- Base URL
-
container port 8007 (host:
CANOPY_PORT_CANOPY_RENEWALS_8007in.ports.env) - Authentication
-
Bearer token: a canopy-identity token for this receiver (its
audisurn:canopy:service:canopy-renewals), authenticated by the service’s identity receiver (ADR-049 Amendment 14): no bearer is 401token_missing, a token it refuses 401token_rejected, anX-Canopy-Actorheader 400actor_header_retired, and no trustworthy key set in time 503keys_unavailable. - Access
-
canopy-eligibility and canopy-reporting hold system edges to canopy-renewals, and the portal one for the in-force read; every route admits a system caller. The seven worker writes admit the writer bar through any client; the listed reads admit canopy-web’s readers, with canopy-cli on the caseload trend and the nudges and canopy-eligibility’s or canopy-applications' onward delegation on the certification reads; the rollup refresh admits
adminthrough canopy-cli; every other route is system-only. A refusal is 403 with itsReceiverDenialcode (ADR-049 Amendment 14); each route’s constant is in the authorization inventory. - Database
-
canopy_renewals
Admission specifics
-
Ownership. The in-force read
GET /v1/renewals/snap/certificationsrequires the portal’sX-Canopy-Applicantclaim to bind the queried household (require_owned_household), decided from the claim before any query: 403ownership_claim_missing/ownership_mismatch. -
Attribution (#1008). The nudge and redetermination actions record
action_by=principal.actor(): a user asHuman(the canopy subject), a system caller asService(its client id). Neither body carries an actor; theactorin the convert and reopen bodies is provenance text, not authorization. The writer bar excludesquality_control, which samples a renewal record and never authors one. -
Outbound. The SNAP change report’s eligibility dry-run (the 130%-FPL screen) rides the request’s outbound (
RequestOutbound: the writer’s delegation onward, or canopy-renewals' system token for a system caller); the canopy-enrollment calls (the convert and VCL recipient, the periodic-report schedule and reopen) and the consumers' and scheduler’s calls send on canopy-renewals' sender (system origin).
Routes
Mounted by routes() (plus periodic_report_routes() and scheduler_routes()) in services/canopy-renewals/src/api/mod.rs; spelling from crates/canopy-contracts-renewals/src/paths.rs. The literal /snap/… paths match before the {program} routes.
| Route | Access | Success | Refusals (RFC 9457 code) |
|---|---|---|---|
|
system; writer |
201 |
409 active certification exists, |
|
system; portal ( |
200 |
403 ownership / scope; 404 none in force |
|
system; writer via canopy-applications |
200 |
404 |
|
system |
200 |
400 |
|
system; writer |
200 |
404; 409 |
|
system; writer |
201 |
409 |
|
system; worker reader via canopy-web |
200 |
— |
|
system; worker reader via canopy-web |
200 |
422 unknown program slug |
|
system; case reader via canopy-web |
200 |
400 |
|
system; case reader via canopy-web, canopy-cli |
200 |
422 |
|
system; |
200 / 202 |
— |
|
system; case reader via canopy-web |
200 |
— |
|
system |
201 |
— |
|
system |
200 |
404 |
|
system; case reader via canopy-web, canopy-cli |
200 |
— |
|
system; writer |
200 |
404 (unknown, immaterial or already actioned); 409 |
|
system; writer |
201 |
400 |
|
system; writer |
201 |
400 |
|
system |
200 |
— |
|
system |
200 |
404 |
|
system |
200 |
409 state; 422 |
|
system |
200 |
409 state; 422 |
|
system |
200 |
409 state |
|
system |
200 |
409 state / certification not active; 422 |
|
system |
200 |
400 receipt date; 409 not |
|
system |
200 |
— |
|
system; writer |
200 |
404 (unknown or already actioned); 409 |
|
system |
200 / 202 |
— |
Access legend: system = any system caller but the portal; portal (<scope>) = the portal’s system token holding that scope; + ownership = the claim check above; writer = a user’s delegation holding a CASEWORKER_WRITER_ROLES role; case reader = CASE_READER_ROLES; worker reader = WORKER_READER_ROLES (all crates/canopy-auth/src/roles.rs); a bar with no client admits a delegation through any client, via X, Y only a delegation those clients present.
Certifications
Create. { household_id, application_id, determination_id, certification_type, certification_start_date, certification_end_date, head_of_household_person_id? }. certification_type is the caller-declared category, persisted verbatim; its vocabulary is the booted pack’s worker_declarable rows under [[snap.certification.categories]] in the pack’s jurisdiction.toml (#2209 — georgia standard 6 months, elderly_disabled 12, senior 36, abawd 4; default standard 6 and elderly_disabled 24), loaded by services/canopy-renewals/src/params.rs and checked at the handler — never by a closed enum or a CHECK. The three 422s: a token outside the declarable rows (a well-formed token another pack declares included) → certification_type_unknown, naming the pack’s declarable codes; expedited → certification_type_not_manual (system-minted only by the determination consumer, 7 CFR 273.2(i)); a declared period longer than the jurisdiction’s ceiling — certification_end_date after the end of certification_period(certification_start_date, [snap.certification].max_certification_months) — → certification_period_exceeds_ceiling, naming the ceiling (the default pack, ceiling 24, can no longer accept a 36-month certification; a worker-declared period is bounded by the ceiling, not by the row’s months, which is the JDM’s assignment). A malformed token ("", Senior, one over 64 characters) fails the CertificationType shape rule (^[a-z][a-z0-9_]{0,63}$) at deserialization, also 422. head_of_household_person_id is required exactly when the period is two months or less (certification_start_date + 2 months > certification_end_date; 7 CFR 273.14(b)(1) — the Notice of Expiration is then staged in the create transaction), else ignored. One certification per determination: a replayed determination_id, or one the continuation adjuster already recorded, is 409 certification_exists_for_determination. The create path takes the household advisory lock first and finalizes the household’s pending_certification continuation rows for this determination after the insert.
In-force read. GET /v1/renewals/snap/certifications?household_id= returns the one row in the in-force class — status ∈ store::IN_FORCE_CERT_STATUSES (active, recertifying — a household that has filed its recertification keeps a certification in force until the renewal is decided) with active = true; a lapsed certification whose end has passed but is still active is in this class, and is the only place the portal learns a period has run out. GET …/{id} reads any status; canopy-applications' renewal filing reads it fail-closed.
Convert. POST …/{id}/convert { reason, converted_on, actor } takes a certification whose pack row is convertible (georgia: senior, Senior SNAP) off the periodic-reporting waiver mid-period (PAMMS 3730:64-65; 3725:29-39, :132-137). A certification whose row is not convertible — or whose token the booted pack does not declare — is 422 certification_not_convertible, naming the pack’s convertible codes (renamed from certification_not_senior, #2209; the default pack declares no convertible row, so every convert there is refused). reason is the jurisdiction’s closed vocabulary snap.certification.esap.conversion_reasons (Georgia: abawd_member, earned_income, member_under_age_floor; required, and non-empty, exactly when a row converts); actor is provenance, not authorization. In one transaction: certification_type becomes the row’s converts_to (georgia senior → standard; the pack schema forbids a waived or convertible target), periodic_report_required is recomputed, the conversion stamps land, the remaining future-serviceable cycles are minted from the 3730 calendar (a conversion past the last serviceable due month records one cancelled / converted_after_last_cycle tombstone), and renewal.snap_certification_converted is staged. The period itself is never touched (3730:69-70; 3725:139-140). The recipient (the live enrollment’s head, from canopy-enrollment) resolves before the write; an unresolvable one is 503 with nothing converted — PAMMS 3725:134 makes the letter mandatory. Replaying the same reason returns the row unchanged. snap.periodic_reporting.conversion_exempt_from_phase_out (Georgia: true) keeps a converted AU reporting past the 3730:21-23 phase-out.
In a jurisdiction that runs no periodic report (no [snap.periodic_reporting] table) a conversion only re-types the certification (#3356): periodic_report_required stays false, no cycle is minted, no event is staged and no letter is sent, since the letter tells the household which reports it now owes. No recipient is resolved, so the 503 above is never answered there.
Due, universe and dashboard feeds
-
GET /v1/renewals/snap/due— keyset-paginated (limitclamped 1..=200, default 50;after_end_date+after_id). Default scope: certifications ending within[as_of, as_of + days](daysdefault[shared.timing].renewals_api_default_lookahead_days= 90, clamped 1..=366;as_ofthe ADR-033 tier-2 override, default the service’s legal day: its injected decision clock as a date in the pack’s[jurisdiction].timezone, #2526), soonest first. Withactive_on: the certifications in force on that date — the SNAP QC / FNS-388 universe (daysignored). ResponseSnapCertificationPage—items,next_cursor(only when the page was exactlylimitrows),total_in_scope(theCOUNT(*), first page only). There is no unbounded array mode; canopy-reporting page-loops to exhaustion and assertsextracted == total_in_scope. -
GET /v1/renewals/{program}/due— the same params and envelope;program = snapreturns the SNAP page, every other known program an empty complete page, an unknown slug 422. -
POST /v1/renewals/snap/universe-snapshots{ active_on }freezes an immutable generation in one transaction (UniverseSnapshot { id, active_on, row_count, created_at }, the bulk-cohort source);GET …/{id}/rows?after=<seq>pages it by denseseq(certification_period_id,household_id,application_id,determination_id, and since #806 U-Ccertification_type— the frozen MT-87 category, on which canopy-eligibility’s COLA admission excludesexpeditedrows — andcontinued_by_determination_id, the certification’s chain head, which the bulk case takes as its supersession baseline when present;crates/canopy-contracts-renewals/src/universe_snapshots.rs). Generations are reaped afterCANOPY_RENEWALS__UNIVERSE_SNAPSHOT_RETENTION_DAYS(default 30). -
GET /v1/renewals/overdue— SNAP in-force rows past their certification end,{ household_id, program, action_type, due_date, days_overdue }(the cross-program aggregator shape; other programs join once they expose due-date stores). Query (OverdueListParams,crates/canopy-contracts-renewals/src/overdue.rs):as_of(the ADR-033 tier-2 anchor; absent, the service’s legal day, as for the due list, so a case never reads overdue a day early in the jurisdiction’s evening, #2526),limit(1..=500, default 100; out of range is 400, never a silent clamp), and the keyset cursorafter_due_date+after_certification_id(both together; a page shorter thanlimitis the last — the response stays a bare array).GET /v1/renewals/snap/interim-contacts/due?as_of=— certifications with an overdue interim contact (as_ofabsent: the service’s legal day). -
GET /v1/renewals/caseload-trend—window(<n>d/<n>w, default12w, ≤ 366 d / 104 w),bucket(day|week),program(snaponly): distinct households with an in-force certification at each bucket close, the days and weeks being legal ones in the jurisdiction’s timezone (#2592), served from thesnap_caseload_dailyrollup the dailycanopy-renewals.caseload-rollupjob materializes over[anchor − 735 d, anchor + 8 d]. Absent coverage or a generation older than 48 hours is an honest 503 +Retry-After: 60, never a fabricated series.POST /v1/renewals/caseload-rollup/refreshrecomputes now (202 when another caller holds the lock; CLIcanopy renewal caseload-rollup-refresh).
Interim contacts, change reports and nudges
-
POST …/{id}/interim-contact{ household_id, contact_method ∈ phone | mail | in_person, notes }(PAMMS 3730 — the state midpoint-contact procedure; no federal paragraph sets the cadence, so none is cited, per thesnap.certification.interim_contact_monthscitation row, #2143). The certification must belong tohousehold_id: a certification of another household is refused 409 with the RFC 9457codecertification_household_mismatchbefore the contact is stamped (#2410). The change report refuses the same pairing with the same code, and both details keep the token as their prefix (#3033). -
POST …/{id}/change-report{ household_id, change_type ∈ income_change | household_change, report_method, description, reported_monthly_income?, reported_household_size? }. The certification must belong tohousehold_idand be in force. For anincome_changethe 130%-FPL simplified-reporting screen (7 CFR 273.12(a)(5)) runs on facts of record: a write-free canopy-eligibility dry-run of the certification’s determination-of-record against the household’s current canopy-persons facts, screened on the assistance-unit size, gross income and 130%-FPL ceiling that replay used. Thereported_*fields are provenance only. The row’sscreen_statussays why it does or does not carry inputs:not_applicable;screened(derived_household_size,derived_monthly_income,gross_income_limit,screen_determination_id,screen_corpus_hashpopulated, andrequires_redetermination = derived_monthly_income > gross_income_limit, enforced by a DB CHECK);dry_run_unprocessable;eligibility_unavailable— a lawful report is never dropped and a degraded screen never falls back to the caller’s figures. -
GET /v1/renewals/snap/nudges?household_id=&pending_only=lists the recert nudges the materiality subscriber recorded (RecertNudge: the triggering fact, baseline and dry-run verdicts,benefit_delta_cents,is_material, the action taken).POST …/nudges/{id}/action{ household_id, action ∈ filed_recert | dismissed }(ActionRecertNudgeRequest) is guardedWHERE is_material AND action_taken IS NULL— the first decision stands. Filing records intent only. The recordedaction_byis the caller’sActor({"actor_type":"human","subject":…}for a worker’s delegation,{"actor_type":"service","service":…}for a system caller; #1008),nullwhile pending. -
The nudge action’s household check (
refuse_foreign_nudge, #2545) runs after admission and before the guarded update.household_idis required: axum’sJsonextractor refuses a body without it with a 422, before admission. An unknown nudge id keeps the 404. A nudge whose storedhousehold_idis not the body’s is 409nudge_household_mismatch, whose detail names the path id and the requested household, never the stored owner; the refusal writes nothing and logs onewarn!carrying the two ids. The OpenAPI 409 of this route also carries the shared idempotency layer’s conflict (crates/canopy-api/src/idempotency.rs). The check holds the stored owner to the household the request names. It does not tell whether the caller may act in that household: canopy-renewals cannot know which household a worker acts in, so a caller that names the nudge’s own household passes. canopy-web binds the nudge to the worker’s household before it sends that household (canopy-web API). -
The program-parameterized twins (
{program}∈tanf | medicaid | caps | wic;snapis 400) are household-level: canopy-renewals keeps no certification for these programs, so the path names only the program, the body names thehousehold_id, and theSnapChangeReportrow it inserts is discriminated byprogramwithcertification_idnull (#2409; the path carried a certification id the handler discarded before).
Periodic-report cycles (PAMMS 3730; 7 CFR 273.12(a)(5)(iii))
Cycles are minted by the daily scheduler (no creation API): one scheduled generation-1 cycle per extended certification, with the 3730 calendar (the 15th-of-prior-month initial notice, the 5th-of-due-month combined notice, month-end closure). The commands record the worker-side workflow; the transition stamps are server-set from the gated clock; out-of-order commands are 409 naming the cycle’s status.
A jurisdiction that runs no periodic report (#3298: no [[snap.certification.categories]] row could owe one, so its pack carries no [snap.periodic_reporting] table) materializes no cycle, mints no frequency-shift or conversion cycles, and answers every command below with 409 periodic_report_not_applicable. A converting row does not by itself require the table (#3356). The cycle reads return what exists, which for such a pack is nothing.
-
…/form{ form_kind, complete }—form_kindfrom[snap.periodic_reporting].accepted_form_kinds(Georgia["528", "297", "508"]; else 422 naming the list);complete: false→form_incomplete(still eligible for the combined notice),true→form_complete(never un-filed). Legal fromscheduled/notice_sent/form_incomplete. -
…/vcl{ reason ∈ reported_change | discrepancy, detail, due_date? }— legal only fromform_complete;due_datedefaults to sent +vcl_response_daysand may not allow under 10 calendar days (3730:218). Fail-closed on the letter: the live enrollment’s head resolves before the transaction andrenewal.snap_periodic_report_vclis staged atomically with thevcl_pendingstamp; an unresolvable recipient is 503 with nothing written.detailnever rides the event. -
…/verified(no body) — legal only fromvcl_pending. -
…/complete{ changes: [ { change_type, report_method, description, reported_monthly_income?, household_size? } ] }— the 130%-FPL screen runs once, outside the lock, for the whole form; then one locked transaction writes theprocessedstamp, one change-report row per change, andrenewal.snap_periodic_report_processed. Legal fromform_completeorverified; completion assigns no new certification period (3730:161). -
…/reopen{ received_date, form_kind?, actor }reopens aterminatedcycle when the missing form or verification arrives within[snap.periodic_reporting].reopen_window_days(30) after the due month (Chart 3730.1 rows 4 / 5): validate → canopy-enrollment’s idempotentPOST /v1/adverse-actions/{id}/reopen→ one local transaction (the cycle rejoins the state machine, the certification reinstatesterminated → active). The arm is derived: a cycle that reached the VCL died on verification (row 4;form_kindmust be omitted); any other is a nonfiler (row 5;form_kindrequired). A retry with a differentreceived_dateis 409. A request whosereceived_datethe cycle already carries as itsreopened_date, while the certification that reopen reinstated is still in force (activeorrecertifying), replays it: 200 with the cycle as it now stands, checked on the pre-flight read and again under the certification lock before the reinstatement, so a lost-response retry and a racing twin both converge on the one reopen (#2656). A superseded certification keeps the 409. -
The re-determination queue: when a periodic-report termination dies on an appeal veto or a worker cancel, the terminal consumer mints a
PrRedetermination(trigger_kind∈action_vetoed | action_cancelled) and marks the cyclecancelled;POST …/redeterminations/{id}/action{ household_id, action ∈ redetermined | dismissed }(ActionRedeterminationRequest) is guardedWHERE action_taken IS NULL(404 otherwise), and records the caller’sActorasaction_by, as the nudge action does. Its household check (refuse_foreign_redetermination, #3108) runs after admission and before the guarded update, with the same contract asrefuse_foreign_nudge:household_idis required (422 before admission if missing), an unknown id keeps the 404, and an entry whose storedhousehold_idis not the body’s is 409redetermination_household_mismatch(naming the path id and the requested household, never the stored owner) with nothing written. The check holds the stored owner to the household the request names; a caller that names the entry’s own household passes.
Scheduler
POST /v1/renewals/scheduler/run runs one daily pass now under the scheduler’s advisory lock (202 skipped: true when a replica holds it): cycle materialization, the two 3730 drains, the lapsed-VCL drain, the 7 CFR 273.14(b)(1) Notice-of-Expiration drain and the due-list gauges, each drained to exhaustion in keyset pages within CANOPY_RENEWALS__PR_TICK_BUDGET_SECS. No caller-supplied date — a trigger mutates. The response SchedulerCheckView carries the counters, including the NOE leg’s expiration_notices_sent, expiration_notice_skipped, expiration_notices_late (sent on or after the first day of the last certification month — a delivery defect to investigate), the gauge expiration_notice_elapsed_unsent, and renewals_minted. The pass (scheduler::run_daily_pass) ends with the mint leg, renewal_decisions::mint_due_renewals: every scheduled snap_renewal_decisions row with certification_start_date ⇐ legal today opens its certification through the shared writer (cert_create::create_with_supersede, the recorded pair and type, the event’s recipient and determined_at) — whose supersede retires the old recertifying certification, now past its end, with supersede_reason = new_certification (never retire_renewed_certification; the renewal linkage is the decision row) — and the row becomes minted; a withdrawn decision mints nothing. The hourly background tick’s window is keyed on the LEGAL day (run_window_fenced), so the first probe after legal midnight of a period start mints it. The certification record may trail canopy-enrollment’s successor landing by the pass cadence; enrollment is the issuing authority.
-
15th-of-prior-month (3730:83): stages
renewal.snap_periodic_report_dueand moves the cyclescheduled → notice_sentin one transaction; recipient = the live enrollment’s head. -
5th-of-due-month (3730:98-108), only for a cycle whose 15th notice was actually sent: schedules the exempt-shaped termination adverse action in canopy-enrollment under the
periodic_reportprovenance triple (reasonperiodic_report_nonfiling, whose row carriescb_available = false; no narrative, so the letter prints the row’sdisplay_text; the exemption authority is the pack’s[snap.periodic_reporting].nonfiling_exemption_authority, #2212; effective = the last workday at or before month-end per[jurisdiction.holidays]); enrollment’s enact sweep is the month-end closure executor; the cycle records the action id andcombined_notice_sent_date, its status untouched. Only ascheduledaction is recorded, as in the lapsed-VCL drain: a replay that returns a cancelled action leaves the cycle unstamped (#2671). The drain’s count of triggered actions counts only a stamp that changed the cycle. -
Lapsed VCL (Chart 3730.1 row 2): a complete form whose checklist lapsed unanswered schedules the
periodic_report_verification_failuretermination under the same triple, with no narrative and the pack’sverification_failure_exemption_authority(#2212: its own reason row,cb_available = false; canopy-notices fans thepr-vcl-terminationletter byreason_code); status staysvcl_pendingso a late verification still cures. -
Notice of Expiration: the drain’s window opens on the first day of the next-to-last month and stays open while the certification is in force today; a certification of two months or less stages the same event at creation. Both arms pre-mint the envelope id as
snap_certifications.noe_source_event_id, the correlation the dispatch consumer reads. -
Renewal due (
renewal.snap_due): the one drain that readsstatus = 'active'alone — arecertifyinghousehold already filed.
Error codes
| Code | Meaning |
|---|---|
400 |
Missing |
401 |
No bearer ( |
403 |
|
404 |
Certification, cycle, nudge or redetermination not found; no certification in force |
409 |
A second active certification; |
422 |
An unknown field in a |
503 |
Fail-closed, nothing written, retryable: the letter recipient could not be resolved on |
Events published
String set from services/canopy-renewals/src; every envelope asserts programs = ["snap"].
-
renewal.snap_certification_created— every certification, by whichever writer. -
renewal.snap_certification_converted— the mid-period conversion of aconvertiblepack row (georgia: Senior SNAP) (person_id,certification_end_date,first_due_month—nullwhen the remainder minted no cycle,reason); routed by canopy-notices to thesenior-conversionletter. -
renewal.snap_due— the renewal-due drain;renewal.snap_interim_contact_due— the interim-contact drain. -
renewal.snap_expiration_notice_due— the 7 CFR 273.14(b)(1) Notice of Expiration trigger (once per certification;renewal_deadline= therecert_timely_filing_dayof the last month, clamped to the end); routed tonotice-of-expiration. -
renewal.snap_expiration_notice_superseded(ExpirationNoticeSupersededV1:source_event_id= the fenced NOE’s envelope id,certification_id,household_id) — staged in the transaction that clears a staged NOE fence (a continuation moved the end, or a continuation-class termination ended the period); consumed bycanopy-notices.noe-superseded. -
renewal.material_change— a material mid-certification change (change_type,change_reasons, the previous / new amounts, the raw cents); routed tochange-in-circumstances. -
renewal.snap_periodic_report_due(RenewalPeriodicReportDueV1:due_month,file_by_date,closure_date) →pr-due;renewal.snap_periodic_report_vcl(RenewalPeriodicReportVclV1:vcl_reason,vcl_sent_date,vcl_due_date,closure_date) →pr-vcl;renewal.snap_periodic_report_processed(RenewalPeriodicReportProcessedV1) — consumed by canopy-enrollment’s completion tombstone.
Consumers
Six durable queues; every handler runs on the inbox transaction, parks an unrecognized routing key, and sends a producer-contract violation (a missing required field, an out-of-vocabulary token) to the DLQ rather than guessing.
-
canopy-renewals.renewal-filings←application.submitted: arecertificationfiling projects onto its certification (status = recertifying,renewal_application_id,renewal_submitted_at = received_at) in one idempotent UPDATE; aninitialfiling is acked; zero rows (superseded, terminated or recertifying under another application) is a WARNrenewal_filing_not_applied, never a retry.IN_FORCE_CERT_STATUSES(active,recertifying) governs every in-force predicate; the renewal-due drain alone stays= 'active'. -
canopy-renewals.adverse-actions←enrollment.adverse_action_{terminated,vetoed,cancelled}(non-periodic_reportsources acked untouched):terminated→ certificationterminated+ the cycleterminatedon the noticed date;vetoed, orcancelledfor any reason butperiodic_report_completed→ the cyclecancelled+ onePrRedetermination. -
canopy-renewals.determinations←determination.completed.snapanddetermination.record_back_refused. On an approvedexpedited_postponedbasis: the causal guard (the event supersedes the active certification iff none, or it names it asprevious_determination_id, or itsdetermined_atis newer), then theexpeditedcertification (1–2 months, no periodic report, no interim contact, the at-certification NOE) superseding the prior. Onrecert_reinstatement: locate the lapsed certification byrenewal_application_id, retire it (status = expired,renewal_determination_idstamped — the only writer of that column), and open a certification of the approval’s assigned category (certification_category, #1703) from the signed dates — the token passes through asCertificationTypeand its membership in the booted pack’s[[snap.certification.categories]]is checked once at the write (an undeclared token is the typedInputDefect::UnknownCategory, naming the pack’s codes, to the DLQ; #2209). On arecord_back_refused(postponement_not_open): the certification the disowned determination opened is superseded withsupersede_reason = record_back_refusedand its staged NOE unstaged. Onrecert_approval— approved OR denied (renewal_decisions::record): under the household lock, locate therecertifyingcertification byrenewal_application_id(none → DLQ, the reinstatement arm’s remedy), thencausal::supersedesagainst the application’ssnap_renewal_decisionsrow — an approval (its signed pair anchored at the renewed end + 1, itscertification_categoryas the type; a missing category is the typedRecertApprovalWithoutCategoryDLQ) →scheduled, a denial →withdrawn, an older or equal decision → acked unchanged (renewal_decision_stale_arrival). NOTHING is minted there and therecertifyingcertification is NOT retired: it stays in force to its end (universe snapshots and current-period continuations keep reading it); the scheduler’s pass mints at period start (below). -
canopy-renewals.notice-dispatched←notice.dispatched(notice_of_expirationonly): stampsnoe_dispatched_at/noe_dispatched_dateset-once bynoe_source_event_id, falling through to thesnap_certification_adjustmentsrow that snapshotted a cleared id. The predicatenoe::noe_evidence_dispatchedis the evidence contract. -
canopy-renewals.continuations←enrollment.continuation_applied/enrollment.continuation_terminated: the adjuster records onesnap_certification_adjustmentsrow per event (applied | no_change | stale | superseded_by_new_certification | pending_certification), moving the certification end and type (the approval’scertification_categoryon anin_cert_conversionof anexpeditedcertification; a conversion without one, or with a token the booted pack does not declare, is refused to the DLQ) by a watermark-fenced compare-and-set, recomputingperiodic_report_required(false forexpeditedand for a row withperiodic_reporting_waived = true, else the[snap.periodic_reporting]threshold and phase-out test) and rescheduling the interim contact (interim_contact_due_date= start +[snap.certification].interim_contact_monthsfor a row withinterim_contact = true, else none — georgiastandardonly; #2209), and re-staging or clearing the NOE fence (renewal.snap_expiration_notice_supersededwhen a fenced id is cleared); a termination setsterminated+terminated_at, cancels open cycles and clears the fence. -
canopy-renewals.materiality←income.claimed,asset.claimed,expense.claimed,household.member_claimed(ADR-027 §6): for a household with an active certification, a write-free dry-run (POST /v1/eligibility/determine/dry-run,as_of= the change’svalid_from) against the determination-of-record; the verdict diff lands inrecert_nudges(idempotent on the event id), and a material change — a verdict flip, or a benefit delta ≥[snap.materiality].benefit_delta_threshold_cents— emitsrenewal.material_change. An event whose envelope timestamp is older than the certification’screated_atis skipped by the ordering rule as already in the baseline, not a change — the outbox may deliver it after the worker opens the period (#2196); a change effective before the cert start is manual review (Decision J). A 4xx dry-run is manual review, not a nudge; the dry-run and the persons reads send on canopy-renewals' sender (system origin;…ELIGIBILITY_URL,…PERSONS_URL), and the subscriber is not registered without one (subscriber::wire).
Configuration
CANOPY_RENEWALS{ELIGIBILITY_URL, PERSONS_URL, ENROLLMENT_URL, PR_TICK_BUDGET_SECS, UNIVERSE_SNAPSHOT_RETENTION_DAYS} (services/canopy-renewals/src/config.rs); the jurisdiction keys [shared.timing].renewals_api_default_lookahead_days, [snap.certification].{recert_timely_filing_day, recert_reinstatement_window_days, recert_late_renewal_window_days}, [snap.periodic_reporting].{vcl_response_days, accepted_form_kinds, reopen_window_days, conversion_exempt_from_phase_out}, [snap.certification.esap].conversion_reasons, [snap.materiality].benefit_delta_threshold_cents. Identity settings are the baseline IDENTITY_ISSUER / IDENTITY_INTERNAL_URL (configuration reference) and the client key CANOPY_RENEWALSIDENTITY_CLIENT_PRIVATE_KEY.