Regenerate Prompts
🔵 POST - Regenerate Prompts
Regenerate Prompts
Manually regenerate AI visibility prompts for a business or product
POST
Regenerate Prompts
Overview
Manually regenerates the AI visibility prompts for a business or product. This endpoint scrapes the website fresh and generates new prompts using Gemini. Use cases:- Debugging prompt generation issues
- Refreshing prompts after significant website content changes
- Testing prompt generation for a specific entity
This endpoint requires API key authentication (
X-API-Key header).Prompt Limits
| Entity Type | Prompts | Notes |
|---|---|---|
| Business | 50 | 10 via Exa (onboarding only) + 40 via Gemini |
| Products | 10 each | Unlimited products |
This endpoint regenerates prompts via Gemini only. The 10 pre-tested Exa prompts are only generated during onboarding.
Request Body
Business identifier (clerk org slug)
Website URL to scrape for prompt generation
Optional product ID for product-specific prompts
Number of prompts to generate (default: 50 for business, 10 for product)
Response
success, skipped, or errorNumber of prompts generated by Gemini
Number of prompts saved to database
Reason for skipping (if status is
skipped)Error message if status is
errorExample
Internal Process
This endpoint calls thegenerate_prompts service which:
- Scrapes the website using Firecrawl (up to 5000 pages)
- Generates prompts using Gemini 3 Flash
- Saves prompts to the
entity_prompts_trackertable
Notes
- Prompts should NOT contain the business name (we test if AI recommends them organically)
- Regenerating prompts does NOT delete existing prompts - it adds new ones
- Visibility results for new prompts will be
nulluntil tested by the daily cron job - Pre-tested Exa prompts (from onboarding) are not affected by regeneration