{"openapi":"3.1.0","info":{"title":"CopyThumb","version":"0.2.0"},"paths":{"/api/outliers/random":{"get":{"summary":"Random","operationId":"random_api_outliers_random_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":12,"title":"Limit"}},{"name":"min_score","in":"query","required":false,"schema":{"type":"number","default":2.0,"title":"Min Score"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Random Api Outliers Random Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/search":{"get":{"summary":"Search","operationId":"search_api_outliers_search_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","default":"","title":"Q"}},{"name":"niche","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Niche"}},{"name":"channel_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":60,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Search Api Outliers Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/scan":{"post":{"summary":"Trigger Scan","description":"Kick off a full background scan of all seed + tracked channels.","operationId":"trigger_scan_api_outliers_scan_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"force","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Force"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Trigger Scan Api Outliers Scan Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/scan/status":{"get":{"summary":"Scan Status","operationId":"scan_status_api_outliers_scan_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Scan Status Api Outliers Scan Status Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/outliers/seed-faceless":{"post":{"summary":"Trigger Seed Faceless","description":"Seed + scan the hand-picked faceless channel library (classic + AI).\n\nRuns in the background, progress via /api/outliers/scan/status.\nOutliers auto-populate the main videos table — no wasted data.","operationId":"trigger_seed_faceless_api_outliers_seed_faceless_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Trigger Seed Faceless Api Outliers Seed Faceless Post"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/outliers/enrich":{"post":{"summary":"Trigger Enrich","description":"Resolve all curated handles → write to registry → scan all channels.","operationId":"trigger_enrich_api_outliers_enrich_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"force","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Force"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Trigger Enrich Api Outliers Enrich Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/smart-finds":{"get":{"summary":"List Smart Finds","description":"Return all saved Smart Find searches, newest first.","operationId":"list_smart_finds_api_outliers_smart_finds_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Smart Finds Api Outliers Smart Finds Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/outliers/by-channels":{"get":{"summary":"By Channels","description":"Return outliers for a comma-separated list of channel IDs.\n\nIf any requested channel has fewer than ~10 longform thumbnails on\nfile, fire a background top-up via `top_videos_for_channels` so the\nNEXT carousel load is full. This keeps newly-tracked Shorts-heavy\nchannels (MrBeast, etc.) from showing a 2-thumb marquee on first\nselection.","operationId":"by_channels_api_outliers_by_channels_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ids","in":"query","required":false,"schema":{"type":"string","default":"","title":"Ids"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response By Channels Api Outliers By Channels Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/smart-search":{"post":{"summary":"Smart Search","description":"Describe a style → LLM generates search queries → YouTube finds real channels → scan.","operationId":"smart_search_api_outliers_smart_search_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Body"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Smart Search Api Outliers Smart Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/outliers/recent":{"get":{"summary":"Recent","description":"Most-recently-indexed outliers by fetched_at DESC. Used by Home page.","operationId":"recent_api_outliers_recent_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":6,"title":"Limit"}},{"name":"min_score","in":"query","required":false,"schema":{"type":"number","default":2.0,"title":"Min Score"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Recent Api Outliers Recent Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/premium":{"get":{"summary":"Premium","description":"Premium-channel-only outliers, score-capped. Used by Home showcase.\n\nfaceless=1 → prioritise illustrated/text-heavy niches (history, finance, ai, etc).","operationId":"premium_api_outliers_premium_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":10,"title":"Limit"}},{"name":"min_subs","in":"query","required":false,"schema":{"type":"integer","default":100000,"title":"Min Subs"}},{"name":"min_score","in":"query","required":false,"schema":{"type":"number","default":3.0,"title":"Min Score"}},{"name":"max_score","in":"query","required":false,"schema":{"type":"number","default":25.0,"title":"Max Score"}},{"name":"faceless","in":"query","required":false,"schema":{"type":"integer","default":1,"title":"Faceless"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Premium Api Outliers Premium Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/stats":{"get":{"summary":"Stats","description":"Score-tier counts for the Dashboard (2x / 3x / 5x / 10x buckets).","operationId":"stats_api_outliers_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Stats Api Outliers Stats Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/outliers/niche-stats":{"get":{"summary":"Get Niche Stats","description":"Per-niche breakdown: channels, videos, avg score, last scanned.","operationId":"get_niche_stats_api_outliers_niche_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Niche Stats Api Outliers Niche Stats Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/outliers/style-tags":{"get":{"summary":"Get Style Tags","description":"Top N style tags across all indexed thumbnails (for Dashboard tag cloud).","operationId":"get_style_tags_api_outliers_style_tags_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"top_n","in":"query","required":false,"schema":{"type":"integer","default":15,"title":"Top N"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Style Tags Api Outliers Style Tags Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/niches":{"get":{"summary":"Get Niches","description":"Distinct niche values for filter dropdowns.","operationId":"get_niches_api_outliers_niches_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Niches Api Outliers Niches Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/outliers/channels-random":{"get":{"summary":"Channels Random","description":"Shuffled mix of curated + tracked channels with outlier stats and mini-thumb IDs.\n\n`fresh=1` bypasses the 2-minute cache — used when the user hits the\nShuffle button and genuinely wants a rebuilt pool.\n\nPer-viewer scoping: anonymous landing-page visitors see ONLY curated\nchannels. Logged-in users see curated + their OWN tracked channels\n(the \"In My Channels\" badge only fires for the viewer's adds).\nCache key includes viewer_id so the founder's pool can never be\nserved to other users — the exact cross-account leak fixed 2026-05-24.","operationId":"channels_random_api_outliers_channels_random_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Limit"}},{"name":"niche","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Niche"}},{"name":"fresh","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Fresh"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Channels Random Api Outliers Channels Random Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/outliers/{video_id}":{"get":{"summary":"Detail","operationId":"detail_api_outliers__video_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"video_id","in":"path","required":true,"schema":{"type":"string","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Detail Api Outliers  Video Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/trackers":{"get":{"summary":"List Tracked","description":"List the caller's reference channels + the plan-driven cap.\n\nThe UI uses the cap fields to render the \"X of N used\" indicator\nand the upgrade prompt when at the limit.","operationId":"list_tracked_api_trackers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Tracked Api Trackers Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"summary":"Add","operationId":"add_api_trackers_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Payload"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Add Api Trackers Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/trackers/{channel_id}":{"delete":{"summary":"Remove","operationId":"remove_api_trackers__channel_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string","title":"Channel Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Remove Api Trackers  Channel Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/trackers/{channel_id}/default":{"patch":{"summary":"Set Default","operationId":"set_default_api_trackers__channel_id__default_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string","title":"Channel Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Set Default Api Trackers  Channel Id  Default Patch"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/trackers/{channel_id}/resummarize":{"post":{"summary":"Resummarize","description":"Re-run AI synthesis for this channel's 'About' text.","operationId":"resummarize_api_trackers__channel_id__resummarize_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string","title":"Channel Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Resummarize Api Trackers  Channel Id  Resummarize Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/trackers/{channel_id}/refresh":{"post":{"summary":"Refresh","description":"Kick off background outlier scan, return job_id for SSE.","operationId":"refresh_api_trackers__channel_id__refresh_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string","title":"Channel Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Refresh Api Trackers  Channel Id  Refresh Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/trackers/scan/{job_id}":{"get":{"summary":"Scan Progress","operationId":"scan_progress_api_trackers_scan__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels":{"get":{"tags":["my-channels"],"summary":"List Channels","operationId":"list_channels_api_my_channels_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["my-channels"],"summary":"Create Channel","operationId":"create_channel_api_my_channels_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/my-channels/discover-niches":{"post":{"tags":["my-channels"],"summary":"Discover Niches Standalone","description":"Discover high-virality niches from a reference channel (standalone, no my_channel needed).","operationId":"discover_niches_standalone_api_my_channels_discover_niches_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NicheDiscoverRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/my-channels/discover-niches/status/{job_id}":{"get":{"tags":["my-channels"],"summary":"Discover Niches Status","operationId":"discover_niches_status_api_my_channels_discover_niches_status__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/discover-niches/history":{"get":{"tags":["my-channels"],"summary":"Niche Discovery History","description":"Return past niche discovery batches, newest first.\n\nThe niche_discoverer already persists individual niches with a shared\nbatch_id. This endpoint groups them back into runs.","operationId":"niche_discovery_history_api_my_channels_discover_niches_history_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"reference_channel_id","in":"query","required":false,"schema":{"type":"string","default":"","title":"Reference Channel Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":20,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/discover-niches/history/{batch_id}":{"delete":{"tags":["my-channels"],"summary":"Delete Niche Discovery","operationId":"delete_niche_discovery_api_my_channels_discover_niches_history__batch_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","title":"Batch Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/duplicate/generate":{"post":{"tags":["my-channels"],"summary":"Duplicate Generate","description":"Run the 5-stage duplication pipeline; returns job_id for progressive polling.\n\nAuth-required and user-scoped: the caller can ONLY pick a tracked\nchannel from their OWN library. Without the user_id filter, any\nuser could pass any channel_id and trigger duplication on another\nuser's saved channel (cross-account leak fixed 2026-05-24).","operationId":"duplicate_generate_api_my_channels_duplicate_generate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DuplicateGenerateRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/my-channels/duplicate/status/{job_id}":{"get":{"tags":["my-channels"],"summary":"Duplicate Status","description":"Poll job state — returns everything streamed so far (progressive UI).","operationId":"duplicate_status_api_my_channels_duplicate_status__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/duplicate/logo-variants":{"post":{"tags":["my-channels"],"summary":"Duplicate Logo Variants","description":"Generate logo images for each concept so the user can pick a winner.\n\nRuns synchronously in a thread pool — each concept generates one image.\nResults are written into _dup_jobs[job_id].logo_variants as a list of\n{concept_index, image_path, status}.","operationId":"duplicate_logo_variants_api_my_channels_duplicate_logo_variants_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LogoVariantsRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/my-channels/duplicate/confirm":{"post":{"tags":["my-channels"],"summary":"Duplicate Confirm","description":"Create the duplicated channel with the confirmed bundle data.","operationId":"duplicate_confirm_api_my_channels_duplicate_confirm_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DuplicateConfirmRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/my-channels/{name}":{"get":{"tags":["my-channels"],"summary":"Get Channel","operationId":"get_channel_api_my_channels__name__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["my-channels"],"summary":"Update Channel","operationId":"update_channel_api_my_channels__name__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["my-channels"],"summary":"Delete Channel","operationId":"delete_channel_api_my_channels__name__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos":{"get":{"tags":["my-channels"],"summary":"List Videos","operationId":"list_videos_api_my_channels__name__videos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["my-channels"],"summary":"Create Video","operationId":"create_video_api_my_channels__name__videos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}":{"patch":{"tags":["my-channels"],"summary":"Update Video","operationId":"update_video_api_my_channels__name__videos__video_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["my-channels"],"summary":"Delete Video","operationId":"delete_video_api_my_channels__name__videos__video_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/generate-logo":{"post":{"tags":["my-channels"],"summary":"Generate Logo Endpoint","operationId":"generate_logo_endpoint_api_my_channels__name__generate_logo_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/logo-status":{"get":{"tags":["my-channels"],"summary":"Logo Status","operationId":"logo_status_api_my_channels__name__logo_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/scan":{"post":{"tags":["my-channels"],"summary":"Start Scan","description":"Kick off URE on the top N videos of the reference channel.\n\nBody: { \"num_videos\": 1 | 2 | 5 | 10 }  (default 3)","operationId":"start_scan_api_my_channels__name__scan_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"type":"object","additionalProperties":true},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/scan/status":{"get":{"tags":["my-channels"],"summary":"Scan Status","operationId":"scan_status_api_my_channels__name__scan_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/scan/abort":{"post":{"tags":["my-channels"],"summary":"Scan Abort","description":"Stop the scan and synthesize DNA from whatever data already exists.\n\nPriority:\n1. Complete blueprints (blueprint.json) → use directly\n2. Partial URE folders (scenes.json present, no blueprint) → resume URE\n   from existing data so frames/scenes aren't re-downloaded\n3. Nothing at all → write a sensible default formula","operationId":"scan_abort_api_my_channels__name__scan_abort_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce":{"post":{"tags":["my-channels"],"summary":"Start Produce","operationId":"start_produce_api_my_channels__name__videos__video_id__produce_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProduceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/status":{"get":{"tags":["my-channels"],"summary":"Produce Status","operationId":"produce_status_api_my_channels__name__videos__video_id__produce_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/dna-summary":{"get":{"tags":["my-channels"],"summary":"Dna Summary","operationId":"dna_summary_api_my_channels__name__dna_summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/ideas":{"post":{"tags":["my-channels"],"summary":"Generate Channel Ideas","operationId":"generate_channel_ideas_api_my_channels__name__ideas_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/ideas/status/{job_id}":{"get":{"tags":["my-channels"],"summary":"Channel Ideas Status","operationId":"channel_ideas_status_api_my_channels__name__ideas_status__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/titles":{"post":{"tags":["my-channels"],"summary":"Generate Video Titles","description":"Generate title variants for a video using the same title_generator as\nthe main Titles tab — anchored in the reference channel's real past titles.","operationId":"generate_video_titles_api_my_channels__name__videos__video_id__titles_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/titles/status":{"get":{"tags":["my-channels"],"summary":"Video Titles Status","operationId":"video_titles_status_api_my_channels__name__videos__video_id__titles_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/thumbnail":{"post":{"tags":["my-channels"],"summary":"Start Thumbnail","description":"Generate a thumbnail using the reference channel's scraped thumbnails as style refs.\nOptional body: { \"style_channel_id\": \"@handle or channel_id\" } to override the style source.","operationId":"start_thumbnail_api_my_channels__name__videos__video_id__thumbnail_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/thumbnail/status":{"get":{"tags":["my-channels"],"summary":"Thumbnail Status","operationId":"thumbnail_status_api_my_channels__name__videos__video_id__thumbnail_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/script":{"post":{"tags":["my-channels"],"summary":"Generate Script","operationId":"generate_script_api_my_channels__name__videos__video_id__script_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScriptRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["my-channels"],"summary":"Get Script","operationId":"get_script_api_my_channels__name__videos__video_id__script_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["my-channels"],"summary":"Save Script","operationId":"save_script_api_my_channels__name__videos__video_id__script_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScriptSave"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/script/status":{"get":{"tags":["my-channels"],"summary":"Script Job Status","operationId":"script_job_status_api_my_channels__name__videos__video_id__script_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/script/approve":{"post":{"tags":["my-channels"],"summary":"Approve Script","operationId":"approve_script_api_my_channels__name__videos__video_id__script_approve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/section/{sid}":{"post":{"tags":["my-channels"],"summary":"Start Section Produce","operationId":"start_section_produce_api_my_channels__name__videos__video_id__produce_section__sid__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}},{"name":"sid","in":"path","required":true,"schema":{"type":"string","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/section/{sid}/approve":{"post":{"tags":["my-channels"],"summary":"Approve Section","description":"User approves a completed section — unlocks the next one.","operationId":"approve_section_api_my_channels__name__videos__video_id__produce_section__sid__approve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}},{"name":"sid","in":"path","required":true,"schema":{"type":"string","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/section/{sid}/status":{"get":{"tags":["my-channels"],"summary":"Section Produce Status","operationId":"section_produce_status_api_my_channels__name__videos__video_id__produce_section__sid__status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}},{"name":"sid","in":"path","required":true,"schema":{"type":"string","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/section/{sid}/redo":{"post":{"tags":["my-channels"],"summary":"Redo Section","operationId":"redo_section_api_my_channels__name__videos__video_id__produce_section__sid__redo_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}},{"name":"sid","in":"path","required":true,"schema":{"type":"string","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/sections":{"get":{"tags":["my-channels"],"summary":"List Produce Sections","operationId":"list_produce_sections_api_my_channels__name__videos__video_id__produce_sections_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/section/{sid}/resume":{"post":{"tags":["my-channels"],"summary":"Resume Section","description":"Resume a section that was interrupted by a server crash.\n\nThe underlying pipeline stages are idempotent: each scene's PNG /\nMP3 / MP4 is only regenerated if the cached file is missing or\nstructurally corrupt. A resume therefore rehits Gemini/ElevenLabs\n*only* for scenes that didn't finish before the crash.","operationId":"resume_section_api_my_channels__name__videos__video_id__produce_section__sid__resume_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}},{"name":"sid","in":"path","required":true,"schema":{"type":"string","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/section/{sid}/stop":{"post":{"tags":["my-channels"],"summary":"Stop Section","description":"HARD STOP the in-flight section production.\n\nNot a polite request — this flips the cancel flag, closes any\nin-flight Gemini/ElevenLabs HTTP socket, and SIGTERMs any live\nFFmpeg child. No further paid API calls will be made for this job\nuntil the user explicitly starts/resumes it again.","operationId":"stop_section_api_my_channels__name__videos__video_id__produce_section__sid__stop_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}},{"name":"sid","in":"path","required":true,"schema":{"type":"string","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/stop":{"post":{"tags":["my-channels"],"summary":"Stop Full","description":"HARD STOP the in-flight full-pipeline production.","operationId":"stop_full_api_my_channels__name__videos__video_id__produce_stop_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/resume":{"post":{"tags":["my-channels"],"summary":"Resume Full","description":"Resume an interrupted full-video production.","operationId":"resume_full_api_my_channels__name__videos__video_id__produce_resume_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProduceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/final":{"post":{"tags":["my-channels"],"summary":"Start Final Assembly","operationId":"start_final_assembly_api_my_channels__name__videos__video_id__produce_final_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/my-channels/{name}/videos/{video_id}/produce/final/status":{"get":{"tags":["my-channels"],"summary":"Final Status","operationId":"final_status_api_my_channels__name__videos__video_id__produce_final_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"video_id","in":"path","required":true,"schema":{"type":"integer","title":"Video Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/generate":{"post":{"summary":"Api Generate","operationId":"api_generate_api_generate_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_api_generate_api_generate_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Api Generate Api Generate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/progress/{job_id}":{"get":{"summary":"Progress Stream","operationId":"progress_stream_api_progress__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/generate/{job_id}/cancel":{"post":{"summary":"Cancel Job","operationId":"cancel_job_api_generate__job_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Cancel Job Api Generate  Job Id  Cancel Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/generate/clone":{"post":{"summary":"Api Generate Clone","description":"Render new variants in the EXACT style of an uploaded source thumbnail.\n\nDistinct from /api/generate: no channel scrape, no style DNA lookup.\nThe source thumbnail IS the style anchor. Token cost identical to a\nsame-variant-count /api/generate call.\n\nPro+ only — Free plan gets 402 (clone-a-thumbnail is a paid feature).","operationId":"api_generate_clone_api_generate_clone_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_api_generate_clone_api_generate_clone_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Api Generate Clone Api Generate Clone Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/refine":{"post":{"summary":"Api Refine","description":"Vertex AI refine (PinPoint edit) on an existing generation.\n\nMoney/security guards (this endpoint was previously wide-open):\n  - auth: Depends(require_user) — anonymous callers get 401 via the\n    global auth middleware now AND the dependency makes attribution\n    explicit on every token spend.\n  - ownership: the caller must own the source image (matched by\n    user_id on the generations row keyed by file_path). Cross-user\n    refines 404 — no info leak.\n  - token gate: same _gen_token_check as /api/generate with\n    variants=1. Failed refines do NOT charge (debit only fires in\n    the success branch).\n  - watermark: free-tier outputs are stamped via apply_post AFTER\n    refine_thumbnail returns. _should_watermark reads PLAN_CAPS so\n    a free user can never get a clean refine of their watermarked\n    source.","operationId":"api_refine_api_refine_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_api_refine_api_refine_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Api Refine Api Refine Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/restyle":{"post":{"summary":"Api Restyle","description":"Restyle a thumbnail: exact same scene, different reference channel's DNA.\n\n1. Vision-reads the original to lock every detail (subjects, composition,\n   text, colors).\n2. Resolves the new channel's style DNA.\n3. Generates with a restyle-specific prompt that forces scene preservation\n   while swapping the visual treatment.\n\nRestyle costs the same as a 1-variant generate for the user's tier\n(1 token on Imagen 4, 3 tokens on Gemini 3 Pro Image). Like /api/generate,\nthe debit only fires on success.\n\nPro+ only — Free plan gets 402 (Restyle is a paid feature).","operationId":"api_restyle_api_restyle_post","requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/Body_api_restyle_api_restyle_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Api Restyle Api Restyle Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/thumbnails/history":{"get":{"summary":"Thumbnails History","description":"User-scoped render history. v0.2.10: filters by user_id so each\naccount only sees their own renders.","operationId":"thumbnails_history_api_thumbnails_history_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"channel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":120,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Thumbnails History Api Thumbnails History Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/thumbnails/by-url":{"delete":{"summary":"Delete Thumbnail By Url","description":"Delete a generated thumbnail by its served URL. Scoped to caller —\na user cannot delete another user's row.","operationId":"delete_thumbnail_by_url_api_thumbnails_by_url_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","title":"Url"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/thumbnails/{gen_id}":{"delete":{"summary":"Delete Thumbnail","description":"Permanently delete a generated thumbnail (DB row + file on disk).\nOnly the owner can delete — cross-user deletes 404 (not 403, to\navoid leaking existence of other users' rows).","operationId":"delete_thumbnail_api_thumbnails__gen_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"gen_id","in":"path","required":true,"schema":{"type":"integer","title":"Gen Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/settings":{"get":{"summary":"Settings","operationId":"settings_api_settings_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Settings Api Settings Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/stats":{"get":{"summary":"Stats","operationId":"stats_api_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Stats Api Stats Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/cost/budget":{"post":{"summary":"Set Cost Budget","description":"Set the hard session cost cap (USD). 0 = unlimited.\n\nWhen the cap is raised above current spend, the paused state clears\nautomatically — the pipeline resumes accepting expensive calls.","operationId":"set_cost_budget_api_cost_budget_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_BudgetRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Set Cost Budget Api Cost Budget Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/cost/reset":{"post":{"summary":"Reset Cost Counter","description":"Reset the per-session cost counter back to zero. Useful when the\nuser wants a clean slate after a test run without restarting.","operationId":"reset_cost_counter_api_cost_reset_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Reset Cost Counter Api Cost Reset Post"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/home/latest-creations":{"get":{"summary":"Latest Creations","description":"Return the most recently modified thumbnails from productions + reverse folders.\n\nUsed by Home \"Your Latest Creations\" showcase.","operationId":"latest_creations_api_home_latest_creations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":4,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Latest Creations Api Home Latest Creations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/settings/open-output":{"post":{"summary":"Open Output Folder","description":"Open the output folder in the OS file browser.","operationId":"open_output_folder_api_settings_open_output_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Open Output Folder Api Settings Open Output Post"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/styles":{"get":{"tags":["styles"],"summary":"List Styles","description":"Return all styles (dna + preset + custom) for the picker.","operationId":"list_styles_api_styles_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Styles Api Styles Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["styles"],"summary":"Create Custom Style","description":"Create a custom style from 1–20 uploaded reference images.\n\nReturns the new style_id and metadata.\n\nToken-gated: style creation runs 3 Gemini Vision calls (DNA\nextraction + brief + prefix). Costs 1 token — cheaper than a\nfull render. Debit fires AFTER all three Vision calls succeed;\nfailed Vision calls bubble as 500 and DO NOT charge.","operationId":"create_custom_style_api_styles_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_create_custom_style_api_styles_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Create Custom Style Api Styles Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/styles/custom":{"get":{"tags":["styles"],"summary":"List Custom Styles","description":"Return presets + custom user-uploaded styles.","operationId":"list_custom_styles_api_styles_custom_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Custom Styles Api Styles Custom Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/styles/{style_uuid}":{"delete":{"tags":["styles"],"summary":"Delete Custom Style","description":"Delete a custom style.","operationId":"delete_custom_style_api_styles__style_uuid__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Delete Custom Style Api Styles  Style Uuid  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["styles"],"summary":"Get Custom Style","description":"Get a custom style by UUID.","operationId":"get_custom_style_api_styles__style_uuid__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Custom Style Api Styles  Style Uuid  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/styles/{style_uuid}/preview":{"post":{"tags":["styles"],"summary":"Generate Preview","description":"Kick off background thread to generate a preview image for a custom style.\n\nToken-gated: previewing a custom style runs a full Vertex render of\nthe canonical preview scene (same compute cost as one /api/generate\nvariant), so it charges the same 3 tokens. The debit fires AFTER\nthe background thread successfully writes the preview; failed\nrenders do not consume tokens.","operationId":"generate_preview_api_styles__style_uuid__preview_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Generate Preview Api Styles  Style Uuid  Preview Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/styles/{style_uuid}/preview/status":{"get":{"tags":["styles"],"summary":"Get Preview Status","description":"Poll the status of a preview generation job.","operationId":"get_preview_status_api_styles__style_uuid__preview_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}},{"name":"job_id","in":"query","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Preview Status Api Styles  Style Uuid  Preview Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/styles/{style_uuid}/preview/image":{"get":{"tags":["styles"],"summary":"Serve Preview Image","description":"Serve the generated preview image PNG.","operationId":"serve_preview_image_api_styles__style_uuid__preview_image_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/styles/{style_uuid}/regenerate-dna":{"post":{"tags":["styles"],"summary":"Regenerate Dna","description":"Re-run style DNA extraction against the existing reference images.\n\nUpgrades an older style in-place so it gains new DNA fields (mood_profiles,\ntechnique_prefix) without re-uploading. Clears the cached preview so the\nnext render reflects the upgraded DNA.\n\nToken-gated: 3 Vision calls — DNA + brief + prefix. 1 token\n(Vision-only, no full render). Debit fires after all 3 succeed;\nVision failures bubble as 500 and DO NOT charge.","operationId":"regenerate_dna_api_styles__style_uuid__regenerate_dna_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Regenerate Dna Api Styles  Style Uuid  Regenerate Dna Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/styles/{style_uuid}/refs/download":{"get":{"tags":["styles"],"summary":"Download All Ref Images","description":"Download every reference image for a style as a single ZIP.\n\nUseful for: backing up a style's training images before regenerating\nDNA, sharing a style with another machine, auditing what Gemini saw,\nor pulling the images into a different tool. Files keep their\noriginal filenames; one image per entry.","operationId":"download_all_ref_images_api_styles__style_uuid__refs_download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/styles/{style_uuid}/ref/{n}":{"get":{"tags":["styles"],"summary":"Serve Ref Image","description":"Serve a reference image by index.","operationId":"serve_ref_image_api_styles__style_uuid__ref__n__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}},{"name":"n","in":"path","required":true,"schema":{"type":"integer","title":"N"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/styles/{style_uuid}/generate-prompt":{"post":{"tags":["styles"],"summary":"Generate Style Prompt","description":"Generate a scene-type-aware image prompt for a given topic in this style.\n\nUses the structured style DNA to intelligently construct environments,\ncharacters, and objects for ANY scene type.","operationId":"generate_style_prompt_api_styles__style_uuid__generate_prompt_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_uuid","in":"path","required":true,"schema":{"type":"string","title":"Style Uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GeneratePromptRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Generate Style Prompt Api Styles  Style Uuid  Generate Prompt Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters":{"post":{"tags":["characters"],"summary":"Create Character","description":"Create a new character and auto-queue sheet generation.\n\nToken-gated: character creation queues a 3-panel Gemini render\n(most expensive operation on the platform). Costs 3 tokens — same\nas one /api/generate variant. Charged ONLY when a sheet is actually\nqueued (i.e., visual_description is non-empty); empty descriptions\ncreate a placeholder row without burning Vertex compute, so no\ncharge.","operationId":"create_character_api_characters_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["characters"],"summary":"List Characters","description":"List characters, optionally filtered by style.","operationId":"list_characters_api_characters_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"style_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Style Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/{char_id}":{"get":{"tags":["characters"],"summary":"Get Character","description":"Get a single character.","operationId":"get_character_api_characters__char_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"char_id","in":"path","required":true,"schema":{"type":"string","title":"Char Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["characters"],"summary":"Update Character","description":"Update a character.","operationId":"update_character_api_characters__char_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"char_id","in":"path","required":true,"schema":{"type":"string","title":"Char Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["characters"],"summary":"Delete Character","description":"Delete a character.","operationId":"delete_character_api_characters__char_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"char_id","in":"path","required":true,"schema":{"type":"string","title":"Char Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/{char_id}/generate-sheet":{"post":{"tags":["characters"],"summary":"Regenerate Character Sheet","description":"Re-queue a 3-panel character sheet generation for this character.\n\nUse to regenerate if the first attempt produced an off-style result.\nRuns in background via the shared serialized worker. Poll\n`GET /{char_id}/sheet-status` for progress.\n\nToken-gated: a sheet regeneration is a full 3-panel Gemini render\n(the most expensive operation on the platform — multiple Vertex\ncalls + Vision QC). Costs 3 tokens (same as one /api/generate\nvariant) and the debit fires AFTER the queue accepts the job.\nFailed queues do not consume tokens; failed RENDERS still charge\n(matches the legacy quota_dependency pattern — moving to post-\nrender debit is follow-up work).","operationId":"regenerate_character_sheet_api_characters__char_id__generate_sheet_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"char_id","in":"path","required":true,"schema":{"type":"string","title":"Char Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Regenerate Character Sheet Api Characters  Char Id  Generate Sheet Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/{char_id}/sheet-status":{"get":{"tags":["characters"],"summary":"Get Sheet Status","description":"Poll in-progress sheet generation. Returns status + panels_done.\n\nAlso surfaces Claude's most-recent sheet QC verdict (parsed from\nthe `last_sheet_verdict` column on the characters row). When\nClaude flagged the sheet (passed=false), the UI uses this to\nbadge the character card with \"Claude rejected — regenerate\"\nso the user knows the sheet is shipping with known issues\nrather than discovering it via downstream scene drift.","operationId":"get_sheet_status_api_characters__char_id__sheet_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"char_id","in":"path","required":true,"schema":{"type":"string","title":"Char Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Sheet Status Api Characters  Char Id  Sheet Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/{char_id}/sheet-full":{"get":{"tags":["characters"],"summary":"Serve Full Sheet","description":"Serve the full wide character turnaround (the canonical 'one sheet').\n\nThis is the raw image generated by one forward pass — the three panels\nside-by-side. The UI displays this large and clickable.","operationId":"serve_full_sheet_api_characters__char_id__sheet_full_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"char_id","in":"path","required":true,"schema":{"type":"string","title":"Char Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/{char_id}/sheet/{panel_idx}":{"get":{"tags":["characters"],"summary":"Serve Sheet Panel","description":"Serve one panel of the character sheet by index (0=full, 1=medium, 2=close).","operationId":"serve_sheet_panel_api_characters__char_id__sheet__panel_idx__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"char_id","in":"path","required":true,"schema":{"type":"string","title":"Char Id"}},{"name":"panel_idx","in":"path","required":true,"schema":{"type":"integer","title":"Panel Idx"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/productions/{production_id}/assign-character":{"post":{"tags":["characters"],"summary":"Assign Character To Production","description":"Assign a character to a production with specific scene appearances.\n\nIf the character is already assigned to this production, updates the scene list.","operationId":"assign_character_to_production_api_characters_productions__production_id__assign_character_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CharacterSceneAssignment"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/productions/{production_id}":{"get":{"tags":["characters"],"summary":"Get Production Characters","description":"Get all characters assigned to a production with their scene appearances.","operationId":"get_production_characters_api_characters_productions__production_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/productions/{production_id}/{character_id}":{"delete":{"tags":["characters"],"summary":"Remove Character From Production","description":"Remove a character from a production (unassign scenes).","operationId":"remove_character_from_production_api_characters_productions__production_id___character_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}},{"name":"character_id","in":"path","required":true,"schema":{"type":"string","title":"Character Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/characters/productions/{production_id}/batch-assign":{"post":{"tags":["characters"],"summary":"Batch Assign Characters","description":"Batch assign multiple characters to a production with their scenes.\n\nReplaces all existing assignments for this production.","operationId":"batch_assign_characters_api_characters_productions__production_id__batch_assign_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"production_id","in":"path","required":true,"schema":{"type":"string","title":"Production Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchCharacterAssignmentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/style-channels":{"get":{"summary":"Style Channels","operationId":"style_channels_api_style_channels_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Style Channels Api Style Channels Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/account/me":{"get":{"tags":["account"],"summary":"Get Me","operationId":"get_me_api_account_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Me Api Account Me Get"}}}}},"security":[{"HTTPBearer":[]}]},"put":{"tags":["account"],"summary":"Update Me","operationId":"update_me_api_account_me_put","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileUpdate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Update Me Api Account Me Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/account/onboarded":{"post":{"tags":["account"],"summary":"Mark Onboarded","description":"Mark the current user as having completed the welcome wizard.\n\nCalled by welcome.js when the user clicks \"Now make yours →\" at step\n5. Subsequent logins read `onboarded_at` and skip the wizard.\n\nIdempotent: re-calling doesn't overwrite the original timestamp so we\nkeep a true \"first onboarding finished at\" audit value.","operationId":"mark_onboarded_api_account_onboarded_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Mark Onboarded Api Account Onboarded Post"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/account/password":{"post":{"tags":["account"],"summary":"Change Password","operationId":"change_password_api_account_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordChange"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Change Password Api Account Password Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/account":{"delete":{"tags":["account"],"summary":"Delete Account","description":"Soft-delete — anonymises email + marks the row with deleted_at.\n\nPer-tenant rows owned by this user stay in the DB (audit trail) but\nare inaccessible because the auth middleware can no longer resolve\nthe supabase_user_id back to this row.","operationId":"delete_account_api_account_delete","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Delete Account Api Account Delete"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/account/usage":{"get":{"tags":["account"],"summary":"Usage Summary","description":"v0.2.2 token-bucket usage. Returns the user's plan grant, tokens\nspent this period, add-on pack balance, and a per-model breakdown\nso the UI can show \"200 tokens on Imagen 4, 30 on Gemini 3\".","operationId":"usage_summary_api_account_usage_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Usage Summary Api Account Usage Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/account/api-keys":{"get":{"tags":["account"],"summary":"List Api Keys","operationId":"list_api_keys_api_account_api_keys_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Api Keys Api Account Api Keys Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["account"],"summary":"Create Api Key","description":"Generate a new API key. The full token is shown ONCE in this response —\nafter this, only the prefix (first 8 chars) is recoverable.","operationId":"create_api_key_api_account_api_keys_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Create Api Key Api Account Api Keys Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/account/api-keys/{key_id}":{"delete":{"tags":["account"],"summary":"Revoke Api Key","operationId":"revoke_api_key_api_account_api_keys__key_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"integer","title":"Key Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Revoke Api Key Api Account Api Keys  Key Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/account/referral":{"get":{"tags":["account"],"summary":"My Referral","description":"The current user's referral code, share URL, and conversion stats.\n\nPowers the in-app \"Invite friends, earn 330 tokens\" popup. Every\npaid signup brought in via the user's code credits 330 tokens\n(~$10 value) — see paypal_manual._maybe_pay_referrer.","operationId":"my_referral_api_account_referral_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response My Referral Api Account Referral Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/support/contact":{"post":{"tags":["support"],"summary":"Contact Support","operationId":"contact_support_api_support_contact_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Contact Support Api Support Contact Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/admin/spend":{"get":{"tags":["admin"],"summary":"Admin Spend","description":"Full operator view. Includes raw dollar amounts (master-only).","operationId":"admin_spend_api_admin_spend_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Admin Spend Api Admin Spend Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/admin/spend/fire-test":{"post":{"tags":["admin"],"summary":"Admin Fire Test Alert","description":"One-shot dispatch of a budget alert at a specified pct. Used to\nverify the Discord webhook + Resend wiring BEFORE you've actually\nburned through 50% of the budget. Always sends — bypasses the\nidempotency check on purpose.","operationId":"admin_fire_test_alert_api_admin_spend_fire_test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pct","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Pct"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Fire Test Alert Api Admin Spend Fire Test Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/feed":{"get":{"tags":["admin"],"summary":"Admin Feed","description":"Recent thumbnail generations across ALL users, newest first.\n\nJoins `generations` to `users` so the operator sees who rendered\nwhat. Returns image URLs that resolve through /output/* so the\noperator can eyeball quality directly from the dashboard.","operationId":"admin_feed_api_admin_feed_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Feed Api Admin Feed Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/users":{"get":{"tags":["admin"],"summary":"Admin Users","description":"All signups with plan + activity summary.","operationId":"admin_users_api_admin_users_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Admin Users Api Admin Users Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/admin/transactions":{"get":{"tags":["admin"],"summary":"Admin Transactions","description":"All PayPal transactions — subscriptions, top-up packs, refunds.\n\nReads `paypal_txns`, the dedup-keyed audit log written by every\n`apply_ipn()` call. `tier` is repurposed as a free-form audit field:\nplain tier names for subscriptions, `addon:<code>` for top-ups,\n`refund:<original>` for refunds.","operationId":"admin_transactions_api_admin_transactions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Transactions Api Admin Transactions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/stats":{"get":{"tags":["admin"],"summary":"Admin Stats","description":"High-level operational summary surfaced at the top of /admin.","operationId":"admin_stats_api_admin_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Admin Stats Api Admin Stats Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/admin/overview":{"get":{"tags":["admin"],"summary":"Admin Overview","description":"Comprehensive overview powering the dashboard hero. Combines:\n- top-line counts and revenue\n- trend (vs last week) for the deltas Stripe/Linear show\n- MRR estimate from last 30 days of non-refund revenue\n- render + cost totals","operationId":"admin_overview_api_admin_overview_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Admin Overview Api Admin Overview Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/admin/timeseries/renders":{"get":{"tags":["admin"],"summary":"Admin Timeseries Renders","description":"Daily render counts + Vertex cost for the last N days. Used by\nthe dashboard's inline line chart.","operationId":"admin_timeseries_renders_api_admin_timeseries_renders_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Days"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Timeseries Renders Api Admin Timeseries Renders Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/timeseries/revenue":{"get":{"tags":["admin"],"summary":"Admin Timeseries Revenue","description":"Daily gross revenue, refunds, and net for the last N days.","operationId":"admin_timeseries_revenue_api_admin_timeseries_revenue_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Days"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Timeseries Revenue Api Admin Timeseries Revenue Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/users/{user_id}":{"get":{"tags":["admin"],"summary":"Admin User Drill","description":"Full per-user view: profile, current state, transactions, recent\nrenders, channels, token balance, audit history.","operationId":"admin_user_drill_api_admin_users__user_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin User Drill Api Admin Users  User Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/users/{user_id}/set-plan":{"post":{"tags":["admin"],"summary":"Admin Set Plan","description":"Flip a user's plan. Logged to admin_audit.","operationId":"admin_set_plan_api_admin_users__user_id__set_plan_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_SetPlanBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Set Plan Api Admin Users  User Id  Set Plan Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/users/{user_id}/grant-tokens":{"post":{"tags":["admin"],"summary":"Admin Grant Tokens","description":"Grant N add-on tokens to a user (never-expiring, source=admin_grant).\nLogged to admin_audit.","operationId":"admin_grant_tokens_api_admin_users__user_id__grant_tokens_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"integer","title":"User Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_GrantTokensBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Grant Tokens Api Admin Users  User Id  Grant Tokens Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/admin/audit":{"get":{"tags":["admin"],"summary":"Admin Audit","description":"Audit log of admin actions (set_plan, grant_tokens, etc.).","operationId":"admin_audit_api_admin_audit_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Admin Audit Api Admin Audit Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/status":{"get":{"tags":["status"],"summary":"Get Status","operationId":"get_status_api_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Status Api Status Get"}}}}}}},"/api/billing/checkout":{"post":{"tags":["billing"],"summary":"Create Checkout","operationId":"create_checkout_api_billing_checkout_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckoutBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Create Checkout Api Billing Checkout Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/billing/checkout-url":{"get":{"tags":["billing"],"summary":"Billing Checkout Url","description":"JSON sibling of /billing/upgrade. The SPA hits this FIRST so any\nfailure (bad tier, provider misconfig, etc.) renders as a polished\nin-app message instead of a raw JSON error inside the PayPal popup.\n\nOn success the SPA navigates the already-opened popup window to\nthe returned URL. On failure it closes the popup and mutates its\nin-app overlay into an error card.","operationId":"billing_checkout_url_api_billing_checkout_url_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tier","in":"query","required":true,"schema":{"type":"string","title":"Tier"}},{"name":"period","in":"query","required":false,"schema":{"type":"string","default":"monthly","title":"Period"}},{"name":"promo","in":"query","required":false,"schema":{"type":"string","default":"","title":"Promo"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Billing Checkout Url Api Billing Checkout Url Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/billing/upgrade":{"get":{"tags":["billing"],"summary":"Billing Upgrade","description":"One-stop upgrade entrypoint. Builds the active provider's\ncheckout URL for (tier, period) and redirects there in a single\n302. Pricing-page CTAs and in-app upgrade prompts point here.\n\nKept as a same-tab fallback for browsers that block the popup.\nThe SPA primary path is GET /api/billing/checkout-url (JSON).","operationId":"billing_upgrade_billing_upgrade_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tier","in":"query","required":true,"schema":{"type":"string","title":"Tier"}},{"name":"period","in":"query","required":false,"schema":{"type":"string","default":"monthly","title":"Period"}},{"name":"promo","in":"query","required":false,"schema":{"type":"string","default":"","title":"Promo"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/billing/paypal/ipn":{"post":{"tags":["billing"],"summary":"Paypal Ipn","description":"PayPal IPN webhook — auto-upgrades the user on completed payment.\n\nPayPal POSTs the full transaction record here whenever a payment\ncompletes (or pending/refunded/etc.). We:\n  1. Echo the body back to PayPal with cmd=_notify-validate prepended\n  2. PayPal replies VERIFIED or INVALID\n  3. On VERIFIED + Completed + receiver/amount match → flip user plan\n  4. Idempotent on txn_id (PayPal can retry up to 4x)\n\nAlways returns 200 — PayPal retries on any non-2xx, which would\ncreate a thundering herd if we error out on bad payloads.","operationId":"paypal_ipn_api_billing_paypal_ipn_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Paypal Ipn Api Billing Paypal Ipn Post"}}}}}}},"/billing/paypal/return":{"get":{"tags":["billing"],"summary":"Paypal Return","description":"Post-payment landing page. We use the same URL for GET (rm=0)\nand POST (rm=2) returns from PayPal. The page polls /api/account/me\nevery 2s until the plan flips, then shows a polished welcome card.","operationId":"paypal_return_billing_paypal_return_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["billing"],"summary":"Paypal Return","description":"Post-payment landing page. We use the same URL for GET (rm=0)\nand POST (rm=2) returns from PayPal. The page polls /api/account/me\nevery 2s until the plan flips, then shows a polished welcome card.","operationId":"paypal_return_billing_paypal_return_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/billing/credit-pack":{"post":{"tags":["billing"],"summary":"Create Credit Pack","operationId":"create_credit_pack_api_billing_credit_pack_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddonBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Create Credit Pack Api Billing Credit Pack Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/billing/portal":{"get":{"tags":["billing"],"summary":"Customer Portal","operationId":"customer_portal_api_billing_portal_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Customer Portal Api Billing Portal Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/webhooks/stripe":{"post":{"tags":["billing"],"summary":"Stripe Webhook","description":"Receive subscription / checkout events from Stripe.\n\nStripe retries 4xx/5xx for up to 3 days; we return 200 on a handled\nevent AND on every internal handler exception so a transient bug\ndoesn't cause a 3-day retry storm. The exception is surfaced in the\nresponse body for debugging via the Stripe dashboard's webhook log.","operationId":"stripe_webhook_api_webhooks_stripe_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Stripe Webhook Api Webhooks Stripe Post"}}}}}}},"/api/webhooks/paddle":{"post":{"tags":["billing"],"summary":"Paddle Webhook","operationId":"paddle_webhook_api_webhooks_paddle_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Paddle Webhook Api Webhooks Paddle Post"}}}}}}},"/api/auth/signup":{"post":{"tags":["auth"],"summary":"Signup","description":"Create a new user account. On success, sets the session cookie\nand returns the user object.\n\nThree abuse defenses run BEFORE any DB write:\n\n  1. Per-IP rate limit (DB-backed, survives restarts). 5/hour, 20/day\n     per /24 (IPv4) or /64 (IPv6) prefix.\n  2. Disposable-email blocklist + Gmail+dot normalisation. A\n     disposable address (10minutemail, mailinator, etc.) is refused;\n     `mehdi+1@gmail.com` is collapsed to `mehdi@gmail.com` so an\n     attacker can't farm 100 free tokens from one inbox.\n  3. Cloudflare Turnstile CAPTCHA. The widget hands a token to the\n     frontend; we verify it server-side. Auto-bypassed when\n     TURNSTILE_SECRET_KEY is unset (local dev).\n\nEvery attempt — accepted or rejected — gets a row in `signup_attempts`\nfor auditing. The rate-limit counter reads from that table.\n\nMaster-account override: if the signup email matches FOUNDER_EMAIL,\nwe refuse the signup. The founder can only be reached via /login.","operationId":"signup_api_auth_signup_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_SignupBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Signup Api Auth Signup Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/verify":{"get":{"tags":["auth"],"summary":"Verify Email","description":"Click-target of the verification link. Validates the token,\nflips email_verified=1, sets a session cookie, and redirects to\nthe success landing page.\n\nThe user reaches this URL from their email client — they expect\na real page, not a JSON blob.","operationId":"verify_email_api_auth_verify_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/resend-verification":{"post":{"tags":["auth"],"summary":"Resend Verification","description":"User didn't get the email? Re-send. Same rate-limit guard as\nsignup so this can't be used to flood inboxes.","operationId":"resend_verification_api_auth_resend_verification_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_ResendBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Resend Verification Api Auth Resend Verification Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/login":{"post":{"tags":["auth"],"summary":"Login","description":"Verify credentials, set the session cookie, return the user.\n\nMaster-account shortcut: when the email matches FOUNDER_EMAIL and\nthe founder row HAS NO password_hash yet, we accept any password\nand set it on first login. Subsequent logins require the password.\nThis lets the founder log in to their own machine without first\nrunning a signup flow.","operationId":"login_api_auth_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_LoginBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Login Api Auth Login Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/logout":{"post":{"tags":["auth"],"summary":"Logout","operationId":"logout_api_auth_logout_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Logout Api Auth Logout Post"}}}}}}},"/api/auth/turnstile-config":{"get":{"tags":["auth"],"summary":"Turnstile Config","description":"Public endpoint — returns the Turnstile site key (if configured)\nso the signup page can render the widget. The SECRET key is never\nexposed; only the SITE key is safe to ship to the client.","operationId":"turnstile_config_api_auth_turnstile_config_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Turnstile Config Api Auth Turnstile Config Get"}}}}}}},"/api/auth/session":{"get":{"tags":["auth"],"summary":"Session Status","description":"Return whether the current cookie is valid + which user it maps to.","operationId":"session_status_api_auth_session_get","parameters":[{"name":"ct_session","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ct Session"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Session Status Api Auth Session Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/production-jobs/interrupted":{"get":{"summary":"List Interrupted Jobs","description":"Return jobs the last crash left mid-flight. UI shows a Resume prompt.","operationId":"list_interrupted_jobs_api_production_jobs_interrupted_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/":{"get":{"summary":"Landing","operationId":"landing__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/pricing":{"get":{"summary":"Pricing Page","operationId":"pricing_page_pricing_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/signup":{"get":{"summary":"Signup Page","operationId":"signup_page_signup_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/login":{"get":{"summary":"Login Page","operationId":"login_page_login_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/forgot-password":{"get":{"summary":"Forgot Page","operationId":"forgot_page_forgot_password_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/admin":{"get":{"summary":"Admin Page","description":"Founder-only operator dashboard. The HTML is public-readable (no\nsecrets are baked in), but every API call it makes is gated on the\nserver by Depends(_require_founder) — so a non-founder loading the\npage sees an empty 'Founder access only' card.","operationId":"admin_page_admin_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/verify-email-success":{"get":{"summary":"Verify Email Success Page","description":"Landing page after a successful click on the verification link.","operationId":"verify_email_success_page_verify_email_success_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/verify-email-failed":{"get":{"summary":"Verify Email Failed Page","description":"Friendly page when the verification link is invalid / expired —\nhas a 'resend verification' form that POSTs to /api/auth/resend-verification.","operationId":"verify_email_failed_page_verify_email_failed_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/auth/callback":{"get":{"summary":"Auth Callback","description":"Supabase OAuth redirect target.\n\nSupabase appends the access_token + refresh_token to the URL fragment\n(#access_token=...). The browser SDK persists them to localStorage\nunder the key set in storageKey (copythumb.auth.session), then we\nredirect into the studio.","operationId":"auth_callback_auth_callback_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/terms":{"get":{"summary":"Terms Page","operationId":"terms_page_terms_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/privacy":{"get":{"summary":"Privacy Page","operationId":"privacy_page_privacy_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/refund":{"get":{"summary":"Refund Page","description":"Refund Policy. Required by Paddle's seller-onboarding review.","operationId":"refund_page_refund_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/demo":{"get":{"summary":"Demo Page","operationId":"demo_page_demo_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/api/newsletter/subscribe":{"post":{"summary":"Newsletter Subscribe","description":"Record an email to a local jsonl log. Real ESP (Resend / ConvertKit /\nButtondown) wires up in Step 9; until then every subscribe is appended\nto data/newsletter_subscribers.jsonl so no email is ever lost.","operationId":"newsletter_subscribe_api_newsletter_subscribe_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_NewsletterBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Newsletter Subscribe Api Newsletter Subscribe Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/app/{path}":{"get":{"summary":"Studio Shell","description":"Studio SPA shell. In live (Supabase) mode this requires a valid\nsession cookie; unauthenticated visits redirect to /login.\n\nLocal-dev mode (no SUPABASE_JWT_SECRET): if there's no session\ncookie we silently mint one for the master account so the founder\nnever has to log in on their own machine. New users still go\nthrough /signup explicitly to get their own user_id.","operationId":"studio_shell_app__path__get","parameters":[{"name":"path","in":"path","required":true,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/app/":{"get":{"summary":"Studio Shell","description":"Studio SPA shell. In live (Supabase) mode this requires a valid\nsession cookie; unauthenticated visits redirect to /login.\n\nLocal-dev mode (no SUPABASE_JWT_SECRET): if there's no session\ncookie we silently mint one for the master account so the founder\nnever has to log in on their own machine. New users still go\nthrough /signup explicitly to get their own user_id.","operationId":"studio_shell_app__get","parameters":[{"name":"path","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/app":{"get":{"summary":"Studio Shell","description":"Studio SPA shell. In live (Supabase) mode this requires a valid\nsession cookie; unauthenticated visits redirect to /login.\n\nLocal-dev mode (no SUPABASE_JWT_SECRET): if there's no session\ncookie we silently mint one for the master account so the founder\nnever has to log in on their own machine. New users still go\nthrough /signup explicitly to get their own user_id.","operationId":"studio_shell_app_get","parameters":[{"name":"path","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/billing/plans":{"get":{"summary":"List Plans","description":"Return the public pricing-page view + the token top-up packs.","operationId":"list_plans_api_billing_plans_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response List Plans Api Billing Plans Get"}}}}}}},"/api/auth/local-signin":{"post":{"summary":"Local Signin","operationId":"local_signin_api_auth_local_signin_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/_LocalSignInBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Local Signin Api Auth Local Signin Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/avatar":{"get":{"summary":"Avatar Proxy","description":"Serve a locally-cached YouTube channel avatar.","operationId":"avatar_proxy_api_avatar_get","parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","title":"Url"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/health":{"get":{"summary":"Health","operationId":"health_api_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Health Api Health Get"}}}}}}},"/api/auth/me":{"get":{"summary":"Auth Me","description":"Return the resolved CurrentUser. Frontend hits this on boot to\ndecide whether to render the authenticated shell or the landing site.\n\nIn Mode A (no Supabase secret) this always returns the founder so\nthe local dev experience is identical to the old single-user studio.\nIn Mode B this returns 401 if no valid JWT is presented.","operationId":"auth_me_api_auth_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Auth Me Api Auth Me Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/channels":{"get":{"summary":"Channels","operationId":"channels_api_channels_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Channels Api Channels Get"}}}}}}},"/api/niches":{"get":{"summary":"Niches","operationId":"niches_api_niches_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Niches Api Niches Get"}}}}}}},"/api/hook":{"get":{"summary":"Hook","description":"Preview the hook that will be rendered on the thumbnail.\n\nIf `channel` is a channel ID we already have a cached text DNA for,\nreturns the smart channel-native hook. Otherwise falls back to the\nregex-based keyword extraction. Never triggers a channel scan — this\nendpoint must stay fast for live typing.","operationId":"hook_api_hook_get","parameters":[{"name":"title","in":"query","required":true,"schema":{"type":"string","title":"Title"}},{"name":"channel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Hook Api Hook Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"AddonBody":{"properties":{"code":{"type":"string","title":"Code"}},"type":"object","required":["code"],"title":"AddonBody"},"ApiKeyCreate":{"properties":{"label":{"type":"string","title":"Label","default":"default"}},"type":"object","title":"ApiKeyCreate"},"BatchCharacterAssignmentRequest":{"properties":{"assignments":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Assignments","default":[]}},"type":"object","title":"BatchCharacterAssignmentRequest"},"Body_api_generate_api_generate_post":{"properties":{"title":{"type":"string","title":"Title"},"channel":{"type":"string","title":"Channel","default":"default"},"script":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Script"},"no_text":{"type":"boolean","title":"No Text","default":false},"variants":{"type":"integer","title":"Variants","default":1},"creative":{"type":"string","title":"Creative","default":"off"},"auto_character":{"type":"boolean","title":"Auto Character","default":true},"style_channel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Style Channel Id"},"sketch":{"anyOf":[{"type":"string","contentMediaType":"application/octet-stream"},{"type":"null"}],"title":"Sketch"},"sketch_help":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sketch Help"},"reference":{"anyOf":[{"type":"string","contentMediaType":"application/octet-stream"},{"type":"null"}],"title":"Reference"},"references":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"References","default":[]}},"type":"object","required":["title"],"title":"Body_api_generate_api_generate_post"},"Body_api_generate_clone_api_generate_clone_post":{"properties":{"title":{"type":"string","title":"Title"},"variants":{"type":"integer","title":"Variants","default":1},"no_text":{"type":"boolean","title":"No Text","default":false},"auto_character":{"type":"boolean","title":"Auto Character","default":true},"clone_image":{"type":"string","contentMediaType":"application/octet-stream","title":"Clone Image"},"sketch":{"anyOf":[{"type":"string","contentMediaType":"application/octet-stream"},{"type":"null"}],"title":"Sketch"},"sketch_help":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sketch Help"},"references":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"References","default":[]}},"type":"object","required":["title","clone_image"],"title":"Body_api_generate_clone_api_generate_clone_post"},"Body_api_refine_api_refine_post":{"properties":{"image_url":{"type":"string","title":"Image Url"},"instruction":{"type":"string","title":"Instruction"},"reference":{"anyOf":[{"type":"string","contentMediaType":"application/octet-stream"},{"type":"null"}],"title":"Reference"},"pinpoint":{"anyOf":[{"type":"string","contentMediaType":"application/octet-stream"},{"type":"null"}],"title":"Pinpoint"}},"type":"object","required":["image_url","instruction"],"title":"Body_api_refine_api_refine_post"},"Body_api_restyle_api_restyle_post":{"properties":{"image_url":{"type":"string","title":"Image Url"},"new_channel_id":{"type":"string","title":"New Channel Id"},"title":{"type":"string","title":"Title"}},"type":"object","required":["image_url","new_channel_id","title"],"title":"Body_api_restyle_api_restyle_post"},"Body_create_custom_style_api_styles_post":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description","default":""},"images":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Images"}},"type":"object","required":["name","images"],"title":"Body_create_custom_style_api_styles_post"},"ChannelCreate":{"properties":{"name":{"type":"string","title":"Name"},"niche":{"type":"string","title":"Niche"},"reference_channel_id":{"type":"string","title":"Reference Channel Id","default":""},"reference_channel_name":{"type":"string","title":"Reference Channel Name","default":""},"reference_yt_url":{"type":"string","title":"Reference Yt Url","default":""},"avatar_color":{"type":"string","title":"Avatar Color","default":""},"target_audience":{"type":"string","title":"Target Audience","default":""},"tone":{"type":"string","title":"Tone","default":""},"voice_id":{"type":"string","title":"Voice Id","default":""},"default_duration":{"type":"string","title":"Default Duration","default":"10min"}},"type":"object","required":["name","niche"],"title":"ChannelCreate"},"ChannelUpdate":{"properties":{"niche":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Niche"},"reference_channel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Channel Id"},"reference_yt_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Yt Url"},"reference_channel_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Channel Name"},"target_audience":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Audience"},"tone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tone"},"voice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Voice Id"},"default_duration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Duration"},"default_style_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Style Id"},"default_template_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Template Id"}},"type":"object","title":"ChannelUpdate"},"CharacterCreate":{"properties":{"name":{"type":"string","title":"Name"},"style_id":{"type":"string","title":"Style Id","default":""},"visual_description":{"type":"string","title":"Visual Description","default":""},"signature_outfit":{"type":"string","title":"Signature Outfit","default":""},"personality":{"type":"string","title":"Personality","default":""}},"type":"object","required":["name"],"title":"CharacterCreate"},"CharacterSceneAssignment":{"properties":{"character_id":{"type":"string","title":"Character Id"},"scene_appearances":{"items":{"type":"integer"},"type":"array","title":"Scene Appearances","default":[]}},"type":"object","required":["character_id"],"title":"CharacterSceneAssignment"},"CharacterUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"style_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Style Id"},"visual_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visual Description"},"signature_outfit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signature Outfit"},"personality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Personality"}},"type":"object","title":"CharacterUpdate"},"CheckoutBody":{"properties":{"tier":{"type":"string","title":"Tier"},"billing_period":{"type":"string","title":"Billing Period","default":"monthly"}},"type":"object","required":["tier"],"title":"CheckoutBody"},"ContactBody":{"properties":{"subject":{"type":"string","maxLength":140,"minLength":2,"title":"Subject"},"message":{"type":"string","maxLength":4000,"minLength":10,"title":"Message"}},"type":"object","required":["subject","message"],"title":"ContactBody"},"DuplicateConfirmRequest":{"properties":{"selected_name":{"type":"string","title":"Selected Name"},"niche":{"type":"string","title":"Niche"},"tagline":{"type":"string","title":"Tagline"},"bio":{"type":"string","title":"Bio"},"target_audience":{"type":"string","title":"Target Audience"},"tone":{"type":"string","title":"Tone"},"reference_channel_id":{"type":"string","title":"Reference Channel Id"},"reference_channel_name":{"type":"string","title":"Reference Channel Name"},"reference_yt_url":{"type":"string","title":"Reference Yt Url"},"logo_prompt":{"type":"string","title":"Logo Prompt"},"logo_color_palette":{"items":{"type":"string"},"type":"array","title":"Logo Color Palette","default":[]},"picked_logo_path":{"type":"string","title":"Picked Logo Path","default":""},"ideas_selected":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Ideas Selected"}},"type":"object","required":["selected_name","niche","tagline","bio","target_audience","tone","reference_channel_id","reference_channel_name","reference_yt_url","logo_prompt","ideas_selected"],"title":"DuplicateConfirmRequest"},"DuplicateGenerateRequest":{"properties":{"tracked_channel_id":{"type":"string","title":"Tracked Channel Id"},"divergence":{"type":"string","title":"Divergence"}},"type":"object","required":["tracked_channel_id","divergence"],"title":"DuplicateGenerateRequest"},"GeneratePromptRequest":{"properties":{"topic":{"type":"string","title":"Topic"}},"type":"object","required":["topic"],"title":"GeneratePromptRequest"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"LogoVariantsRequest":{"properties":{"job_id":{"type":"string","title":"Job Id"},"channel_name":{"type":"string","title":"Channel Name"},"concept_indices":{"items":{"type":"integer"},"type":"array","title":"Concept Indices","default":[]}},"type":"object","required":["job_id","channel_name"],"title":"LogoVariantsRequest"},"NicheDiscoverRequest":{"properties":{"reference_channel_id":{"type":"string","title":"Reference Channel Id","default":""},"channel_name":{"type":"string","title":"Channel Name","default":""},"count":{"type":"integer","title":"Count","default":12}},"type":"object","title":"NicheDiscoverRequest"},"PasswordChange":{"properties":{"current_password":{"type":"string","title":"Current Password"},"new_password":{"type":"string","title":"New Password"}},"type":"object","required":["current_password","new_password"],"title":"PasswordChange"},"ProduceRequest":{"properties":{"resolution":{"type":"string","title":"Resolution","default":"4K"},"duration_hint":{"type":"string","title":"Duration Hint","default":"10min"},"voice_id":{"type":"string","title":"Voice Id","default":""}},"type":"object","title":"ProduceRequest"},"ProfileUpdate":{"properties":{"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"youtube_channel_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Youtube Channel Url"},"youtube_channel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Youtube Channel Id"}},"type":"object","title":"ProfileUpdate"},"ScriptRequest":{"properties":{"duration_hint":{"type":"string","title":"Duration Hint","default":"10min"}},"type":"object","title":"ScriptRequest"},"ScriptSave":{"properties":{"script_json":{"type":"string","title":"Script Json"}},"type":"object","required":["script_json"],"title":"ScriptSave"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"VideoCreate":{"properties":{"topic":{"type":"string","title":"Topic"},"brief":{"type":"string","title":"Brief","default":""},"duration_hint":{"type":"string","title":"Duration Hint","default":"10min"},"resolution":{"type":"string","title":"Resolution","default":"4K"},"status":{"type":"string","title":"Status","default":"titled"}},"type":"object","required":["topic"],"title":"VideoCreate"},"VideoUpdate":{"properties":{"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"brief":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brief"},"thumbnail_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnail Path"},"script_json":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Script Json"},"script_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Script Status"},"blueprint_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blueprint Path"},"production_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Production Name"},"final_mp4_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final Mp4 Path"}},"type":"object","title":"VideoUpdate"},"_BudgetRequest":{"properties":{"budget_usd":{"type":"number","title":"Budget Usd"}},"type":"object","required":["budget_usd"],"title":"_BudgetRequest"},"_GrantTokensBody":{"properties":{"tokens":{"type":"integer","title":"Tokens"},"note":{"type":"string","title":"Note","default":""}},"type":"object","required":["tokens"],"title":"_GrantTokensBody"},"_LocalSignInBody":{"properties":{"email":{"type":"string","title":"Email","default":""}},"type":"object","title":"_LocalSignInBody"},"_LoginBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"_LoginBody"},"_NewsletterBody":{"properties":{"email":{"type":"string","title":"Email","default":""}},"type":"object","title":"_NewsletterBody"},"_ResendBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"}},"type":"object","required":["email"],"title":"_ResendBody"},"_SetPlanBody":{"properties":{"plan":{"type":"string","title":"Plan"},"note":{"type":"string","title":"Note","default":""}},"type":"object","required":["plan"],"title":"_SetPlanBody"},"_SignupBody":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"turnstile_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Turnstile Token"},"referrer_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referrer Code"}},"type":"object","required":["email","password"],"title":"_SignupBody"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}