Skip to content

[Expert Finder] Email generation (service, hooks and transformers)#659

Open
nicktytarenko wants to merge 4 commits intoexpert-finder-foundationfrom
expert-finder-email-generation
Open

[Expert Finder] Email generation (service, hooks and transformers)#659
nicktytarenko wants to merge 4 commits intoexpert-finder-foundationfrom
expert-finder-email-generation

Conversation

@nicktytarenko
Copy link
Contributor

@nicktytarenko nicktytarenko commented Feb 22, 2026

What?

  • Implement email generation and management features in the expert finder service, including hooks for generating, and managing emails and templates.
  • Add new types and API methods for handling email drafts and generated emails.

Note

Medium Risk
Adds multiple new API integrations and client-side state hooks for creating/updating/deleting email-related records; main risk is contract mismatch with backend response shapes/status codes (notably preview vs saved generate-email and 204 deletes).

Overview
Adds end-to-end support for Expert Finder outreach emails: generating emails (preview vs saved draft), and CRUD/paginated listing for generated emails and saved templates via ExpertFinderService and new hooks in useExpertFinder.

Introduces new GeneratedEmail/SavedTemplate app types with snake_case→camelCase transformers, plus a new ApiClient.deleteNoContent helper to correctly handle 204 DELETE responses used by the new delete endpoints.

Written by Cursor Bugbot for commit e7e1399. This will update automatically on new commits. Configure here.

@vercel
Copy link
Contributor

vercel bot commented Feb 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
web Ready Ready Preview, Comment Feb 25, 2026 7:43pm

@nicktytarenko nicktytarenko marked this pull request as ready for review February 25, 2026 19:41
@nicktytarenko nicktytarenko requested a review from a team as a code owner February 25, 2026 19:41
@chatgpt-codex-connector
Copy link

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

@sonarqubecloud
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
4.2% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

@nicktytarenko nicktytarenko changed the title Email generation (service, hooks and transformers) [Expert Finder] Email generation (service, hooks and transformers) Feb 25, 2026
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

This is the final PR Bugbot will review for you during this billing cycle

Your free Bugbot reviews will reset on March 17

Details

Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

? `?${options?.action === 'generate' ? 'action=generate' : 'save=false'}`
: '';
const raw = await ApiClient.post<Record<string, unknown>>(
`${this.BASE_PATH}/generate-email${query}`,
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing trailing slash in generate-email endpoint URL

High Severity

The generate-email endpoint URL is constructed as `${this.BASE_PATH}/generate-email${query}` which omits the trailing slash. Every other endpoint in this service uses a trailing slash (e.g. /search/, /emails/, /templates/), and the docstring itself specifies POST /api/research_ai/expert-finder/generate-email/. On a Django backend with APPEND_SLASH=True, a POST without a trailing slash triggers a 301 redirect that converts the request to a GET, losing the payload entirely. This would cause all email generation calls to fail.

Fix in Cursor Fix in Web

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant