[Expert Finder] Email generation (service, hooks and transformers)#659
[Expert Finder] Email generation (service, hooks and transformers)#659nicktytarenko wants to merge 4 commits intoexpert-finder-foundationfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
There was a problem hiding this comment.
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}`, |
There was a problem hiding this comment.
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.




What?
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
ExpertFinderServiceand new hooks inuseExpertFinder.Introduces new
GeneratedEmail/SavedTemplateapp types with snake_case→camelCase transformers, plus a newApiClient.deleteNoContenthelper 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.