BuiltEmail workspace

Insurance claim received

Source: App\Mail\InsuranceClaimSubmitted, app/Mail/InsuranceClaimSubmitted.php:19–31; resources/views/emails/insurance/claim_submitted.blade.php:1–8, originally mail::message. Native subject: **Insurance Claim Submitted**. Suggested preheader: Your claim request for policy {{policy_id}} was received.

TokenExisting sourceHandling
{{first_name}}Source view reads user.first_name ?? '', but the Mailable binds only policyOptional complete greeting block. Default omit it. Explicitly binding a user or mapping policy.user.first_name requires a consuming-project decision; do not silently assume it is bound today. Preserve supplied string 0.
{{policy_id}}Constructor NewInsurancePolicy policy → policy.policy_idRequired source identifier. Not InsuranceClaim.policy_id, which is the relationship foreign key, and not claim UUID/database ID. No N/A fallback in the source; do not coerce zero or empty strings.
{{app_name}}config('app.name')Required sign-off name.
{{preheader}}Proposed summary using the same supplied policy identifierEscaped text, no new amount, claim ID, processing time or approval claim.

Default logo is the established Built HTTPS asset. Optional {{logo_url}} override, PNG badge assets and CID/approved HTTPS hosting requirements are documented in [shared footer](../shared-footer.md). Shared company/app-store footer is the separately approved library policy. There is no workflow action URL, legacy duplicate link field or source PDF/email attachment. App-store/contact destinations belong to the footer, not claim processing.

Trigger, recipients, queue and evidence

InsuranceClaimController::store (:56–136), POST policies/{id}/claims (routes/api.php:1463), selects an authenticated user's NewInsurancePolicy, checks status open, validates scope, optional comments/files and bank fields, uploads supplied files, and creates a pending InsuranceClaim plus NewInsuranceActivity in a transaction. It then queues InsuranceClaimSubmitted(policy) to authenticated user.email with the native internal BCC at :117–118, and queues the same Mailable/body to a separately addressed internal recipient with native BCC at :120–121. Preserve both copies, their To/BCC and queue(); do not split this into two types or repurpose the claimant copy as an internal-only message. Recipient addresses are intentionally not copied into this library.

The following SMS to policy.order.phone_number (:123–130) is a separate channel. The Mailable constructor accepts policy, not claim, and binds no user explicitly. No explicit From/Reply-To override is present; preserve native configured headers. Stored claim scope, comments, bank details and uploaded files exist in the application but are not rendered or attached by this email. Do not add them, fetch live records, promise review timing or imply coverage/approval/payment. The separate update and customer cancel endpoints do not queue this acknowledgement or a new cancellation email.

Static references establish usage evidence, not proof of current production delivery. The library changes no persistence, authorization, uploads, queue routing or SMS behavior.

Integration

Use the existing Mailable with a complete HTML Blade view and a proposed plain-text view, preserving queue/headers. Do not nest this full document inside mail::message. Portable {{placeholder_name}} tokens are not automatically Laravel Blade; map them explicitly. If using native Blade, escape each text/attribute with its normal escaping and wrap the complete optional greeting in a deliberate conditional. If using replacement, escape dynamic text, validate image URL scheme/host/path separately and replace in **one pass** so inserted token-shaped text is never recursively evaluated. No dynamic value is trusted raw HTML. Shared-footer aliases have their own contract.

Keep policy ID visible inside the email. Remove the optional greeting block from both HTML and plain-text when no explicitly mapped name exists. No source project-owned plain-text alternative was found; the included .txt is proposed equivalent content. CID attachments require actual embedding; relative preview images are not portable sendable asset URLs.

Five fictional states cover the native unbound greeting, an explicit greeting integration choice, supplied identifier 0, empty identifier and long values. Empty/zero view checks do not establish valid claim creation or policy state. Files: public/ready/insurance-claim-submitted.html/.txt, previews/insurance-claim-submitted-*.html/.txt. The copy now has a descriptive receipt heading and labelled policy ID; it retains receipt-only meaning and source instructions/data. Browser rendering does not establish Gmail/Outlook/iOS Mail, delivery or policy eligibility.