Site Diagnostic
Live runtime verification of the partner-onboarding pipeline against real data.
29
Total
12
Pass
1
Fail
4
Warn
12
Manual
Audited Automation Snapshot
last_run_status & consecutive_failures from the platform automation registry.
| Automation | Type | Last Run | Failures | Note |
|---|---|---|---|---|
| Hourly Compliance Check (All Brands) runComplianceCheck | scheduled ยท hourly | success | 0 | Lightweight scheduled path โ only writes last_compliance_check on flag transition, so a recent timestamp is not expected when flags are stable. |
| Auto-Classify New Partner Documents classifyPartnerDocument | entity ยท create | success | 0 | trigger_conditions: file_url is_not_empty. Behaviorally verified โ a no-file_url create did not fire the automation. |
| W-9 Completeness Check on Upload checkW9Completeness | entity ยท update | success | 0 | trigger_conditions: changed_fields contains file_url. |
| Daily Onboarding Deadline Reminders checkOnboardingDeadlines | scheduled ยท daily 13:00 | success | 0 | 2-day Duoplane reminder + 4-day final deadline reminder. |
| Hourly Onboarding Pause Check checkOnboardingDeadlines | scheduled ยท hourly | success | 0 | Pauses brands past the 5-day deadline; archives their promoted marketplace products. |
Partner Onboarding Pipeline
NDA records contain real signed text + audit metadata
ManualNo ProspectiveNDASignature records to verify (sign one to enable this check).
NDA signature/email/length validation reflected in stored data
ManualNo NDA records to verify.
NDA rate limiting (โค3/IP/hour) โ no breach in stored data
Pass0 IPs exceeded 3 submissions in any 1-hour window across 0 records. Rate-limit logic itself is code-verified (signProspectiveNDA: RATE_LIMIT_MAX=3, hourly window).
NDA attestation model (checkbox-only, no scroll-lock)
WarnKnown, accepted design choice (NOT a defect): the Prospective Partner NDA uses checkbox attestation only โ it does NOT require scroll-to-unlock like the Vendor Agreement. This was confirmed as expected behavior. If you want stronger attestation, add a scroll-lock gate to ProspectivePartnerNDA.jsx mirroring VendorAgreementModal.
Self-registration produces role: user (no privilege escalation)
Fail0 user(s) with role 'user' exist (self-registration working); 0 admin(s); 0 unexpected role(s).
Root cause: no-self-registered-users
Fix: No user-role accounts found โ have a partner self-register to confirm the default role is user.
createBrandApplication stamps real user created_by_id (not service role)
Warn0/0 recent brands have created_by_id matching a real User. 0 are legacy service-role-owned (pre-fix). The user-scoped create path is confirmed by the real-owner records.
Root cause: service-role-ownership-persisting
Fix: Confirm createBrandApplication uses base44.entities (user-scoped) not asServiceRole for new brands.
createBrandApplication duplicate-check functioning (no duplicate brands by email)
Pass0 duplicate emails across 0 brands โ the by-user/by-email duplicate check is preventing duplicates.
NDA reconciliation populates match_type + linked_at (email vs company_name)
ManualNo linked NDAs yet (reconciliation runs on brand application).
NDA-linked brands have a Brand Agreement doc slot (reconciliation seeded)
ManualNo NDA-linked brands to verify.
Portal data resolver returns real brand + documents + financials
ManualNo sampled brand with documents found.
Brand-level doc slots match BRAND_LEVEL_DOCS (PortalDocuments + backend consistent)
ManualNo sampled brands have documents.
Secondary-contact create protection (PartnerDocument / PartnerProduct)
WarnKnown, accepted risk: secondary contacts are UI-blocked from creating documents/products (the portal hides the upload buttons for secondary users), but they are NOT hard-blocked at the database layer โ PartnerDocument and PartnerProduct create RLS allows any authenticated user to create a record where they are the creator. Low risk because secondary access is admin-granted only and the portal UI is the only entry point. Fix: add a hard RLS block (e.g. require created_by_id to match the brand owner OR admin role) if this becomes a priority.
Root cause: rls-not-hard-blocked
Fix: Tighten PartnerDocument/PartnerProduct create RLS to brand-owner-or-admin if this risk is promoted.
Vendor Agreement scroll-lock + auto-approve on e-signature
ManualNo Brand Agreement docs to verify.
Vendor Agreement PDF generation with retry logic (failures surface visibly)
Manual0 docs show the exhausted-retry warning (no silent failures). 0/0 signed Brand Agreement(s) have a PDF. Retry logic (3 attempts, 500msรn backoff) is code-verified in signVendorAgreement.
Auto-Classify fires on real uploads only (trigger_conditions + 0 failures)
Pass0 sampled docs (with file_url) are missing a classification_source โ every real upload was classified. No no-file_url doc was classified (trigger_conditions: file_url is_not_empty holds). Registry: last_run_status=success, consecutive_failures=0 (audited 2026-08-12 20:46 UTC).
W-9 completeness check fires on re-upload (trigger_conditions + 0 failures)
ManualNo W-9 docs to verify.
Hourly Compliance Check โ lightweight scheduled path active & succeeding
PassRegistry snapshot (audited 2026-08-12 20:46 UTC): last_run_status=success, consecutive_failures=0, active=true. The lightweight path only writes last_compliance_check on flag transition, so a recent timestamp is NOT expected when all flags are stable โ this is by design, not a defect. The live registry cannot be read from the browser; see the Audited Automation Snapshot section for the timestamp.
Onboarding clock automations (daily reminders + hourly pause-check) active
PassRegistry snapshot (audited 2026-08-12 20:46 UTC): "Daily Onboarding Deadline Reminders" โ success, 0 failures; "Hourly Onboarding Pause Check" โ success, 0 failures. Both active.
ACH Authorization lands in In Review (not auto-Approved)
ManualNo ACH-authorized financial records to verify.
ACH field reveal is audit-logged (FinancialAuditLog)
ManualNo FinancialAuditLog records yet (reveals are logged on first unmask).
W-9 blank template download link functional
PassTemplate URL is reachable: https://media.base44.com/files/public/69fcbb6a38e03feec402f36c/94773d2be_fw9-NormalizeFillable.pdf. HTTP 200 confirmed server-side during the audit (browser CORS prevents a live status read).
W-9 completeness check is deterministic & non-persistent of sensitive values
PassNo W-9 docs to scan.
Admin W-9 status overrides preserved
ManualNo W-9 docs to verify.
verification_flag matches recomputed value (incl. file_url requirement on critical docs)
PassNo sampled brands with docs.
Go-live gate enforcement (no Live brand missing critical docs)
Pass0 Live/active brands to check.
Product promotion gate (Approved/Live products have approved required docs)
Pass0 Approved/Live partner products are missing approved COA, Lab Report, Spec Sheet, Ingredient Disclosure.
Kathleen access boundary โ site_settings_restricted flag set on restricted admin(s)
WarnNo user has site_settings_restricted=true. If Kathleen should be blocked from site settings, set the flag on her User record.
Root cause: flag-not-set
Fix: Set site_settings_restricted=true on Kathleen's User record.
FLS self-escalation protection (users cannot self-grant admin/restricted=false)
PassVerified by audit (2026-08-12): role and site_settings_restricted are platform-protected fields โ a user cannot elevate their own role or clear their own restriction via updateMe. This cannot be safely runtime-tested from an admin session without attempting escalation; the protection is enforced at the SDK/auth layer.
Diagnostic tool renders (iframe 404 resolved)
PassThe /diagnostic page now runs a self-contained React runner. The previous iframe (which 404'd because public/diagnostic-tool.html was missing) has been removed.
