{"openapi":"3.1.0","info":{"title":"Lead Hunter Auth Service","version":"1.0.0"},"paths":{"/health":{"get":{"summary":"Health","operationId":"health_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/panel/":{"get":{"summary":"Serve Panel Root","description":"Serve index.html for panel root","operationId":"serve_panel_root_panel__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"head":{"summary":"Serve Panel Root","description":"Serve index.html for panel root","operationId":"serve_panel_root_panel__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/panel":{"get":{"summary":"Serve Panel Root","description":"Serve index.html for panel root","operationId":"serve_panel_root_panel_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"head":{"summary":"Serve Panel Root","description":"Serve index.html for panel root","operationId":"serve_panel_root_panel_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/panel/{file_path}":{"get":{"summary":"Serve Static File","description":"Serve static files from panel directory.\nبرای admin.html نیز بدون احراز هویت سرو می‌شود.","operationId":"serve_static_file_panel__file_path__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"file_path","in":"path","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"head":{"summary":"Serve Static File","description":"Serve static files from panel directory.\nبرای admin.html نیز بدون احراز هویت سرو می‌شود.","operationId":"serve_static_file_panel__file_path__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"file_path","in":"path","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin":{"get":{"summary":"Serve Admin Root","operationId":"serve_admin_root_admin_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/leadhunter/admin.html":{"get":{"summary":"Serve Admin Prefixed","operationId":"serve_admin_prefixed_leadhunter_admin_html_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/leadhunter/admin":{"get":{"summary":"Serve Admin Prefixed Root","operationId":"serve_admin_prefixed_root_leadhunter_admin_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/leadhunter/admin/{file_path}":{"get":{"summary":"Serve Admin Prefixed Files","operationId":"serve_admin_prefixed_files_leadhunter_admin__file_path__get","parameters":[{"name":"file_path","in":"path","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/register":{"post":{"summary":"Register","operationId":"register_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserRegister"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Token"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/otp/request":{"post":{"summary":"Request Otp","operationId":"request_otp_otp_request_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OTPRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/otp/verify":{"post":{"summary":"Verify Otp","operationId":"verify_otp_otp_verify_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OTPVerify"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/leads/ingest":{"post":{"summary":"Ingest Leads","description":"افزایش شمارنده لید و ثبت رویداد ساده.","operationId":"ingest_leads_leads_ingest_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadIngest"}}},"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":[]}]}},"/leads/import/file":{"post":{"summary":"Leads Import File","operationId":"leads_import_file_leads_import_file_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"source","in":"query","required":false,"schema":{"type":"string","default":"upload","title":"Source"}},{"name":"dry_run","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Dry Run"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":2000,"title":"Limit"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_leads_import_file_leads_import_file_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/leads/import/preview":{"post":{"summary":"Leads Import Preview","description":"Preview نرمالسازی بدون ذخیره در دیتابیس\nکاربر می‌تواند مطمئن شود که دیتا درست استخراج شده است","operationId":"leads_import_preview_leads_import_preview_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"source","in":"query","required":false,"schema":{"type":"string","default":"upload","title":"Source"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":2000,"title":"Limit"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_leads_import_preview_leads_import_preview_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/leads/import/google-sheet":{"post":{"summary":"Leads Import Google Sheet","operationId":"leads_import_google_sheet_leads_import_google_sheet_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadImportGoogleSheetRequest"}}},"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":[]}]}},"/leads":{"get":{"summary":"List Leads","description":"لیست تمام لیدهای کاربر (imported + discovered)","operationId":"list_leads_leads_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/discovery-leads":{"get":{"summary":"List Discovery Leads","description":"لیست تمام لیدهای دریافت شده (discovery)","operationId":"list_discovery_leads_discovery_leads_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/enriched-leads":{"get":{"summary":"List Enriched Leads","description":"لیست لیدهای enriched شده برای استفاده در کمپین","operationId":"list_enriched_leads_enriched_leads_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/discovery/search":{"post":{"summary":"Discovery Search","description":"کشف لید با Searxng و Bing Agent (جایگزین وبهوک n8n)","operationId":"discovery_search_discovery_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoveryRequest"}}},"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":[]}]}},"/discovery/aggregate":{"post":{"summary":"Discovery Aggregate","description":"برگرداندن خروجی تفکیک‌شده برای موتورهای مختلف (searxng, bing, linkedin, maps).","operationId":"discovery_aggregate_discovery_aggregate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoveryAggregateRequest"}}},"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":[]}]}},"/discovery/aggregate/web":{"post":{"summary":"Discovery Aggregate Web","operationId":"discovery_aggregate_web_discovery_aggregate_web_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoveryAggregateRequest"}}},"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":[]}]}},"/discovery/aggregate/apify":{"post":{"summary":"Discovery Aggregate Apify","operationId":"discovery_aggregate_apify_discovery_aggregate_apify_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoveryAggregateRequest"}}},"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":[]}]}},"/discovery/quick":{"post":{"summary":"Discovery Quick","description":"مسیر سریع: چند لید پیشنهادی فوری بر اساس پروفایل و بدون اسکرپ عمیق.","operationId":"discovery_quick_discovery_quick_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuickLeadRequest"}}},"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":[]}]}},"/debug/quick-lead-status":{"get":{"summary":"Debug Quick Lead Status","description":"Debug endpoint to check admin status for quick lead","operationId":"debug_quick_lead_status_debug_quick_lead_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/debug/seed-stats":{"post":{"summary":"Seed Stats","description":"دمو: چند لید و رویداد برای کاربر فعلی اضافه می‌کند.","operationId":"seed_stats_debug_seed_stats_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/profile":{"get":{"summary":"Get Profile","operationId":"get_profile_profile_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"put":{"summary":"Upsert Profile","operationId":"upsert_profile_profile_put","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserProfile"}}},"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":[]}]}},"/login":{"post":{"summary":"Login","operationId":"login_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserLogin"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Token"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/me":{"get":{"summary":"Get Me","operationId":"get_me_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/reset-quota":{"post":{"summary":"Reset Quota","description":"Admin-only: reset leads_used for a target user.","operationId":"reset_quota_reset_quota_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminResetQuotaPayload"}}},"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":[]}]}},"/stats/summary":{"get":{"summary":"Stats Summary","description":"خلاصه متریک‌های داشبورد برای نمایش در فرانت.","operationId":"stats_summary_stats_summary_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api-keys":{"get":{"summary":"Get Api Keys","operationId":"get_api_keys_api_keys_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"put":{"summary":"Update Api Keys","operationId":"update_api_keys_api_keys_put","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeysUpdate"}}},"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":[]}]}},"/admin/api-keys":{"get":{"summary":"Admin Get Api Keys","description":"مشاهده کلیدهای ادمین (نیاز به توکن ادمین).","operationId":"admin_get_api_keys_admin_api_keys_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"put":{"summary":"Admin Update Api Keys","description":"اضافه/ویرایش کلیدهای ادمین (نیاز به توکن ادمین).","operationId":"admin_update_api_keys_admin_api_keys_put","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeysUpdate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/prompts":{"get":{"summary":"Admin List Prompts","operationId":"admin_list_prompts_admin_prompts_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/admin/prompts/{name}":{"get":{"summary":"Admin Get Prompt","operationId":"admin_get_prompt_admin_prompts__name__get","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"}}}}}}},"/admin/prompts/test":{"post":{"summary":"Admin Test Prompt","operationId":"admin_test_prompt_admin_prompts_test_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTestRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/scrape/apify/maps":{"post":{"summary":"Apify Maps","operationId":"apify_maps_scrape_apify_maps_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApifyMapsRequest"}}},"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":[]}]}},"/scrape/apify/linkedin":{"post":{"summary":"Apify Linkedin","operationId":"apify_linkedin_scrape_apify_linkedin_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApifyLinkedInRequest"}}},"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":[]}]}},"/admin-api/v1/prompts":{"get":{"summary":"Admin List Prompts V1","operationId":"admin_list_prompts_v1_admin_api_v1_prompts_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"summary":"Admin Upsert Prompt V1","operationId":"admin_upsert_prompt_v1_admin_api_v1_prompts_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptUpsert"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin-api/v1/prompts/{name}":{"get":{"summary":"Admin Get Prompt V1","operationId":"admin_get_prompt_v1_admin_api_v1_prompts__name__get","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"}}}}}},"delete":{"summary":"Admin Delete Prompt V1","operationId":"admin_delete_prompt_v1_admin_api_v1_prompts__name__delete","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"}}}}}}},"/admin-api/v1/prompts/{name}/versions":{"get":{"summary":"Admin Get Prompt Versions V1","description":"Get all versions of a prompt.","operationId":"admin_get_prompt_versions_v1_admin_api_v1_prompts__name__versions_get","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"}}}}}}},"/admin-api/v1/prompts/{name}/versions/{version}":{"get":{"summary":"Admin Get Prompt Version V1","description":"Get a specific version of a prompt.","operationId":"admin_get_prompt_version_v1_admin_api_v1_prompts__name__versions__version__get","parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"version","in":"path","required":true,"schema":{"type":"string","title":"Version"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin-api/v1/prompts/{name}/rollback/{version}":{"post":{"summary":"Admin Rollback Prompt V1","description":"Rollback a prompt to a previous version.","operationId":"admin_rollback_prompt_v1_admin_api_v1_prompts__name__rollback__version__post","parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"version","in":"path","required":true,"schema":{"type":"string","title":"Version"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin-api/v1/prompts/test":{"post":{"summary":"Admin Test Prompt V1","operationId":"admin_test_prompt_v1_admin_api_v1_prompts_test_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptTestRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin-api/v1/prompt-aliases":{"get":{"summary":"Admin List Prompt Aliases","operationId":"admin_list_prompt_aliases_admin_api_v1_prompt_aliases_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"summary":"Admin Upsert Prompt Alias","operationId":"admin_upsert_prompt_alias_admin_api_v1_prompt_aliases_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptAliasUpsert"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/api-keys/health":{"get":{"summary":"Admin Api Keys Health","description":"استعلام سلامت همه کلیدهای ادمین (نیاز به توکن ادمین).","operationId":"admin_api_keys_health_admin_api_keys_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/notify/sendgrid/test":{"post":{"summary":"Notify Sendgrid","operationId":"notify_sendgrid_notify_sendgrid_test_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTest"}}},"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":[]}]}},"/notify/resend/test":{"post":{"summary":"Notify Resend","operationId":"notify_resend_notify_resend_test_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTest"}}},"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":[]}]}},"/email-validation/test":{"post":{"summary":"Email Validation Test","operationId":"email_validation_test_email_validation_test_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailValidationTest"}}},"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":[]}]}},"/email-validation/health":{"get":{"summary":"Email Validation Health","description":"وضعیت کلیدهای ولیدیشن ایمیل را برمی‌گرداند و ترتیب failover را نشان می‌دهد.","operationId":"email_validation_health_email_validation_health_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"email","in":"query","required":false,"schema":{"type":"string","default":"test@example.com","title":"Email"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/resend/health":{"get":{"summary":"Resend Health","description":"تست سلامت کلیدهای Resend (چندکلیدی) با یک درخواست ساده به /domains","operationId":"resend_health_resend_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/brevo/health":{"get":{"summary":"Brevo Health","description":"تست سلامت کلید Brevo با فراخوانی /v3/account","operationId":"brevo_health_brevo_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/twilio/health":{"get":{"summary":"Twilio Health","description":"تست سلامت Twilio با SID/TOKEN ذخیره‌شده","operationId":"twilio_health_twilio_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/campaigns/agent/evaluate":{"post":{"summary":"Campaign Agent Evaluate","description":"ایجنت دو مرحله‌ای کمپین (Stage1 پروفایل + Stage2 ارزیابی/آیس‌بریکر) برای یک لید.","operationId":"campaign_agent_evaluate_campaigns_agent_evaluate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignAgentRequest"}}},"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":[]}]}},"/campaigns/agent/evaluate-batch":{"post":{"summary":"Campaign Agent Evaluate Batch","description":"اجرای ایجنت برای چند لید به صورت پشت‌سرهم (حداکثر 20 لید در هر درخواست).","operationId":"campaign_agent_evaluate_batch_campaigns_agent_evaluate_batch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignAgentBatchRequest"}}},"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":[]}]}},"/campaigns/agent/enqueue":{"post":{"summary":"Campaign Agent Enqueue","description":"اجرای ایجنت دو مرحله‌ای و ایجاد صف کمپین (email)؛ با dry_run می‌توان فقط پیش‌نمایش گرفت.","operationId":"campaign_agent_enqueue_campaigns_agent_enqueue_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignAgentEnqueueRequest"}}},"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":[]}]}},"/sdr/enrich-batch":{"post":{"summary":"Sdr Enrich Batch","description":"Batch SDR enrichment: fetch site, extract links, run Stage1/2, update leads.\n- اگر enqueue_if_ideal=true باشد، لیدهای Ideal به صف کمپین ایمیل اضافه می‌شوند.\n- dry_run: فقط پیش‌نمایش، بدون نوشتن در DB.","operationId":"sdr_enrich_batch_sdr_enrich_batch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SDREnrichRequest"}}},"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":[]}]}},"/emails/verify-batch":{"post":{"summary":"Emails Verify Batch","description":"Batch email verification با استفاده از provider پیکربندی شده (reoon/mailboxlayer).\nlead_score طبق نتیجه آپدیت می‌شود.","operationId":"emails_verify_batch_emails_verify_batch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailVerifyBatchRequest"}}},"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":[]}]}},"/discovery/rerank":{"post":{"summary":"Discovery Rerank","description":"LLM rerank + summary روی نتایج سرچ (Gemini اولویت دارد).","operationId":"discovery_rerank_discovery_rerank_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoveryRerankRequest"}}},"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":[]}]}},"/discovery/snippet-summary":{"post":{"summary":"Discovery Snippet Summary","description":"خلاصه/کلیدواژه یک نتیجه سرچ یا صفحه.","operationId":"discovery_snippet_summary_discovery_snippet_summary_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoverySnippetSummaryRequest"}}},"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":[]}]}},"/emails/risk":{"post":{"summary":"Email Risk","description":"تخمین ریسک/اعتبار ایمیل پیش از verify (کاهش هزینه).","operationId":"email_risk_emails_risk_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailRiskRequest"}}},"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":[]}]}},"/enrich":{"post":{"summary":"Single Enrich","description":"Single email or domain enrichment using Clearbit, Hunter, etc.","operationId":"single_enrich_enrich_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnrichmentRequest"}}},"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":[]}]}},"/enrich/analyze":{"post":{"summary":"Analyze Leads For Enrichment","description":"Pre-flight analysis: بررسی لیدها برای تعیین وضعیت داده‌ها و ابزارهای مناسب enrichment","operationId":"analyze_leads_for_enrichment_enrich_analyze_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchEnrichmentRequest"}}},"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":[]}]}},"/enrich/batch":{"post":{"summary":"Batch Enrich","description":"Batch enrichment of multiple leads","operationId":"batch_enrich_enrich_batch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchEnrichmentRequest"}}},"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":[]}]}},"/verify-email":{"post":{"summary":"Verify Email Single","description":"Verify single email address","operationId":"verify_email_single_verify_email_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailVerifyRequest"}}},"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":[]}]}},"/dedupe":{"post":{"summary":"Dedupe Batch","description":"Batch deduplication of leads using Splink service","operationId":"dedupe_batch_dedupe_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DedupeRequest"}}},"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":[]}]}},"/campaigns/list":{"get":{"summary":"List Campaigns","description":"لیست کمپین‌ها با pagination ساده","operationId":"list_campaigns_campaigns_list_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","default":1,"title":"Page"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/campaigns/create":{"post":{"summary":"Create Campaign","operationId":"create_campaign_campaigns_create_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignCreate"}}},"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":[]}]}},"/campaigns/{campaign_id}":{"put":{"summary":"Update Campaign","description":"ویرایش کمپین (legacy یا چندمرحله‌ای)\n- کمپین متعلق به کاربر باید باشد\n- صف قبلی حذف و دوباره ساخته می‌شود (برای چندمرحله‌ای)\n- وضعیت به draft برگردانده می‌شود","operationId":"update_campaign_campaigns__campaign_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"summary":"Get Campaign","operationId":"get_campaign_campaigns__campaign_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"summary":"Delete Campaign","description":"حذف یک کمپین","operationId":"delete_campaign_campaigns__campaign_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/campaigns/templates":{"get":{"summary":"Get Campaign Templates","description":"دریافت لیست پکیج‌های پیشنهادی","operationId":"get_campaign_templates_campaigns_templates_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/campaigns/templates/{template_id}":{"get":{"summary":"Get Campaign Template","description":"دریافت جزئیات یک پکیج","operationId":"get_campaign_template_campaigns_templates__template_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","title":"Template Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/campaigns/execute-pending":{"post":{"summary":"Execute Pending Campaigns","description":"اجرای مراحل pending که زمان اجرای آن‌ها رسیده است (برای cron job یا background task)","operationId":"execute_pending_campaigns_campaigns_execute_pending_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/campaigns/{campaign_id}/details":{"get":{"summary":"Get Campaign Details","description":"دریافت جزئیات کامل کمپین شامل تمام ارسال‌ها و وضعیت آن‌ها","operationId":"get_campaign_details_campaigns__campaign_id__details_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/campaigns/{campaign_id}/queue":{"get":{"summary":"Get Campaign Queue","description":"دریافت صف ارسال کمپین (pending/sent/failed)","operationId":"get_campaign_queue_campaigns__campaign_id__queue_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/campaigns/{campaign_id}/send":{"post":{"summary":"Send Campaign","operationId":"send_campaign_campaigns__campaign_id__send_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignSend"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notify/mailchimp/test":{"post":{"summary":"Notify Mailchimp","operationId":"notify_mailchimp_notify_mailchimp_test_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTest"}}},"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":[]}]}},"/notify/telegram/test":{"post":{"summary":"Notify Telegram","operationId":"notify_telegram_notify_telegram_test_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TelegramTest"}}},"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":[]}]}},"/verify-token":{"post":{"summary":"Verify Token","operationId":"verify_token_verify_token_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/admin/debug-auth":{"get":{"summary":"Debug Admin Auth","description":"Endpoint برای دیباگ مشکل احراز هویت ادمین","operationId":"debug_admin_auth_admin_debug_auth_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/webhooks/resend":{"post":{"summary":"Resend Webhook","description":"Webhook endpoint برای دریافت events از Resend (open, click, bounce, etc.)","operationId":"resend_webhook_webhooks_resend_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/billing/balance":{"get":{"summary":"Billing Balance","operationId":"billing_balance_billing_balance_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/billing/transactions":{"get":{"summary":"Billing Transactions","operationId":"billing_transactions_billing_transactions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/billing/topup-request":{"post":{"summary":"Billing Topup Request","operationId":"billing_topup_request_billing_topup_request_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TopupRequestPayload"}}},"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":[]}]}},"/admin/users":{"get":{"summary":"Admin List Users","operationId":"admin_list_users_admin_users_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Q"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/credits/add":{"post":{"summary":"Admin Credits Add","operationId":"admin_credits_add_admin_credits_add_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreditAddPayload"}}},"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":[]}]}},"/admin/topup-requests":{"get":{"summary":"Admin Topup Requests","operationId":"admin_topup_requests_admin_topup_requests_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"pending","title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/credits/approve":{"post":{"summary":"Admin Credits Approve","operationId":"admin_credits_approve_admin_credits_approve_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreditActionPayload"}}},"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":[]}]}},"/admin/credits/reject":{"post":{"summary":"Admin Credits Reject","operationId":"admin_credits_reject_admin_credits_reject_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreditActionPayload"}}},"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":[]}]}},"/billing/nowpayments/webhook":{"post":{"summary":"Nowpayments Webhook","operationId":"nowpayments_webhook_billing_nowpayments_webhook_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/billing/zarinpal/callback":{"get":{"summary":"Zarinpal Callback","operationId":"zarinpal_callback_billing_zarinpal_callback_get","parameters":[{"name":"Status","in":"query","required":false,"schema":{"type":"string","default":"","title":"Status"}},{"name":"Authority","in":"query","required":false,"schema":{"type":"string","default":"","title":"Authority"}},{"name":"user_id","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"User Id"}},{"name":"amount","in":"query","required":false,"schema":{"type":"number","default":0.0,"title":"Amount"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/stats":{"get":{"summary":"Get User Stats","operationId":"get_user_stats_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/admin/notes":{"get":{"summary":"Get Admin Notes","operationId":"get_admin_notes_admin_notes_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"post":{"summary":"Save Admin Note","operationId":"save_admin_note_admin_notes_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminNote"}}},"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":[]}]}},"/auth/password/set":{"post":{"summary":"Set Password","operationId":"set_password_auth_password_set_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordSet"}}},"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":[]}]}},"/profile/status":{"get":{"tags":["studio","profile"],"summary":"Profile Status","operationId":"profile_status_profile_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/profile/query-seeds":{"get":{"tags":["studio","profile"],"summary":"Profile Query Seeds","operationId":"profile_query_seeds_profile_query_seeds_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":5,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/billing/plans":{"get":{"tags":["studio","billing"],"summary":"Billing Plans","operationId":"billing_plans_billing_plans_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/billing/plan-request":{"post":{"tags":["studio","billing"],"summary":"Billing Plan Request","operationId":"billing_plan_request_billing_plan_request_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlanUpgradeRequest"}}},"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":[]}]}},"/admin/modules":{"get":{"tags":["studio"],"summary":"Admin Modules","operationId":"admin_modules_admin_modules_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/admin/fleet-status":{"get":{"tags":["studio"],"summary":"Fleet Status","operationId":"fleet_status_admin_fleet_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/profile/enrich":{"post":{"tags":["studio","profile"],"summary":"Profile Enrich","operationId":"profile_enrich_profile_enrich_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileEnrichRequest"}}},"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":[]}]}},"/profile/apply-enrich":{"post":{"tags":["studio","profile"],"summary":"Profile Apply Enrich","operationId":"profile_apply_enrich_profile_apply_enrich_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplyEnrichRequest"}}},"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":[]}]}},"/profile/enrichment-history":{"get":{"tags":["studio"],"summary":"Profile Enrichment History","operationId":"profile_enrichment_history_profile_enrichment_history_get","security":[{"HTTPBearer":[]}],"parameters":[{"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"}}}}}}},"/discovery/benchmark":{"post":{"tags":["studio"],"summary":"Discovery Benchmark","operationId":"discovery_benchmark_discovery_benchmark_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoveryBenchmarkRequest"}}},"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":[]}]}},"/admin/discovery-runs":{"get":{"tags":["studio"],"summary":"Admin Discovery Runs","operationId":"admin_discovery_runs_admin_discovery_runs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/campaign-queue":{"get":{"tags":["studio"],"summary":"Admin Campaign Queue","operationId":"admin_campaign_queue_admin_campaign_queue_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/plans":{"get":{"tags":["studio"],"summary":"Admin Plans","operationId":"admin_plans_admin_plans_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/admin/plan-requests":{"get":{"tags":["studio"],"summary":"Admin Plan Requests","operationId":"admin_plan_requests_admin_plan_requests_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"pending","title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/plan-requests/approve":{"post":{"tags":["studio"],"summary":"Admin Approve Plan Request","operationId":"admin_approve_plan_request_admin_plan_requests_approve_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApprovePlanRequestPayload"}}},"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":[]}]}},"/admin/users/set-plan":{"post":{"tags":["studio"],"summary":"Admin Set User Plan","operationId":"admin_set_user_plan_admin_users_set_plan_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminSetPlanRequest"}}},"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":[]}]}},"/agent/run":{"post":{"tags":["studio"],"summary":"Agent Run","operationId":"agent_run_agent_run_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentRunRequest"}}},"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":[]}]}},"/mcp/tools":{"get":{"tags":["studio"],"summary":"Mcp Tools List","operationId":"mcp_tools_list_mcp_tools_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/mcp/invoke":{"post":{"tags":["studio"],"summary":"Mcp Invoke","description":"Internal MCP-style tool dispatcher (requires Bearer auth).","operationId":"mcp_invoke_mcp_invoke_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/McpInvokeRequest"}}},"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":[]}]}},"/mailerfind/health":{"get":{"tags":["mailerfind"],"summary":"Mailerfind Health","operationId":"mailerfind_health_mailerfind_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/mailerfind":{"get":{"tags":["mailerfind"],"summary":"Mailerfind Root","operationId":"mailerfind_root_mailerfind_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/mailerfind/":{"get":{"tags":["mailerfind"],"summary":"Mailerfind Root","operationId":"mailerfind_root_mailerfind__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/mailerfind/scrape":{"get":{"tags":["mailerfind"],"summary":"Mailerfind Scrape Help","operationId":"mailerfind_scrape_help_mailerfind_scrape_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["mailerfind"],"summary":"Mailerfind Scrape","operationId":"mailerfind_scrape_mailerfind_scrape_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailerfindScrapeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailerfindScrapeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/mailerfind/analyze-profile":{"post":{"tags":["mailerfind"],"summary":"Mailerfind Analyze Profile","operationId":"mailerfind_analyze_profile_mailerfind_analyze_profile_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailerfindAnalyzeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProfileAnalysis"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/mailerfind/scrape-and-ingest":{"post":{"tags":["mailerfind"],"summary":"Mailerfind Scrape And Ingest","operationId":"mailerfind_scrape_and_ingest_mailerfind_scrape_and_ingest_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailerfindScrapeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailerfindScrapeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/mailerfind/agent/identity":{"post":{"tags":["mailerfind-agent"],"summary":"Agent Create Identity","description":"Create disposable email+password via mail.tm for registration agents.","operationId":"agent_create_identity_mailerfind_agent_identity_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IdentityOnlyRequest"}}},"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":[]}]}},"/mailerfind/agent/register":{"post":{"tags":["mailerfind-agent"],"summary":"Agent Register","description":"Start Playwright registration job — poll /register/progress/{job_id} for live status.","operationId":"agent_register_mailerfind_agent_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterMailerfindRequest"}}},"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":[]}]}},"/mailerfind/agent/register/progress/{job_id}":{"get":{"tags":["mailerfind-agent"],"summary":"Agent Register Progress","operationId":"agent_register_progress_mailerfind_agent_register_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"}}}}}}},"/mailerfind/instagram/scrape":{"post":{"tags":["mailerfind-agent"],"summary":"Agent Instagram Scrape","description":"Direct Instagram extraction via browser — free, no Mailerfind/Cloudflare dependency.","operationId":"agent_instagram_scrape_mailerfind_instagram_scrape_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InstagramScrapeRequest"}}},"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":[]}]}},"/mailerfind/instagram/scrape/progress/{job_id}":{"get":{"tags":["mailerfind-agent"],"summary":"Agent Instagram Progress","operationId":"agent_instagram_progress_mailerfind_instagram_scrape_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"}}}}}}},"/mailerfind/agent/scrape-live":{"post":{"tags":["mailerfind-agent"],"summary":"Agent Scrape Live","operationId":"agent_scrape_live_mailerfind_agent_scrape_live_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScrapeLiveRequest"}}},"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":[]}]}},"/mailerfind/agent/scrape-live/progress/{job_id}":{"get":{"tags":["mailerfind-agent"],"summary":"Agent Scrape Live Progress","operationId":"agent_scrape_live_progress_mailerfind_agent_scrape_live_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"}}}}}}},"/onboarding/account-preflight":{"post":{"tags":["mailerfind-agent"],"summary":"Onboarding Account Preflight","description":"Fast private/public check (~1s) before starting a long scrape.","operationId":"onboarding_account_preflight_onboarding_account_preflight_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuickLeadsRequest"}}},"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":[]}]}},"/onboarding/quick-leads":{"post":{"tags":["mailerfind-agent"],"summary":"Onboarding Quick Leads","description":"Hybrid quick first-leads: fast instagram_direct, fall back to mailerfind_browser.\n\nReturns either an immediate result (fast path) or a job to poll (slow path) with an\neta_seconds so the onboarding UI can show a countdown.","operationId":"onboarding_quick_leads_onboarding_quick_leads_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuickLeadsRequest"}}},"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":[]}]}},"/mailerfind/agent/accounts":{"get":{"tags":["mailerfind-agent"],"summary":"Agent Accounts List","operationId":"agent_accounts_list_mailerfind_agent_accounts_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["mailerfind-agent"],"summary":"Agent Accounts Add","description":"Add a real Mailerfind account to the credit-rotation pool (admin only).","operationId":"agent_accounts_add_mailerfind_agent_accounts_post","requestBody":{"content":{"application/json":{"schema":{"type":"object","title":"Payload"}}},"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":[]}]}},"/mailerfind/agent/accounts/{email}":{"delete":{"tags":["mailerfind-agent"],"summary":"Agent Accounts Delete","operationId":"agent_accounts_delete_mailerfind_agent_accounts__email__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"email","in":"path","required":true,"schema":{"type":"string","title":"Email"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/mailerfind/agent/proxy-health":{"get":{"tags":["mailerfind-agent"],"summary":"Agent Proxy Health","operationId":"agent_proxy_health_mailerfind_agent_proxy_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/mailerfind/agent/status":{"get":{"tags":["mailerfind-agent"],"summary":"Agent Status","operationId":"agent_status_mailerfind_agent_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/mailerfind/agent/session/import":{"post":{"tags":["mailerfind-agent"],"summary":"Agent Import Session","description":"Import session after manual Mailerfind login in your browser (Cloudflare workaround).","operationId":"agent_import_session_mailerfind_agent_session_import_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportSessionRequest"}}},"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":[]}]}},"/admin/{file_path}":{"get":{"summary":"Serve Admin Static Files","operationId":"serve_admin_static_files_admin__file_path__get","parameters":[{"name":"file_path","in":"path","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"APIKeysUpdate":{"properties":{"openai_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Openai Key"},"clearbit_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Clearbit Key"},"hunter_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hunter Key"},"sendgrid_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sendgrid Key"},"brevo_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brevo Key"},"email_validation_api":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email Validation Api"},"email_validation_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email Validation Key"},"email_validation_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Email Validation Keys"},"resend_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Resend Keys"},"apify_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apify Key"},"apify_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Apify Keys"},"twilio_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Twilio Sid"},"twilio_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Twilio Token"},"mailchimp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mailchimp"},"resend":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resend"},"telegram_bot":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Telegram Bot"},"openrouter_key":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Openrouter Key"},"google_gemini_key":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Google Gemini Key"},"farazsms_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Farazsms Key"},"farazsms_sender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Farazsms Sender"}},"type":"object","title":"APIKeysUpdate"},"AdminCreditActionPayload":{"properties":{"transaction_id":{"type":"integer","title":"Transaction Id"},"credits":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Credits"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["transaction_id"],"title":"AdminCreditActionPayload"},"AdminCreditAddPayload":{"properties":{"user_id":{"type":"integer","title":"User Id"},"credits":{"type":"number","title":"Credits"},"money_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Money Amount"},"currency":{"type":"string","title":"Currency","default":"IRR"},"payment_method":{"type":"string","enum":["cash","online","bank_transfer","admin"],"title":"Payment Method","default":"admin"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["user_id","credits"],"title":"AdminCreditAddPayload"},"AdminNote":{"properties":{"phase_id":{"type":"integer","title":"Phase Id"},"content":{"type":"string","title":"Content"},"is_agent":{"type":"boolean","title":"Is Agent","default":false},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"}},"type":"object","required":["phase_id","content"],"title":"AdminNote"},"AdminResetQuotaPayload":{"properties":{"user_id":{"type":"integer","title":"User Id"}},"type":"object","required":["user_id"],"title":"AdminResetQuotaPayload"},"AdminSetPlanRequest":{"properties":{"user_id":{"type":"integer","title":"User Id"},"plan_id":{"type":"string","title":"Plan Id"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["user_id","plan_id"],"title":"AdminSetPlanRequest"},"AgentRunRequest":{"properties":{"steps":{"items":{"type":"string"},"type":"array","title":"Steps"},"search_query":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search Query"},"dry_run":{"type":"boolean","title":"Dry Run","default":true}},"type":"object","title":"AgentRunRequest"},"ApifyLinkedInRequest":{"properties":{"company_urls":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Company Urls"},"profile_urls":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Profile Urls"},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"},"limit":{"type":"integer","title":"Limit","default":5},"actor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Id","default":"apimaestro~linkedin-profile-detail"}},"type":"object","title":"ApifyLinkedInRequest","description":"Scrape LinkedIn companies via Apify actor."},"ApifyMapsRequest":{"properties":{"query":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query"},"place_urls":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Place Urls"},"limit":{"type":"integer","title":"Limit","default":10},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"actor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Id","default":"compass~crawler-google-places"},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language","default":"en"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region","default":"US"}},"type":"object","title":"ApifyMapsRequest","description":"Scrape Google Maps via Apify actor."},"ApplyEnrichRequest":{"properties":{"history_id":{"type":"integer","title":"History Id"},"overwrite":{"type":"boolean","title":"Overwrite","default":false}},"type":"object","required":["history_id"],"title":"ApplyEnrichRequest"},"ApprovePlanRequestPayload":{"properties":{"request_id":{"type":"integer","title":"Request Id"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["request_id"],"title":"ApprovePlanRequestPayload"},"BatchEnrichmentRequest":{"properties":{"lead_ids":{"items":{"type":"string"},"type":"array","title":"Lead Ids"},"data_type":{"type":"string","title":"Data Type","default":"all"},"dry_run":{"type":"boolean","title":"Dry Run","default":true}},"type":"object","required":["lead_ids"],"title":"BatchEnrichmentRequest","description":"Batch enrichment of multiple lead IDs"},"Body_leads_import_file_leads_import_file_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_leads_import_file_leads_import_file_post"},"Body_leads_import_preview_leads_import_preview_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_leads_import_preview_leads_import_preview_post"},"CampaignAgentBatchRequest":{"properties":{"lead_ids":{"items":{"type":"string"},"type":"array","title":"Lead Ids"},"industry_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry Context"},"target_market":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Market"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.35},"prompt_stage1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage1","default":"campaign_company_profile"},"prompt_stage2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage2","default":"campaign_lead_eval"}},"type":"object","required":["lead_ids"],"title":"CampaignAgentBatchRequest","description":"Batch اجرای ایجنت برای چند لید."},"CampaignAgentEnqueueRequest":{"properties":{"lead_ids":{"items":{"type":"string"},"type":"array","title":"Lead Ids"},"industry_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry Context"},"target_market":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Market"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.35},"prompt_stage1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage1","default":"campaign_company_profile"},"prompt_stage2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage2","default":"campaign_lead_eval"},"channel":{"const":"email","title":"Channel","default":"email"},"subject_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject Template"},"body_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body Template"},"dry_run":{"type":"boolean","title":"Dry Run","default":true},"campaign_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Name"},"from_display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From Display Name"},"reply_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reply To"},"validate_emails":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Validate Emails","default":false}},"type":"object","required":["lead_ids"],"title":"CampaignAgentEnqueueRequest","description":"ایجاد صف کمپین از خروجی ایجنت دو مرحله‌ای."},"CampaignAgentRequest":{"properties":{"lead_id":{"type":"string","title":"Lead Id"},"company_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Url"},"href":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Href"},"industry_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry Context"},"target_market":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Market"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.35},"prompt_stage1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage1","default":"campaign_company_profile"},"prompt_stage2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage2","default":"campaign_lead_eval"}},"type":"object","required":["lead_id"],"title":"CampaignAgentRequest","description":"درخواست اجرای ایجنت دو مرحله‌ای کمپین برای یک لید."},"CampaignCreate":{"properties":{"campaign_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Name"},"lead_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Lead Ids"},"steps":{"anyOf":[{"items":{"$ref":"#/components/schemas/CampaignStep"},"type":"array"},{"type":"null"}],"title":"Steps"},"template_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Id"},"lead_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Id"},"total_steps":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Steps","default":0},"personalization_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Personalization Notes"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"recipients":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Recipients"},"from_display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From Display Name"},"reply_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reply To"},"validate_emails":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Validate Emails","default":false}},"type":"object","title":"CampaignCreate"},"CampaignSend":{"properties":{"preview":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Preview","default":false},"start_immediately":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Start Immediately","default":true}},"type":"object","title":"CampaignSend"},"CampaignStep":{"properties":{"step_number":{"type":"integer","title":"Step Number"},"channel":{"type":"string","enum":["email","sms","whatsapp"],"title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"message":{"type":"string","title":"Message"},"wait_hours":{"type":"integer","title":"Wait Hours","default":0},"wait_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Wait Days"}},"type":"object","required":["step_number","channel","message"],"title":"CampaignStep"},"DedupeRequest":{"properties":{"batch_size":{"type":"integer","title":"Batch Size","default":100},"dry_run":{"type":"boolean","title":"Dry Run","default":true}},"type":"object","title":"DedupeRequest","description":"Deduplication batch operation"},"DiscoveryAggregateRequest":{"properties":{"use_profile":{"type":"boolean","title":"Use Profile","default":true},"limit":{"type":"integer","title":"Limit","default":6},"limit_queries":{"type":"integer","title":"Limit Queries","default":6},"smart_rerank":{"type":"boolean","title":"Smart Rerank","default":true},"max_sections":{"type":"integer","title":"Max Sections","default":5}},"type":"object","title":"DiscoveryAggregateRequest"},"DiscoveryBenchmarkRequest":{"properties":{"search_query":{"type":"string","title":"Search Query"},"use_profile":{"type":"boolean","title":"Use Profile","default":false},"smart_rerank":{"type":"boolean","title":"Smart Rerank","default":true},"snippet":{"type":"boolean","title":"Snippet","default":false},"limit":{"type":"integer","title":"Limit","default":5}},"type":"object","required":["search_query"],"title":"DiscoveryBenchmarkRequest"},"DiscoveryRequest":{"properties":{"seed_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Seed Id"},"search_query":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search Query"},"company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"},"limit":{"type":"integer","title":"Limit","default":10},"queries":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Queries"},"use_profile":{"type":"boolean","title":"Use Profile","default":false},"limit_queries":{"type":"integer","title":"Limit Queries","default":10},"smart_rerank":{"type":"boolean","title":"Smart Rerank","default":true},"smart_snippet":{"type":"boolean","title":"Smart Snippet","default":false},"smart_snippet_topk":{"type":"integer","title":"Smart Snippet Topk","default":5}},"type":"object","title":"DiscoveryRequest"},"DiscoveryRerankRequest":{"properties":{"results":{"items":{"type":"object"},"type":"array","title":"Results"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.2}},"type":"object","required":["results"],"title":"DiscoveryRerankRequest"},"DiscoverySnippetSummaryRequest":{"properties":{"title":{"type":"string","title":"Title"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"snippet":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Snippet"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.2}},"type":"object","required":["title"],"title":"DiscoverySnippetSummaryRequest"},"EmailRiskRequest":{"properties":{"email":{"type":"string","title":"Email"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.2}},"type":"object","required":["email"],"title":"EmailRiskRequest"},"EmailTest":{"properties":{"to":{"type":"string","format":"email","title":"To"},"subject":{"type":"string","title":"Subject","default":"Health Check"},"text":{"type":"string","title":"Text","default":"Test email from LeadHunter admin panel"}},"type":"object","required":["to"],"title":"EmailTest"},"EmailValidationTest":{"properties":{"email":{"type":"string","format":"email","title":"Email"}},"type":"object","required":["email"],"title":"EmailValidationTest"},"EmailVerifyBatchRequest":{"properties":{"lead_ids":{"items":{"type":"string"},"type":"array","title":"Lead Ids"},"bump_score":{"type":"integer","title":"Bump Score","default":10},"hot_threshold":{"type":"integer","title":"Hot Threshold","default":80},"warm_threshold":{"type":"integer","title":"Warm Threshold","default":50},"dry_run":{"type":"boolean","title":"Dry Run","default":true},"use_risk_guard":{"type":"boolean","title":"Use Risk Guard","default":true}},"type":"object","required":["lead_ids"],"title":"EmailVerifyBatchRequest","description":"Email verification batch using configured provider (reoon/mailboxlayer)."},"EmailVerifyRequest":{"properties":{"email":{"type":"string","title":"Email"}},"type":"object","required":["email"],"title":"EmailVerifyRequest","description":"Single email verification"},"EnrichmentRequest":{"properties":{"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"}},"type":"object","title":"EnrichmentRequest","description":"Single email or domain enrichment request"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"IdentityOnlyRequest":{"properties":{"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"password_length":{"type":"integer","maximum":32.0,"minimum":10.0,"title":"Password Length","default":14}},"type":"object","title":"IdentityOnlyRequest"},"ImportSessionRequest":{"properties":{"email":{"type":"string","title":"Email"},"password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password"},"storage_state":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Storage State"}},"type":"object","required":["email"],"title":"ImportSessionRequest","description":"Import Mailerfind session after manual browser login (bypasses Cloudflare register)."},"InstagramScrapeRequest":{"properties":{"instagram_account":{"type":"string","title":"Instagram Account"},"mode":{"type":"string","title":"Mode","default":"profile"},"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit","default":50},"instagram_session":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram Session"},"instagram_user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram User Agent"},"headless":{"type":"boolean","title":"Headless","default":true},"timeout_sec":{"type":"integer","maximum":600.0,"minimum":30.0,"title":"Timeout Sec","default":120}},"type":"object","required":["instagram_account"],"title":"InstagramScrapeRequest"},"LeadImportGoogleSheetRequest":{"properties":{"sheet_url":{"type":"string","title":"Sheet Url"},"dry_run":{"type":"boolean","title":"Dry Run","default":true},"limit":{"type":"integer","title":"Limit","default":2000},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","default":"google_sheet"}},"type":"object","required":["sheet_url"],"title":"LeadImportGoogleSheetRequest"},"LeadIngest":{"properties":{"count":{"type":"integer","title":"Count"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","default":"ingest"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","default":"success"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["count"],"title":"LeadIngest"},"MailerfindAnalyzeRequest":{"properties":{"account":{"type":"string","title":"Account","description":"Instagram URL or @username"},"force_demo":{"type":"boolean","title":"Force Demo","default":false},"provider":{"type":"string","title":"Provider","description":"auto | instagram_direct | apify | demo","default":"auto"},"instagram_session":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram Session","description":"Optional Instagram sessionid cookie (overrides env)."},"instagram_user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram User Agent","description":"Optional User-Agent matching the session cookie to bypass mismatch rules."},"instagram_proxy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram Proxy","description":"Optional proxy URL for Instagram."}},"type":"object","required":["account"],"title":"MailerfindAnalyzeRequest"},"MailerfindLead":{"properties":{"username":{"type":"string","title":"Username"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"bio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bio"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"profile_url":{"type":"string","title":"Profile Url"},"followers_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Followers Count"},"following_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Following Count"},"posts_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Posts Count"},"is_verified":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Verified"},"is_business":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Business"},"external_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Url"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"source_account":{"type":"string","title":"Source Account"},"mode":{"type":"string","title":"Mode"},"provider":{"type":"string","title":"Provider","default":"demo"},"raw":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Raw"}},"type":"object","required":["username","profile_url","source_account","mode"],"title":"MailerfindLead"},"MailerfindScrapeRequest":{"properties":{"account":{"type":"string","title":"Account","description":"Instagram URL, @username, or username"},"mode":{"type":"string","enum":["followers","following","profile"],"title":"Mode","default":"followers"},"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit","default":50},"force_demo":{"type":"boolean","title":"Force Demo","default":false},"dry_run":{"type":"boolean","title":"Dry Run","default":true},"ingest":{"type":"boolean","title":"Ingest","default":false},"provider":{"type":"string","enum":["auto","instagram_direct","apify","demo"],"title":"Provider","description":"Extraction backend. 'auto' prefers instagram_direct, then apify, then demo.","default":"auto"},"instagram_session":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram Session","description":"Optional Instagram sessionid cookie for authenticated extraction (overrides env)."},"instagram_user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram User Agent","description":"Optional User-Agent associated with the Instagram session to prevent mismatch errors."},"instagram_proxy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram Proxy","description":"Optional proxy URL for the Instagram requests (overrides env)."}},"type":"object","required":["account"],"title":"MailerfindScrapeRequest"},"MailerfindScrapeResponse":{"properties":{"account":{"type":"string","title":"Account"},"username":{"type":"string","title":"Username"},"mode":{"type":"string","title":"Mode"},"provider":{"type":"string","title":"Provider"},"count":{"type":"integer","title":"Count"},"leads":{"items":{"$ref":"#/components/schemas/MailerfindLead"},"type":"array","title":"Leads"},"profile_analysis":{"anyOf":[{"$ref":"#/components/schemas/ProfileAnalysis"},{"type":"null"}]},"ingested":{"type":"integer","title":"Ingested","default":0},"duration_ms":{"type":"integer","title":"Duration Ms","default":0},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["account","username","mode","provider","count"],"title":"MailerfindScrapeResponse"},"McpInvokeRequest":{"properties":{"tool":{"type":"string","title":"Tool"},"arguments":{"type":"object","title":"Arguments"}},"type":"object","required":["tool"],"title":"McpInvokeRequest"},"OTPRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"channel":{"type":"string","enum":["sms","email"],"title":"Channel"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"}},"type":"object","required":["email","channel"],"title":"OTPRequest"},"OTPVerify":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"code":{"type":"string","title":"Code"}},"type":"object","required":["email","code"],"title":"OTPVerify"},"PasswordSet":{"properties":{"new_password":{"type":"string","title":"New Password"}},"type":"object","required":["new_password"],"title":"PasswordSet"},"PlanUpgradeRequest":{"properties":{"plan_id":{"type":"string","title":"Plan Id"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["plan_id"],"title":"PlanUpgradeRequest"},"ProfileAnalysis":{"properties":{"username":{"type":"string","title":"Username"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"bio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bio"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"profile_url":{"type":"string","title":"Profile Url"},"followers_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Followers Count"},"following_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Following Count"},"posts_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Posts Count"},"is_verified":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Verified"},"is_business":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Business"},"external_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Url"},"business_category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Business Category"},"niche_hints":{"items":{"type":"string"},"type":"array","title":"Niche Hints"},"suggested_hashtags":{"items":{"type":"string"},"type":"array","title":"Suggested Hashtags"},"suggested_services":{"items":{"type":"string"},"type":"array","title":"Suggested Services"},"provider":{"type":"string","title":"Provider","default":"demo"},"raw":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Raw"}},"type":"object","required":["username","profile_url"],"title":"ProfileAnalysis"},"ProfileEnrichRequest":{"properties":{"mode":{"type":"string","pattern":"^(tools|llm|both)$","title":"Mode","default":"both"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"dry_run":{"type":"boolean","title":"Dry Run","default":false}},"type":"object","title":"ProfileEnrichRequest"},"PromptAliasUpsert":{"properties":{"alias":{"type":"string","title":"Alias"},"prompt_name":{"type":"string","title":"Prompt Name"}},"type":"object","required":["alias","prompt_name"],"title":"PromptAliasUpsert"},"PromptTestRequest":{"properties":{"prompt_name":{"type":"string","title":"Prompt Name"},"input_vars":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Input Vars"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.3},"model_preference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model Preference"}},"type":"object","required":["prompt_name"],"title":"PromptTestRequest"},"PromptUpsert":{"properties":{"name":{"type":"string","title":"Name"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"system_msg":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"System Msg"},"user_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Template"},"variables":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Variables"},"model_preference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model Preference"},"change_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Change Reason"}},"type":"object","required":["name"],"title":"PromptUpsert","description":"Create or update a prompt."},"QuickLeadRequest":{"properties":{"profile":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Profile"},"sources":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Sources"},"limit":{"type":"integer","title":"Limit","default":6},"save":{"type":"boolean","title":"Save","default":true},"use_profile":{"type":"boolean","title":"Use Profile","default":true},"extra":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extra"}},"type":"object","title":"QuickLeadRequest"},"QuickLeadsRequest":{"properties":{"instagram_account":{"type":"string","title":"Instagram Account","description":"رقیب: @username یا URL اینستاگرام"},"mode":{"type":"string","title":"Mode","default":"followers"},"limit":{"type":"integer","maximum":50.0,"minimum":1.0,"title":"Limit","default":10},"instagram_session":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instagram Session"},"skip_preflight":{"type":"boolean","title":"Skip Preflight","description":"Skip private check (use when UI already called account-preflight)","default":false},"force_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Force Provider","description":"instagram_direct | mailerfind_browser | None(هیبرید)"}},"type":"object","required":["instagram_account"],"title":"QuickLeadsRequest"},"RegisterMailerfindRequest":{"properties":{"identity":{"anyOf":[{"$ref":"#/components/schemas/TempIdentity"},{"type":"null"}]},"auto_create_identity":{"type":"boolean","title":"Auto Create Identity","default":true},"headless":{"type":"boolean","title":"Headless","default":true},"timeout_sec":{"type":"integer","maximum":300.0,"minimum":30.0,"title":"Timeout Sec","default":120}},"type":"object","title":"RegisterMailerfindRequest"},"SDREnrichRequest":{"properties":{"lead_ids":{"items":{"type":"string"},"type":"array","title":"Lead Ids"},"max_links":{"type":"integer","title":"Max Links","default":5},"industry_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry Context"},"target_market":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Market"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature","default":0.35},"prompt_stage1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage1","default":"campaign_company_profile"},"prompt_stage2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Stage2","default":"campaign_lead_eval"},"enqueue_if_ideal":{"type":"boolean","title":"Enqueue If Ideal","default":false},"dry_run":{"type":"boolean","title":"Dry Run","default":true}},"type":"object","required":["lead_ids"],"title":"SDREnrichRequest","description":"Batch SDR enrichment (scrape + Stage1/2)"},"ScrapeLiveRequest":{"properties":{"instagram_account":{"type":"string","title":"Instagram Account"},"mode":{"type":"string","title":"Mode","default":"followers"},"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit","default":50},"session_storage_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Storage Path"},"headless":{"type":"boolean","title":"Headless","default":true},"timeout_sec":{"type":"integer","maximum":600.0,"minimum":60.0,"title":"Timeout Sec","default":180}},"type":"object","required":["instagram_account"],"title":"ScrapeLiveRequest"},"TelegramTest":{"properties":{"chat_id":{"type":"string","title":"Chat Id"},"message":{"type":"string","title":"Message","default":"Health check from LeadHunter admin panel"}},"type":"object","required":["chat_id"],"title":"TelegramTest"},"TempIdentity":{"properties":{"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"mail_domain":{"type":"string","title":"Mail Domain"},"mail_tm_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mail Tm Account Id"},"mail_tm_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mail Tm Token"},"provider":{"type":"string","title":"Provider","default":"mail.tm"}},"type":"object","required":["email","password","first_name","last_name","mail_domain"],"title":"TempIdentity"},"Token":{"properties":{"access_token":{"type":"string","title":"Access Token"},"token_type":{"type":"string","title":"Token Type"},"user":{"type":"object","title":"User"}},"type":"object","required":["access_token","token_type","user"],"title":"Token"},"TopupRequestPayload":{"properties":{"credits_requested":{"type":"number","title":"Credits Requested"},"money_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Money Amount"},"currency":{"type":"string","title":"Currency","default":"IRR"},"payment_method":{"type":"string","enum":["cash","online","bank_transfer"],"title":"Payment Method","default":"online"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["credits_requested"],"title":"TopupRequestPayload"},"UserLogin":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"UserLogin"},"UserProfile":{"properties":{"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"competitors":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Competitors"},"socials":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Socials"},"hashtags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Hashtags"},"services":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Services"},"customer_desc":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Desc"},"persona":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Persona"},"competitor_instagram":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Competitor Instagram"}},"type":"object","title":"UserProfile"},"UserRegister":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"},"full_name":{"type":"string","title":"Full Name"},"company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"}},"type":"object","required":["email","password","full_name"],"title":"UserRegister"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}