admin-affiliate
Ask an LLM for the next affiliate-link improvement of one component
Sends component and stats to the Anthropic Messages API (ANTHROPIC_API_KEY required and checked before the body is read; model EXTRACT_MODEL, default claude-haiku-4-5-20251001; max_tokens 1200) and normalises the returned JSON. Nothing is persisted; apply the result with POST /api/admin/affiliate-apply.
- An unknown actionType becomes manual_review; reasoning keeps at most 4 strings.
- use_existing_url without preferredUrl, and search_and_apply or keep_search_fallback without searchQuery, are downgraded to manual_review with canAutoApply: false.
- For search_and_apply the server calls POST /api/admin/search-amazon on its own origin (forwarding the Authorization header) and puts the top hit into researchedUrl; without a hit it downgrades to manual_review and appends a reasoning line.
post/api/admin/affiliate-suggest
Request
- Base URL: https://voltplan.app
- URL: https://voltplan.app/api/admin/affiliate-suggest
- Auth: HTTP bearer
Request body
Response
Normalised suggestion.
Changes
No recorded changes to this operation across all 1 revision of this API.