Repository navigation
Conversation
…t is queued A code send that goes through the sandbox sender now gets the worker's sandbox checks before it is queued: the switch, the pause, the organization block, the member check on every to, cc and bcc address, and a read-only look at the daily allowance. A refused send answers `400 sandbox_recipient_not_allowed`, `400 sandbox_limit_reached`, `422 sending_suspended` or `503 sandbox_check_failed`, and nothing is queued. The refusal's blocked event waits at most a second. The integration loader reads an id the read replica lacks from the primary, so a sandbox integration Django just created is found by the admission check and the worker. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of map #461 (sandbox sender for API sends). SA1 part 2 of 3, split from #632: the admission gate. Stacked on #636 (part 1). Part 3 is #638, and #633 sits on top.
Problem
Merge Danger
Warning
🔴 Merge risk: high · two-way door: a revert brings back the 202 for every sandbox code send
workflows-sandbox-sender.Changes
400 sandbox_recipient_not_allowed400 sandbox_limit_reached422 sending_suspended503 sandbox_check_failedworkflows sandbox email blockedwithsource: api, and waits at most a second for it.How did you test this code?
Test seams: the cdp-api code-send route over HTTP (
cdp-api.serial.test.ts) andIntegrationManagerService.get.Test rationale: each refusal row above, a refusal while the blocked-event store hangs, and a lookup the replica misses going to the primary.
Proofs: the live run, cross-version run and shadow diff ran on #632, whose code equals this stack's top (part 3). Prod shape is a gap until read-only production access exists on 2026-11-02.
CI: this PR sits on an integration base until the sandbox stack (through #587) and the send stacks (through #584 and #585) reach master.
Release status
Docs update
docs/internal/workflows-email-sending-tiers.mdis updated in feat(messaging): send code emails through the sandbox sender without a domain #633.🤖 Agent context
Autonomy: Human-driven (agent-assisted)
Agent: Claude Code, Claude Opus 5.5 (claude-opus-5-5)
Skills:
/tdd,/writing-tests,/qa-swarm,/pr-description,/writing-pr-descriptions400 sandbox_recipient_not_allowedand400 sandbox_limit_reacheddelivery_mode422 sending_suspended, the master code for a suspensionInvolvement: the SA1 review carries over from #632, whose code these three parts hold: one design pass, a 7-lens security swarm, a 4-lens fix round and one clean final read (GPT-6.1 Sol and Claude Opus 5.5). One GPT-6.1 Sol read of this part raised one minor, rejected as in #632 (Django answers a lookup failure with a 503). A GPT-6.1 Sol read of the merge that took the newer base came back clean.
More context for AI agents
sbx-apiof map Map: send code-managed email templates with one PostHog call #461, Claude Code.87af9d607ca.sandbox-send-gate.ts,checkTransactionalEmailincdp-api.ts, andintegration-manager.service.ts.🤖 Generated with Claude Code