Conversation
Skip organizations where no member has logged in within 90 days. Prevents sending emails to dead/abandoned addresses that may have become spam traps, which contributes to domain reputation damage. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Adds hasAccess and onboardingCompleted filters alongside the 90-day session check. This excludes ~4,087 orgs (831 ghost + 3,256 churned) from receiving weekly digest emails. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
GET /v1/admin/organizations/activity Returns per-org activity data: last session, last audit log, and combined last activity timestamp. Supports filtering by hasAccess, onboardingCompleted, and inactivity threshold. Used for identifying inactive orgs that should be suppressed from email notifications. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Prevents inactiveDays=0 from silently defaulting to 90. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
parseInt returns NaN on invalid input, which is not nullish so ?? won't catch it. Use Number.isFinite to properly fall back to 90. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Per Tofik's review - match the same member scope used in the select clause so deactivated members don't count as active. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
[dev] [claudfuen] fix/suppress-inactive-org-emails
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
PR SummaryMedium Risk Overview Browser automations: updates Stagehand model IDs, and adds UI + hook support to pause/enable and delete automations (with disabled-state handling for scheduling and running). Onboarding & notifications: makes minimal org creation idempotent (reuses an existing not-onboarded org and completes missing initialization) and blocks duplicate form submissions; weekly task reminder emails now target only orgs with access, completed onboarding, and member sessions within the last 90 days. Removes unused Reviewed by Cursor Bugbot for commit cfee2f2. Bugbot is set up for automated code reviews on this repo. Configure here. |
Helps diagnose org health - an org with 0 tasks, 0 policies, and 0 audit logs is clearly a ghost regardless of session data. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…/toggle controls The Stagehand model config used 'claude-3-7-sonnet-latest' without the required 'provider/model' prefix, causing "Unsupported model" errors. Updated both init and CUA agent models to use 'anthropic/claude-sonnet-4-5-20250929'. Also added delete automation and enable/disable toggle to the frontend for a more complete MVP experience. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…eDays - Add deactivated:false to members query in getOrgActivity so deactivated users don't inflate lastSession or get picked as owner - Clamp inactiveDays to non-negative to prevent future-dated cutoffs Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
… paused Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
fix(browser-automation): fix Stagehand v3 model format and add MVP controls
Organization model uses singular `policy` not `policies`. Would have caused runtime Prisma validation error. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
feat: admin org activity endpoint
* fix(app): prevent duplicate org creation during setup onboarding When users retry or refresh during the redirect after org creation, the action fires again and creates a duplicate org. Add server-side idempotency check that reuses an existing incomplete org with the same name owned by the user, plus a client-side guard against double-submission. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix(app): complete partial setup when reusing existing org When reusing an existing incomplete org (idempotency path), ensure onboarding record and framework initialization exist. Handles the case where the original request failed after DB insert but before completing all setup steps. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Mariano Fuentes <marfuen98@gmail.com> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Co-authored-by: Tofik Hasanov <72318342+tofikwest@users.noreply.github.com>
Both apps/app and apps/portal had orphaned Resend client initializations that nothing imported. All email sending goes through Trigger.dev via the API. Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
🎉 This PR is included in version 3.20.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
This is an automated pull request to release the candidate branch into production, which will trigger a deployment.
It was created by the [Production PR] action.