Generate Email Templates
LLM-build the outreach brief for segment and persist it.
Lifted out of bridge.run_bridge so POST /projects returns in <1s instead of waiting on the 15-30s LLM round-trip. The frontend fires this endpoint as soon as the user picks a campaign in the onboarding wizard, so by the time they reach the template-editor sub-step the brief is already populated and email_templates_version > 0.
Idempotent: if the segment already carries non-empty instructions, the LLM call is skipped and the existing brief is returned. Failures (timeout, parse error) leave the row untouched (DEFAULT_TEMPLATES are NOT written — empty instructions would block the sender, same policy as the old bridge code).
Path parameters
Cookies
Response
Successful Response
Changes
No recorded changes to this endpoint across all 2 revisions of this API.