{"openapi":"3.1.0","info":{"title":"Expert Network MVP","version":"0.1.0"},"paths":{"/interviews/upload-file":{"post":{"tags":["interviews"],"summary":"Upload Self Upload File","description":"Upload one self-upload file (audio or transcript) to S3 and return its key.\n\nTwo-step flow: the client uploads here first, then passes the returned\n`s3_key` to POST /interviews/self-upload. Files stream straight to the\nmeeting-bot S3 bucket (Seoul) so playback never depends on Supabase Storage.","operationId":"upload_self_upload_file_interviews_upload_file_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_self_upload_file_interviews_upload_file_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/self-upload":{"post":{"tags":["interviews"],"summary":"Self Upload Interview","description":"Client uploads their own interview audio and/or transcript files.\nCreates a COMPLETED interview with no expert, no credits, no payment.","operationId":"self_upload_interview_interviews_self_upload_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SelfUploadInterviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/book":{"post":{"tags":["interviews"],"summary":"Book Interview","description":"Book an interview: create Zoom meeting, send invitations to expert + all\nproject clients, and invite Fireflies bot to record.","operationId":"book_interview_interviews_book_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BookInterviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/{interview_id}/reschedule":{"post":{"tags":["interviews"],"summary":"Reschedule Interview","description":"Reschedule an interview:\n- Restore old time slot to expert's availability\n- Create new Zoom meeting at new time\n- Update interview record\n- Send updated invitations and invite Fireflies bot","operationId":"reschedule_interview_interviews__interview_id__reschedule_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RescheduleInterviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/{interview_id}/cancel":{"post":{"tags":["interviews"],"summary":"Cancel Interview","description":"Cancel a scheduled interview:\n- Cancel the Zoom meeting\n- Restore the time slot to expert's availability\n- Set interview status to CANCELED\n- Keep expert in the project pipeline (don't remove PE/PEU)\n\nOrder matters: status=CANCELED + slot release MUST be committed BEFORE\nZoom/bot/email cleanup runs. Otherwise a fast cancel→rebook on the same\ntime races the conflict-check (which only excludes SCHEDULED rows)\nagainst the still-uncommitted CANCELED status, producing a phantom\n\"concurrent meeting\" error for ~1s after each cancel.","operationId":"cancel_interview_interviews__interview_id__cancel_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/CancelInterviewRequest"},{"type":"null"}],"title":"Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/{interview_id}/end-early":{"post":{"tags":["interviews"],"summary":"End Interview Early","description":"Admin: mark the interview ended now and return the unused tail of its\n90-min block to the expert's availability.\n\nA scheduled meeting reserves [start, start+90min). If the call wraps up\nearly — say at start+35min — the slots in [start+45, start+90min) are\nstill marked \"blocked\" with no real meeting to back them up. This lets\nan admin release them on demand so a follow-up can be booked into the\nsame window.","operationId":"end_interview_early_interviews__interview_id__end_early_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/{interview_id}/request-reschedule":{"post":{"tags":["interviews"],"summary":"Client Request Reschedule","description":"Client requests reschedule when none of the expert's available slots work.\n- Sets interview status to RESCHEDULE\n- Restores old time slot to expert availability\n- Expert will be flagged to provide more dates","operationId":"client_request_reschedule_interviews__interview_id__request_reschedule_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/RequestRescheduleRequest"},{"type":"null"}],"title":"Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/request-more-slots":{"post":{"tags":["interviews"],"summary":"Request More Slots","description":"Client requests more timeslots from an expert BEFORE scheduling an interview.\nSets PEU status to RESCHEDULE (following priority rules).","operationId":"request_more_slots_interviews_request_more_slots_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestMoreSlotsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews":{"post":{"tags":["interviews"],"summary":"List Interviews","description":"List all interviews with expert info. Auto-syncs from Fireflies on load.","operationId":"list_interviews_interviews_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefaultExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/InterviewResponse"},"title":"Response List Interviews Interviews Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/{interview_id}":{"get":{"tags":["interviews"],"summary":"Get Interview","description":"Get specific interview with fresh media URLs from Zoom or Fireflies (legacy)","operationId":"get_interview_interviews__interview_id__get","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InterviewDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["interviews"],"summary":"Update Interview","description":"Rename an interview. Sets `title_is_custom` so meeting-bot sync paths\nwon't clobber the user's title on subsequent syncs.","operationId":"update_interview_interviews__interview_id__patch","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InterviewUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/{interview_id}/audio":{"get":{"tags":["interviews"],"summary":"Stream Interview Audio","description":"Stream interview audio. Redirects to a presigned S3 URL for meeting-bot\nrecordings, a Supabase signed URL for self-uploaded audio, or proxies Zoom\ncloud recordings as a legacy fallback.\nAuth via ?token= query param (needed for <audio> elements that can't set headers).","operationId":"stream_interview_audio_interviews__interview_id__audio_get","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"token","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/sync-from-zoom":{"post":{"tags":["interviews"],"summary":"Sync From Zoom","description":"Manual endpoint to sync Zoom cloud recordings + transcribe with CLOVA Speech.","operationId":"sync_from_zoom_interviews_sync_from_zoom_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefaultExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Sync From Zoom Interviews Sync From Zoom Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/sync-from-fireflies":{"post":{"tags":["interviews"],"summary":"Sync From Fireflies Legacy","description":"[LEGACY] Manual endpoint to sync from Fireflies.ai. Kept as backup.","operationId":"sync_from_fireflies_legacy_interviews_sync_from_fireflies_post","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":10,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Sync From Fireflies Legacy Interviews Sync From Fireflies Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/interviews/{interview_id}/redetect-silence":{"post":{"tags":["interviews"],"summary":"Redetect Silence Offsets Endpoint","description":"Admin-only: re-run the ffmpeg silence detector on an existing interview's\naudio and overwrite the stored offsets. Doesn't touch the transcript or\nre-bill Clova — useful for backfilling interviews recorded before the\nauto-trim pipeline shipped, or for re-running with tweaked thresholds.\n\nResolves the audio URL the same way the public /audio endpoint does, so the\noffsets line up with what the user actually hears in the player.","operationId":"redetect_silence_offsets_endpoint_interviews__interview_id__redetect_silence_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat":{"post":{"tags":["chat"],"summary":"Ask Question","description":"Ask a question about selected interview transcripts.\nStreams the OpenAI response back as Server-Sent Events.\nPersists chat history to existing chat_sessions / chat_messages tables.","operationId":"ask_question_chat_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/sessions/{project_id}":{"get":{"tags":["chat"],"summary":"List Sessions","description":"List chat sessions for a project (for future frontend use).","operationId":"list_sessions_chat_sessions__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/sessions/{project_id}/{session_id}/messages":{"get":{"tags":["chat"],"summary":"Get Session Messages","description":"Get all messages for a chat session (for future frontend use).","operationId":"get_session_messages_chat_sessions__project_id___session_id__messages_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts":{"post":{"tags":["experts"],"summary":"Geallexpertsforproject","operationId":"geAllExpertsForProject_experts_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefaultExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/project/{project_id}/companies":{"get":{"tags":["experts"],"summary":"Get Project Companies","description":"Get distinct searched companies for a project (for filter dropdown)","operationId":"get_project_companies_experts_project__project_id__companies_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/{expert_id}/notes":{"put":{"tags":["experts"],"summary":"Upsert Expert Note","description":"Add or update a shared note on an expert in a project","operationId":"upsert_expert_note_experts__expert_id__notes_put","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertNoteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/{expert_id}/reaction":{"put":{"tags":["experts"],"summary":"Upsert Expert Reaction","description":"Toggle a user's reaction (favourite/irrelevant) on an expert in a project","operationId":"upsert_expert_reaction_experts__expert_id__reaction_put","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertReactionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/outreach":{"post":{"tags":["experts"],"summary":"Sendoutreachexperts","operationId":"SendOutreachExperts_experts_outreach_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutreachRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/companysearch":{"post":{"tags":["experts"],"summary":"Shortlist Companies","operationId":"shortlist_companies_experts_companysearch_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/companies/db-search":{"get":{"tags":["experts"],"summary":"Search Companies Db","description":"Search companies in the local database by name (client-accessible).","operationId":"search_companies_db_experts_companies_db_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/search":{"post":{"tags":["experts"],"summary":"Expert Search","description":"Submit an expert search request. Records a SearchHistory row that the\nsourcing agent will pick up once approved (admins auto-approve; client\nsubmissions wait for admin review at /admin/search-requests).\nRate limited to 3 submissions per project per day for non-admin users.","operationId":"expert_search_experts_search_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/search/{request_id}":{"patch":{"tags":["experts"],"summary":"Edit Expert Search","description":"Edit a still-pending request in place, so a correction updates the row\ninstead of forking a duplicate. Owner-only. HITL: once an admin approves and\nsourcing starts (approved_at set) edits are refused — the client must contact\nthe team. Does not consume the 3/day create quota.","operationId":"edit_expert_search_experts_search__request_id__patch","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/search/{request_id}/withdraw":{"post":{"tags":["experts"],"summary":"Withdraw Expert Search","description":"Soft-cancel a still-pending request (owner-only). Reuses the reject\ncolumns so admins keep full history and can un-reject; never a hard delete.\nRefused once sourcing has started (approved_at set).","operationId":"withdraw_expert_search_experts_search__request_id__withdraw_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/experts/search/quota/{project_id}":{"get":{"tags":["experts"],"summary":"Get Search Quota","description":"Get the user's remaining search quota for a specific project today.","operationId":"get_search_quota_experts_search_quota__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects":{"get":{"tags":["projects"],"summary":"Geallprojectforuser","description":"Get all projects the user is involved in","operationId":"geAllProjectForUser_projects_get","parameters":[{"name":"include_archived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Archived"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/create":{"post":{"tags":["projects"],"summary":"Createproject","description":"Create new project","operationId":"createProject_projects_create_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateProjectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}":{"delete":{"tags":["projects"],"summary":"Deleteorphanproject","description":"Delete a project ONLY if it's a pure empty orphan.\n\ncreateProject persists the Project (+ creator ProjectUser) before the first\nsearch request is attached via /experts/search. If that search step fails or\nthe user abandons the form, an empty shell is left behind — these pile up on\nthe Outreach list as \"No outreach yet\" junk. The New Project flow calls this\nto roll back such a shell. Guarded: refuses (409) if the project has ANY\nexperts, outreach, search requests, interviews, or agent candidates, so it can\nnever delete a live project. Only the creator's ProjectUser row may exist (it\ncascades via the Project.users relationship).","operationId":"deleteOrphanProject_projects__project_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["projects"],"summary":"Updateproject","description":"Update a project (e.g. rename)","operationId":"updateProject_projects__project_id__put","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateProjectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/searches":{"get":{"tags":["projects"],"summary":"Listprojectsearches","description":"Return every SearchHistory row for every project the current user participates in.\nUsed by the finder requests rail to enumerate each submitted search as a distinct request.","operationId":"listProjectSearches_projects_searches_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/members-summary":{"get":{"tags":["projects"],"summary":"Listprojectmembers","description":"Members of every project the user belongs to, keyed by project id — in ONE\nbounded query so the project list page can render team avatars without fanning\nout a GET /projects/{id}/users request per project (a real stampede on the\n~60-connection tier). Returns { \"<project_id>\": [ {id, first_name, last_name,\nemail} ] }. Team membership carries no anonymity concern (client-side only).","operationId":"listProjectMembers_projects_members_summary_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/archive":{"patch":{"tags":["projects"],"summary":"Archiveproject","description":"Archive or unarchive a project (reversible). Hides it from the default\nproject list AND pauses/resumes agent sourcing so an archived project stops\nspending sourcing budget. Deletes no history.","operationId":"archiveProject_projects__project_id__archive_patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArchiveProjectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/users":{"get":{"tags":["projects"],"summary":"Getprojectusers","description":"Get all users in a project","operationId":"getProjectUsers_projects__project_id__users_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["projects"],"summary":"Addusertoproject","description":"Add a user to a project by email","operationId":"addUserToProject_projects__project_id__users_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddUserRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/users/{target_user_id}":{"delete":{"tags":["projects"],"summary":"Removeuserfromproject","description":"Remove a user from a project","operationId":"removeUserFromProject_projects__project_id__users__target_user_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"target_user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Target User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/credits/balance":{"get":{"tags":["projects"],"summary":"Get Credit Balance","description":"Get the current user's company credit balance","operationId":"get_credit_balance_projects_credits_balance_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/expert-guidelines":{"get":{"tags":["projects"],"summary":"Get Project Expert Guidelines","description":"Get all experts in this project with their guideline files","operationId":"get_project_expert_guidelines_projects__project_id__expert_guidelines_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/experts/{expert_id}/guidelines":{"post":{"tags":["projects"],"summary":"Upload Expert Guidelines","description":"Save guideline file paths for a project expert.\nBody: { \"files\": [{ \"file_path\": \"...\", \"original_filename\": \"...\" }, ...] }\nClient uploads files to Supabase Storage first, then calls this with paths.","operationId":"upload_expert_guidelines_projects__project_id__experts__expert_id__guidelines_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/guidelines/bulk":{"post":{"tags":["projects"],"summary":"Upload Guidelines To Multiple Experts","description":"Upload guideline files to multiple project experts at once.\nBody: { \"files\": [{ \"file_path\": \"...\", \"original_filename\": \"...\" }, ...], \"expert_ids\": [\"...\", ...] }\nClient uploads files to Supabase Storage first, then calls this with paths and expert IDs.","operationId":"upload_guidelines_to_multiple_experts_projects__project_id__guidelines_bulk_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/guidelines/{guideline_id}":{"delete":{"tags":["projects"],"summary":"Delete Expert Guideline","description":"Delete a single guideline file","operationId":"delete_expert_guideline_projects__project_id__guidelines__guideline_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"guideline_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Guideline Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/experts/{expert_id}/ens-pricing":{"get":{"tags":["projects"],"summary":"Get Expert Ens Pricing","description":"View ENS pricing comparison for a specific expert in a project.\nReturns Veyond's competitive price alongside all ENS firm prices.\n\nPricing logic:\n- Start with standard experience-based pricing\n- If any ENS firm quotes lower than standard, Veyond = cheapest_ens * 0.9","operationId":"get_expert_ens_pricing_projects__project_id__experts__expert_id__ens_pricing_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status":{"post":{"tags":["status"],"summary":"Geallexpertswithstatus","description":"Get all experts (with outreach status) for a project the caller can access.","operationId":"geAllExpertsWithStatus_status_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefaultExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status/sourcing":{"post":{"tags":["status"],"summary":"Get Sourcing Status","description":"Sourcing-in-progress banner data for the project detail page.\n\nA `SearchHistory` row counts as still-in-progress until at least one of its\nsourced experts (`ProjectExpert.search_history_id = sh.id`) reaches the\npoint where the client can actually engage with them on the list — i.e.\nthe expert has at least one ANSWERED vetting question OR has shared\navailability. Both signals match the visibility rules used elsewhere\n(see dashboard.py / status.py). The banner auto-clears as soon as the\nfirst associated expert hits one of those signals.\n\n`variant` distinguishes the initial sourcing message (first request on a\nfresh project — \"Veyond is sourcing experts\") from the additional-sourcing\nmessage (request #2+ on an existing project — \"Veyond is sourcing more\nexperts\"). Based on total request count, not pending count, so the copy\nmatches what the user clicked on the way in.","operationId":"get_sourcing_status_status_sourcing_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefaultExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status/translate-texts":{"post":{"tags":["status"],"summary":"Translate Texts","description":"Generic helper used by the frontend's per-expert \"Translate\" toggle on\nVQs and follow-up answers. Auto-detects each text's source language and\nonly translates the ones that aren't already in `target_lang`. Papago has\na DB-backed cache, so repeat calls for the same text are free.","operationId":"translate_texts_status_translate_texts_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslateTextsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status/decline":{"post":{"tags":["status"],"summary":"Decline Expert","description":"Client declines an expert — sets their PEU status to USER_DECLINED","operationId":"decline_expert_status_decline_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeclineExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status/reallocate":{"post":{"tags":["status"],"summary":"Reallocate Expert","description":"Move an expert from one project to another. Client must be member of both projects.","operationId":"reallocate_expert_status_reallocate_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReallocateExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status/vetting-questions/{pevq_id}":{"put":{"tags":["status"],"summary":"Edit Vetting Question","description":"Edit a vetting question's text. Only allowed if not yet answered.","operationId":"edit_vetting_question_status_vetting_questions__pevq_id__put","parameters":[{"name":"pevq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pevq Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditVQRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status/additional-vqs":{"post":{"tags":["status"],"summary":"Add Additional Vetting Questions","description":"Allow clients to add additional vetting questions to selected experts.\nNew VQs are created with status=PENDING so admins can see and send them.","operationId":"add_additional_vetting_questions_status_additional_vqs_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdditionalVQsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/status/export-xlsx":{"post":{"tags":["status"],"summary":"Export Expert List Xlsx","description":"Render the project's expert list as an .xlsx download for clients,\nmatching the columns of the supplied template.","operationId":"export_expert_list_xlsx_status_export_xlsx_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefaultExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/invite/{token}":{"get":{"tags":["expert-auth"],"summary":"Expert Invite Prefill","description":"Public: resolve an outreach signup token to prefill the signup form. The\ntoken is the capability (unguessable). Returns ONLY the expert's own\nname/LinkedIn — their own public data, never any client/firm identity — and\nflags if a User already claimed it so the FE can send them to sign-in.","operationId":"expert_invite_prefill_expert_invite__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/signup":{"post":{"tags":["expert-auth"],"summary":"Expert Signup","description":"Create expert account:\n1. Check if user already exists, if so return error\n2. Create Supabase auth user with email/password\n3. If LinkedIn URL provided:\n   - Check if expert exists by linkedin_url\n   - If exists: Link to existing expert\n   - If not: Fetch from Unipile and create expert profile\n4. If no LinkedIn URL: Create minimal expert profile\n5. Create User record with user_type=EXPERT, account_status=PENDING_REVIEW\n\nReturns success message indicating account pending review","operationId":"expert_signup_expert_signup_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertSignupRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertSignupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/users/me":{"get":{"tags":["expert-auth"],"summary":"Get Current User","description":"Get current user's profile and metadata\n\nReturns:\n- user_id, email, first_name, last_name\n- user_type (CLIENT, EXPERT, ADMIN)\n- account_status\n- expert_id (if expert)","operationId":"get_current_user_expert_users_me_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserInfoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/availability":{"get":{"tags":["expert-auth"],"summary":"Get Expert Availability","description":"Get expert's available time slots (future dates only)","operationId":"get_expert_availability_expert_availability_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["expert-auth"],"summary":"Update Expert Availability","description":"Update expert's available time slots","operationId":"update_expert_availability_expert_availability_put","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateAvailabilityRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/slot-requests":{"get":{"tags":["expert-auth"],"summary":"Get Expert Slot Requests","description":"Check if clients have requested more timeslots from this expert (no project info disclosed).","operationId":"get_expert_slot_requests_expert_slot_requests_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/interviews":{"get":{"tags":["expert-auth"],"summary":"Get Expert Interviews","description":"Get expert's interviews (no project info disclosed)","operationId":"get_expert_interviews_expert_interviews_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExpertInterviewResponse"},"title":"Response Get Expert Interviews Expert Interviews Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/interviews/{interview_id}/request-reschedule":{"post":{"tags":["expert-auth"],"summary":"Expert Request Reschedule","description":"Expert requests to reschedule an interview.\nSets interview status to RESCHEDULE. The old time slot is added back to\nexpert's availability so it can be rebooked. Client/admin will pick a new time.","operationId":"expert_request_reschedule_expert_interviews__interview_id__request_reschedule_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertRescheduleRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/interviews/{interview_id}/request-payment":{"post":{"tags":["expert-auth"],"summary":"Expert Request Payment","description":"Expert requests payment for a completed interview.\nRequires payment info to be set up first.","operationId":"expert_request_payment_expert_interviews__interview_id__request_payment_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/guidelines":{"get":{"tags":["expert-auth"],"summary":"Get Expert Guidelines","description":"Get all guideline files for the authenticated expert's projects.\nNo project or client info is disclosed.","operationId":"get_expert_guidelines_expert_guidelines_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/guidelines/upload":{"post":{"tags":["expert-auth"],"summary":"Upload Expert Files","description":"Allow experts to upload their own files (audio recordings, transcripts).\nBody: { \"files\": [{ \"file_path\": \"...\", \"original_filename\": \"...\" }, ...] }\nFiles are distributed across all project_expert records for this expert.","operationId":"upload_expert_files_expert_guidelines_upload_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/me":{"get":{"tags":["expert-profile"],"summary":"Get Expert Profile","description":"Get expert's own profile including work experience\n\nReturns:\n- Expert profile data\n- List of work experience (ExpertCompany records with company names)","operationId":"get_expert_profile_expert_me_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertProfileResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["expert-profile"],"summary":"Update Expert Profile","description":"Update expert's own profile\n\nAllowed fields:\n- first_name, last_name\n- headline, summary\n- location, linkedin_url, industry","operationId":"update_expert_profile_expert_me_put","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateExpertProfileRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertProfileResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/companies/search":{"get":{"tags":["expert-profile"],"summary":"Search Companies Expert","description":"Search companies via Unipile/LinkedIn (expert-accessible).","operationId":"search_companies_expert_expert_companies_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/companies/db-search":{"get":{"tags":["expert-profile"],"summary":"Search Companies Db Expert","description":"Search companies in local database by name (expert-accessible).","operationId":"search_companies_db_expert_expert_companies_db_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/me/experience":{"post":{"tags":["expert-profile"],"summary":"Add Work Experience","description":"Add work experience entry to expert's profile\n\nCreates or finds Company record by name, then creates ExpertCompany link","operationId":"add_work_experience_expert_me_experience_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddExperienceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertCompanyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/me/experience/{experience_id}":{"put":{"tags":["expert-profile"],"summary":"Update Work Experience","description":"Update work experience entry\n\nExperts can only update their own experience entries","operationId":"update_work_experience_expert_me_experience__experience_id__put","parameters":[{"name":"experience_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Experience Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateExperienceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertCompanyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["expert-profile"],"summary":"Delete Work Experience","description":"Delete work experience entry\n\nExperts can only delete their own experience entries","operationId":"delete_work_experience_expert_me_experience__experience_id__delete","parameters":[{"name":"experience_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Experience Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/payment":{"get":{"tags":["expert-profile"],"summary":"Get Expert Payment","description":"Get expert's payment information (sensitive fields masked)","operationId":"get_expert_payment_expert_payment_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertPaymentInfoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["expert-profile"],"summary":"Update Expert Payment","description":"Update expert's payment information","operationId":"update_expert_payment_expert_payment_put","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateExpertPaymentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertPaymentInfoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/payment/id-document":{"post":{"tags":["expert-profile"],"summary":"Upload Payment Id Document","description":"Upload an ID card / passport scan for tax reporting (replaces any prior one).\n\nBytes go straight to SSE-encrypted private S3 keyed by expert_id; only the\nobject key + filename are stored. Read back by admins only, via a short-lived\npresigned URL (GET /admin/experts/{id}/payment/id-document).","operationId":"upload_payment_id_document_expert_payment_id_document_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_payment_id_document_expert_payment_id_document_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertPaymentInfoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/questions":{"get":{"tags":["expert-vetting"],"summary":"Get My Vetting Questions","description":"Get all vetting questions assigned to this expert\n\nReturns questions grouped by project with answer status","operationId":"get_my_vetting_questions_expert_questions_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/VettingQuestionResponse"},"title":"Response Get My Vetting Questions Expert Questions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/expert/questions/{question_id}/answer":{"post":{"tags":["expert-vetting"],"summary":"Submit Vetting Answer","description":"Submit answer to vetting question\n\nCreates or updates ProjectExpertVettingAnswers record","operationId":"submit_vetting_answer_expert_questions__question_id__answer_post","parameters":[{"name":"question_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Question Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitAnswerRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitAnswerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/pending":{"get":{"tags":["admin"],"summary":"Get Pending Experts","description":"List all experts awaiting approval (admin only)\n\nReturns list of experts with account_status=PENDING_REVIEW","operationId":"get_pending_experts_admin_experts_pending_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PendingExpertResponse"},"title":"Response Get Pending Experts Admin Experts Pending Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{user_id}/approve":{"post":{"tags":["admin"],"summary":"Approve Expert","description":"Approve expert account (admin only)\n\nSets account_status to APPROVED","operationId":"approve_expert_admin_experts__user_id__approve_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApproveExpertResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{user_id}/reject":{"post":{"tags":["admin"],"summary":"Reject Expert","description":"Flag expert as spam/rejected (admin only)\n\nSets account_status to REJECTED\nUser still exists but cannot access features","operationId":"reject_expert_admin_experts__user_id__reject_post","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RejectExpertResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{user_id}":{"delete":{"tags":["admin"],"summary":"Delete Expert","description":"Permanently delete rejected/spam expert account (admin only)\n\nSafety check: Only allows deletion if account_status is REJECTED\nDeletes:\n- User record (cascade will handle related data)\n- Supabase auth user (optional)\n- Expert record remains if referenced elsewhere","operationId":"delete_expert_admin_experts__user_id__delete","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteExpertResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/merge":{"post":{"tags":["admin"],"summary":"Merge Duplicate Experts","description":"Fold a duplicate expert into a canonical one (admin only).\n\nFor the \"same human, two LinkedIn accounts\" case that no automatic rule can\ncatch. Reassigns every reference from the duplicate onto the canonical,\nrecords the duplicate's LinkedIn id as an alias (so re-sourcing can't recreate\nit), then deletes the duplicate. Irreversible — the UI confirms first.","operationId":"merge_duplicate_experts_admin_experts_merge_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MergeExpertsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/contact-submissions":{"get":{"tags":["admin"],"summary":"Get Contact Submissions","description":"List all contact form submissions (admin only), newest first","operationId":"get_contact_submissions_admin_contact_submissions_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/contact-submissions/{submission_id}/read":{"post":{"tags":["admin"],"summary":"Mark Submission Read","description":"Mark a contact submission as read (admin only)","operationId":"mark_submission_read_admin_contact_submissions__submission_id__read_post","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Submission Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__contact__MarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/contact-submissions/{submission_id}/unread":{"post":{"tags":["admin"],"summary":"Mark Submission Unread","description":"Mark a contact submission as unread (admin only)","operationId":"mark_submission_unread_admin_contact_submissions__submission_id__unread_post","parameters":[{"name":"submission_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Submission Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__contact__MarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/all":{"get":{"tags":["admin"],"summary":"Get All Experts","description":"List experts (admin only), paginated with server-side search/filter.\n\nReturns an envelope {items, total, review_total}. `search` matches name /\nemail / headline (case-insensitive); `review_needed` restricts to experts\nwith needs_review work-history rows. Replaces the old load-the-whole-table\nbehavior — the frontend pages this via offset/limit (\"load more\").","operationId":"get_all_experts_admin_experts_all_get","parameters":[{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"review_needed","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Review Needed"}},{"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"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllExpertsPage"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/status":{"put":{"tags":["admin"],"summary":"Update Expert Status","description":"Update expert status (ACTIVE or BLACKLISTED) (admin only)","operationId":"update_expert_status_admin_experts__expert_id__status_put","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"status","in":"query","required":true,"schema":{"type":"string","title":"Status"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/enrich-sales-nav":{"post":{"tags":["admin"],"summary":"Enrich Expert Sales Nav","description":"Re-scan one expert on a Sales Navigator seat to recover a hidden name /\nmissing work history (costs 1 profile-view credit).\n\nCalled two ways by the admin UI: automatically when a candidate is opened\n(force=false — skips if nothing's missing or already attempted) and from the\nmanual \"Enrich from Sales Nav\" button (force=true). Gated by\nSALES_NAV_ENRICH_ENABLED so nothing spends credits until it's flipped on.","operationId":"enrich_expert_sales_nav_admin_experts__expert_id__enrich_sales_nav_post","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Force"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/profile":{"get":{"tags":["admin"],"summary":"Get Expert Profile Admin","description":"Get any expert's full profile (admin only).\n\nWith ?project_id=, also returns the \"why this match\" for that project (the\noverride-aware score_breakdown why_match) so the profile side panel in the\nbulk-InMail / client-email composers can show the match rationale inline.","operationId":"get_expert_profile_admin_admin_experts__expert_id__profile_get","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertProfileResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["admin"],"summary":"Update Expert Profile Admin","description":"Update any expert's profile (admin only)","operationId":"update_expert_profile_admin_admin_experts__expert_id__profile_put","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUpdateExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertProfileResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/companies/search":{"get":{"tags":["admin"],"summary":"Search Companies Admin","description":"Search companies via Unipile/LinkedIn (admin only)","operationId":"search_companies_admin_admin_companies_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/experience":{"post":{"tags":["admin"],"summary":"Add Expert Experience Admin","description":"Add work experience to any expert's profile (admin only)","operationId":"add_expert_experience_admin_admin_experts__expert_id__experience_post","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAddExperienceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertCompanyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/experience/{experience_id}":{"put":{"tags":["admin"],"summary":"Update Expert Experience Admin","description":"Update work experience on any expert's profile (admin only)","operationId":"update_expert_experience_admin_admin_experts__expert_id__experience__experience_id__put","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"experience_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Experience Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateExperienceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertCompanyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin"],"summary":"Delete Expert Experience Admin","description":"Delete work experience from any expert's profile (admin only)","operationId":"delete_expert_experience_admin_admin_experts__expert_id__experience__experience_id__delete","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"experience_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Experience Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/experience/{experience_id}/review":{"patch":{"tags":["admin"],"summary":"Dismiss Experience Review","description":"Dismiss the needs_review flag on a work experience entry","operationId":"dismiss_experience_review_admin_experts__expert_id__experience__experience_id__review_patch","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"experience_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Experience Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects":{"get":{"tags":["admin"],"summary":"Get Admin Projects","description":"List all projects with outreach statistics (admin only)","operationId":"get_admin_projects_admin_projects_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdminProjectResponse"},"title":"Response Get Admin Projects Admin Projects Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Admin Create Project","description":"Create a project from the admin manual LinkedIn-search flow.\n\nDiffers from the client-facing POST /projects/create in two ways: it\nrequires admin auth (not client), and it seeds the project with the\ncreating admin as the initial ProjectUser so it isn't orphaned.\n\nOptionally assigns a client account at creation (`client_user_id`) so the\nproject shows up in that client's dashboard right away. Admins can also\nadd/remove client assignments later via the /projects/{id}/clients endpoints.","operationId":"admin_create_project_admin_projects_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateProjectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/experts":{"get":{"tags":["admin"],"summary":"Get Project Experts Admin","description":"Get expert list for a project grouped by search (admin only). Reuses client helper.","operationId":"get_project_experts_admin_admin_projects__project_id__experts_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/outreach":{"get":{"tags":["admin"],"summary":"Get Project Outreach","description":"Get all experts in a project with full outreach details (admin only)","operationId":"get_project_outreach_admin_projects__project_id__outreach_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/project-experts/{pe_id}/admin-meta":{"patch":{"tags":["admin"],"summary":"Update Project Expert Admin Meta","description":"Update admin reactions + note + showcase flag on a ProjectExpert row.\n\nBody accepts any subset of:\n  {\"favorite\": bool, \"dislike\": bool, \"showcased\": bool, \"note\": str | null}\n\nFavorite and dislike are mutually exclusive — setting one to true\nautomatically clears the other (matches the client-facing reaction UX).\nfavorite/dislike/note are admin-private and never appear on any\nclient-facing endpoint. `showcased` is NOT private: when true it lets the\nexpert appear on the client status page before they've answered a VQ or\nshared availability (see status.py / dashboard.py visibility gates).","operationId":"update_project_expert_admin_meta_admin_project_experts__pe_id__admin_meta_patch","parameters":[{"name":"pe_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pe Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/project-experts/{pe_id}/regenerate-why-match":{"post":{"tags":["admin"],"summary":"Regenerate Why Match","description":"Regenerate the `why_match` text on a ProjectExpert row.\n\nBody (optional): {\"focus_hint\": \"free-text guidance for the LLM\"}.\n\nThis rewrites only `score_breakdown.why_match` — the component scores\n(and any admin score override) are preserved. The current why_match is\npassed back to the model as the \"previous angle\" so the regenerated\noutput surfaces different facts, which is the whole point of clicking\nRegenerate.","operationId":"regenerate_why_match_admin_project_experts__pe_id__regenerate_why_match_post","parameters":[{"name":"pe_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pe Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/outreach/{peu_id}/status":{"put":{"tags":["admin"],"summary":"Update Outreach Status","description":"Update outreach status for a project expert user (admin only)","operationId":"update_outreach_status_admin_outreach__peu_id__status_put","parameters":[{"name":"peu_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Peu Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUpdateOutreachStatusRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/requests/{search_history_id}/client-update":{"post":{"tags":["admin"],"summary":"Send Request Client Update","description":"Manually send a client status-update email for the whole project this\nrequest belongs to, with the live reviewed/outreached counts and the\noutreached-expert list attached as .xlsx (admin only). The update is\naggregated across every request in the project (one email, not one per\nrequest). The first send also doubles as the automated \"initial\" update\n(stamps initial_update_sent_at on all the project's requests) so the 7am\nsweeper won't also send it.","operationId":"send_request_client_update_admin_requests__search_history_id__client_update_post","parameters":[{"name":"search_history_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Search History Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/users":{"get":{"tags":["admin"],"summary":"Get Admin Users","description":"List all admin users (admin only)","operationId":"get_admin_users_admin_users_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/outreach/{peu_id}/assign":{"post":{"tags":["admin"],"summary":"Assign Outreach","description":"Assign or unassign an admin to an expert outreach (admin only)","operationId":"assign_outreach_admin_outreach__peu_id__assign_post","parameters":[{"name":"peu_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Peu Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAssignRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/outreach/{peu_id}/answers":{"post":{"tags":["admin"],"summary":"Submit Vetting Answers","description":"Submit vetting question answers on behalf of an expert (admin only)","operationId":"submit_vetting_answers_admin_outreach__peu_id__answers_post","parameters":[{"name":"peu_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Peu Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminSubmitAnswersRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/outreach/{peu_id}/availability":{"put":{"tags":["admin"],"summary":"Set Availability","description":"Set availability datetime slots for an expert (admin only). Writes to Expert.availability (global).","operationId":"set_availability_admin_outreach__peu_id__availability_put","parameters":[{"name":"peu_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Peu Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminSetAvailabilityRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/outreach/{peu_id}/rates":{"put":{"tags":["admin"],"summary":"Update Peu Rates","description":"Manually override client_rate and/or expert_cost on a PEU row (admin only).","operationId":"update_peu_rates_admin_outreach__peu_id__rates_put","parameters":[{"name":"peu_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Peu Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUpdatePEURateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/project-experts/{pe_id}/score":{"put":{"tags":["admin"],"summary":"Update Project Expert Score Override","description":"Override (or clear) the admin score on a ProjectExpert row (admin only).\n\nThe original `score` and `score_breakdown` are left untouched; the override is\nstored alongside so we can show both, and removed when `clear=True` is passed.","operationId":"update_project_expert_score_override_admin_project_experts__pe_id__score_put","parameters":[{"name":"pe_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pe Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUpdateScoreOverrideRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/project-experts/{pe_id}/target-company":{"put":{"tags":["admin"],"summary":"Update Project Expert Target Company","description":"Pin (or clear) the displayed target company for a ProjectExpert (admin only).\n\nBody: {\"company_name\": \"<name>\"} to set, or {\"company_name\": null} / \"\" to clear.\nThe value should be one of the expert's own work-history companies; it only\nchanges what the outreach page displays and never mutates the shared\nSearchHistory / search request.","operationId":"update_project_expert_target_company_admin_project_experts__pe_id__target_company_put","parameters":[{"name":"pe_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pe Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/vetting-questions/{pevq_id}/status":{"put":{"tags":["admin"],"summary":"Update Vetting Question Status","description":"Update the status of an individual vetting question (admin only)","operationId":"update_vetting_question_status_admin_vetting_questions__pevq_id__status_put","parameters":[{"name":"pevq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pevq Id"}},{"name":"status","in":"query","required":true,"schema":{"type":"string","title":"Status"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/vetting-questions/{pevq_id}":{"put":{"tags":["admin"],"summary":"Admin Edit Vetting Question","description":"Edit the text of an individual vetting question (admin only).","operationId":"admin_edit_vetting_question_admin_vetting_questions__pevq_id__put","parameters":[{"name":"pevq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pevq Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin"],"summary":"Admin Delete Vetting Question","description":"Remove an individual vetting question from a specific expert (admin only).\n\nDeletes the project-expert assignment (and its answer via cascade). The shared\nVettingQuestions text row is left intact since it may be reused by other experts.","operationId":"admin_delete_vetting_question_admin_vetting_questions__pevq_id__delete","parameters":[{"name":"pevq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Pevq Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/outreach/vetting-questions":{"post":{"tags":["admin"],"summary":"Admin Add Vetting Questions","description":"Admin adds vetting questions to selected experts in a project","operationId":"admin_add_vetting_questions_admin_projects__project_id__outreach_vetting_questions_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/companies":{"get":{"tags":["admin"],"summary":"Get Companies With Credits","description":"List companies that have at least one client user, with credit balances.\n\nReturns { items, total }, paginated with a server-side name search. The\npage's client users are batch-loaded in one query (was a query per company).","operationId":"get_companies_with_credits_admin_companies_get","parameters":[{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"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"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCompaniesPage"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/companies/{company_id}/credits":{"put":{"tags":["admin"],"summary":"Update Company Credits","description":"Set credit balance for a company","operationId":"update_company_credits_admin_companies__company_id__credits_put","parameters":[{"name":"company_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Company Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUpdateCreditsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pricing/tiers":{"get":{"tags":["admin"],"summary":"Get Pricing Tiers","description":"Return the KRW credit-pack catalog for the admin top-up form.","operationId":"get_pricing_tiers_admin_pricing_tiers_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PricingTierCatalogResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/revenue-transactions":{"get":{"tags":["admin"],"summary":"List Revenue Transactions","description":"List bank-transfer / top-up ledger rows. Newest first.","operationId":"list_revenue_transactions_admin_revenue_transactions_get","parameters":[{"name":"company_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RevenueTransactionResponse"},"title":"Response List Revenue Transactions Admin Revenue Transactions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Create Revenue Transaction","description":"Log a bank transfer. Atomically inserts a ledger row AND tops up the\ncompany's credit_balance cache. Tier presets auto-fill amount_krw, credits,\nand expires_at; tier_code='CUSTOM' requires explicit amount_krw + credits.","operationId":"create_revenue_transaction_admin_revenue_transactions_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateRevenueTransactionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevenueTransactionCreateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/revenue-transactions/{tx_id}":{"delete":{"tags":["admin"],"summary":"Delete Revenue Transaction","description":"Undo a logged transfer. Reverses the balance top-up by the ledger row's\ncredits_remaining only — if credits have already been partially drawn\nagainst this pack, the drawn portion is treated as already-consumed revenue\nand is NOT clawed back from the company.","operationId":"delete_revenue_transaction_admin_revenue_transactions__tx_id__delete","parameters":[{"name":"tx_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tx Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/companies/{company_id}/client-type":{"put":{"tags":["admin"],"summary":"Update Company Client Type","description":"Set or clear client type for a company","operationId":"update_company_client_type_admin_companies__company_id__client_type_put","parameters":[{"name":"company_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Company Id"}},{"name":"client_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Type"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/clients":{"post":{"tags":["admin"],"summary":"Create Client Account","description":"Create a new client account (admin only)","operationId":"create_client_account_admin_clients_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateClientRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateClientResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["admin"],"summary":"Get Client Users","description":"List all client users with their company assignment","operationId":"get_client_users_admin_clients_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdminClientUserResponse"},"title":"Response Get Client Users Admin Clients Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/clients/{user_id}/projects":{"get":{"tags":["admin"],"summary":"Get Client Projects","description":"Lightweight list of projects this client user is a member of.\n\nUsed by the search-requests \"Assign to existing project\" picker. Returns\njust id + title so the dropdown stays cheap.","operationId":"get_client_projects_admin_clients__user_id__projects_get","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/clients/{user_id}/company":{"put":{"tags":["admin"],"summary":"Assign User To Company","description":"Assign a client user to a company","operationId":"assign_user_to_company_admin_clients__user_id__company_put","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAssignCompanyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/companies/db-search":{"get":{"tags":["admin"],"summary":"Search Companies In Db","description":"Search companies in the local database by name","operationId":"search_companies_in_db_admin_companies_db_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/companies/create":{"post":{"tags":["admin"],"summary":"Create Company Manually","description":"Manually create a company record","operationId":"create_company_manually_admin_companies_create_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateCompanyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/experts/{expert_id}/search-company":{"put":{"tags":["admin"],"summary":"Update Expert Search Company","description":"Replace a specific searched company link for an expert in a project","operationId":"update_expert_search_company_admin_projects__project_id__experts__expert_id__search_company_put","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin"],"summary":"Delete Expert Search Company","description":"Remove a searched company link for an expert in a project","operationId":"delete_expert_search_company_admin_projects__project_id__experts__expert_id__search_company_delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Add Expert Search Company","description":"Add an additional searched company link for an expert in a project","operationId":"add_expert_search_company_admin_projects__project_id__experts__expert_id__search_company_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/clients/{user_id}/company-by-linkedin":{"put":{"tags":["admin"],"summary":"Assign User To Company By Linkedin","description":"Create company from LinkedIn data (if needed) and assign user to it","operationId":"assign_user_to_company_by_linkedin_admin_clients__user_id__company_by_linkedin_put","parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"company_linkedin_id","in":"query","required":true,"schema":{"type":"string","title":"Company Linkedin Id"}},{"name":"company_name","in":"query","required":true,"schema":{"type":"string","title":"Company Name"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/kpis":{"get":{"tags":["admin"],"summary":"Get Kpis","description":"Get KPI metrics for admin dashboard","operationId":"get_kpis_admin_kpis_get","parameters":[{"name":"date_from","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Date From"}},{"name":"date_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Date To"}},{"name":"company_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"}},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},{"name":"client_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Type"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/KPIResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/kpis/monthly-trend":{"get":{"tags":["admin"],"summary":"Get Monthly Kpi Trend","description":"Monthly interview count + revenue trend vs targets (not affected by filters)","operationId":"get_monthly_kpi_trend_admin_kpis_monthly_trend_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/kpis/sourcing-comparison":{"get":{"tags":["admin"],"summary":"Get Sourcing Comparison","description":"Compare sourcing performance: Agent vs each human admin.","operationId":"get_sourcing_comparison_admin_kpis_sourcing_comparison_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/interviews/upcoming":{"get":{"tags":["admin"],"summary":"Upcoming Interviews","description":"Scheduled interviews with scheduled_at in [from, to] (ISO) — drives the\nnotification dock's Interviews agenda (Today / This Week / This Month). The FE\nsends local-time window bounds and buckets client-side. Admin-only; column-\nprojected + LIMIT to keep egress bounded (CLAUDE.md). CANCELED excluded.","operationId":"upcoming_interviews_admin_interviews_upcoming_get","parameters":[{"name":"from","in":"query","required":true,"schema":{"type":"string","title":"From"}},{"name":"to","in":"query","required":true,"schema":{"type":"string","title":"To"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/interviews":{"get":{"tags":["admin"],"summary":"List All Interviews","description":"List interviews for admin, paginated with server-side filters.\n\nReturns { items, total, companies, projects, statuses }. The facet lists keep\nthe filter dropdowns populated now that the page pages results instead of\nloading every interview. One row per (interview, expert). Per-row pricing /\npayment-info / client-company are batch-loaded for the page (was N+1).","operationId":"list_all_interviews_admin_interviews_get","parameters":[{"name":"payment","in":"query","required":false,"schema":{"type":"string","default":"all","title":"Payment"}},{"name":"company","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"}},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"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"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/slot-requests":{"get":{"tags":["admin"],"summary":"List Slot Requests","description":"List slot requests (admin only).\n\nReturns *every* row that has had a request — open AND resolved — so the\nadmin gets an audit trail. `status` filter lets the UI flip between\nOpen / Resolved / All without re-shaping the response.\n\nEach row carries `resolved_at` (nullable) so the page can render the\ncorrect badge and show how long it took to fulfill.","operationId":"list_slot_requests_admin_slot_requests_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","description":"open | resolved | all","default":"all","title":"Status"},"description":"open | resolved | all"},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/slot-requests/{peu_id}/resolve":{"post":{"tags":["admin"],"summary":"Resolve Slot Request","description":"Manually mark a slot request resolved (e.g. admin handled it out-of-band).\n\nPosting with no body just stamps `more_slots_resolved_at = now()`. Re-\nposting on an already-resolved row is a no-op. Use the unresolve\nendpoint to flip back.","operationId":"resolve_slot_request_admin_slot_requests__peu_id__resolve_post","parameters":[{"name":"peu_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Peu Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/slot-requests/{peu_id}/unresolve":{"post":{"tags":["admin"],"summary":"Unresolve Slot Request","description":"Flip a previously-resolved slot request back to open (admin tool).","operationId":"unresolve_slot_request_admin_slot_requests__peu_id__unresolve_post","parameters":[{"name":"peu_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Peu Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/interviews/{interview_id}/duration":{"put":{"tags":["admin"],"summary":"Update Interview Duration","description":"Update the manual duration override for an interview","operationId":"update_interview_duration_admin_interviews__interview_id__duration_put","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"manual_duration_minutes","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Manual Duration Minutes"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/interviews/{interview_id}/status":{"put":{"tags":["admin"],"summary":"Update Interview Status","description":"Manually set an interview's status — for calls the bot/Fireflies never\nsynced (e.g. the recording bot failed to join but the call happened). Setting\nCOMPLETED stamps completed_at (from scheduled_at, else now) if it's still\nempty. Optionally sets the manual duration override in the same call. Leaves\nexpert payment + client credits untouched — mirrors the zoom/bot webhook.","operationId":"update_interview_status_admin_interviews__interview_id__status_put","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"status","in":"query","required":true,"schema":{"type":"string","description":"New InterviewStatus, e.g. COMPLETED / NO_SHOW / CANCELED","title":"Status"},"description":"New InterviewStatus, e.g. COMPLETED / NO_SHOW / CANCELED"},{"name":"manual_duration_minutes","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Manual Duration Minutes"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/payments/{interview_id}/process":{"put":{"tags":["admin"],"summary":"Process Interview Payment","description":"Mark an interview's expert payment as processed","operationId":"process_interview_payment_admin_payments__interview_id__process_put","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminProcessPaymentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/payments/bulk-process":{"post":{"tags":["admin"],"summary":"Bulk Process Payments","description":"Mark many interview payouts PROCESSED in one transaction, each with its own\ncomputed amount/currency. Single commit; notifications fan out after.","operationId":"bulk_process_payments_admin_payments_bulk_process_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminBulkProcessPaymentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/referral-credits":{"get":{"tags":["admin"],"summary":"List Referral Credits","description":"Experts with a PENDING referral-credit balance — the standalone-payout view\n(credit with no upcoming interview to ride). Empty when nobody has any, so the\nadmin section stays hidden until there's something to pay. Bounded queries.","operationId":"list_referral_credits_admin_referral_credits_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdminReferralCreditRow"},"title":"Response List Referral Credits Admin Referral Credits Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/referral-analytics":{"get":{"tags":["admin"],"summary":"Get Referral Analytics","description":"Referral-program analytics for the admin dashboard (balances, top referrers,\nconversion, VOID/fraud rate). Bounded aggregates.","operationId":"get_referral_analytics_admin_referral_analytics_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/referral-credits/{expert_id}/payout":{"post":{"tags":["admin"],"summary":"Payout Referral Credits","description":"Standalone payout of an expert's PENDING referral credits (the threshold\ncase — no interview to ride). Marks them PAID with paid_interview_id NULL.","operationId":"payout_referral_credits_admin_referral_credits__expert_id__payout_post","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/payment":{"get":{"tags":["admin"],"summary":"Get Expert Payment Admin","description":"Get expert's full (unmasked) payment information","operationId":"get_expert_payment_admin_admin_experts__expert_id__payment_get","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminExpertPaymentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["admin"],"summary":"Update Expert Payment Admin","description":"Update expert's payment information (admin)","operationId":"update_expert_payment_admin_admin_experts__expert_id__payment_put","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateExpertPaymentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminExpertPaymentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/payment/id-document":{"get":{"tags":["admin"],"summary":"Get Expert Id Document Admin","description":"Short-lived presigned URL to the expert's ID/passport scan (admin only).","operationId":"get_expert_id_document_admin_admin_experts__expert_id__payment_id_document_get","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/{expert_id}/payment/purge":{"post":{"tags":["admin"],"summary":"Purge Expert Payment Info Admin","description":"Manually delete one expert's payout PII (RRN/bank/ID doc) now. Refuses if the\nexpert still has an unpaid/in-flight payout (would strand them). Admin-initiated;\nignores the auto-purge grace window.","operationId":"purge_expert_payment_info_admin_admin_experts__expert_id__payment_purge_post","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/payments/purge-settled":{"post":{"tags":["admin"],"summary":"Purge Settled Payment Info Admin","description":"Bulk-delete payout PII for every expert who has info on file and NO unpaid/\nin-flight payout. Admin-initiated (e.g. right after the 세무사 files) — ignores the\nauto-purge grace window; still skips experts with an owed payout.","operationId":"purge_settled_payment_info_admin_admin_payments_purge_settled_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/search":{"get":{"tags":["admin"],"summary":"Search Experts","description":"Search existing experts by name, email, or LinkedIn URL.","operationId":"search_experts_admin_experts_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdminExpertSearchResult"},"title":"Response Search Experts Admin Experts Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/palette-search":{"get":{"tags":["admin"],"summary":"Palette Search","description":"Unified type-ahead for the Cmd/Ctrl-K command palette: experts + projects\nin ONE round-trip. Deliberately NOT built on /admin/projects (the heavy\nall-projects + 6-aggregate endpoint) — a per-keystroke palette must be cheap\non the small prod pool, so this is bounded (limit 8 each) and column-projected\n(only the fields the palette renders), per the repo egress rules.","operationId":"palette_search_admin_palette_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaletteSearchResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/create":{"post":{"tags":["admin"],"summary":"Create Expert","description":"Create a new expert from LinkedIn URL (standalone, not linked to a project).\nIf expert already exists with that LinkedIn URL, returns the existing one.","operationId":"create_expert_admin_experts_create_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/create-manual":{"post":{"tags":["admin"],"summary":"Create Expert Manual","description":"Create an expert with NO LinkedIn profile (referred by hand) and return the\nVY code (anon_code) to hand the client. The LinkedIn path (POST /experts/create)\ncan't be used here since it requires a profile URL to enrich.\n\nIdempotent-ish: a same-named, LinkedIn-less expert is returned instead of\nmaking a near-duplicate (repeated submits don't spam the table).","operationId":"create_expert_manual_admin_experts_create_manual_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateManualExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminCreateExpertResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}":{"delete":{"tags":["admin"],"summary":"Admin Delete Orphan Project","description":"Delete an empty orphan project created from the admin search flows.\n\nThe manual / LinkedIn search pages create a project to add experts into; if\nthe admin adds nothing (or the add step fails), it's left as an empty shell.\nThose pages call this to clean it up. GUARDED (shared with the client-side\nrollback): refuses 409 unless the project has 0 experts/outreach/requests/\ninterviews/candidates, so a populated project is never deleted — admin + client\nProjectUser rows cascade. Best-effort on the client: a 409 just means it was\npopulated and is correctly kept.","operationId":"admin_delete_orphan_project_admin_projects__project_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/clients":{"get":{"tags":["admin"],"summary":"List Project Clients","description":"List the CLIENT accounts assigned to a project.\n\nThese are the users who see the project in their dashboard (ProjectUser\nrows whose user is a CLIENT — admin members are excluded). Powers the\n\"Assigned clients\" control on the admin manage-project view.","operationId":"list_project_clients_admin_projects__project_id__clients_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdminClientUserResponse"},"title":"Response List Project Clients Admin Projects  Project Id  Clients Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Add Project Client","description":"Assign an existing CLIENT account to a project so it appears in that\nclient's dashboard. Idempotent — assigning an already-assigned client is a\nno-op that returns the client. Only CLIENT users can be assigned (this is\nthe \"showcase on the client side only when they have an account\" path).","operationId":"add_project_client_admin_projects__project_id__clients_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAddProjectClientRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminClientUserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/clients/{user_id}":{"delete":{"tags":["admin"],"summary":"Remove Project Client","description":"Un-assign a client from a project (removes their ProjectUser row) so the\nproject no longer shows in their dashboard. No-op if not assigned.","operationId":"remove_project_client_admin_projects__project_id__clients__user_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/experts/{expert_id}":{"delete":{"tags":["admin"],"summary":"Remove Expert From Project","description":"Detach a single expert from a project (undo a mis-add) without touching\nthe expert elsewhere — the scoped alternative to the global blacklist, which\nremoves an expert from EVERY client's project.\n\nDeletes the `ProjectExpert` (its vetting questions/answers + guidelines\ncascade at the ORM level) plus the sibling rows keyed by (project, expert):\noutreach `ProjectExpertUser`, target-company annotations, client reactions,\nand any expert share links. Blocked when the expert has a live (non-canceled)\ninterview in this project — cancel it first. Sourcing history (AgentCandidate,\nInMailSendLog) is intentionally left as an audit trail.","operationId":"remove_expert_from_project_admin_projects__project_id__experts__expert_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/add-expert":{"post":{"tags":["admin"],"summary":"Add Expert To Project","description":"Add an expert to a project.\nProvide either expert_id (existing) or linkedin_url (lookup / create).","operationId":"add_expert_to_project_admin_projects__project_id__add_expert_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAddExpertRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAddExpertResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/experts/check-existing":{"post":{"tags":["admin"],"summary":"Check Existing Experts","description":"Pre-add dedup for the manual URL-paste flow. Given LinkedIn URLs (+ optional\nproject_id), report which already exist as experts, are already ON this project,\nor have already been CONTACTED on it — so an admin doesn't spend a multi-second\nadd re-adding someone. Reuses the SAME normalize_linkedin_url the add path dedups\non, so a \"new\" verdict here can't silently miss a real duplicate.\n\nBody: { urls: [str], project_id?: UUID }. Bounded, batched, column-projected.","operationId":"check_existing_experts_admin_experts_check_existing_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/linkedin-search/accounts":{"get":{"tags":["admin"],"summary":"Linkedin Search Accounts","description":"List selectable LinkedIn seats with per-account daily budget headroom.\n\nThe Sales Navigator seat is the default — it is idle for agent sourcing,\nso manual search there never competes with the agent's Recruiter seats.","operationId":"linkedin_search_accounts_admin_linkedin_search_accounts_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkedInSearchAccountsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/geographies/search":{"get":{"tags":["admin"],"summary":"Search Geographies Admin","description":"Search LinkedIn regions via Unipile (admin only) — geography autocomplete.","operationId":"search_geographies_admin_admin_geographies_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/linkedin-search/parameters":{"get":{"tags":["admin"],"summary":"Admin Linkedin Search Parameters","description":"Resolve filter values to Unipile IDs (SCHOOL, DEPARTMENT, INDUSTRY,\nJOB_TITLE, SKILL, DEGREE, SERVICE, GROUPS). Used by the admin LinkedIn-\nsearch page autocompletes for school / function / etc.","operationId":"admin_linkedin_search_parameters_admin_linkedin_search_parameters_get","parameters":[{"name":"type","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Type"}},{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/linkedin-search":{"post":{"tags":["admin"],"summary":"Admin Linkedin Search","description":"Run one page of a manual LinkedIn people search through Unipile.\n\nResults are NOT persisted — this is a live preview. An expert row is\ncreated only when the admin adds a result via /projects/{id}/add-expert.\nEach page fetched decrements the chosen seat's shared daily budget.","operationId":"admin_linkedin_search_admin_linkedin_search_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminLinkedInSearchRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminLinkedInSearchResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/linkedin-search/profile/{unipile_user_id}":{"get":{"tags":["admin"],"summary":"Admin Linkedin Search Profile","description":"Fetch the full LinkedIn profile for one manual-search result (preview).","operationId":"admin_linkedin_search_profile_admin_linkedin_search_profile__unipile_user_id__get","parameters":[{"name":"unipile_user_id","in":"path","required":true,"schema":{"type":"string","title":"Unipile User Id"}},{"name":"account_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkedInProfileResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/guidelines":{"get":{"tags":["admin"],"summary":"List Guidelines","description":"List all project experts that have guideline files uploaded","operationId":"list_guidelines_admin_guidelines_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminGuidelineListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/guidelines/{guideline_id}/sent":{"post":{"tags":["admin"],"summary":"Mark Guideline Sent","description":"Mark a single guideline file as sent to expert","operationId":"mark_guideline_sent_admin_guidelines__guideline_id__sent_post","parameters":[{"name":"guideline_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Guideline Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkGuidelineSentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/guidelines/{guideline_id}/unsent":{"post":{"tags":["admin"],"summary":"Mark Guideline Unsent","description":"Mark a single guideline file as unsent","operationId":"mark_guideline_unsent_admin_guidelines__guideline_id__unsent_post","parameters":[{"name":"guideline_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Guideline Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkGuidelineSentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/interviews/{interview_id}/sync":{"post":{"tags":["admin"],"summary":"Admin Sync Interview","description":"Admin: manually trigger Fireflies→CLOVA sync for a specific interview.\n\nRuns the fetch→transcribe→summarize→bill pipeline in the BACKGROUND and\nreturns immediately. Doing it inline blocked the request for 30-120s (CLOVA\ntranscription + summaries + translate), which the browser/ALB timed out as\n\"Failed to fetch\" — and an aborted request left the row wedged at\n\"processing\". The frontend shows the row as processing and picks up the\nresult on the next reload.","operationId":"admin_sync_interview_admin_interviews__interview_id__sync_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/interviews/{interview_id}/resend-expert-invite":{"post":{"tags":["admin"],"summary":"Resend Expert Invitation","description":"Admin: resend interview invitation email to the expert only.","operationId":"resend_expert_invitation_admin_interviews__interview_id__resend_expert_invite_post","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/interviews/{interview_id}/email-draft":{"get":{"tags":["admin"],"summary":"Get Interview Email Draft","description":"Admin: build a copy-pastable, Outlook-friendly draft of the interview\ninvitation (``{subject, html, text}``) so an admin can paste it into their\nown mailbox and send it with a personal note. The platform SENDS NOTHING.\n\nDefaults to the CLIENT-facing version (project title + expert anon code +\ndial-in). ``audience=expert`` omits project details. Passcode + dial-in\nnumbers aren't stored on the interview, so they're re-fetched live from Zoom.","operationId":"get_interview_email_draft_admin_interviews__interview_id__email_draft_get","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Interview Id"}},{"name":"audience","in":"query","required":false,"schema":{"type":"string","default":"client","title":"Audience"}},{"name":"language","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language"}},{"name":"timezone","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/agent":{"patch":{"tags":["admin"],"summary":"Update Agent Settings","description":"Pause/resume agent and set priority for a project.","operationId":"update_agent_settings_admin_projects__project_id__agent_patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentProjectSettingsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/agent-settings":{"get":{"tags":["admin"],"summary":"Get Agent Project Settings","description":"Settings + approved searches for ONE project. Used by the candidates\npage so it doesn't have to pull the whole `/admin/agent/projects` list.","operationId":"get_agent_project_settings_admin_projects__project_id__agent_settings_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/projects":{"get":{"tags":["admin"],"summary":"List Agent Projects","description":"List all projects with agent candidate counts.","operationId":"list_agent_projects_admin_agent_projects_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AgentProjectResponse"},"title":"Response List Agent Projects Admin Agent Projects Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/agent-candidates":{"get":{"tags":["admin"],"summary":"List Agent Candidates","description":"List agent-sourced candidates for a project.\n\nPagination: pass `limit` to get a bounded page back as an envelope\n``{\"items\": [...], \"total\": N}`` — the frontend fetches pages in sequence\nand accumulates them, so no single request loads (and serializes the\nwork-history join for) hundreds of candidates at once and trips the 15s\nclient timeout. `total` counts all candidates matching the status filter so\nthe client knows when it has them all. Without `limit` the endpoint returns\nthe bare list unchanged (backward-compatible with the pre-pagination UI).","operationId":"list_agent_candidates_admin_projects__project_id__agent_candidates_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"limit","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":500,"minimum":1},{"type":"null"}],"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent-candidates/pending":{"get":{"tags":["admin"],"summary":"List Pending Agent Candidates Global","description":"Cross-project PENDING candidate stream (F6) — one keyboard triage queue\nspanning every project, so the admin clears the global Gate-D backlog in one\nsitting instead of opening each project's page.\n\n`project_ids` (optional) scopes the queue to specific projects so a picked\nproject's FULL pending set surfaces (not just whatever lands in the global\nscore-desc top page). Target-company filtering is done client-side over the\nreturned rows' `search_companies`.\n\nBOUNDED on purpose: hard-capped page (<=200), score-desc + id tiebreak, and\nthe same column-projected / batched enrichment as the per-project endpoint\n(no SELECT * over Expert, one work-history join). Returns the same\nAgentCandidateResponse shape (+ project_title) so the FE reuses the row.","operationId":"list_pending_agent_candidates_global_admin_agent_candidates_pending_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"project_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated project UUIDs to scope the queue to (default: all projects)","title":"Project Ids"},"description":"Comma-separated project UUIDs to scope the queue to (default: all projects)"},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent-candidates/{candidate_id}/review":{"post":{"tags":["admin"],"summary":"Review Agent Candidate","description":"Approve or reject an agent candidate.","operationId":"review_agent_candidate_admin_agent_candidates__candidate_id__review_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentReviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent-candidates/{candidate_id}/reason":{"post":{"tags":["admin"],"summary":"Stamp Agent Candidate Reason","description":"Attach/replace the ANALYSIS-ONLY reject reason on an already-reviewed\ncandidate WITHOUT touching its status or feedback label.\n\nWhy a separate endpoint: the fast one-key reject stays one key (triage speed),\nand the follow-up toast captures the \"why\" in one tap by calling this. That is\nhow the reason signal actually gets populated — it was ~0% precisely because\nthe fast reject path skipped it, and re-POSTing /review would re-stamp the NEG\nfeedback label (double signal). stamp_reason is analysis-only, never read by\nthe scorer/few-shot, so this can't perturb scoring.","operationId":"stamp_agent_candidate_reason_admin_agent_candidates__candidate_id__reason_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentReasonRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent-candidates/bulk-review":{"post":{"tags":["admin"],"summary":"Bulk Review Agent Candidates","description":"Bulk approve or reject agent candidates.\n\nApprovals are batched: all dependent rows are pre-fetched once, then each\ncandidate is promoted inside its own SAVEPOINT (db.begin_nested) so a single\ncandidate's failure rolls back only that candidate while the rest still\npersist on the single outer commit. This preserves the per-candidate skip\nreporting the UI relies on while fixing the old per-iteration-commit path,\nwhich left candidates 1..N-1 permanently committed if candidate N failed.","operationId":"bulk_review_agent_candidates_admin_agent_candidates_bulk_review_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentBulkReviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/audit-log":{"get":{"tags":["admin"],"summary":"List Audit Log","description":"Admin audit trail — who did what, when. Filter by entity (the common\n'history for this candidate/request' lookup), action, or admin. Newest first.\n\nEnriches each row with the acting admin's name/email (best-effort) so the UI\ndoesn't have to resolve ids.","operationId":"list_audit_log_admin_audit_log_get","parameters":[{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"}},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"}},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"}},{"name":"admin_user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Admin User Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/status":{"get":{"tags":["admin"],"summary":"Get Agent Status","description":"Get agent dashboard status.\n\nState is derived from the DB (agent_state), NOT the web tier's in-memory\nsourcing_agent. The agent runs ONLY on the worker tier, so the web instance\nis permanently _running=False / not-paused — which is exactly why the panel\nshowed \"stopped + Pause\" no matter the real state. The worker pings\nlast_heartbeat every loop iteration (even while paused), so a fresh heartbeat\nmeans the loop is alive; paused_at is the live pause state both tiers share.","operationId":"get_agent_status_admin_agent_status_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/seat":{"patch":{"tags":["admin"],"summary":"Set Agent Seat","description":"Pin which Recruiter seat the sourcing agent should prefer.\n\nbody: {\"seat\": \"agent\" | \"recruiter\" | null}. null/\"\" = automatic (env\npriority, else round-robin). The pinned seat is drained first but is still\nfailed over when it's in cooldown (429/seat-busy), so pinning never strands\nsourcing on a throttled account.","operationId":"set_agent_seat_admin_agent_seat_patch","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/bandit-report":{"get":{"tags":["admin"],"summary":"Get Bandit Report","description":"F11: keyword-combination bandit visibility. Read-only snapshot of the\ntime-decayed AgentKeywordStat ledger the combo-picker Thompson-samples from —\nwhich role/skill keywords are earning approvals vs getting rejected — plus the\ncurrent serving mode (off / shadow / live). Lets an admin watch the bandit in\nSHADOW and decide whether to flip it live. Bounded: the keyword ledger is one\nrow per normalized keyword.","operationId":"get_bandit_report_admin_agent_bandit_report_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/scoring-calibration":{"get":{"tags":["admin"],"summary":"Get Scoring Calibration","description":"READ-ONLY score↔approval calibration for the admin panel: does the sourcing score\npredict admin approval? Returns the same report as scripts/score_calibration_report.py\nplus a biggest-disagreements list (high-score-but-rejected / low-score-but-approved) for\nadmins to eyeball. Bounded, expert-side reads only; result is memoized briefly.","operationId":"get_scoring_calibration_admin_agent_scoring_calibration_get","parameters":[{"name":"rubric_version","in":"query","required":false,"schema":{"type":"string","default":"v2","title":"Rubric Version"}},{"name":"staged_after","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Staged After"}},{"name":"staged_before","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Staged Before"}},{"name":"bins","in":"query","required":false,"schema":{"type":"integer","maximum":20,"minimum":2,"default":5,"title":"Bins"}},{"name":"exclude_blacklist","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Exclude Blacklist"}},{"name":"by_project","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"By Project"}},{"name":"denoise","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Denoise"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/response-calibration":{"get":{"tags":["admin"],"summary":"Get Response Calibration","description":"READ-ONLY response-likelihood ↔ actual-reply calibration (Phase 1 of self-learning). Does the\nreply heuristic rank people who ACTUALLY replied above those who didn't (reply-AUC + cluster-\nbootstrap CI), how calibrated is it (reliability curve), and what is the learned per-bucket reply\nbelief the served score would shrink toward once RESPONSE_LIKELIHOOD_LEARN_ENABLED is on? Bounded,\nexpert-side reads (no message bodies / requester identity); memoized briefly.","operationId":"get_response_calibration_admin_agent_response_calibration_get","parameters":[{"name":"lookback_days","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Lookback Days"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/manual-add-learning":{"get":{"tags":["admin"],"summary":"Get Manual Add Learning","description":"READ-ONLY \"what is the sourcing agent MISSING?\" report (Phase 2 of learn-from-\nmanual-adds). Each manual add is a recall miss; this diffs the admin's actual manual\nLinkedIn filter set against the request into a LEVER vector (drop-company, widen-geo,\nAND→OR, …) and reports the lever frequencies per-project / global, plus WHO the added\nexperts are and WHY. Global scope is lever-SHAPE only (no company names). Nothing\nchanges sourcing — Phase 3 reads this (via build_manual_add_serving_state) and\nadditionally gates on not degrading approval rate. Bounded reads; memoized briefly.","operationId":"get_manual_add_learning_admin_agent_manual_add_learning_get","parameters":[{"name":"lookback_days","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Lookback Days"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/operator-parity":{"get":{"tags":["admin"],"summary":"Get Operator Parity","description":"READ-ONLY per-operator outreach funnel (contact→reply→scheduled→interviewed) with 90% Wilson\nCIs, for the admin parity panel — the outcome half of the \"does the system work with anyone\noperating it\" question. Same numbers as scripts/operator_funnel_report.py: lay a new hire's row\nbeside an experienced admin's and check the novice's rates fall inside the CI band. Bounded,\nexpert-side reads (no message bodies / requester identity); memoized briefly.","operationId":"get_operator_parity_admin_agent_operator_parity_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Days"}},{"name":"min_contacts","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":5,"title":"Min Contacts"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent-candidates/{candidate_id}/trial-review":{"post":{"tags":["admin"],"summary":"Trial Review Agent Candidate","description":"Record a BLINDED, off-queue approve/reject for the operator-parity experiment (Phase 3C).\n\nWrites ONLY agent_review_trial — the live AgentCandidate.status is NOT touched — so a new hire\nand an experienced admin can independently review the SAME candidates under a shared `trial_id`,\nand we then measure their Cohen's kappa (GET /agent/trial-agreement). One decision per\n(trial_id, candidate, reviewer); re-submitting updates it.","operationId":"trial_review_agent_candidate_admin_agent_candidates__candidate_id__trial_review_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrialReviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/trial-agreement":{"get":{"tags":["admin"],"summary":"Get Trial Agreement","description":"READ-ONLY Cohen's kappa between reviewers on a blinded trial (Phase 3C). Same numbers as\nscripts/blinded_agreement_report.py — novice ≈ expert when kappa is 'substantial' (>=0.6)+.","operationId":"get_trial_agreement_admin_agent_trial_agreement_get","parameters":[{"name":"trial_id","in":"query","required":true,"schema":{"type":"string","title":"Trial Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/pause":{"post":{"tags":["admin"],"summary":"Pause Agent","description":"Pause the agent globally (admin can use the LinkedIn account manually).","operationId":"pause_agent_admin_agent_pause_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/resume":{"post":{"tags":["admin"],"summary":"Resume Agent","description":"Resume the agent after an admin pause.","operationId":"resume_agent_admin_agent_resume_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/agent/reset-budget":{"post":{"tags":["admin"],"summary":"Reset Agent Budget","description":"Reset the agent's daily budget counter so it runs again today.","operationId":"reset_agent_budget_admin_agent_reset_budget_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/linkedin-accounts":{"get":{"tags":["admin"],"summary":"Get Linkedin Accounts","description":"Get current LinkedIn account IDs from AWS Secrets Manager (real-time).","operationId":"get_linkedin_accounts_admin_linkedin_accounts_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["admin"],"summary":"Update Linkedin Accounts","description":"Update LinkedIn account IDs in AWS Secrets Manager and hot-reload in memory.\n\nBody (all optional — only provided fields are updated):\n{\n    \"client_recruiter\": \"new_account_id\",\n    \"client_sales_navigator\": \"new_account_id\",\n    \"agent\": \"new_account_id\",\n    \"daye\": \"new_account_id\"\n}","operationId":"update_linkedin_accounts_admin_linkedin_accounts_put","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/ens-emails":{"get":{"tags":["admin"],"summary":"List Ens Emails","description":"List all inbound ENS emails with filtering.","operationId":"list_ens_emails_admin_ens_emails_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/ens-emails/{email_id}":{"get":{"tags":["admin"],"summary":"Get Ens Email Detail","description":"View single ENS email details including parsed data and raw body.","operationId":"get_ens_email_detail_admin_ens_emails__email_id__get","parameters":[{"name":"email_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Email Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/ens-emails/{email_id}/reprocess":{"post":{"tags":["admin"],"summary":"Reprocess Ens Email","description":"Re-trigger processing for a failed ENS email.","operationId":"reprocess_ens_email_admin_ens_emails__email_id__reprocess_post","parameters":[{"name":"email_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Email Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/ens-pricing":{"get":{"tags":["admin"],"summary":"Get Project Ens Pricing","description":"View all ENS pricing tags for a project's experts.","operationId":"get_project_ens_pricing_admin_projects__project_id__ens_pricing_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/accounts":{"get":{"tags":["admin"],"summary":"Get Inmail Accounts","description":"Return the 3 LinkedIn accounts with their current InMail credit balances.\n\nDeclared as sync `def` (NOT `async def`) ON PURPOSE: it makes up to 3\n*blocking* Unipile HTTP calls (unipile_client.get_account_credits) and is\npolled ~every 60s by the admin chat panel. As an async handler those blocking\ncalls ran on the event loop and froze ALL request handling on the single web\nworker for the duration of the (often slow/flaky) Unipile round-trips —\nstalling every other endpoint. A sync def runs in Starlette's threadpool, so\nthe event loop stays free. Per-seat balances are TTL-cached via\nget_account_credits_cached (UNIPILE_INMAIL_ACCOUNTS_TTL_S, kept above the poll\ninterval) so steady polls return from cache without hammering Unipile.","operationId":"get_inmail_accounts_admin_inmail_accounts_get","parameters":[{"name":"credits","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Credits"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InMailAccountsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/credit-efficiency":{"get":{"tags":["admin"],"summary":"Get Inmail Credit Efficiency","description":"Per-seat outreach ROI: credits spent (InMails sent) vs replies earned, over\nthe last `days` (default = the credit refund window). A low reply_rate is the\n'you're burning credits on no-reply sends — fix targeting before topping up'\nsignal, shown on the dock credits sub-tab.\n\nFetched ON DEMAND when the credits tab opens — NOT on the 60s poll — and uses\ntwo bounded grouped aggregates (func.count over an indexed chat_id join), so it\nstays well within the Supabase connection ceiling. Note: a no-reply send inside\nthe refund window may still earn a refund if the expert replies later, so very\nrecent sends slightly understate the true reply_rate.","operationId":"get_inmail_credit_efficiency_admin_inmail_credit_efficiency_get","parameters":[{"name":"days","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InMailEfficiencyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/unipile/accounts/status":{"get":{"tags":["admin"],"summary":"Get Unipile Accounts Status","description":"Live connection state for each LinkedIn account, straight from Unipile.\n\nThis is the authoritative source — unlike the Unipile dashboard (cached /\npolled) or the inbox thread list (rendered from our own DB cache). Use it\nto confirm whether a send failure is a disconnected account vs. something\nelse. `connected: false` with a non-OK source status means the account\nneeds reconnecting.","operationId":"get_unipile_accounts_status_admin_unipile_accounts_status_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/unipile/accounts/{account_id}/reconnect-link":{"post":{"tags":["admin"],"summary":"Create Unipile Reconnect Link","description":"Generate a Unipile Hosted Auth URL to reconnect a disconnected account.\n\nReconnection cannot be fully automated — LinkedIn requires an interactive\nlogin (and usually a checkpoint/MFA). This returns a one-time link an\nadmin opens to complete the login; Unipile then restores the session\nunder the same account_id, with no config change needed on our side.","operationId":"create_unipile_reconnect_link_admin_unipile_accounts__account_id__reconnect_link_post","parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","title":"Account Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/ops":{"get":{"tags":["admin"],"summary":"Ops Health","description":"One 'is the system OK right now?' panel. CHEAP BY DESIGN — in-process pool\nstats + two small reads, NO Unipile calls — so monitoring never loads the\nthing being monitored. It surfaces the one signal nothing else showed: DB pool\nsaturation (the tiny prod pool has frozen the whole panel ~20s before).\n\nDB-pool numbers are for THIS web instance only (the web tier runs >1 task) and\ninclude the connection this very request holds.","operationId":"ops_health_admin_ops_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/templates":{"get":{"tags":["admin"],"summary":"List Inmail Templates","description":"List expert-outreach message templates. Composer pickers get active-only;\nthe template manager passes include_inactive=true.","operationId":"list_inmail_templates_admin_inmail_templates_get","parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Create Inmail Template","operationId":"create_inmail_template_admin_inmail_templates_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InmailTemplateCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/templates/{template_id}":{"patch":{"tags":["admin"],"summary":"Update Inmail Template","operationId":"update_inmail_template_admin_inmail_templates__template_id__patch","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InmailTemplateUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin"],"summary":"Delete Inmail Template","description":"Delete a template. If it's a built-in key it will be re-seeded on next\naccess; disable (is_active=false) instead to keep it hidden permanently.","operationId":"delete_inmail_template_admin_inmail_templates__template_id__delete","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/qa/tickets":{"get":{"tags":["admin"],"summary":"List Qa Tickets","description":"Admin bug board. Optional status/category filters; newest first.","operationId":"list_qa_tickets_admin_qa_tickets_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Create Qa Ticket","operationId":"create_qa_ticket_admin_qa_tickets_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QaTicketCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/qa/tickets/{ticket_id}":{"get":{"tags":["admin"],"summary":"Get Qa Ticket","operationId":"get_qa_ticket_admin_qa_tickets__ticket_id__get","parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["admin"],"summary":"Update Qa Ticket","operationId":"update_qa_ticket_admin_qa_tickets__ticket_id__patch","parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QaTicketUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin"],"summary":"Delete Qa Ticket","description":"Delete a ticket. v1 leaves any S3 screenshots as orphans (best-effort cleanup later).","operationId":"delete_qa_ticket_admin_qa_tickets__ticket_id__delete","parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/qa/attachments":{"post":{"tags":["admin"],"summary":"Upload Qa Attachment","description":"Upload one screenshot to private S3 (while composing, before the ticket exists).\nReturns the ref to include in the ticket's `attachments` on the next create/patch.","operationId":"upload_qa_attachment_admin_qa_attachments_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_qa_attachment_admin_qa_attachments_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/qa/tickets/{ticket_id}/attachments/presign":{"post":{"tags":["admin"],"summary":"Presign Qa Attachment","description":"Short-lived presigned GET URL for one of a ticket's screenshots. Guards that\nthe key actually belongs to this ticket before signing.","operationId":"presign_qa_attachment_admin_qa_tickets__ticket_id__attachments_presign_post","parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QaPresignIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/qa/tickets/{ticket_id}/comments":{"get":{"tags":["admin"],"summary":"List Qa Comments","operationId":"list_qa_comments_admin_qa_tickets__ticket_id__comments_get","parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Create Qa Comment","description":"Add a comment to a ticket's thread. Admins post with the defaults; the QA/QC\ntriage agent posts its verdict with author_kind='agent' + verdict.","operationId":"create_qa_comment_admin_qa_tickets__ticket_id__comments_post","parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QaCommentCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/qa/comments/{comment_id}":{"delete":{"tags":["admin"],"summary":"Delete Qa Comment","operationId":"delete_qa_comment_admin_qa_comments__comment_id__delete","parameters":[{"name":"comment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Comment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/generate":{"post":{"tags":["admin"],"summary":"Generate Inmail Message","description":"Auto-generate an InMail message for an expert based on communication templates.","operationId":"generate_inmail_message_admin_inmail_generate_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateInMailRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateInMailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/send":{"post":{"tags":["admin"],"summary":"Send Inmail","description":"Send an InMail to an expert via Unipile.","operationId":"send_inmail_admin_inmail_send_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendInMailRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendInMailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/preview":{"post":{"tags":["admin"],"summary":"Bulk Inmail Preview","description":"Resolve per-expert variables + a rendered preview for a bulk InMail send.\nRead-only (no Unipile, no writes). Capped so the synchronous per-expert\nrendering stays under the ALB idle timeout.","operationId":"bulk_inmail_preview_admin_inmail_bulk_preview_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInMailPreviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInMailPreviewResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/send":{"post":{"tags":["admin"],"summary":"Bulk Inmail Send","description":"Enqueue a bulk InMail batch. Renders + SNAPSHOTS each expert's final\nmessage now (exactly what the admin approved); the worker sends the pending\nitems one-by-one. Insert-only — no Unipile here.","operationId":"bulk_inmail_send_admin_inmail_bulk_send_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInMailSendRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInMailSendResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk":{"get":{"tags":["admin"],"summary":"List Bulk Outreach Batches","description":"Recent bulk batches, newest first.\n\nExists because the composer held `batch_id` in component state only: close\nthe modal and the id was gone, and with no list route the batch — including\nwhich experts it never reached — was unrecoverable. That matters most on the\nabort path: a seat that disconnects mid-batch leaves every remaining item\n'pending' forever, so those experts were never contacted and nobody could\nfind out who they were.\n\nHeader columns only (`load_only`, no items, no Expert join) per the egress\nrule — drill into /inmail/bulk/{batch_id} for names.","operationId":"list_bulk_outreach_batches_admin_inmail_bulk_get","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":20,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BulkOutreachBatchSummary"},"title":"Response List Bulk Outreach Batches Admin Inmail Bulk Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/failed":{"get":{"tags":["admin"],"summary":"List Failed Bulk Items","description":"Failed bulk-InMail items across all batches (newest first). Bounded; returns\nmetadata + a short body preview, not the full snapshot (read on retry).","operationId":"list_failed_bulk_items_admin_inmail_bulk_failed_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"default":200,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/failed/retry":{"post":{"tags":["admin"],"summary":"Retry Failed Bulk Items","description":"Retry failed first-outreach items by queuing each as a scheduled\nlinkedin_inmail on its ORIGINAL seat (verbatim snapshot keeps the signature\ncorrect). send_at blank => now (fires next drainer tick, self-staggered per\nseat); else reschedule. The source item is marked 'dismissed' so it leaves the\nfailed list — its retry now lives as a scheduled_message. Needs the scheduler.","operationId":"retry_failed_bulk_items_admin_inmail_bulk_failed_retry_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkFailedRetryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/failed/dismiss":{"post":{"tags":["admin"],"summary":"Dismiss Failed Bulk Items","description":"Dismiss failed bulk-InMail items — mark them 'dismissed' so they leave the\nfailed list. Terminal; the worker never touches a dismissed item.","operationId":"dismiss_failed_bulk_items_admin_inmail_bulk_failed_dismiss_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkFailedIdsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/{batch_id}":{"get":{"tags":["admin"],"summary":"Get Bulk Outreach Batch","description":"Batch status + per-expert send state, for the composer's progress bar.","operationId":"get_bulk_outreach_batch_admin_inmail_bulk__batch_id__get","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Batch Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkOutreachBatchStatus"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/{batch_id}/cancel":{"post":{"tags":["admin"],"summary":"Cancel Bulk Outreach Batch","description":"Request cancellation. The worker checks control.cancel between items, so\nalready-sent items stay sent; remaining pending items won't dispatch.","operationId":"cancel_bulk_outreach_batch_admin_inmail_bulk__batch_id__cancel_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Batch Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/{batch_id}/resume":{"post":{"tags":["admin"],"summary":"Resume Bulk Outreach Batch","description":"Resume a batch that ERRORED (typically the seat dropped mid-run). Without\nthis, the remaining experts stay 'pending' forever and the only way to finish\nwas to re-select everyone into a NEW batch — which risks double-messaging the\nones already sent. Flipping the batch back to 'queued' lets the drainer pick\nit up and send ONLY the still-'pending' items; already-'sent' items are\nskipped automatically. The item that failed at the disconnect never actually\nsent (the send raised before delivering), so it is re-queued too.","operationId":"resume_bulk_outreach_batch_admin_inmail_bulk__batch_id__resume_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Batch Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/bulk/{batch_id}/retry-failed":{"post":{"tags":["admin"],"summary":"Retry Failed Bulk Outreach","description":"'Second try' — clone the FAILED items of a settled batch into a NEW batch\non a (usually different) seat. A resource-restricted refusal is per-seat\n(network distance / product scope), so a broader-reach seat can land some of\nthem. A new batch rather than in-place re-queue keeps the audit honest: the\nalready-sent items went out from the original seat, these go from the new one.\n\nRe-renders (not verbatim copy): {{signature}} and the sender name are derived\nfrom the seat in _resolve_common_context, so a different seat MUST get its own\nidentity — copying the old snapshot would sign the message as the wrong person\n(and skip the recruiter-seat footer handling). Everything else is reproduced\nfrom the batch's template + the item's stored grid variables, so the expert-\nfacing copy is unchanged. Skipped items (blacklist / no-LinkedIn) are NOT\nretried — a different seat can't fix those.","operationId":"retry_failed_bulk_outreach_admin_inmail_bulk__batch_id__retry_failed_post","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Batch Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInMailRetryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkInMailSendResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inmail/send-email":{"post":{"tags":["admin"],"summary":"Send Email To Expert","description":"Send an email to an expert via Resend with a custom sender address.","operationId":"send_email_to_expert_admin_inmail_send_email_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendEmailRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendEmailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/client-users":{"get":{"tags":["admin"],"summary":"List Project Client Users","description":"Client (user_type=CLIENT) members of a project, with company context.\n\nPowers the \"Generate client email\" modal's recipient picker. Unlike the\nclient-facing GET /projects/{id}/users, this filters to clients and includes\ncompany info.","operationId":"list_project_client_users_admin_projects__project_id__client_users_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/share-experts-draft":{"post":{"tags":["admin"],"summary":"Generate Expert Share Draft","description":"Create a public share link per selected expert and return ONE copy-pastable\nemail draft (HTML + plain text). The platform SENDS NOTHING — the admin pastes\nthe draft into their own mailbox. The ExpertShareLink rows are the audit trail.","operationId":"generate_expert_share_draft_admin_projects__project_id__share_experts_draft_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShareExpertsDraftRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/share-experts-draft/regenerate-section":{"post":{"tags":["admin"],"summary":"Regenerate Share Draft Section","description":"Regenerate ONE expert's why_match and return that expert's re-rendered draft\nsection, so the admin can refresh a single card in the client-email draft without\nrebuilding the whole email (and losing edits to the other blocks).\n\nBody: {\"expert_id\": \"<uuid>\", \"language\"?: \"en\"|\"ko\", \"timezone\"?: \"<IANA>\",\n       \"focus_hint\"?: \"<free-text>\"}. Reuses the expert's existing share link.","operationId":"regenerate_share_draft_section_admin_projects__project_id__share_experts_draft_regenerate_section_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/client-email-senders":{"get":{"tags":["admin"],"summary":"List Client Email Senders","description":"The allowed 'send as' accounts for the client email (name + address).\nEmpty when direct-send is off — the modal then shows copy-paste only.","operationId":"list_client_email_senders_admin_client_email_senders_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/send-experts-email":{"post":{"tags":["admin"],"summary":"Send Experts Email","description":"Send the (already generated + edited) client expert-profile email directly\nvia Resend, FROM the admin-chosen veyond.ai account (so replies land there — no\nnoreply). The share links live in the HTML already (created at draft time).","operationId":"send_experts_email_admin_projects__project_id__send_experts_email_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendExpertsEmailRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendExpertsEmailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat/expert/{expert_id}":{"get":{"tags":["admin"],"summary":"Get Expert Chats","description":"Find all existing chat threads with an expert across all LinkedIn accounts.","operationId":"get_expert_chats_admin_chat_expert__expert_id__get","parameters":[{"name":"expert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Expert Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExpertChatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat/{chat_id}/messages":{"get":{"tags":["admin"],"summary":"Get Chat Messages","description":"Get message history for a chat.","operationId":"get_chat_messages_admin_chat__chat_id__messages_get","parameters":[{"name":"chat_id","in":"path","required":true,"schema":{"type":"string","title":"Chat Id"}},{"name":"account_id","in":"query","required":true,"schema":{"type":"string","title":"Account Id"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatMessagesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Send Chat Reply","description":"Send a reply (optionally with file attachments) AND persist it.\n\nAccepts multipart/form-data: `account_id` + `text` fields plus zero or\nmore `files`. Replies used to be sent to Unipile but never written to our\nDB, so the inbox would refresh and the reply would vanish (Unipile's\n`is_sender:true` echo is intentionally dropped by the webhook). We write\nthe reply to inmail_send_log on success — same table as the initial InMail\nsend, which is what the inbox messages endpoint already queries for\noutbound history. Attachment metadata (file_name/mime_type/size) is stored\nso the sent bubble shows what went out.","operationId":"send_chat_reply_admin_chat__chat_id__messages_post","parameters":[{"name":"chat_id","in":"path","required":true,"schema":{"type":"string","title":"Chat Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_send_chat_reply_admin_chat__chat_id__messages_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendChatMessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat/notifications":{"get":{"tags":["admin"],"summary":"Get Chat Notifications","description":"Get recent chats with unread counts across all LinkedIn accounts.\n\nSync `def` (NOT `async def`) ON PURPOSE: it calls the BLOCKING\nunipile_client.get_recent_chats() and is polled every 15s by the admin chat\npanel. As an async handler that blocking Unipile round-trip ran on the event\nloop and froze ALL request handling on the single web worker every 15s —\nthe dominant cause of the multi-second stalls across every endpoint. A sync\ndef runs in Starlette's threadpool so the event loop stays free.","operationId":"get_chat_notifications_admin_chat_notifications_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatNotificationsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests":{"get":{"tags":["admin"],"summary":"List Search Requests","description":"List client search submissions for admin review.\nstatus = pending|approved|rejected|all.\n\nPending hides rejected rows so they don't clutter the action queue.\nApproved hides rejected rows (a row can't be both, but be defensive).\nRejected returns only soft-rejected rows for the rejection-history view.\nAll returns everything including rejected so admins can audit the full flow.","operationId":"list_search_requests_admin_search_requests_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","pattern":"^(pending|approved|rejected|all)$","default":"pending","title":"Status"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/email-body":{"get":{"tags":["admin"],"summary":"Get Search Request Email Body","description":"Lazy-load the original inbound email body for one request.\n\nThe list endpoint defers raw_email_body (large, only viewed on demand via\nthe card's \"View original email\" expander) and returns a has_email_body\nflag instead — this serves the full body for a single row when opened.","operationId":"get_search_request_email_body_admin_search_requests__request_id__email_body_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/preview-count":{"post":{"tags":["admin"],"summary":"Preview Search Request Count","description":"Return the number of LinkedIn candidates matching this search request's\ncriteria + a candidate company. Lets admins pick the right Unipile company\nwhen the title-match is ambiguous.\n\nDB work runs in a short to_thread session that CLOSES before the Unipile\ncall, so no pooled connection is held across the slow round-trip (see\n_load_preview_inputs). Body: {\"unipile_id\": \"<id>\", \"raw\"?: bool}\n-> {\"count\", \"company_id\", \"raw\"}.\n\n`raw: true` returns the company-only headcount (drops roles + experience),\nso admins can see how much the filters narrow a company — lazily fetched on\nrow expand. Default (`raw` falsy) is the filtered count (company + roles +\nexperience), unchanged from before.","operationId":"preview_search_request_count_admin_search_requests__request_id__preview_count_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/reach-preview":{"get":{"tags":["admin"],"summary":"Reach Preview Search Request","description":"Per-company + per-keyword LinkedIn reach for a request, so admins see BEFORE\napproving whether the agent's query will find anyone. Read-only, count-only\n(limit=1), geo-filtered, on the off-agent seat with a seat-walk fallback.\n\nThe result is persisted on the request row (SearchHistory.reach_preview) keyed\nby a criteria hash, so once computed it's served from the DB for free — no seat\nwalks — until the companies/keywords/geography change (hash miss) or the admin\nforces a refresh (?refresh=true, the \"Check LinkedIn reach\" button). All Unipile\nwork runs off the event loop; the DB session closes before it.","operationId":"reach_preview_search_request_admin_search_requests__request_id__reach_preview_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"refresh","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Refresh"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReachPreviewResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/preview":{"post":{"tags":["admin"],"summary":"Preview Search Request Matches","description":"Combined orientation total + 5-10 sample profiles for the CURRENT (unsaved)\ncriteria, across all target companies. On-demand (admin clicks \"Preview\nmatches\") — never auto-fired, since it rides the scarce recruiter off-seat.\n\nReuses _load_preview_inputs only for auth + off-seat steering; the criteria\ncome from the body so the preview reflects unsaved edits. Cached by a hash of\nthe criteria. Strictly read-only — no records, no outreach.","operationId":"preview_search_request_matches_admin_search_requests__request_id__preview_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreviewMatchesRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreviewMatchesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/companies":{"get":{"tags":["admin"],"summary":"Get Search Request Companies","description":"Return one request's structured target companies (companies_data + display\nstring). Backs the mid-run Agent Sourcing hub company editor so admins get the\nsame pick-a-page-or-keyword control they have at intake.","operationId":"get_search_request_companies_admin_search_requests__request_id__companies_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/update-companies":{"post":{"tags":["admin"],"summary":"Update Search Request Companies","description":"Replace search_companies_data (admin enrichment with Unipile company IDs).\nFor an approved request this also reactivates sourcing so the edit takes\neffect on the next fetch cycle.","operationId":"update_search_request_companies_admin_search_requests__request_id__update_companies_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/add-companies":{"post":{"tags":["admin"],"summary":"Add Search Request Companies","description":"APPEND companies to a request without clobbering the existing list (which\nmay carry resolved Unipile IDs). Used when accepting company suggestions from\na surface that doesn't hold the full company list (the live sourcing hub).\nBody {\"companies\": [{\"title\", \"unipile_id\"?, \"type\"?, \"picture_url\"?}]}.\nDedupes by title (case-insensitive) and reactivates sourcing when approved.","operationId":"add_search_request_companies_admin_search_requests__request_id__add_companies_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/sourcing-mode":{"patch":{"tags":["admin"],"summary":"Patch Search Request Sourcing Mode","description":"Set a request's sourcing mode (changeable mid-run).\n\n  standard    → target companies + keyword combos (Phase A/B/C)\n  no_company  → keyword combos, but DROP the company filter\n  no_keywords → DROP keyword combos → Phase C (broad, role-based)\n  broad       → DROP both the company filter AND keywords (role/geo only)\n\nNon-destructive: search_companies / keyword sets / agent_combination_runs are\nleft intact — the mode only changes HOW the worker applies them, so flipping\nback to 'standard' restores full behavior. For an approved (non-rejected)\nrequest the switch reactivates sourcing (unpause + point active-search +\nforce-run + cap-lift) so it takes effect on the next worker poll (~1 min).\nEntering no_keywords/broad routes straight to phase_c_running — the combo\nbandit is bypassed in Phase C by design, same as an empty-keyword approval.\nGated by AGENT_SOURCING_MODE_ENABLED.","operationId":"patch_search_request_sourcing_mode_admin_search_requests__request_id__sourcing_mode_patch","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateSourcingModeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/keyword-combinator":{"patch":{"tags":["admin"],"summary":"Patch Search Request Keyword Combinator","description":"Flip a request's Phase A/B keyword combinator between AND (precise — each\ncombo's 1-2 keywords must all appear) and OR (broad, manual-search-like\nrecall), changeable mid-run. Non-destructive — keyword sets/combos are kept;\nonly how they're queried changes. For an approved (non-rejected) request,\nswitching re-queues the exhausted A/B combos (skip reset) and reactivates\nsourcing so the new combinator re-runs on the next worker poll. This is the\nmanual counterpart to the worker's niche AND→OR auto-fallback.","operationId":"patch_search_request_keyword_combinator_admin_search_requests__request_id__keyword_combinator_patch","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateKeywordCombinatorRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/company-keyword-combinator":{"patch":{"tags":["admin"],"summary":"Patch Search Request Company Keyword Combinator","description":"Flip a request's COMPANY↔keyword combinator between AND (default — target\ncompanies AND the keywords, today's behavior) and OR (union — anyone at ANY\ntarget company OR matching ANY keyword; company names are searched as keywords,\nresolved or not, so a resolved company loses its precise id-facet for breadth).\nOR recovers pools that AND zeroes out (niche companies not on LinkedIn + a niche\nkeyword). Non-destructive; for an approved (non-rejected) request it re-queues\nthe exhausted A/B combos (skip reset) and reactivates so the new mode re-runs on\nthe next worker poll. Mirrors patch_search_request_keyword_combinator.","operationId":"patch_search_request_company_keyword_combinator_admin_search_requests__request_id__company_keyword_combinator_patch","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateKeywordCombinatorRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}":{"patch":{"tags":["admin"],"summary":"Patch Search Request","description":"Admin edit of any subset of the client-submitted search criteria.\n\nAccepts any of: job_roles, industry, geography, employment_status,\nmin_experience, max_experience, target_interviews, verifying_questions.\nFields not in the payload are left untouched.","operationId":"patch_search_request_admin_search_requests__request_id__patch","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/archive-project":{"post":{"tags":["admin"],"summary":"Archive Search Request Project","description":"Admin 'Delete project' on a Search Request — archives the linked project\n(reversible, mirrors the client-side archive): hides it from active lists and\npauses agent sourcing so it stops spending budget. Deletes no history.","operationId":"archive_search_request_project_admin_search_requests__request_id__archive_project_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/approve":{"post":{"tags":["admin"],"summary":"Approve Search Request","description":"Approve a pending search request. Agent will pick it up on the next cycle.","operationId":"approve_search_request_admin_search_requests__request_id__approve_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/extend-sourcing":{"post":{"tags":["admin"],"summary":"Extend Search Request Sourcing","description":"Reset the per-request sourcing counter so the agent sources another\ncapped batch of profiles for this approved request. Admins call this once\nthey've reviewed the previous batch and want more candidates.\n\nOnly meaningful on approved (and non-rejected) requests; pending/rejected\nrows have nothing to source yet.","operationId":"extend_search_request_sourcing_admin_search_requests__request_id__extend_sourcing_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/rerun":{"post":{"tags":["admin"],"summary":"Rerun Search Request","description":"Re-source an already-approved request from scratch, in one click.\n\nEquivalent to Revert + Approve, but without bouncing the row through the\nPending tab — it stays approved. Combinations that previously ran to\nEXHAUSTED (e.g. because a seat was down and 0-results were mis-read as\n\"no candidates\") are wiped and re-materialized as fresh QUEUED, the phase\nis reset to phase_a_running, the per-request counter is zeroed, and the\nproject is unpaused + force-run so the agent picks it up within ~1 min.\n\nUse when a request hit `complete` (or stalled) and you want the agent to\ncover it again — typically after fixing whatever made the seats return 0.","operationId":"rerun_search_request_admin_search_requests__request_id__rerun_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/force-run":{"post":{"tags":["admin"],"summary":"Force Run Project","description":"Admin \"Run now\": force an immediate sourcing cycle for a project.\n\nStamps the cross-tier force-run flag the worker re-reads every cycle, so the\nproject jumps the round-robin and gets sourced on the next worker poll\n(≤ AGENT_CYCLE_DELAY_SECONDS, and back-to-back with no delay when several are\nqueued) instead of waiting its turn. Also unpauses the project — forcing a\nrun while paused is almost always a mistake.\n\nThe run still honors the per-request cap; if the active request is capped,\nuse Extend sourcing (which also forces a run) to unlock another batch.","operationId":"force_run_project_admin_projects__project_id__force_run_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/force-run":{"post":{"tags":["admin"],"summary":"Force Run Search Request","description":"Admin \"Run now\" for a specific approved request.\n\nPoints the agent at THIS request (agent_active_search_id override) and stamps\nthe cross-tier force-run flag so the worker sources it on the next poll\ninstead of waiting for the round-robin. Unpauses the project. Unlike Extend\nsourcing, this does NOT reset the per-request cap — it just runs now against\nwhatever budget the request has left. Returns capped=True when the request\nhas already hit the cap (the run will be a no-op until you Extend).","operationId":"force_run_search_request_admin_search_requests__request_id__force_run_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/revert":{"post":{"tags":["admin"],"summary":"Revert Search Request","description":"Undo approval of a search request — for accidental approvals.\n\nSends the row back to the pending queue so admins can edit and re-approve\nit (or reject it). The agent stops sourcing this specific request: if the\nproject's active_search_id pointed here, it's cleared (the agent falls back\nto the project's most-recent approved search). The project itself is\npaused so a half-reverted request doesn't keep burning Unipile budget on\na sibling search the admin didn't intend to run.","operationId":"revert_search_request_admin_search_requests__request_id__revert_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/assign-project":{"post":{"tags":["admin"],"summary":"Assign Search Request To Project","description":"Attach an email-sourced SearchHistory row to a project.\n\nBody: { mode: \"new\"|\"existing\", owner_user_id: UUID, title?: str, project_id?: UUID }\n\nAdmins act on behalf of the email sender. The chosen `owner_user_id` (a\nreal client user, picked by the admin from the user DB) becomes the\nproject's creator/participant via ProjectUser. Admins are NOT added to\nProjectUser — this is a facilitative action only.","operationId":"assign_search_request_to_project_admin_search_requests__request_id__assign_project_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/unassign":{"post":{"tags":["admin"],"summary":"Unassign Search Request","description":"Detach a search request from its project so it can be re-assigned (undo a\nwrong assign-project pick). Clears `project_id`/`user_id`; the row drops back\ninto the unassigned queue and the existing assign flow can re-run.\n\nBlocked once the request has SOURCED experts (ProjectExpert rows under it):\nthose live under the old project and moving only the request pointer would\nstrand them — that case needs a real migration, not a pointer flip.","operationId":"unassign_search_request_admin_search_requests__request_id__unassign_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/reject":{"post":{"tags":["admin"],"summary":"Reject Search Request","description":"Soft-reject a pending search request. The row is kept (with rejected_at\nset) so admins can see rejection history and unreject if it was a mistake.","operationId":"reject_search_request_admin_search_requests__request_id__reject_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/unreject":{"post":{"tags":["admin"],"summary":"Unreject Search Request","description":"Undo a rejection — for admins who clicked Reject by mistake. Clears\nrejected_at/rejected_by_user_id; the row goes back to pending.","operationId":"unreject_search_request_admin_search_requests__request_id__unreject_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/bulk-review":{"post":{"tags":["admin"],"summary":"Bulk Review Search Requests","description":"Approve or reject many pending search requests at once (the inbound queue\nis high-volume). Per-request guards mirror the single-row endpoints; a\nrequest that doesn't qualify is reported as skipped rather than failing the\nbatch. Approvals run in a per-request SAVEPOINT so one bad row rolls back\nonly itself while the rest persist on the single outer commit — same shape\nas the agent-candidate bulk review.","operationId":"bulk_review_search_requests_admin_search_requests_bulk_review_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkSearchRequestReviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/keyword-phase-stats":{"get":{"tags":["admin"],"summary":"Keyword Phase Stats","description":"Blast-radius view for the keyword pipeline: counts of non-rejected search\nrequests grouped by keyword_phase. `awaiting_extraction` is the stuck bucket\n(task killed mid-flight). Check before/after a deploy. Distinct path (not\nunder /search-requests/{id}) so the {request_id} route can't capture it.","operationId":"keyword_phase_stats_admin_keyword_phase_stats_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/keywords":{"get":{"tags":["admin"],"summary":"Get Search Request Keywords","description":"Return the current keyword pipeline state for a SearchHistory (both phase\nsets + keyword_phase + active set), self-healing a stuck pipeline and lazily\nkicking extraction. All DB work runs in a dedicated bounded threadpool (see\n_KEYWORDS_LOAD_EXECUTOR) so the polled self-heal write never blocks the event\nloop AND a stampede of panels can't starve the request pool or the shared\nto_thread executor; only the extraction kick (which needs the running loop)\nstays on it.","operationId":"get_search_request_keywords_admin_search_requests__request_id__keywords_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["admin"],"summary":"Patch Search Request Keywords","description":"Modify the active keyword set (Phase A or B, depending on phase).\n\nAccepted ops in `payload`:\n  {\"action\": \"add\",    \"phase\": \"A\"|\"B\", \"text\": \"...\", \"priority\": 1|2|3}\n  {\"action\": \"update\", \"phase\": \"A\"|\"B\", \"keyword_id\": uuid,\n   \"text\"?: \"...\", \"priority\"?: 1|2|3, \"paused\"?: bool}\n  {\"action\": \"delete\", \"phase\": \"A\"|\"B\", \"keyword_id\": uuid}\n\nBulk variants — same semantics, but the whole batch is ONE JSONB write, ONE\ncombination re-materialization, ONE reactivation and ONE commit. Editing N\nkeywords one-at-a-time used to cost N of each, which is why the panel's\nmulti-select posts these instead:\n  {\"action\": \"bulk_add\",    \"phase\": \"A\"|\"B\", \"priority\": 1|2|3, \"texts\": [...]}\n  {\"action\": \"bulk_update\", \"phase\": \"A\"|\"B\", \"keyword_ids\": [...],\n   \"priority\"?: 1|2|3, \"paused\"?: bool}   (no \"text\" — it'd set them all equal)\n  {\"action\": \"bulk_delete\", \"phase\": \"A\"|\"B\", \"keyword_ids\": [...]}\n\nPhase defaults to whichever set is active for the current keyword_phase\nif omitted. Edits to a phase that's already running regenerate the queued\nportion of agent_combination_runs (started/exhausted/paused/skipped rows\nare preserved for audit).\n\nNOTE on post-approval edits: re-materialization runs with\n`on_existing=\"skip\"`, so only genuinely-NEW keyword pairs become combos. An\nedit that adds no new pair (a priority change, a pause) therefore leaves an\nalready-`complete` request complete instead of silently re-running every\nexhausted combo from page 0. Use Extend / \"Restart sourcing\" to re-source\nground that has already been covered.","operationId":"patch_search_request_keywords_admin_search_requests__request_id__keywords_patch","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/company-suggestions":{"get":{"tags":["admin"],"summary":"Get Company Suggestions","description":"Return cached similar-company/role suggestions for a request. When\ngenerate=true (default; used by the single-request live hub) it lazily\ngenerates the fast set on first view; the list page passes generate=false so\na page of cards doesn't fire one LLM call each. All DB + LLM work runs in a\ndedicated threadpool so the (possibly slow) call never blocks the loop.","operationId":"get_company_suggestions_admin_search_requests__request_id__company_suggestions_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"generate","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Generate"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/company-suggestions/refresh":{"post":{"tags":["admin"],"summary":"Refresh Company Suggestions","description":"Regenerate suggestions. Body {\"deep\": bool} — deep=true uses the slower\nGoogle-Search-grounded model (the 'Deep web search' button).","operationId":"refresh_company_suggestions_admin_search_requests__request_id__company_suggestions_refresh_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/company-suggestions/dismiss":{"post":{"tags":["admin"],"summary":"Dismiss Company Suggestion","description":"Remember a dismissed suggestion so it won't resurface. Body\n{\"company\"?: str, \"role\"?: str}.","operationId":"dismiss_company_suggestion_admin_search_requests__request_id__company_suggestions_dismiss_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/combination-runs":{"get":{"tags":["admin"],"summary":"List Combination Runs","description":"List all combination runs for a SearchHistory, ordered by phase + order_index.\nUsed by the Agent Sourcing project pane's live progress panel.","operationId":"list_combination_runs_admin_search_requests__request_id__combination_runs_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin"],"summary":"Create Combination Run","description":"Hand-build one keyword combination and queue it.\n\nCombinations are otherwise only ever produced by the fixed priority sequence\nin materialize_combination_runs (P1×P1 → P1×P2 → … ), so an admin who KNOWS\na particular pair is the productive one had to juggle keyword priorities to\ncoax it out. This inserts it directly, and `position=\"front\"` makes it the\nnext combo the picker takes (it orders by order_index asc).","operationId":"create_combination_run_admin_search_requests__request_id__combination_runs_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCombinationRunRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/combination-runs/{run_id}/pause":{"post":{"tags":["admin"],"summary":"Pause Combination Run","description":"Admin pauses a specific combination — the picker skips paused rows\nuntil they're resumed. Already-exhausted/skipped rows can't be paused.","operationId":"pause_combination_run_admin_combination_runs__run_id__pause_post","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Run Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/combination-runs/{run_id}/resume":{"post":{"tags":["admin"],"summary":"Resume Combination Run","description":"Resume a paused combination — flips back to queued so the picker\nconsiders it again. Re-running a previously-running row preserves\nstarted_at and the `skip` cursor (pagination continues where it left off).","operationId":"resume_combination_run_admin_combination_runs__run_id__resume_post","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Run Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/combination-runs/{run_id}/skip":{"post":{"tags":["admin"],"summary":"Skip Combination Run","description":"Permanently skip a combination — admin decided this combination isn't\nworth sourcing for. Sets a terminal status; cannot be undone via API\n(admin can manually re-enqueue via Extend / \"Restore\" if needed).","operationId":"skip_combination_run_admin_combination_runs__run_id__skip_post","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Run Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/combination-runs/{run_id}/extend":{"post":{"tags":["admin"],"summary":"Extend Combination Run","description":"Re-activate a single combination so the agent sources it again.\n\nOne control for three admin intents, all of which flip the row back to\nQUEUED (keeping its `skip` cursor so pagination CONTINUES deeper rather than\nrestarting):\n  • EXHAUSTED → \"source more of this combination\" (admin likes its results,\n    or it was falsely exhausted by a transient 429/seat blip).\n  • SKIPPED   → \"un-skip / revert the skip\".\n  • PAUSED    → same as resume (kept here so the UI can use one endpoint).\n\nRe-queuing alone isn't enough to make work flow, so this also:\n  • rewinds SearchHistory.keyword_phase to the earliest phase that now has\n    live work (else a request sitting at `complete`/`phase_b_running` would\n    never re-enter Phase A to pick this row up),\n  • unpauses the project, points the agent at THIS request, and force-runs it\n    so it's picked up within ~1 min instead of waiting for the round-robin,\n  • if the request has already hit the per-request cap, zeroes the counter so\n    the extend can actually fetch (this is the \"extend before/after the 300\n    cap\" lever admins were missing — they were pressing full \"restart\n    sourcing\" just to get this).","operationId":"extend_combination_run_admin_combination_runs__run_id__extend_post","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Run Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/combination-runs/bulk":{"post":{"tags":["admin"],"summary":"Bulk Combination Runs","description":"Apply one lifecycle op (pause/resume/skip/extend) to many combinations.\n\nExists because the per-row endpoints are individually expensive: skip and\nextend each force-run the request, so triaging a queue one click at a time\nmeant one re-activation per click. Here the status flips happen together and\n`_reactivate_request_sourcing` runs AT MOST ONCE for the whole batch, on a\nsingle commit.\n\nRows are scoped to `request_id` — an id belonging to another request is\nreported in `skipped_ids`, not applied. Per-row refusals (pausing an\nexhausted row, resuming a non-paused one) are likewise reported rather than\nfailing the batch, mirroring /agent-candidates/bulk-review.","operationId":"bulk_combination_runs_admin_search_requests__request_id__combination_runs_bulk_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkCombinationRunRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/combination-runs/{run_id}/move":{"post":{"tags":["admin"],"summary":"Move Combination Run","description":"Reposition one combination within its phase — \"run this next\" (front) or\n\"run this last\" (back). Only order_index moves; status and the pagination\ncursor are untouched, and no other row is renumbered.","operationId":"move_combination_run_admin_combination_runs__run_id__move_post","parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Run Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MoveCombinationRunRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/keyword-review-count":{"get":{"tags":["admin"],"summary":"Keyword Review Count","description":"Count of PENDING SearchHistory rows that need admin attention because\ntheir keywords are ready to review (or extraction failed). Filtered to\npending-only so the badge doesn't double-count requests admins have\nalready approved. Powers the sidebar badge.","operationId":"keyword_review_count_admin_search_requests_keyword_review_count_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/action-counts":{"get":{"tags":["admin"],"summary":"Admin Action Counts","description":"Aggregate 'action required' counts for the admin sidebar badges.\n\nOne endpoint instead of N polls — the sidebar fans these out to the\nrelevant nav links. Inbox unread keeps its own endpoint because that\nhook also drives the new-message toast.\n\nCounts:\n  * search_requests  — pending client search submissions (not yet\n    approved or rejected). Covers brand-new requests AND ones whose\n    keywords are ready for review, so the badge fires the moment a\n    request lands (not just at the keyword-review step).\n  * slot_requests    — open client requests for more timeslots.\n  * expert_approvals — experts whose account is PENDING_REVIEW.\n  * guidelines       — interview-questionnaire files not yet marked sent.\n  * candidates_pending — agent candidates awaiting review (Gate D) across\n    ALL projects. The highest-volume gate, previously invisible on the rail.\n    This is the RAW candidate count (hundreds), right for the candidates\n    page but wrong as a \"how many things need me\" signal.\n  * candidate_projects — number of DISTINCT projects with pending candidates.\n    This is the actionable-lane count: it matches one row per project in the\n    Today queue, so the Today badge tracks the list length instead of the raw\n    candidate volume (which never dropped below 99+).\n  * capped_requests  — approved requests parked at the per-request sourcing\n    cap (Gate C); sourcing has stalled until an admin Extends.\n\n(Inbox replies keep their own /admin/inbox/unread-count endpoint — that hook\nalso drives the new-message toast — so they are intentionally NOT duplicated\nhere.)","operationId":"admin_action_counts_admin_action_counts_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/badge-counts":{"get":{"tags":["admin"],"summary":"Admin Badge Counts","description":"One endpoint for EVERY admin-shell sidebar badge, so the shell polls once\ninstead of four times.\n\nThe shell used to run four independent 15s pollers (action-counts, sales\naction-counts, LinkedIn inbox unread, chat inbox unread), each acquiring its\nown connection — four HTTP round-trips and four connection checkouts every\n15s, on every open admin tab, against the tiny prod pool. This merges them\ninto ONE round-trip on ONE session by reusing each endpoint's existing logic\n(no duplicated queries → no drift). The individual endpoints stay for pages\nthat poll them on their own (inbox/chat pages, ChatPanel).","operationId":"admin_badge_counts_admin_badge_counts_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/funnel":{"get":{"tags":["admin"],"summary":"Project Funnel","description":"Per-project delivery funnel for the EXPERT side: profiles scanned → staged\nfor review → approved → contacted → replied → interviews, with the conversion\nbetween stages and the single biggest drop-off. Sales already had a funnel\ndashboard; the expert side (where the sourcing admin lives all day) had none,\nso 'sourced 300, delivered 2' was invisible. All counts are project-scoped\n(naturally bounded) and read from data that already exists.","operationId":"project_funnel_admin_projects__project_id__funnel_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/action-queue":{"get":{"tags":["admin"],"summary":"Admin Action Queue","description":"Cross-project Action Queue (F5) — a ranked, deep-linked \"what next\" list.\n\nRead-only aggregation over the sourcing gates (approve request, extend\ncapped request, review candidate backlog). Each item deep-links to the page\nthat clears the gate; nothing here performs an irreversible action. Gated by\nACTION_QUEUE_ENABLED (returns an empty queue + enabled:false when off).","operationId":"admin_action_queue_admin_action_queue_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/search-requests/{request_id}/retry-extraction":{"post":{"tags":["admin"],"summary":"Retry Keyword Extraction","description":"Retry keyword extraction after a GPT failure. Regenerates both Phase A\nand Phase B keyword sets in one task (matches the unified pre-approval\nreview flow).","operationId":"retry_keyword_extraction_admin_search_requests__request_id__retry_extraction_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/search-requests":{"get":{"tags":["admin"],"summary":"List Project Search Requests","description":"Compact list of SearchHistory rows for one project. Powers the request\nlist rail on Manual Expert Search. Returns the criteria fields the admin\nneeds to pre-populate the form, plus a count of associated experts so\nadmins see at-a-glance whether each request has manual additions.","operationId":"list_project_search_requests_admin_projects__project_id__search_requests_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/projects/{project_id}/admin-search-request":{"post":{"tags":["admin"],"summary":"Admin Create Search Request","description":"Admin-create a SearchHistory row directly (for the Manual Expert Search\n\"Save as new request\" flow). Auto-approved on the spot since the admin is\nthe creator.\n\nBody:\n  {\n    \"job_roles\": \"comma,separated\", \"industry\": \"...\", \"geography\": \"...\",\n    \"employment_status\": \"...\", \"min_experience\": 0, \"max_experience\": 30,\n    \"target_interviews\": \"5\", \"verifying_questions\": [{\"q\":\"...\",\"subs\":[...]}],\n    \"companies_data\": [{\"unipile_id\":\"...\",\"title\":\"...\",\"type\":\"unipile\"|\"freetext\"}],\n    \"skip_keyword_pipeline\": false  # true if attaching manual experts only\n  }\n\nskip_keyword_pipeline=true: keyword_phase stays `not_started` and no\nextraction is kicked — request exists purely as criteria context for the\nmanually-added experts. The agent never sources for it.","operationId":"admin_create_search_request_admin_projects__project_id__admin_search_request_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Payload"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/threads":{"get":{"tags":["admin-inbox"],"summary":"List Threads","description":"List threads grouped by company → project → expert.\n\nSources two streams:\n  1. inbound_linkedin_message — chats where the expert has replied\n  2. inmail_send_log — chats we initiated (may have no inbound yet)\nBoth are unioned by (account_id, chat_id). Each thread is then mapped to\nits expert's project (via the most-recent InMailSendLog for that expert\n+ project, or as a fallback the most-recent ProjectExpert) and the\nproject's company (via ProjectUser → User → Company).\n\nThreads with no resolvable project land in a synthetic \"Unassigned\"\nbucket so they're still visible.","operationId":"list_threads_admin_inbox_threads_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxThreadsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/threads/{chat_id}/messages":{"get":{"tags":["admin-inbox"],"summary":"Get Thread Messages","description":"Full history for one thread: inbound from webhook store + outbound send log.","operationId":"get_thread_messages_admin_inbox_threads__chat_id__messages_get","parameters":[{"name":"chat_id","in":"path","required":true,"schema":{"type":"string","title":"Chat Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxThreadMessagesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/threads/{chat_id}/draft":{"post":{"tags":["admin-inbox"],"summary":"Draft Thread Reply","description":"Generate (via Gemini) the next reply draft for a thread, using the full\nconversation history + light expert/project context assembled server-side.\nThe draft is returned for the admin to review/edit before sending — nothing\nis sent here.","operationId":"draft_thread_reply_admin_inbox_threads__chat_id__draft_post","parameters":[{"name":"chat_id","in":"path","required":true,"schema":{"type":"string","title":"Chat Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DraftReplyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DraftReplyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/threads/{chat_id}/suggest":{"post":{"tags":["admin-inbox"],"summary":"Suggest Thread Replies","description":"Propose 2-3 situation-labeled reply candidates for a thread, grounded in\nthat chat's full live history (same server-side assembly as the single\ndraft) + the inbound-situation taxonomy. Nothing is sent — the operator\npicks one into the composer. Returns no_reply_needed for acks/off-topic.","operationId":"suggest_thread_replies_admin_inbox_threads__chat_id__suggest_post","parameters":[{"name":"chat_id","in":"path","required":true,"schema":{"type":"string","title":"Chat Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestRepliesRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestRepliesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/attachments/{message_id}/{attachment_id}":{"get":{"tags":["admin-inbox"],"summary":"Download Attachment","description":"Proxy-download one inbound attachment from Unipile.\n\n`message_id` is our `inbound_linkedin_message.id` (NOT the Unipile id);\nwe resolve it to the Unipile message id + account_id and stream the bytes\nback. Unipile gates attachment downloads behind the API key, so the\nbrowser can't fetch directly — this is the only way the admin gets the\nfile. Outbound (our own sent) attachments aren't downloadable here: we\nstore only their metadata, never re-fetch them.","operationId":"download_attachment_admin_inbox_attachments__message_id___attachment_id__get","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}},{"name":"attachment_id","in":"path","required":true,"schema":{"type":"string","title":"Attachment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/threads/{chat_id}/read":{"post":{"tags":["admin-inbox"],"summary":"Mark Thread Read","description":"Mark every inbound message in a thread as read.\n\nResolves the expert behind the chat_id and marks across ALL of that\nexpert's chat_ids (per account) — the merged thread can span several\nchat_ids, so marking only the opened one would leave stragglers unread.","operationId":"mark_thread_read_admin_inbox_threads__chat_id__read_post","parameters":[{"name":"chat_id","in":"path","required":true,"schema":{"type":"string","title":"Chat Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxMarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/threads/{chat_id}/unread":{"post":{"tags":["admin-inbox"],"summary":"Mark Thread Unread","description":"Mark a thread UNREAD again (re-raise its unread badge) so an admin can flag\na conversation to come back to — PER-ADMIN: clears only THIS admin's read\nwatermark for the merged conversation, so the thread re-surfaces as unread for\nthem (its is_read=False messages) without touching other admins.","operationId":"mark_thread_unread_admin_inbox_threads__chat_id__unread_post","parameters":[{"name":"chat_id","in":"path","required":true,"schema":{"type":"string","title":"Chat Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxMarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/unread-count":{"get":{"tags":["admin-inbox"],"summary":"Get Unread Count","description":"Total unread inbound messages for the CALLING ADMIN — for the nav badge.\n\nPer-admin: counts messages still is_read=False that this admin hasn't read\n(no covering InboxThreadRead watermark). See _unread_for_admin / models/inbox_read.py.","operationId":"get_unread_count_admin_inbox_unread_count_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxUnreadCountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/unread-threads":{"get":{"tags":["admin-inbox"],"summary":"List Unread Threads","description":"The calling admin's unread Expert-InMail threads — flat + bounded, for the\nadmin notification center's \"Expert InMail\" tab. Live from the inbox (per-admin\nunread), so it always matches the inbox badge. Column-projected + LIMIT to keep\negress bounded (CLAUDE.md).","operationId":"list_unread_threads_admin_inbox_unread_threads_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":30,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxThreadsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/read-all":{"post":{"tags":["admin-inbox"],"summary":"Mark All Read","description":"Mark every Expert-InMail thread read for the CALLING ADMIN — the dock's\n\"read all\". Sets this admin's watermark=now on all chat_ids they currently have\nunread; other admins are untouched.","operationId":"mark_all_read_admin_inbox_read_all_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxMarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/webhook-log":{"get":{"tags":["admin-inbox"],"summary":"Get Webhook Log","description":"Most recent Unipile webhook hits — for debugging payload shape mismatches.\n\nIncludes rejected payloads (bad signature, missing fields) so admins can\nsee why a message didn't land in the inbox without tailing logs.","operationId":"get_webhook_log_admin_inbox_webhook_log_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookLogResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/inbox/attachment-probe":{"get":{"tags":["admin-inbox"],"summary":"Attachment Probe","description":"Surface real inbound-attachment payloads from the webhook log.\n\nConfirms the exact shape Unipile sends — scans the last `limit` webhook\nhits, finds any that carried an `attachments` array, and returns BOTH the\nraw Unipile objects (untouched field names) and what our normalizer made\nof them. If `normalized` is empty while `raw_attachments` is not, the\nfield names drifted and `inbox_attachments.normalize_attachment` needs a\nnew alias. Use this after a real expert reply with a file to verify the\nreceive path end-to-end without DB access.","operationId":"attachment_probe_admin_inbox_attachment_probe_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttachmentProbeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/scheduled-messages/config":{"get":{"tags":["scheduled-messages"],"summary":"Scheduled Config","description":"Lets the UI show/hide the scheduling controls without a 403 round-trip.","operationId":"scheduled_config_admin_scheduled_messages_config_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/scheduled-messages/upload":{"post":{"tags":["scheduled-messages"],"summary":"Upload Attachment","description":"Persist one file to S3 (keyed under its thread) so a scheduled reply can\nre-attach it at fire time. Returns the ref to pass back in the item's\n`attachments` list. Reuses the live-chat attachment bucket.","operationId":"upload_attachment_admin_scheduled_messages_upload_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_attachment_admin_scheduled_messages_upload_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/scheduled-messages":{"post":{"tags":["scheduled-messages"],"summary":"Create Scheduled","description":"Queue one or more messages. >1 item shares a batch_id. Each item carries\nits own body + send_at, so same/different message × same/different time all\nwork with one call.","operationId":"create_scheduled_admin_scheduled_messages_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduleCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["scheduled-messages"],"summary":"List Scheduled","description":"Pending (default) scheduled messages, newest fire time first. Filter by\nchat_id / expert_id for the per-thread inbox panel.","operationId":"list_scheduled_admin_scheduled_messages_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"scheduled","title":"Status"}},{"name":"chat_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chat Id"}},{"name":"expert_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"default":200,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/scheduled-messages/{msg_id}":{"patch":{"tags":["scheduled-messages"],"summary":"Reschedule","description":"Edit a still-pending scheduled message (time / body / subject).","operationId":"reschedule_admin_scheduled_messages__msg_id__patch","parameters":[{"name":"msg_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Msg Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SchedulePatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/scheduled-messages/{msg_id}/cancel":{"post":{"tags":["scheduled-messages"],"summary":"Cancel Scheduled","description":"Cancel a still-pending message. A message already 'sending'/'sent' cannot\nbe pulled back.","operationId":"cancel_scheduled_admin_scheduled_messages__msg_id__cancel_post","parameters":[{"name":"msg_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Msg Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/scheduled-messages/retry":{"post":{"tags":["scheduled-messages"],"summary":"Retry Failed","description":"Re-queue failed/skipped scheduled messages (bulk). send_at blank => send now\n(next drainer tick, self-staggered per seat); else reschedule. Only dead rows\n(failed/skipped) are touched — an in-flight or already-sent row is left alone.\nLocks the rows so the status flip is atomic vs the drainer's skip-locked claim.","operationId":"retry_failed_admin_scheduled_messages_retry_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/scheduled-messages/dismiss":{"post":{"tags":["scheduled-messages"],"summary":"Dismiss Failed","description":"Dismiss failed/skipped scheduled messages (bulk) — mark them canceled so\nthey leave the failed list. Drops any attachments. No-op on live/sent rows.","operationId":"dismiss_failed_admin_scheduled_messages_dismiss_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkIdsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/reply-intel/insights":{"get":{"tags":["admin-reply-intel"],"summary":"Get Reply Insights","description":"Sync def on purpose: blocks on the single-flight model build (~1–4 s; FE timeout\n60 s), so it must stay off the event loop. refresh=1 rebuilds only if the last build\nis ≥ 10 min old (per web task).","operationId":"get_reply_insights_admin_reply_intel_insights_get","parameters":[{"name":"refresh","in":"query","required":false,"schema":{"type":"integer","maximum":1,"minimum":0,"default":0,"title":"Refresh"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/reply-intel/send-evidence":{"get":{"tags":["admin-reply-intel"],"summary":"Get Send Evidence","description":"Seat / template / length / subject-hook within-project evidence (+ this project's mature\nk/n per seat and template). NON-blocking: serves the cached build, or {\"enabled\": true,\n\"status\": \"building\"} while one runs; {\"enabled\": false, \"status\": \"disabled\"} when\nREPLY_INTEL_ENABLED is off.","operationId":"get_send_evidence_admin_reply_intel_send_evidence_get","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/reply-intel/segment-mix":{"get":{"tags":["admin-reply-intel"],"summary":"Get Segment Mix","description":"'Who replies in this batch' advisory: for the selected experts, per non-sensitive descriptive\ndim (region/company_type/sector/function/career/tenure/connections/premium — never gender/race),\nthe count in each level and that level's HISTORICAL reply rate from the cached model ledger.\nAggregate counts only (anonymity-first); never scores, skips or sorts. NON-blocking. Reads the\nrequest db for one bounded feature query, so the session stays open (unlike /insights).","operationId":"get_segment_mix_admin_reply_intel_segment_mix_get","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},{"name":"expert_ids","in":"query","required":false,"schema":{"type":"string","description":"comma-separated expert UUIDs (≤200)","default":"","title":"Expert Ids"},"description":"comma-separated expert UUIDs (≤200)"},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/gemini-bench/tasks":{"get":{"tags":["admin"],"summary":"Get Tasks","operationId":"get_tasks_admin_gemini_bench_tasks_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/gemini-bench/run":{"post":{"tags":["admin"],"summary":"Run","description":"Non-streaming run (used by tests / clients that don't stream).","operationId":"run_admin_gemini_bench_run_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/gemini-bench/stream":{"post":{"tags":["admin"],"summary":"Stream","description":"Server-Sent-Events run: each model's result streams back the moment it\nfinishes, then the judge verdict, then `done`. The UI renders progressively.","operationId":"stream_admin_gemini_bench_stream_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/conversation":{"get":{"tags":["chat"],"summary":"Get My Conversation","description":"Fetch-or-create the caller's thread with Veyond + its messages.","operationId":"get_my_conversation_chat_conversation_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConversationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/conversation/messages":{"post":{"tags":["chat"],"summary":"Send My Message","description":"External user sends a message to Veyond admins.","operationId":"send_my_message_chat_conversation_messages_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendMessageRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__routers__chat_inbox__ChatMessageItem"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/conversation/read":{"post":{"tags":["chat"],"summary":"Mark My Read","operationId":"mark_my_read_chat_conversation_read_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__routers__chat_inbox__MarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/unread-count":{"get":{"tags":["chat"],"summary":"My Unread Count","operationId":"my_unread_count_chat_unread_count_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnreadCountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/attachable-experts":{"get":{"tags":["chat"],"summary":"Attachable Experts","description":"Experts a client may attach, grouped by project — the composer picker\nhas the client pick a project first, then an expert within it. Only projects\nwith at least one attachable expert are returned. Empty list for experts\n(they can't attach).","operationId":"attachable_experts_chat_attachable_experts_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AttachableProject"},"title":"Response Attachable Experts Chat Attachable Experts Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/conversation/attachments":{"post":{"tags":["chat"],"summary":"Upload My Attachment","description":"External user uploads one file to S3 (pre-send). Returns the key to pass\nback in the next POST /conversation/messages `files` list.","operationId":"upload_my_attachment_chat_conversation_attachments_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_my_attachment_chat_conversation_attachments_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chat/conversation/attachments/{attachment_id}":{"get":{"tags":["chat"],"summary":"Get My Attachment Url","description":"Short-lived presigned S3 URL for a file in the caller's own thread.","operationId":"get_my_attachment_url_chat_conversation_attachments__attachment_id__get","parameters":[{"name":"attachment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Attachment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttachmentUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/conversations":{"get":{"tags":["chat-admin"],"summary":"List Conversations","description":"All threads, sorted by recency. Optional ?kind=CLIENT|EXPERT filter.","operationId":"list_conversations_admin_chat_inbox_conversations_get","parameters":[{"name":"kind","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminConversationsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/experts/search":{"get":{"tags":["chat-admin"],"summary":"Admin Search Experts","description":"Free-text expert search for the admin composer's attach picker.\n\nMirrors /admin/experts/search but returns the ExpertCard shape the chat UI\nalready consumes (anon_code / display_name / headline), so attached cards\nrender identically to client-attached ones. Admins may attach ANY expert\n(authorization is enforced again at send time in _validate_attachments).","operationId":"admin_search_experts_admin_chat_inbox_experts_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExpertCard"},"title":"Response Admin Search Experts Admin Chat Inbox Experts Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/conversations/{conversation_id}/messages":{"get":{"tags":["chat-admin"],"summary":"Get Conversation Messages","operationId":"get_conversation_messages_admin_chat_inbox_conversations__conversation_id__messages_get","parameters":[{"name":"conversation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Conversation Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConversationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["chat-admin"],"summary":"Admin Send Message","description":"Admin replies to an external user. Admins may attach any expert.","operationId":"admin_send_message_admin_chat_inbox_conversations__conversation_id__messages_post","parameters":[{"name":"conversation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Conversation Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendMessageRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__routers__chat_inbox__ChatMessageItem"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/conversations/{conversation_id}/attachments":{"post":{"tags":["chat-admin"],"summary":"Admin Upload Attachment","description":"Admin uploads one file to S3 (pre-send) for a specific thread.","operationId":"admin_upload_attachment_admin_chat_inbox_conversations__conversation_id__attachments_post","parameters":[{"name":"conversation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Conversation Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_admin_upload_attachment_admin_chat_inbox_conversations__conversation_id__attachments_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/attachments/{attachment_id}":{"get":{"tags":["chat-admin"],"summary":"Admin Get Attachment Url","description":"Short-lived presigned S3 URL for any thread's attachment (admins see all).","operationId":"admin_get_attachment_url_admin_chat_inbox_attachments__attachment_id__get","parameters":[{"name":"attachment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Attachment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttachmentUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/conversations/{conversation_id}/read":{"post":{"tags":["chat-admin"],"summary":"Admin Mark Read","description":"Mark a thread read FOR THIS ADMIN (per-admin watermark — another admin's\nunread is untouched). Also advances the shared admin_last_read_at (the email\ndebounce's \"last read by anyone\" signal) and clears this admin's bell rows.","operationId":"admin_mark_read_admin_chat_inbox_conversations__conversation_id__read_post","parameters":[{"name":"conversation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Conversation Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__routers__chat_inbox__MarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/read-all":{"post":{"tags":["chat-admin"],"summary":"Admin Mark All Read","description":"Mark every chat thread read FOR THIS ADMIN (per-admin watermarks), advance\nthe shared admin_last_read_at (notify debounce), and clear this admin's\nCHAT_MESSAGE bell rows. Mirrors /admin/inbox/read-all for the dock's\n'Mark all read' on the App chat sub-tab.","operationId":"admin_mark_all_read_admin_chat_inbox_read_all_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__routers__chat_inbox__MarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/conversations/{conversation_id}/assign":{"post":{"tags":["chat-admin"],"summary":"Admin Assign","description":"Set/clear the advisory owner of a thread (does not lock other admins).","operationId":"admin_assign_admin_chat_inbox_conversations__conversation_id__assign_post","parameters":[{"name":"conversation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Conversation Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AssignRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__routers__chat_inbox__MarkReadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/chat-inbox/unread-count":{"get":{"tags":["chat-admin"],"summary":"Admin Unread Count","description":"Total external-origin unread across all threads, PER-ADMIN — for the nav badge.","operationId":"admin_unread_count_admin_chat_inbox_unread_count_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnreadCountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/contact/submit":{"post":{"tags":["contact"],"summary":"Submit Contact Form","description":"Public endpoint - no authentication required.\nLanding-page demo/contact submissions are persisted to `contact_submissions`\n(source='landing_page') so admins have a durable record in the admin panel,\nthen routed to Slack (#z-contact-demo-request). Previously this was\nfire-and-forget to Slack only — a missed Slack ping lost the lead entirely.","operationId":"submit_contact_form_contact_submit_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactSubmissionRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactSubmissionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/contact/feedback":{"post":{"tags":["contact"],"summary":"Submit Feedback","description":"Authenticated endpoint for in-app feedback and inquiries.\nPre-fills name/email from the logged-in user.","operationId":"submit_feedback_contact_feedback_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeedbackRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactSubmissionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/users/me/profile":{"get":{"tags":["users"],"summary":"Get My Profile","description":"Get current user's profile (any user type)","operationId":"get_my_profile_users_me_profile_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserProfileResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["users"],"summary":"Update My Profile","description":"Update current user's profile (any user type)","operationId":"update_my_profile_users_me_profile_put","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateUserProfileRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserProfileResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/users/me/password":{"put":{"tags":["users"],"summary":"Change My Password","description":"Change current user's password","operationId":"change_my_password_users_me_password_put","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChangePasswordRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/users/reset-password":{"post":{"tags":["users"],"summary":"Request Password Reset","description":"Send password reset email via Resend (no auth required)","operationId":"request_password_reset_users_reset_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResetPasswordRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/webhooks/zoom":{"post":{"tags":["webhooks"],"summary":"Zoom Webhook","description":"Zoom webhook endpoint.\nHandles URL validation challenge and recording.completed events.","operationId":"zoom_webhook_webhooks_zoom_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/webhooks/fireflies":{"post":{"tags":["webhooks"],"summary":"Fireflies Webhook","description":"Fireflies webhook endpoint.\nTriggered when Fireflies finishes processing a recording (~2-5 min after meeting ends).\nThis is the FAST PATH — processes audio before Zoom cloud recording is ready.","operationId":"fireflies_webhook_webhooks_fireflies_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/webhooks/sdk-join-params/{interview_id}":{"get":{"tags":["webhooks"],"summary":"Sdk Join Params","description":"Fresh join credentials for the Meeting SDK bot, fetched at bot startup.\n\nReturns {meetingNumber, passcode, zak, signature, sdkKey, botName}. The\nsignature and passcode are meeting-specific and short-lived; the ZAK is\nminted here rather than baked into the schedule at booking time (a booking\ncan be days ahead and the ZAK expires).\n\nAuth: a bearer secret in the `x-bot-secret` header, constant-time compared to\nMEETING_BOT_JOIN_PARAMS_SECRET — DISTINCT from the recording-completed HMAC\nkey so a transmitted token can't be used to forge webhooks. The SCHEDULED +\ntime-window gate below bounds only WHEN creds can be requested; note it does\nNOT bound the returned ZAK, which is a user-scoped credential valid for its\nown lifetime — so ZOOM_BOT_USER_ID must be a dedicated, low-privilege Zoom\nuser that owns no interview meetings (never ZOOM_HOST_EMAIL).","operationId":"sdk_join_params_webhooks_sdk_join_params__interview_id__get","parameters":[{"name":"interview_id","in":"path","required":true,"schema":{"type":"string","title":"Interview Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/webhooks/recording-completed":{"post":{"tags":["webhooks"],"summary":"Recording Completed Webhook","description":"Meeting Bot webhook endpoint.\nTriggered when the self-hosted bot finishes recording and uploads to S3.","operationId":"recording_completed_webhook_webhooks_recording_completed_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/webhooks/unipile":{"post":{"tags":["webhooks"],"summary":"Unipile Webhook","description":"Unipile account status webhook.\nFires when a connected LinkedIn account changes status (disconnected, error, etc.).\nSends admin notification email when account is not OK.","operationId":"unipile_webhook_webhooks_unipile_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/webhooks/unipile/messages":{"post":{"tags":["webhooks"],"summary":"Unipile Messages Webhook","description":"Unipile new-message webhook.\n\nFires when a connected LinkedIn account receives a new chat or InMail\nmessage. We persist every message so the admin inbox can render threads\nand unread counts without polling Unipile's chat endpoints.","operationId":"unipile_messages_webhook_webhooks_unipile_messages_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/webhooks/ens/inbound-email":{"post":{"tags":["webhooks"],"summary":"Ens Inbound Email","description":"Resend inbound email webhook endpoint.\nReceives forwarded ENS emails from clients and queues them for processing.\n\nResend sends an `email.received` event with metadata only (no body/attachments).\nThe agent fetches full content via the Resend Receiving API.","operationId":"ens_inbound_email_webhooks_ens_inbound_email_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/notifications":{"get":{"tags":["notifications"],"summary":"List Notifications","operationId":"list_notifications_notifications_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notifications/{notification_id}/read":{"post":{"tags":["notifications"],"summary":"Mark Read","operationId":"mark_read_notifications__notification_id__read_post","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Notification Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notifications/read-all":{"post":{"tags":["notifications"],"summary":"Mark All Read","operationId":"mark_all_read_notifications_read_all_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notifications/read-kinds":{"post":{"tags":["notifications"],"summary":"Mark Kinds Read","description":"Mark all of this user's unread notifications in a set of kinds read — the\nper-tab \"read all\" in the notification center (e.g. clear just the Expert\nInMail tab). One bounded UPDATE, not N per-row reads (connection ceiling).","operationId":"mark_kinds_read_notifications_read_kinds_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReadKindsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notifications/read-project/{project_id}":{"post":{"tags":["notifications"],"summary":"Mark Project Read","description":"Mark all of this user's unread notifications for ONE project read.\n\nFired when the client opens the project detail page: visiting a project\nmeans \"I've seen what's new here\", so it stops nagging on the dashboard even\nif experts remain in an open status (the project page itself is where the\nper-expert work list lives). New activity later creates fresh unread rows\nthat re-raise it. One bounded UPDATE — not N per-notification calls, which\nmatters on the small connection tier.","operationId":"mark_project_read_notifications_read_project__project_id__post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notifications/{notification_id}":{"delete":{"tags":["notifications"],"summary":"Dismiss","operationId":"dismiss_notifications__notification_id__delete","parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Notification Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notifications/preferences":{"get":{"tags":["notifications"],"summary":"Get Preferences","operationId":"get_preferences_notifications_preferences_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/notifications/preferences/{kind}":{"put":{"tags":["notifications"],"summary":"Update Preference","operationId":"update_preference_notifications_preferences__kind__put","parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","title":"Kind"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateNotificationPreferenceRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/dashboard/summary":{"get":{"tags":["dashboard"],"summary":"Dashboard Summary","description":"Returns the single payload the new home page renders from:\n- The 3 most-recent active projects with their counts + most recent status pill hint\n- Upcoming interviews in the next ~30 days (max 6) across all the user's projects\n- Latest few notifications (for the hero state selector)\n- Credit balance","operationId":"dashboard_summary_dashboard_summary_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Dashboard Summary Dashboard Summary Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/webhooks/deploy/amplify":{"post":{"tags":["deploy-webhooks"],"summary":"Amplify Webhook","description":"Accept both the flat shape (from an EventBridge input transformer)\nand the raw EventBridge event (where the real fields live under\n`detail`). Sample raw event:\n    {\n      \"source\": \"aws.amplify\",\n      \"detail-type\": \"Amplify Deployment Status Change\",\n      \"detail\": {\n        \"appId\": \"...\",\n        \"branchName\": \"mvp-draft\",\n        \"jobId\": \"1\",\n        \"jobStatus\": \"SUCCEED\",\n        \"commitId\": \"abc123...\"\n      }\n    }","operationId":"amplify_webhook_webhooks_deploy_amplify_post","parameters":[{"name":"x-veyond-deploy-secret","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Veyond-Deploy-Secret"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/webhooks/deploy/apprunner":{"post":{"tags":["deploy-webhooks"],"summary":"Apprunner Webhook","description":"Expected payload — EventBridge sends App Runner deployment events:\n{\n  \"detail\": {\n    \"OperationStatus\": \"SUCCEEDED\" | \"FAILED\",\n    \"ServiceArn\": \"...\",\n    \"OperationId\": \"...\"\n  },\n  \"commit_sha\": \"abc123...\"  (must be added by the EventBridge transform\n                              or read from the App Runner GitHub source)\n}\n\nApp Runner's EventBridge events do NOT include the commit SHA. Two\noptions to fix that:\n  1. Configure the EventBridge target to include `$.detail.SourceCommitId`\n     if your service uses a Git source (App Runner exposes this on\n     CreateService / UpdateService responses but not the deploy event).\n  2. Have your CI pipeline POST here directly with the SHA after the\n     deploy completes (most reliable).\n\nEither way, we read commit_sha from the top level of the payload —\nif missing, we drop the event (see below).","operationId":"apprunner_webhook_webhooks_deploy_apprunner_post","parameters":[{"name":"x-veyond-deploy-secret","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Veyond-Deploy-Secret"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/webhooks/deploy/worker":{"post":{"tags":["deploy-webhooks"],"summary":"Worker Webhook","description":"Deploy status for the `veyond-backend-worker` ECS service.\n\nPosted by CI (.github/workflows/deploy-backend.yml) after it refreshes the\nworker service and waits for it to stabilize on the new image. Shares the\nbackend (App Runner) secret since both come from the same trusted CI run.\n\nExpected payload:\n    {\"commit_sha\": \"abc123...\", \"detail\": {\"OperationStatus\": \"SUCCEEDED\"}}\n`status` / `jobStatus` at the top level are accepted as fallbacks.","operationId":"worker_webhook_webhooks_deploy_worker_post","parameters":[{"name":"x-veyond-deploy-secret","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Veyond-Deploy-Secret"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/webhooks/deploy/cloudflare":{"post":{"tags":["deploy-webhooks"],"summary":"Cloudflare Webhook","description":"Expected payload — Cloudflare Pages deploy hook:\n{\n  \"deployment\": {\n    \"id\": \"...\",\n    \"deployment_trigger\": {\n      \"metadata\": {\n        \"branch\": \"mvp-draft\",\n        \"commit_hash\": \"abc123...\",\n        \"commit_message\": \"...\"\n      }\n    },\n    \"latest_stage\": {\n      \"name\": \"deploy\",\n      \"status\": \"success\" | \"failure\"\n    },\n    \"stages\": [...]\n  }\n}","operationId":"cloudflare_webhook_webhooks_deploy_cloudflare_post","parameters":[{"name":"secret","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secret"}},{"name":"x-veyond-deploy-secret","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Veyond-Deploy-Secret"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/demo/login":{"post":{"tags":["demo"],"summary":"Demo Login","description":"Validate the shared passcode. No account, no DB row, no token.\n\nThe frontend keeps the passcode the prospect typed and replays it as the\nX-Demo-Passcode header on /demo/chat, so there's nothing to hand back except\nthe email (echoed for use as the PostHog distinct_id).","operationId":"demo_login_demo_login_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoLoginRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/demo/chat":{"post":{"tags":["demo"],"summary":"Demo Chat","description":"Stateless AI Q&A over the fixture transcripts. Same SSE shape as /chat.","operationId":"demo_chat_demo_chat_post","parameters":[{"name":"X-Demo-Passcode","in":"header","required":false,"schema":{"type":"string","default":"","title":"X-Demo-Passcode"}},{"name":"X-Prospect-Email","in":"header","required":false,"schema":{"type":"string","default":"","title":"X-Prospect-Email"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoChatRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/public/share/{token}":{"get":{"tags":["public-share"],"summary":"Get Public Share","description":"Return the anonymized profile for the token's single expert + open slots.\n\n``lang`` (query param, \"en\"|\"ko\") drives the translation of free-text content\n(why_match) so the public page matches the language of the email that linked\nhere. The page chrome is localized client-side from the same param.","operationId":"get_public_share_public_share__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}},{"name":"lang","in":"query","required":false,"schema":{"type":"string","default":"en","title":"Lang"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/public/share/{token}/schedule":{"post":{"tags":["public-share"],"summary":"Schedule Public Share","description":"Book an interview from the public page — full Zoom booking, no login.\n\nAttributed to the link's client_user_id (interview shows on the client's\ndashboard, billed to the project's company like a normal booking); the\ncalendar/confirmation email goes to the link's recipient_email.","operationId":"schedule_public_share_public_share__token__schedule_post","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicScheduleRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meta":{"get":{"tags":["admin-sales"],"summary":"Get Meta","operationId":"get_meta_admin_sales_meta_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesMetaOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/owners":{"get":{"tags":["admin-sales"],"summary":"List Owners","description":"Assignable lead owners = the sales reps (admin users). Powers the owner\npicker + the 'My leads' filter; `current_user_id` lets the UI default to me.","operationId":"list_owners_admin_sales_owners_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/metrics":{"get":{"tags":["admin-sales"],"summary":"Get Metrics","description":"Conversion / funnel dashboard. Computed from the live DB — the funnel,\ntype and contact-engagement breakdowns are meaningful off imported data\n(contact statuses were backfilled), before any new sends happen.","operationId":"get_metrics_admin_sales_metrics_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads":{"get":{"tags":["admin-sales"],"summary":"List Leads","description":"Leads for the board/table. The board is a Kanban that wants whole columns,\nso this returns a generous page (default 500, cap 1000) plus `total`; the UI\nsurfaces a 'refine to narrow' notice when total exceeds what's loaded rather\nthan fetching the table unbounded.","operationId":"list_leads_admin_sales_leads_get","parameters":[{"name":"funnel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Funnel"}},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"}},{"name":"lead_type","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Lead Type"}},{"name":"owner_user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner User Id"}},{"name":"unassigned","in":"query","required":false,"schema":{"type":"boolean","description":"only leads with no owner","default":false,"title":"Unassigned"},"description":"only leads with no owner"},{"name":"country","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"title":"Country"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"substring match on company name","title":"Q"},"description":"substring match on company name"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":500,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesLeadsPage"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin-sales"],"summary":"Create Lead","operationId":"create_lead_admin_sales_leads_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesLeadCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesLeadOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}":{"get":{"tags":["admin-sales"],"summary":"Get Lead","operationId":"get_lead_admin_sales_leads__lead_id__get","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesLeadOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["admin-sales"],"summary":"Update Lead","operationId":"update_lead_admin_sales_leads__lead_id__patch","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesLeadUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesLeadOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin-sales"],"summary":"Delete Lead","operationId":"delete_lead_admin_sales_leads__lead_id__delete","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/bulk":{"post":{"tags":["admin-sales"],"summary":"Bulk Leads","description":"Apply one action to many leads at once (board multi-select).\nstage/lead_type mark each lead dirty so the Notion mirror re-syncs; a stage\nthat crosses funnels just drops the lead off the current board on reload.","operationId":"bulk_leads_admin_sales_leads_bulk_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkLeadsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/contacts":{"post":{"tags":["admin-sales"],"summary":"Add Contact","operationId":"add_contact_admin_sales_leads__lead_id__contacts_post","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesContactIn"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesContactOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/contacts/{contact_id}":{"patch":{"tags":["admin-sales"],"summary":"Update Contact","operationId":"update_contact_admin_sales_contacts__contact_id__patch","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesContactIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesContactOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin-sales"],"summary":"Delete Contact","operationId":"delete_contact_admin_sales_contacts__contact_id__delete","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/contacts/{contact_id}/linkedin-id":{"get":{"tags":["admin-sales"],"summary":"Sales Contact Linkedin Id","description":"Resolve a contact's Unipile provider id (+ the sales seat) so the panel can\nopen the in-platform LinkedIn profile view via GET\n/admin/linkedin-search/profile/{id}, instead of only linking out to\nlinkedin.com. Reuses the same lazy resolve the InMail send uses, so the id is\ncached on the contact after the first lookup.","operationId":"sales_contact_linkedin_id_admin_sales_contacts__contact_id__linkedin_id_get","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/contacts/bulk":{"post":{"tags":["admin-sales"],"summary":"Bulk Contacts","description":"Bulk-set outreach status or enroll many contacts into a cadence at once\n(inbox multi-select). Enroll skips contacts already in an active/paused\nsequence so re-running is safe; returns how many were skipped.","operationId":"bulk_contacts_admin_sales_contacts_bulk_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkContactsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/referrals":{"post":{"tags":["admin-sales"],"summary":"Create Referral","description":"Record a referral edge (referrer → referred). The referrer can be a known\nlead, a specific contact, or an external name. A referred-in lead with no\nsource set is stamped lead_source='Referral'.","operationId":"create_referral_admin_sales_referrals_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferralCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReferralOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/referrals":{"get":{"tags":["admin-sales"],"summary":"List Lead Referrals","description":"Both directions for one lead: who referred it (referred_by) and who it has\nreferred to us (referrals_made).","operationId":"list_lead_referrals_admin_sales_leads__lead_id__referrals_get","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/referrals/{referral_id}":{"delete":{"tags":["admin-sales"],"summary":"Delete Referral","operationId":"delete_referral_admin_sales_referrals__referral_id__delete","parameters":[{"name":"referral_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Referral Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/signals":{"get":{"tags":["admin-sales"],"summary":"List Signals","description":"Signal feed across all leads (newest, highest-score first) for the dashboard.","operationId":"list_signals_admin_sales_signals_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"new","title":"Status"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"default":30,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SignalOut"},"title":"Response List Signals Admin Sales Signals Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/signals":{"get":{"tags":["admin-sales"],"summary":"List Lead Signals","operationId":"list_lead_signals_admin_sales_leads__lead_id__signals_get","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SignalOut"},"title":"Response List Lead Signals Admin Sales Leads  Lead Id  Signals Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/check-signals":{"post":{"tags":["admin-sales"],"summary":"Check Signals","description":"Queue a manual signal check — the worker's signal sweep drains\n`signals_check_requested_at` on its next pass. We deliberately do NOT report\na web-tier `enabled` flag here: SALES_SIGNALS_ENABLED gates the WORKER loop\nand is always false on the web tier, so surfacing it told the user \"off\" even\nwhen the worker was actively draining. The web tier can't observe worker\nliveness, so the honest answer is just \"queued.","operationId":"check_signals_admin_sales_leads__lead_id__check_signals_post","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/signals/{signal_id}/status":{"post":{"tags":["admin-sales"],"summary":"Set Signal Status","operationId":"set_signal_status_admin_sales_signals__signal_id__status_post","parameters":[{"name":"signal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Signal Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalStatusRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignalOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/templates":{"get":{"tags":["admin-sales"],"summary":"List Templates","description":"Sales message templates. Pickers get active-only (default); the template\nmanager passes include_inactive=true to also list disabled ones.","operationId":"list_templates_admin_sales_templates_get","parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TemplateOut"},"title":"Response List Templates Admin Sales Templates Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin-sales"],"summary":"Create Template","operationId":"create_template_admin_sales_templates_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/templates/{template_id}":{"patch":{"tags":["admin-sales"],"summary":"Update Template","operationId":"update_template_admin_sales_templates__template_id__patch","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin-sales"],"summary":"Delete Template","description":"Hard-delete a template. Sequence steps referencing its key keep the key but\nrender empty (handled gracefully) until re-pointed — same as 'write live'.","operationId":"delete_template_admin_sales_templates__template_id__delete","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/accounts":{"get":{"tags":["admin-sales"],"summary":"List Send Accounts","description":"LinkedIn accounts the sales composer can send from, each with its live\nUnipile InMail credit balance + connectivity — same seats/credits the expert\ninbox shows, so reps can see headroom before sending.\n\nWith `contact_id`, each seat also carries `blocked_for_contact` — a seat we've\nseen LinkedIn refuse for this specific person (so the composer can deprioritize\nit and pre-pick a reachable seat instead of repeating a doomed send).\n\nSync `def` (NOT async) on purpose: it makes blocking Unipile HTTP calls\n(get_account_credits) that must run in Starlette's threadpool, not on the event\nloop. Per-seat balances are TTL-cached (UNIPILE_INMAIL_ACCOUNTS_TTL_S) and the\nseats are fetched concurrently, mirroring /admin/inmail/accounts.","operationId":"list_send_accounts_admin_sales_accounts_get","parameters":[{"name":"contact_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"annotate seats LinkedIn refuses for this contact","title":"Contact Id"},"description":"annotate seats LinkedIn refuses for this contact"},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/mailboxes":{"get":{"tags":["admin-sales"],"summary":"List Mailboxes","description":"Sales mailboxes the email composer can send from (first = default).","operationId":"list_mailboxes_admin_sales_mailboxes_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/generate":{"post":{"tags":["admin-sales"],"summary":"Generate Message","operationId":"generate_message_admin_sales_generate_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/thread":{"get":{"tags":["admin-sales"],"summary":"Get Thread","operationId":"get_thread_admin_sales_leads__lead_id__thread_get","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ThreadMessage"},"title":"Response Get Thread Admin Sales Leads  Lead Id  Thread Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/inbox/contacts":{"get":{"tags":["admin-sales"],"summary":"List Inbox Contacts","description":"The sales inbox is per-PERSON: one row per contact, carrying the parent\nlead's company + stage. Sorted/filtered/paginated SERVER-SIDE so the list\nscales — the activity sort, status + direction filters, and name/company\nsearch all run in SQL, and the client appends pages via limit/offset.","operationId":"list_inbox_contacts_admin_sales_inbox_contacts_get","parameters":[{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"substring match on contact name OR company","title":"Q"},"description":"substring match on contact name OR company"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"filter by the contact's outreach_status","title":"Status"},"description":"filter by the contact's outreach_status"},{"name":"direction","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"'received' (they spoke last) | 'sent' (we spoke last)","title":"Direction"},"description":"'received' (they spoke last) | 'sent' (we spoke last)"},{"name":"channel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"comma-sep subset of email,linkedin_inmail — keep contacts with ≥1 message on those channels","title":"Channel"},"description":"comma-sep subset of email,linkedin_inmail — keep contacts with ≥1 message on those channels"},{"name":"funnel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"comma-sep subset of cold_outreach,sales_pipeline — the parent lead's funnel","title":"Funnel"},"description":"comma-sep subset of cold_outreach,sales_pipeline — the parent lead's funnel"},{"name":"sort","in":"query","required":false,"schema":{"type":"string","description":"'response' (latest reply) | 'activity' (latest in/out)","default":"activity","title":"Sort"},"description":"'response' (latest reply) | 'activity' (latest in/out)"},{"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"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxContactsPage"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/inbox/contacts/{contact_id}":{"get":{"tags":["admin-sales"],"summary":"Get Inbox Contact","description":"One inbox row — lets a deep-link (?contact=…) open a thread whose contact\nisn't on the currently-loaded page.","operationId":"get_inbox_contact_admin_sales_inbox_contacts__contact_id__get","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboxContactOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/contacts/{contact_id}/thread":{"get":{"tags":["admin-sales"],"summary":"Get Contact Thread","description":"The conversation with ONE person (messages tagged to this contact).","operationId":"get_contact_thread_admin_sales_contacts__contact_id__thread_get","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ThreadMessage"},"title":"Response Get Contact Thread Admin Sales Contacts  Contact Id  Thread Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/triage":{"get":{"tags":["admin-sales"],"summary":"Get Triage","description":"Replies awaiting your response — the contact spoke last and it's a REAL\nreply (auto/OOO excluded). Prioritized by intent then close-likelihood.","operationId":"get_triage_admin_sales_triage_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TriageItem"},"title":"Response Get Triage Admin Sales Triage Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/action-counts":{"get":{"tags":["admin-sales"],"summary":"Get Action Counts","description":"Consolidated 'needs action' counts for the Sales sidebar badges — replies\nawaiting you, pending agent candidates, and new signals.","operationId":"get_action_counts_admin_sales_action_counts_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/contacts/{contact_id}/set-main":{"post":{"tags":["admin-sales"],"summary":"Set Main Contact","operationId":"set_main_contact_admin_sales_contacts__contact_id__set_main_post","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesContactOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/demo":{"post":{"tags":["admin-sales"],"summary":"Schedule Demo","description":"Rep schedules an in-person demo. Advances cold leads to Demo Scheduled and\nsets the attending contact as the lead's main contact.","operationId":"schedule_demo_admin_sales_leads__lead_id__demo_post","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/demos":{"get":{"tags":["admin-sales"],"summary":"List Demos","operationId":"list_demos_admin_sales_demos_get","parameters":[{"name":"scope","in":"query","required":false,"schema":{"type":"string","default":"upcoming","title":"Scope"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DemoOut"},"title":"Response List Demos Admin Sales Demos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/demos/{demo_id}/ics":{"get":{"tags":["admin-sales"],"summary":"Get Demo Ics","description":"Return the .ics so the frontend can offer 'Add to calendar' (the calendar\nthen handles reminders — we don't send Slack/email).","operationId":"get_demo_ics_admin_sales_demos__demo_id__ics_get","parameters":[{"name":"demo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Demo Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/demos/{demo_id}/outcome":{"post":{"tags":["admin-sales"],"summary":"Demo Outcome","operationId":"demo_outcome_admin_sales_demos__demo_id__outcome_post","parameters":[{"name":"demo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Demo Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoOutcomeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/inbox/contacts/{contact_id}/move-to-expert":{"post":{"tags":["admin-sales"],"summary":"Move Contact To Expert","description":"This person isn't a sales lead — move their LinkedIn thread(s) to the\nexpert inbox and remember the decision so future messages follow it.","operationId":"move_contact_to_expert_admin_sales_inbox_contacts__contact_id__move_to_expert_post","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/inbox/adopt":{"post":{"tags":["admin-sales"],"summary":"Adopt Thread To Sales","description":"Pull a thread from the expert inbox into the sales inbox under the chosen\nlead/contact, and remember the decision.","operationId":"adopt_thread_to_sales_admin_sales_inbox_adopt_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdoptThreadRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/send":{"post":{"tags":["admin-sales"],"summary":"Send Sales Message","description":"Manual sales send. Runs in FastAPI's threadpool (sync def) so the blocking\nUnipile/Graph calls don't touch the event loop.","operationId":"send_sales_message_admin_sales_send_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/draft":{"post":{"tags":["admin-sales"],"summary":"Draft Sales Reply","description":"Gemini-generated next sales message over the lead's full thread + context.\nReturned for the rep to review/edit — nothing is sent here.","operationId":"draft_sales_reply_admin_sales_draft_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DraftRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DraftResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/sequences":{"get":{"tags":["admin-sales"],"summary":"List Sequences","operationId":"list_sequences_admin_sales_sequences_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceOut"},"title":"Response List Sequences Admin Sales Sequences Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin-sales"],"summary":"Create Sequence","operationId":"create_sequence_admin_sales_sequences_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/sequences/{sequence_id}":{"delete":{"tags":["admin-sales"],"summary":"Delete Sequence","operationId":"delete_sequence_admin_sales_sequences__sequence_id__delete","parameters":[{"name":"sequence_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Sequence Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/contacts/{contact_id}/enrollment":{"get":{"tags":["admin-sales"],"summary":"Get Enrollment","description":"The contact's current cadence enrollment (+ the rendered due step), or null.","operationId":"get_enrollment_admin_sales_contacts__contact_id__enrollment_get","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/contacts/{contact_id}/enroll":{"post":{"tags":["admin-sales"],"summary":"Enroll Contact","operationId":"enroll_contact_admin_sales_contacts__contact_id__enroll_post","parameters":[{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnrollRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/enrollments/{enrollment_id}/send":{"post":{"tags":["admin-sales"],"summary":"Send Sequence Step","description":"Approve + send the current (due) step, then advance the cadence.","operationId":"send_sequence_step_admin_sales_enrollments__enrollment_id__send_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SeqSendRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/enrollments/{enrollment_id}/skip":{"post":{"tags":["admin-sales"],"summary":"Skip Sequence Step","operationId":"skip_sequence_step_admin_sales_enrollments__enrollment_id__skip_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/enrollments/{enrollment_id}/pause":{"post":{"tags":["admin-sales"],"summary":"Pause Enrollment","operationId":"pause_enrollment_admin_sales_enrollments__enrollment_id__pause_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/enrollments/{enrollment_id}/resume":{"post":{"tags":["admin-sales"],"summary":"Resume Enrollment","operationId":"resume_enrollment_admin_sales_enrollments__enrollment_id__resume_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/enrollments/{enrollment_id}/stop":{"post":{"tags":["admin-sales"],"summary":"Stop Enrollment","operationId":"stop_enrollment_admin_sales_enrollments__enrollment_id__stop_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/enrollments/due":{"get":{"tags":["admin-sales"],"summary":"List Due Steps","description":"Read-only 'steps due' queue: active enrollments whose next step is due\n(same filter as hh_sourcing_agent._remind_due_steps), joined to contact/lead\nso the dashboard can deep-link to each thread without opening it first.","operationId":"list_due_steps_admin_sales_enrollments_due_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/discover":{"post":{"tags":["admin-sales"],"summary":"Discover","operationId":"discover_admin_sales_discover_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscoverRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/enrich":{"post":{"tags":["admin-sales"],"summary":"Enrich","operationId":"enrich_admin_sales_enrich_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnrichRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/linkedin-fetch":{"post":{"tags":["admin-sales"],"summary":"Linkedin Fetch","operationId":"linkedin_fetch_admin_sales_linkedin_fetch_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkedInFetchRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/jobs":{"get":{"tags":["admin-sales"],"summary":"List Jobs","operationId":"list_jobs_admin_sales_jobs_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/JobOut"},"title":"Response List Jobs Admin Sales Jobs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/candidates":{"get":{"tags":["admin-sales"],"summary":"List Candidates","operationId":"list_candidates_admin_sales_candidates_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"PENDING","title":"Status"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CandidateOut"},"title":"Response List Candidates Admin Sales Candidates Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/candidates/{candidate_id}/approve":{"post":{"tags":["admin-sales"],"summary":"Approve Candidate","description":"Promote a candidate into a sales_lead (+ contact). Dedups onto an existing\nlead by company name; net-new leads enter the cold funnel as 'Not Contacted'.","operationId":"approve_candidate_admin_sales_candidates__candidate_id__approve_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SalesLeadOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/candidates/bulk":{"post":{"tags":["admin-sales"],"summary":"Bulk Candidates","description":"Approve many discovery candidates in ONE transaction (single commit).\nDedups company names WITHIN the batch so 3 candidates for the same company\nfold onto one lead — the race a naive front-end Promise.all of single approves\nwould hit. Returns {created, duplicates}.","operationId":"bulk_candidates_admin_sales_candidates_bulk_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkCandidatesRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/candidates/{candidate_id}/reject":{"post":{"tags":["admin-sales"],"summary":"Reject Candidate","operationId":"reject_candidate_admin_sales_candidates__candidate_id__reject_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/candidates/{candidate_id}/dismiss":{"post":{"tags":["admin-sales"],"summary":"Dismiss Candidate","description":"Remove a candidate from the pending review list without rejecting it. Unlike\na reject this carries no \"bad lead\" signal — it just clears the board. DISMISSED\nis non-PENDING, so it leaves the list/badge and stays re-sourceable by a future run.","operationId":"dismiss_candidate_admin_sales_candidates__candidate_id__dismiss_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/candidates/dismiss-all":{"post":{"tags":["admin-sales"],"summary":"Dismiss All Candidates","description":"Clear the whole pending review list in one go (e.g. before re-running discovery).\nDismissed candidates stay re-sourceable — see dismiss_candidate. Returns the ids\ntouched so the UI can offer an Undo.","operationId":"dismiss_all_candidates_admin_sales_candidates_dismiss_all_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/candidates/{candidate_id}/restore":{"post":{"tags":["admin-sales"],"summary":"Restore Candidate","description":"Undo a dismiss/reject — put the candidate back on the pending review list.\nNo-op if it was already promoted to a lead (APPROVED).","operationId":"restore_candidate_admin_sales_candidates__candidate_id__restore_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/qa":{"post":{"tags":["admin-sales"],"summary":"Sales Qa","description":"Answer a question over the current sales pipeline (on-platform Q&A).","operationId":"sales_qa_admin_sales_qa_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QARequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QAResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meetings/upload-file":{"post":{"tags":["admin-sales"],"summary":"Upload Meeting File","description":"Stream one meeting audio (or transcript) file to S3 and return its key. The\nclient then passes `s3_key` to POST /leads/{lead_id}/meetings. Reuses the same\nprivate meeting-bot bucket as interview self-uploads.","operationId":"upload_meeting_file_admin_sales_meetings_upload_file_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_meeting_file_admin_sales_meetings_upload_file_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/meetings":{"post":{"tags":["admin-sales"],"summary":"Create Meeting","description":"Create a meeting under a company. If audio or a pasted transcript is present,\nstatus='processing' + kick the background transcribe/summarize; else 'ready'.","operationId":"create_meeting_admin_sales_leads__lead_id__meetings_post","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["admin-sales"],"summary":"List Meetings","description":"A company's meetings, newest first. Projects ONLY light columns — never the\ntranscript/notes/summary bodies (egress discipline on the hot drawer path).","operationId":"list_meetings_admin_sales_leads__lead_id__meetings_get","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MeetingListItem"},"title":"Response List Meetings Admin Sales Leads  Lead Id  Meetings Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meetings":{"get":{"tags":["admin-sales"],"summary":"List All Meetings","description":"Firm-wide meetings list for the Meetings tab. Filter by one OR many companies\n(company_ids) and/or search by company name, meeting title, or the met-with\ncontact's name/email (q). Projects ONLY light columns — never transcript/notes/\nsummary bodies (egress discipline).","operationId":"list_all_meetings_admin_sales_meetings_get","parameters":[{"name":"company_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string","format":"uuid"}},{"type":"null"}],"title":"Company Ids"}},{"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,"default":100,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MeetingListItem"},"title":"Response List All Meetings Admin Sales Meetings Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meeting-companies":{"get":{"tags":["admin-sales"],"summary":"List Meeting Companies","description":"Companies that have at least one meeting — powers the Meetings-tab company filter.","operationId":"list_meeting_companies_admin_sales_meeting_companies_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MeetingCompanyFacet"},"title":"Response List Meeting Companies Admin Sales Meeting Companies Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meetings/{meeting_id}":{"get":{"tags":["admin-sales"],"summary":"Get Meeting","operationId":"get_meeting_admin_sales_meetings__meeting_id__get","parameters":[{"name":"meeting_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Meeting Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["admin-sales"],"summary":"Update Meeting","description":"Save admin edits. Editing `notes` stamps the author/time audit fields.","operationId":"update_meeting_admin_sales_meetings__meeting_id__patch","parameters":[{"name":"meeting_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Meeting Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin-sales"],"summary":"Delete Meeting","operationId":"delete_meeting_admin_sales_meetings__meeting_id__delete","parameters":[{"name":"meeting_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Meeting Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meetings/{meeting_id}/ics":{"get":{"tags":["admin-sales"],"summary":"Get Meeting Ics","description":"Return the .ics so the admin can add this meeting to their calendar.","operationId":"get_meeting_ics_admin_sales_meetings__meeting_id__ics_get","parameters":[{"name":"meeting_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Meeting Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meetings/{meeting_id}/regenerate-note":{"post":{"tags":["admin-sales"],"summary":"Regenerate Meeting Note","description":"Re-run the AI note from the stored transcript. Writes ai_summary/ai_summary_en\nONLY — never the admin-owned `notes`.","operationId":"regenerate_meeting_note_admin_sales_meetings__meeting_id__regenerate_note_post","parameters":[{"name":"meeting_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Meeting Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meetings/{meeting_id}/process":{"post":{"tags":["admin-sales"],"summary":"Process Meeting","description":"(Re)attach a recording and/or existing notes to a meeting and (re)run the\npipeline. New audio is always re-transcribed (and resets the transcript + AI\ndraft); an uploaded notes file/text overwrites the editable note.","operationId":"process_meeting_admin_sales_meetings__meeting_id__process_post","parameters":[{"name":"meeting_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Meeting Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingProcess"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/meetings/{meeting_id}/next-action":{"post":{"tags":["admin-sales"],"summary":"Suggest Next Action","description":"Generate (or regenerate) the AI next-action suggestion from this meeting's\ntranscript + notes, and persist it. Admin-initiated; always available (the\nSALES_MEETING_NEXT_ACTION_ENABLED flag only gates the automatic one at ingest).","operationId":"suggest_next_action_admin_sales_meetings__meeting_id__next_action_post","parameters":[{"name":"meeting_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Meeting Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/sales/leads/{lead_id}/meetings/qa":{"post":{"tags":["admin-sales"],"summary":"Sales Meeting Qa","description":"Q&A across a company's meeting transcripts + notes. Full-stuff (no RAG);\nreal names (sales is NOT anonymized). Scoped strictly by sales_lead_id.","operationId":"sales_meeting_qa_admin_sales_leads__lead_id__meetings_qa_post","parameters":[{"name":"lead_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Lead Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeetingQARequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QAResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/blog":{"get":{"tags":["blog"],"summary":"Blog Index","operationId":"blog_index_blog_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/blog/sitemap.xml":{"get":{"tags":["blog"],"summary":"Blog Sitemap","operationId":"blog_sitemap_blog_sitemap_xml_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/blog/feed.json":{"get":{"tags":["blog"],"summary":"Blog Feed","description":"Public JSON feed for the landing page's news strip. Declared before\n/blog/{slug} so the slug route doesn't swallow it.","operationId":"blog_feed_blog_feed_json_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/blog/{slug}":{"get":{"tags":["blog"],"summary":"Blog Post","operationId":"blog_post_blog__slug__get","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/press":{"get":{"tags":["blog"],"summary":"Press Index","description":"Consolidated into /media (opens on the 'In the news' tab).","operationId":"press_index_press_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/media":{"get":{"tags":["blog"],"summary":"Media Index","description":"Combined 'Media' page — press coverage and the blog, split into two tabs.\nOne public entry point (linked from the landing footer + header); the blog\nposts still have their own crawlable permalinks at /blog/{slug}.","operationId":"media_index_media_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/admin/pr/items":{"get":{"tags":["admin-pr"],"summary":"List Items","operationId":"list_items_admin_pr_items_get","parameters":[{"name":"channel","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PRItemOut"},"title":"Response List Items Admin Pr Items Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/generate-now":{"post":{"tags":["admin-pr"],"summary":"Generate Now","description":"Cross-tier 'Generate now' — the worker claims force_run_requested_at.","operationId":"generate_now_admin_pr_generate_now_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRGenerateNowRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/press":{"post":{"tags":["admin-pr"],"summary":"Add Press","description":"Add a third-party press mention by hand — enters the PENDING queue like a\ngenerated draft, then an admin approves it onto the public /press page. (The\nfuture Google-News discovery loop will create press items the same way.)","operationId":"add_press_admin_pr_press_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRPressCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRItemOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/blog":{"post":{"tags":["admin-pr"],"summary":"Add Blog","description":"Compose an original blog post by hand — enters the PENDING queue like a\ngenerated draft; approving it publishes to /blog via the blog publisher. The\nanonymity guard still applies on approve (don't leak a client's identity).","operationId":"add_blog_admin_pr_blog_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRBlogCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRItemOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/items/{item_id}":{"patch":{"tags":["admin-pr"],"summary":"Update Item","operationId":"update_item_admin_pr_items__item_id__patch","parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Item Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRItemOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin-pr"],"summary":"Delete Item","operationId":"delete_item_admin_pr_items__item_id__delete","parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Item Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/items/{item_id}/review":{"post":{"tags":["admin-pr"],"summary":"Review Item","operationId":"review_item_admin_pr_items__item_id__review_post","parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Item Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRReviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRItemOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/items/bulk-review":{"post":{"tags":["admin-pr"],"summary":"Bulk Review","operationId":"bulk_review_admin_pr_items_bulk_review_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRBulkReviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRBulkReviewResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/topics":{"get":{"tags":["admin-pr"],"summary":"List Topics","operationId":"list_topics_admin_pr_topics_get","parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Inactive"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PRTopicOut"},"title":"Response List Topics Admin Pr Topics Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin-pr"],"summary":"Create Topic","operationId":"create_topic_admin_pr_topics_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRTopicCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRTopicOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/topics/{topic_id}":{"patch":{"tags":["admin-pr"],"summary":"Update Topic","operationId":"update_topic_admin_pr_topics__topic_id__patch","parameters":[{"name":"topic_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Topic Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRTopicUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRTopicOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["admin-pr"],"summary":"Delete Topic","operationId":"delete_topic_admin_pr_topics__topic_id__delete","parameters":[{"name":"topic_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Topic Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/pr/settings":{"get":{"tags":["admin-pr"],"summary":"Get Settings","operationId":"get_settings_admin_pr_settings_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRSettingsOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["admin-pr"],"summary":"Update Settings","operationId":"update_settings_admin_pr_settings_patch","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRSettingsUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PRSettingsOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/me":{"get":{"tags":["headhunter"],"summary":"Get Me","operationId":"get_me_hh_me_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhMeOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/dashboard":{"get":{"tags":["headhunter"],"summary":"Dashboard","description":"Overview metrics for the firm's home page (member-visibility scoped).","operationId":"dashboard_hh_dashboard_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/reports":{"get":{"tags":["headhunter"],"summary":"Reports","description":"Deeper analytics for the firm: funnel conversion, time-to-X, per-recruiter\nbreakdown, and weekly outreach volume. Member-visibility scoped, approved\ncandidates only (matching the pipeline).","operationId":"reports_hh_reports_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/seat":{"get":{"tags":["headhunter"],"summary":"List Seats","operationId":"list_seats_hh_seat_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhSeatOut"},"title":"Response List Seats Hh Seat Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/seat/connect-link":{"post":{"tags":["headhunter"],"summary":"Seat Connect Link","description":"Owner starts connecting the firm's LinkedIn account (hosted auth). Creates\nan empty seat row if none exists, and returns the one-time wizard URL.","operationId":"seat_connect_link_hh_seat_connect_link_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/seat/{seat_id}/reconnect-link":{"post":{"tags":["headhunter"],"summary":"Seat Reconnect Link","operationId":"seat_reconnect_link_hh_seat__seat_id__reconnect_link_post","parameters":[{"name":"seat_id","in":"path","required":true,"schema":{"type":"string","title":"Seat Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/projects":{"get":{"tags":["headhunter"],"summary":"List Projects","operationId":"list_projects_hh_projects_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhProjectOut"},"title":"Response List Projects Hh Projects Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Create Project","operationId":"create_project_hh_projects_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhProjectCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhProjectOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/projects/{project_id}":{"patch":{"tags":["headhunter"],"summary":"Update Project","operationId":"update_project_hh_projects__project_id__patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhProjectUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhProjectOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/projects/{project_id}/shares":{"get":{"tags":["headhunter"],"summary":"List Project Shares","description":"Who a project is explicitly shared with (per-member grants) + whether it's\nfirm-wide. The caller must be able to see the project.","operationId":"list_project_shares_hh_projects__project_id__shares_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhProjectSharesOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Add Project Share","description":"Share a project with a specific firm member (ENS-style). Idempotent; pings\nthe firm's Slack. The target must belong to the same firm.","operationId":"add_project_share_hh_projects__project_id__shares_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhProjectShareIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhProjectSharesOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/projects/{project_id}/shares/{target_member_id}":{"delete":{"tags":["headhunter"],"summary":"Remove Project Share","description":"Revoke a member's access to a project (their own private rows stay theirs).","operationId":"remove_project_share_hh_projects__project_id__shares__target_member_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"target_member_id","in":"path","required":true,"schema":{"type":"string","title":"Target Member Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/requests":{"get":{"tags":["headhunter"],"summary":"List Requests","operationId":"list_requests_hh_requests_get","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhRequestOut"},"title":"Response List Requests Hh Requests Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Create Request","description":"Create a prompt-based request and parse it into structured search params.\nThe recruiter then reviews the parse and confirms to start sourcing.","operationId":"create_request_hh_requests_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhRequestCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhRequestOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/requests/{request_id}/reparse":{"post":{"tags":["headhunter"],"summary":"Reparse Request","operationId":"reparse_request_hh_requests__request_id__reparse_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhRequestOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/requests/{request_id}/confirm":{"post":{"tags":["headhunter"],"summary":"Confirm Request","description":"Recruiter confirms/edits the parsed fields → approve the SearchHistory and\nenqueue a worker-tier sourcing job on the firm's seat.","operationId":"confirm_request_hh_requests__request_id__confirm_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhRequestConfirm"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhRequestOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/requests/{request_id}/extract-keywords":{"post":{"tags":["headhunter"],"summary":"Extract Request Keywords","description":"Suggest search keywords for the recruiter to review/edit before sourcing —\nthe ENS keyword-review step. Returns whatever's already saved on the request;\nif none, extracts fresh from the parsed verifying questions (and persists them\nso the list is stable across reloads). Best-effort: never 500 on an LLM blip.","operationId":"extract_request_keywords_hh_requests__request_id__extract_keywords_post","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/requests/{request_id}/sourcing":{"get":{"tags":["headhunter"],"summary":"Request Sourcing Status","description":"Live sourcing status + per-keyword progress for a request (drives the\nAgent Sourcing progress panel). Returns nulls when nothing has been queued.","operationId":"request_sourcing_status_hh_requests__request_id__sourcing_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/sourcing-jobs/{job_id}/combos/{combo_index}/{op}":{"post":{"tags":["headhunter"],"summary":"Control Combo","description":"Pause / skip / resume a single keyword combination mid-run (ENS parity).\nThe worker honours the control between combinations and between pages.","operationId":"control_combo_hh_sourcing_jobs__job_id__combos__combo_index___op__post","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}},{"name":"combo_index","in":"path","required":true,"schema":{"type":"integer","title":"Combo Index"}},{"name":"op","in":"path","required":true,"schema":{"type":"string","title":"Op"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/sourcing-jobs/{job_id}/{op}":{"post":{"tags":["headhunter"],"summary":"Control Job","description":"Pause / resume the whole sourcing run. Pause stops the worker at the next\npage boundary and parks the job; resume re-queues it to continue where it\nleft off (persisted per-keyword progress).","operationId":"control_job_hh_sourcing_jobs__job_id___op__post","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}},{"name":"op","in":"path","required":true,"schema":{"type":"string","title":"Op"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates":{"get":{"tags":["headhunter"],"summary":"List Candidates","description":"List candidates. The Pipeline board passes review_status='approved' (so\nit never shows un-reviewed agent picks); the Agent Sourcing review page\npasses review_status='pending' (or 'rejected'/'approved' via tabs).","operationId":"list_candidates_hh_candidates_get","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"}},{"name":"stage","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"}},{"name":"review_status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Status"}},{"name":"source","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhCandidateOut"},"title":"Response List Candidates Hh Candidates Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Add Candidate","description":"Add a profile from manual LinkedIn search into a project's pipeline.\nDedups on (project, linkedin_id).","operationId":"add_candidate_hh_candidates_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhCandidateCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhCandidateOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}":{"patch":{"tags":["headhunter"],"summary":"Update Candidate","operationId":"update_candidate_hh_candidates__candidate_id__patch","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhCandidateUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhCandidateOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/suppressions":{"get":{"tags":["headhunter"],"summary":"List Suppressions","description":"The firm's off-limits companies + do-not-contact people (firm policy —\nevery recruiter shares it).","operationId":"list_suppressions_hh_suppressions_get","parameters":[{"name":"kind","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhSuppressionOut"},"title":"Response List Suppressions Hh Suppressions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Add Suppression","description":"Add an off-limits company or a do-not-contact person.","operationId":"add_suppression_hh_suppressions_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSuppressionIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSuppressionOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/suppressions/{suppression_id}":{"delete":{"tags":["headhunter"],"summary":"Delete Suppression","description":"Remove an off-limits / do-not-contact entry (un-block outreach).","operationId":"delete_suppression_hh_suppressions__suppression_id__delete","parameters":[{"name":"suppression_id","in":"path","required":true,"schema":{"type":"string","title":"Suppression Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/suppress":{"post":{"tags":["headhunter"],"summary":"Suppress Candidate","description":"Mark a pipeline candidate do-not-contact from the candidate drawer — adds a\nperson entry keyed on their LinkedIn identity so future sends are blocked.","operationId":"suppress_candidate_hh_candidates__candidate_id__suppress_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhCandidateSuppressIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSuppressionOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/interview-invite":{"post":{"tags":["headhunter"],"summary":"Create Interview Invite","description":"Propose interview slots for a candidate → a no-login self-book link. Any\nprior pending invite for the candidate is revoked so only one is live.","operationId":"create_interview_invite_hh_candidates__candidate_id__interview_invite_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhInterviewInviteCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhInterviewInviteOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/interview-invites":{"get":{"tags":["headhunter"],"summary":"List Interview Invites","description":"Interview invites for a candidate (newest first) — for the drawer.","operationId":"list_interview_invites_hh_candidates__candidate_id__interview_invites_get","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhInterviewInviteOut"},"title":"Response List Interview Invites Hh Candidates  Candidate Id  Interview Invites Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/interview-invites/{invite_id}/revoke":{"post":{"tags":["headhunter"],"summary":"Revoke Interview Invite","operationId":"revoke_interview_invite_hh_interview_invites__invite_id__revoke_post","parameters":[{"name":"invite_id","in":"path","required":true,"schema":{"type":"string","title":"Invite Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/talent-pools":{"get":{"tags":["headhunter"],"summary":"List Talent Pools","description":"The firm's talent pools (member-visibility scoped) with member counts.","operationId":"list_talent_pools_hh_talent_pools_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhTalentPoolOut"},"title":"Response List Talent Pools Hh Talent Pools Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Create Talent Pool","operationId":"create_talent_pool_hh_talent_pools_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTalentPoolCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTalentPoolOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/talent-pools/{pool_id}":{"get":{"tags":["headhunter"],"summary":"Get Talent Pool","operationId":"get_talent_pool_hh_talent_pools__pool_id__get","parameters":[{"name":"pool_id","in":"path","required":true,"schema":{"type":"string","title":"Pool Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTalentPoolDetailOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["headhunter"],"summary":"Update Talent Pool","operationId":"update_talent_pool_hh_talent_pools__pool_id__patch","parameters":[{"name":"pool_id","in":"path","required":true,"schema":{"type":"string","title":"Pool Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTalentPoolUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTalentPoolOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["headhunter"],"summary":"Delete Talent Pool","operationId":"delete_talent_pool_hh_talent_pools__pool_id__delete","parameters":[{"name":"pool_id","in":"path","required":true,"schema":{"type":"string","title":"Pool Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/talent-pools/{pool_id}/candidates":{"post":{"tags":["headhunter"],"summary":"Add To Talent Pool","description":"Add candidates to a pool. From the pipeline pass candidate_ids (the server\nsnapshots their identity); from manual search pass a raw member. De-duped per\n(pool, linkedin_id). Returns how many were newly added.","operationId":"add_to_talent_pool_hh_talent_pools__pool_id__candidates_post","parameters":[{"name":"pool_id","in":"path","required":true,"schema":{"type":"string","title":"Pool Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhPoolAddIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/talent-pools/{pool_id}/members/{member_row_id}":{"delete":{"tags":["headhunter"],"summary":"Remove From Talent Pool","operationId":"remove_from_talent_pool_hh_talent_pools__pool_id__members__member_row_id__delete","parameters":[{"name":"pool_id","in":"path","required":true,"schema":{"type":"string","title":"Pool Id"}},{"name":"member_row_id","in":"path","required":true,"schema":{"type":"string","title":"Member Row Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/send":{"post":{"tags":["headhunter"],"summary":"Send Outreach","description":"Send an InMail from the FIRM's own seat and log it. Advances the candidate\nto Contacted. (Email channel is a later phase.)","operationId":"send_outreach_hh_candidates__candidate_id__send_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhOutboundIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhCandidateOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/draft":{"post":{"tags":["headhunter"],"summary":"Draft Outreach","description":"AI-draft an outbound recruiting InMail grounded in the candidate's profile\n(the \"hooking message\"). Non-anonymized — this is the recruiter's own\noutreach. Optionally adapts a chosen template + a free-text instruction.","operationId":"draft_outreach_hh_candidates__candidate_id__draft_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhDraftIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/thread":{"get":{"tags":["headhunter"],"summary":"Candidate Thread","description":"The outbound + inbound message timeline for one candidate (for the detail\ndrawer).","operationId":"candidate_thread_hh_candidates__candidate_id__thread_get","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/appearances":{"get":{"tags":["headhunter"],"summary":"Candidate Appearances","description":"Other pipeline appearances of the SAME person (matched by linkedin_id) across\nthe firm's OTHER projects — so a recruiter never double-outreaches. Visibility-\nscoped: only appearances the member may see (shared or their own) are returned.","operationId":"candidate_appearances_hh_candidates__candidate_id__appearances_get","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/linkedin-search":{"post":{"tags":["headhunter"],"summary":"Linkedin Search","description":"One page of manual LinkedIn people search on the firm's OWN seat, drawing\ndown the firm's daily budget (hh_seat_usage). Body: {filters, page_size, cursor}.","operationId":"linkedin_search_hh_linkedin_search_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/linkedin-search/parameters":{"get":{"tags":["headhunter"],"summary":"Linkedin Search Parameters","description":"Resolve a company/location/etc. name to Unipile ids for the search\nautocompletes, so the recruiter targets a company/region by ID (which\nLinkedIn actually enforces) instead of free text. Mirrors the ENS admin\nautocomplete; company/region resolve via our shared param seat, exactly like\nthe sourcing agent does.","operationId":"linkedin_search_parameters_hh_linkedin_search_parameters_get","parameters":[{"name":"type","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Type"}},{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/linkedin-search/profile/{unipile_user_id}":{"get":{"tags":["headhunter"],"summary":"Linkedin Profile","operationId":"linkedin_profile_hh_linkedin_search_profile__unipile_user_id__get","parameters":[{"name":"unipile_user_id","in":"path","required":true,"schema":{"type":"string","title":"Unipile User Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/saved-searches":{"get":{"tags":["headhunter"],"summary":"List Saved Searches","operationId":"list_saved_searches_hh_saved_searches_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhSavedSearchOut"},"title":"Response List Saved Searches Hh Saved Searches Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Create Saved Search","operationId":"create_saved_search_hh_saved_searches_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSavedSearchIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSavedSearchOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/saved-searches/{search_id}":{"patch":{"tags":["headhunter"],"summary":"Update Saved Search","description":"Toggle alerts / sharing on a saved search. Enabling alerts is opt-in; the\nworker only sweeps when HH_SAVED_SEARCH_ALERTS_ENABLED is on.","operationId":"update_saved_search_hh_saved_searches__search_id__patch","parameters":[{"name":"search_id","in":"path","required":true,"schema":{"type":"string","title":"Search Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSavedSearchUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSavedSearchOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["headhunter"],"summary":"Delete Saved Search","operationId":"delete_saved_search_hh_saved_searches__search_id__delete","parameters":[{"name":"search_id","in":"path","required":true,"schema":{"type":"string","title":"Search Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/saved-searches/{search_id}/check":{"post":{"tags":["headhunter"],"summary":"Check Saved Search","description":"Re-run a saved search NOW and surface which results are NEW since the last\ncheck (in-app equivalent of the worker's alert). Updates the baseline +\nlast_checked_at. First check just records the baseline (nothing is \"new\").\nSpends daily seat budget like a manual search.","operationId":"check_saved_search_hh_saved_searches__search_id__check_post","parameters":[{"name":"search_id","in":"path","required":true,"schema":{"type":"string","title":"Search Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/shortlists":{"post":{"tags":["headhunter"],"summary":"Create Shortlist","description":"Create a shareable client shortlist from candidates the member may see.","operationId":"create_shortlist_hh_shortlists_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhShortlistIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["headhunter"],"summary":"List Shortlists","operationId":"list_shortlists_hh_shortlists_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/shortlists/{shortlist_id}":{"get":{"tags":["headhunter"],"summary":"Get Shortlist","operationId":"get_shortlist_hh_shortlists__shortlist_id__get","parameters":[{"name":"shortlist_id","in":"path","required":true,"schema":{"type":"string","title":"Shortlist Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["headhunter"],"summary":"Delete Shortlist","operationId":"delete_shortlist_hh_shortlists__shortlist_id__delete","parameters":[{"name":"shortlist_id","in":"path","required":true,"schema":{"type":"string","title":"Shortlist Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/shortlists/{shortlist_id}/revoke":{"post":{"tags":["headhunter"],"summary":"Revoke Shortlist","description":"Revoke the public link (feedback is kept; the client view stops working).","operationId":"revoke_shortlist_hh_shortlists__shortlist_id__revoke_post","parameters":[{"name":"shortlist_id","in":"path","required":true,"schema":{"type":"string","title":"Shortlist Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/templates":{"get":{"tags":["headhunter"],"summary":"List Templates","operationId":"list_templates_hh_templates_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhTemplateOut"},"title":"Response List Templates Hh Templates Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Create Template","operationId":"create_template_hh_templates_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTemplateIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTemplateOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/templates/stats":{"get":{"tags":["headhunter"],"summary":"Template Stats","description":"Per-template outreach performance, keyed by template_key:\n  sent      — total InMails sent that used this template\n  contacted — distinct candidates it reached\n  replied   — distinct of those candidates who then replied\n  reply_rate — replied / contacted (0..1)\n  last_sent_at — most recent send\n\nFirm-wide (a template is a firm asset). Reply attribution: a candidate\ncounts as a reply for template K if they were sent K and later replied\n(replied_at at/after the send) — approximate when several templates hit the\nsame person, but a solid per-template signal.","operationId":"template_stats_hh_templates_stats_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/templates/draft":{"post":{"tags":["headhunter"],"summary":"Draft Template","description":"AI-draft a REUSABLE outreach template from a free-text description. Uses the\n{name} placeholder (filled per-candidate on send), no signature (appended\nseparately). Returns {subject, body}.","operationId":"draft_template_hh_templates_draft_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTemplateDraftIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/templates/{template_id}":{"patch":{"tags":["headhunter"],"summary":"Update Template","operationId":"update_template_hh_templates__template_id__patch","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","title":"Template Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTemplateIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhTemplateOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["headhunter"],"summary":"Delete Template","operationId":"delete_template_hh_templates__template_id__delete","parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","title":"Template Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/inbox":{"get":{"tags":["headhunter"],"summary":"List Inbox","description":"Inbound replies for the firm. By default only replies from candidates in the\npipeline who were actually CONTACTED are shown — a headhunter contacts first, so\neverything else (unmatched senders, never-contacted rows) is noise. Pass\ninclude_unmatched=true to also surface unmatched inbound (e.g. a reply whose\nLinkedIn id didn't resolve to a candidate).","operationId":"list_inbox_hh_inbox_get","parameters":[{"name":"unread_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Unread Only"}},{"name":"include_unmatched","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Unmatched"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhInboundOut"},"title":"Response List Inbox Hh Inbox Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/inbox/{message_id}/read":{"post":{"tags":["headhunter"],"summary":"Mark Read","operationId":"mark_read_hh_inbox__message_id__read_post","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/inbox/{message_id}/draft":{"post":{"tags":["headhunter"],"summary":"Draft Reply","description":"AI-draft a reply to a candidate's inbound message (recruiter edits + sends).\nNon-anonymized — this is the recruiter's own outreach. An optional free-text\n`instruction` steers the tone/angle of the draft.","operationId":"draft_reply_hh_inbox__message_id__draft_post","parameters":[{"name":"message_id","in":"path","required":true,"schema":{"type":"string","title":"Message Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhDraftIn","default":{}}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/members":{"get":{"tags":["headhunter"],"summary":"List Members","operationId":"list_members_hh_members_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhMemberOut"},"title":"Response List Members Hh Members Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/members/invite":{"post":{"tags":["headhunter"],"summary":"Invite Member","description":"Firm owner invites a recruiter. If the email already has an account we\nattach them; otherwise we return an invite link they open after signing up.","operationId":"invite_member_hh_members_invite_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhMemberInviteIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/firm/branding":{"patch":{"tags":["headhunter"],"summary":"Update Branding","description":"Owner sets the firm's brand name / accent color / logo (shown in the /hh\nshell). Requires the branding migration.","operationId":"update_branding_hh_firm_branding_patch","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhBrandingIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/firm/settings":{"get":{"tags":["headhunter"],"summary":"Get Firm Settings","description":"Owner reads the firm's channel config (Slack webhook, send mailbox).","operationId":"get_firm_settings_hh_firm_settings_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["headhunter"],"summary":"Update Firm Settings","operationId":"update_firm_settings_hh_firm_settings_patch","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhFirmSettingsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/members/{target_id}":{"patch":{"tags":["headhunter"],"summary":"Update Member","operationId":"update_member_hh_members__target_id__patch","parameters":[{"name":"target_id","in":"path","required":true,"schema":{"type":"string","title":"Target Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhMemberRoleIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhMemberOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["headhunter"],"summary":"Remove Member","operationId":"remove_member_hh_members__target_id__delete","parameters":[{"name":"target_id","in":"path","required":true,"schema":{"type":"string","title":"Target Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/sequences":{"get":{"tags":["headhunter"],"summary":"List Sequences","operationId":"list_sequences_hh_sequences_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhSequenceOut"},"title":"Response List Sequences Hh Sequences Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["headhunter"],"summary":"Create Sequence","operationId":"create_sequence_hh_sequences_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSequenceIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSequenceOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/sequences/{sequence_id}":{"patch":{"tags":["headhunter"],"summary":"Update Sequence","operationId":"update_sequence_hh_sequences__sequence_id__patch","parameters":[{"name":"sequence_id","in":"path","required":true,"schema":{"type":"string","title":"Sequence Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSequenceIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhSequenceOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["headhunter"],"summary":"Delete Sequence","operationId":"delete_sequence_hh_sequences__sequence_id__delete","parameters":[{"name":"sequence_id","in":"path","required":true,"schema":{"type":"string","title":"Sequence Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/{candidate_id}/enroll":{"post":{"tags":["headhunter"],"summary":"Enroll Candidate","description":"Enroll a candidate into a sequence. Sets the first step due (now + its\nday_offset). Idempotent per (candidate, sequence) while active.","operationId":"enroll_candidate_hh_candidates__candidate_id__enroll_post","parameters":[{"name":"candidate_id","in":"path","required":true,"schema":{"type":"string","title":"Candidate Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhEnrollIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/bulk-stage":{"post":{"tags":["headhunter"],"summary":"Bulk Stage","description":"Move many candidates to a stage in one call. Returns how many were updated.","operationId":"bulk_stage_hh_candidates_bulk_stage_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhBulkStageIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/bulk-review":{"post":{"tags":["headhunter"],"summary":"Bulk Review","description":"Approve / reject / restore many sourced candidates in one call (the Agent\nSourcing review page's bulk bar). approve → enters the Pipeline; reject →\nhidden from Pipeline; restore → back to pending. Returns how many changed.","operationId":"bulk_review_hh_candidates_bulk_review_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhBulkReviewIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/scoring/defaults":{"get":{"tags":["headhunter"],"summary":"Scoring Defaults","description":"Default fit-scoring weight profile + component labels for the Request-page\nweight editor. VQ-answerability is excluded from the HH default.","operationId":"scoring_defaults_hh_scoring_defaults_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/candidates/bulk-enroll":{"post":{"tags":["headhunter"],"summary":"Bulk Enroll","description":"Enroll many candidates into one sequence (idempotent per candidate).","operationId":"bulk_enroll_hh_candidates_bulk_enroll_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhBulkEnrollIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/sequences/due":{"get":{"tags":["headhunter"],"summary":"Due Steps","description":"Active enrollments whose current step is due now, with the rendered step —\nthe recruiter reviews and approves each (nothing auto-sends).","operationId":"due_steps_hh_sequences_due_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhDueStepOut"},"title":"Response Due Steps Hh Sequences Due Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/sequences/paused":{"get":{"tags":["headhunter"],"summary":"Paused Steps","description":"Paused enrollments — surfaced so a recruiter can resume or stop them\n(otherwise a paused cadence is invisible).","operationId":"paused_steps_hh_sequences_paused_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhDueStepOut"},"title":"Response Paused Steps Hh Sequences Paused Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/enrollments/{enrollment_id}/send":{"post":{"tags":["headhunter"],"summary":"Send Due Step","description":"Approve + send the enrollment's current due step (recruiter may have edited\nthe text), then advance to the next step or complete.","operationId":"send_due_step_hh_enrollments__enrollment_id__send_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhOutboundIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/enrollments/{enrollment_id}/pause":{"post":{"tags":["headhunter"],"summary":"Pause Enrollment","operationId":"pause_enrollment_hh_enrollments__enrollment_id__pause_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/enrollments/{enrollment_id}/resume":{"post":{"tags":["headhunter"],"summary":"Resume Enrollment","operationId":"resume_enrollment_hh_enrollments__enrollment_id__resume_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/enrollments/{enrollment_id}/stop":{"post":{"tags":["headhunter"],"summary":"Stop Enrollment","operationId":"stop_enrollment_hh_enrollments__enrollment_id__stop_post","parameters":[{"name":"enrollment_id","in":"path","required":true,"schema":{"type":"string","title":"Enrollment Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/demo/status":{"get":{"tags":["headhunter-demo"],"summary":"Demo Status","operationId":"demo_status_hh_demo_status_get","parameters":[{"name":"email","in":"query","required":true,"schema":{"type":"string","title":"Email"}},{"name":"x-demo-passcode","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Demo-Passcode"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/demo/linkedin-search/parameters":{"get":{"tags":["headhunter-demo"],"summary":"Demo Search Parameters","description":"Passcode-gated company/location autocomplete for the public demo form, so a\nprospect targets a company/region by Unipile id (with logos) exactly like the\nin-platform Search page. Metadata lookup on the shared param seat only — no\npeople-search, no profile spend — so it isn't subject to the search/profile\ncaps. Restricted to company + location (all the demo form needs).","operationId":"demo_search_parameters_hh_demo_linkedin_search_parameters_get","parameters":[{"name":"type","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Type"}},{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2,"title":"Q"}},{"name":"x-demo-passcode","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Demo-Passcode"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/demo/linkedin-search":{"post":{"tags":["headhunter-demo"],"summary":"Demo Linkedin Search","description":"One capped, real-data LinkedIn people-search on the shared demo seat.\nBody: {filters, page_size}. Requires X-Demo-Passcode + X-Prospect-Email.","operationId":"demo_linkedin_search_hh_demo_linkedin_search_post","parameters":[{"name":"x-demo-passcode","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Demo-Passcode"}},{"name":"x-prospect-email","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Prospect-Email"}},{"name":"x-forwarded-for","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Forwarded-For"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/demo/linkedin-search/profile/{unipile_user_id}":{"get":{"tags":["headhunter-demo"],"summary":"Demo Profile","description":"Full profile for one demo search result (passcode-gated), so demo results\nexpand into the same in-platform profile view as the paid product. Doesn't\ncount against the profile cap — it's viewing an already-searched result.","operationId":"demo_profile_hh_demo_linkedin_search_profile__unipile_user_id__get","parameters":[{"name":"unipile_user_id","in":"path","required":true,"schema":{"type":"string","title":"Unipile User Id"}},{"name":"x-demo-passcode","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Demo-Passcode"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/public/shortlist/{token}":{"get":{"tags":["headhunter-public"],"summary":"Public Shortlist","operationId":"public_shortlist_hh_public_shortlist__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/public/shortlist/{token}/feedback":{"post":{"tags":["headhunter-public"],"summary":"Public Feedback","operationId":"public_feedback_hh_public_shortlist__token__feedback_post","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}},{"name":"x-forwarded-for","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Forwarded-For"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhShortlistFeedbackIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/public/interview/{token}":{"get":{"tags":["headhunter-public"],"summary":"Public Interview","description":"No-login candidate view of an interview invite: brand + proposed slots.","operationId":"public_interview_hh_public_interview__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhPublicInterviewOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/public/interview/{token}/book":{"post":{"tags":["headhunter-public"],"summary":"Public Interview Book","description":"Candidate books one of the proposed slots. Idempotent-ish: re-booking the\nsame slot is fine; a booked invite can't be re-picked to a different slot.","operationId":"public_interview_book_hh_public_interview__token__book_post","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}},{"name":"x-forwarded-for","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Forwarded-For"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhInterviewBookIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/public/interview/{token}/decline":{"post":{"tags":["headhunter-public"],"summary":"Public Interview Decline","operationId":"public_interview_decline_hh_public_interview__token__decline_post","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}},{"name":"x-forwarded-for","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Forwarded-For"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/hh/auth/register":{"post":{"tags":["headhunter-auth"],"summary":"Register","operationId":"register_hh_auth_register_post","parameters":[{"name":"x-forwarded-for","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Forwarded-For"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhRegisterIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/hh/firms":{"get":{"tags":["admin-headhunter"],"summary":"List Firms","operationId":"list_firms_admin_hh_firms_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HhFirmAdminOut"},"title":"Response List Firms Admin Hh Firms Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin-headhunter"],"summary":"Create Firm","operationId":"create_firm_admin_hh_firms_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhFirmCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhFirmAdminOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/hh/firms/{firm_id}":{"patch":{"tags":["admin-headhunter"],"summary":"Update Firm","operationId":"update_firm_admin_hh_firms__firm_id__patch","parameters":[{"name":"firm_id","in":"path","required":true,"schema":{"type":"string","title":"Firm Id"}},{"name":"plan","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhFirmAdminOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/hh/firms/{firm_id}/seat/connect-link":{"post":{"tags":["admin-headhunter"],"summary":"Firm Seat Connect Link","description":"Create (if needed) the firm's seat and return a hosted-auth connect link\nfor the AE to complete the firm's LinkedIn login.","operationId":"firm_seat_connect_link_admin_hh_firms__firm_id__seat_connect_link_post","parameters":[{"name":"firm_id","in":"path","required":true,"schema":{"type":"string","title":"Firm Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/hh/firms/{firm_id}/branding":{"patch":{"tags":["admin-headhunter"],"summary":"Firm Branding","description":"AE sets a firm's branding (brand name / accent / logo).","operationId":"firm_branding_admin_hh_firms__firm_id__branding_patch","parameters":[{"name":"firm_id","in":"path","required":true,"schema":{"type":"string","title":"Firm Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhBrandingIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/hh/firms/{firm_id}/invite":{"post":{"tags":["admin-headhunter"],"summary":"Invite Recruiter","description":"Invite a recruiter to a firm. If a user with that email already exists we\nattach them immediately; otherwise we return an invite link they open after\nsigning up (the /hh accept page calls /hh/auth/register with invite_firm_id).","operationId":"invite_recruiter_admin_hh_firms__firm_id__invite_post","parameters":[{"name":"firm_id","in":"path","required":true,"schema":{"type":"string","title":"Firm Id"}},{"name":"authorization","in":"header","required":true,"schema":{"type":"string","title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HhInviteIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/":{"get":{"summary":"Root","description":"Root endpoint","operationId":"root__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health":{"get":{"summary":"Health Check","description":"Liveness probe for the ALB target group — MUST stay cheap and never\ntouch the DB.\n\nThis used to run a *synchronous* `SELECT 1` inside this `async def`, which\nblocks the single event loop. During a new task's startup the Supabase\npooler briefly refuses connections (`warm_pool ... econnrefused, retrying`),\nso that blocking call hung the loop past the ALB's 5s health-check timeout →\n\"Request timed out\" → the deployment circuit breaker rolled the new image\nback to the previous one. The web tier therefore never advanced past an old\nimage. A liveness probe should answer \"is this process accepting requests\",\nnot \"is every downstream dependency up\" — so we no longer gate ALB health on\nthe DB. DB connectivity/latency is available at `/health/db` for debugging.","operationId":"health_check_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/version":{"get":{"summary":"Version","description":"Report the exact commit this running process was built from — cheap, no\nDB. CI hits this after a deploy to confirm the live web tier is actually\nserving the just-shipped SHA. If an ECS circuit-breaker rollback left the\nOLD task running, this returns the previous SHA and the deploy job fails →\nSlack reports FAILED instead of a phantom success.","operationId":"version_version_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health/db":{"get":{"summary":"Health Check Db","description":"DB connectivity + pool stats (manual/debugging — NOT the ALB probe).\n\nSync `def` so FastAPI runs the blocking SQLAlchemy call in the threadpool,\noff the event loop. Returns 200 with `status: unhealthy` on failure rather\nthan raising, so a probe pointed here still distinguishes process-up from\nDB-down by body, not by a hung connection.","operationId":"health_check_db_health_db_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"AddExperienceRequest":{"properties":{"company_name":{"type":"string","title":"Company Name"},"company_linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Linkedin Id"},"role":{"type":"string","title":"Role"},"role_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"}},"type":"object","required":["company_name","role"],"title":"AddExperienceRequest","description":"Request schema for adding work experience"},"AddUserRequest":{"properties":{"email":{"type":"string","title":"Email"}},"type":"object","required":["email"],"title":"AddUserRequest","description":"Request to add a user to a project by email"},"AdditionalVQsRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"expert_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Expert Ids"},"questions":{"items":{"type":"string"},"type":"array","title":"Questions"},"question_type":{"type":"string","title":"Question Type","default":"VETTING"}},"type":"object","required":["project_id","expert_ids","questions"],"title":"AdditionalVQsRequest"},"AdminAddExperienceRequest":{"properties":{"company_linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Linkedin Id"},"company_name":{"type":"string","title":"Company Name"},"company_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Id"},"role":{"type":"string","title":"Role"},"role_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"}},"type":"object","required":["company_name","role"],"title":"AdminAddExperienceRequest","description":"Request schema for admin adding work experience with LinkedIn company info"},"AdminAddExpertRequest":{"properties":{"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"unipile_user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unipile User Id"},"unipile_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unipile Account Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"company_linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Linkedin Id"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"add_to_outreach":{"type":"boolean","title":"Add To Outreach","default":false},"search_history_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Search History Id"},"source_filters":{"anyOf":[{"$ref":"#/components/schemas/LinkedInSearchFilters"},{"type":"null"}]},"why_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Why Note"},"target_company_override":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Company Override"}},"type":"object","title":"AdminAddExpertRequest","description":"Request to add an expert to a project (by ID, LinkedIn URL, or Unipile id)"},"AdminAddExpertResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"expert_name":{"type":"string","title":"Expert Name"},"is_new":{"type":"boolean","title":"Is New"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","expert_id","expert_name","is_new","message"],"title":"AdminAddExpertResponse","description":"Response after adding expert to project"},"AdminAddProjectClientRequest":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"}},"type":"object","required":["user_id"],"title":"AdminAddProjectClientRequest","description":"Assign an existing client account to a project so it appears in that\nclient's dashboard. `user_id` must be a CLIENT user."},"AdminAnswerItem":{"properties":{"question_id":{"type":"string","format":"uuid","title":"Question Id"},"answer_text":{"type":"string","title":"Answer Text"}},"type":"object","required":["question_id","answer_text"],"title":"AdminAnswerItem","description":"Single question answer pair"},"AdminAssignCompanyRequest":{"properties":{"company_id":{"type":"string","format":"uuid","title":"Company Id"}},"type":"object","required":["company_id"],"title":"AdminAssignCompanyRequest","description":"Request to assign a user to a company"},"AdminAssignRequest":{"properties":{"admin_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Admin Id"}},"type":"object","title":"AdminAssignRequest","description":"Request to assign/unassign an admin to an expert outreach"},"AdminBulkProcessPaymentItem":{"properties":{"interview_id":{"type":"string","format":"uuid","title":"Interview Id"},"amount":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Amount"},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"}},"type":"object","required":["interview_id"],"title":"AdminBulkProcessPaymentItem","description":"One row in a bulk payout run — carries its own computed amount/currency."},"AdminBulkProcessPaymentRequest":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AdminBulkProcessPaymentItem"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"AdminBulkProcessPaymentRequest","description":"Process many interview payouts in one transaction."},"AdminClientUserResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"type":"string","title":"Email"},"company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"}},"type":"object","required":["id","email"],"title":"AdminClientUserResponse","description":"Client user with optional company assignment"},"AdminCompaniesPage":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AdminCompanyResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"AdminCompaniesPage","description":"Paginated envelope for the admin companies-with-credits list."},"AdminCompanyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"credit_balance":{"type":"number","title":"Credit Balance"},"client_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Type"},"user_count":{"type":"integer","title":"User Count"},"users":{"items":{"$ref":"#/components/schemas/AdminCompanyUserInfo"},"type":"array","title":"Users","default":[]}},"type":"object","required":["id","name","credit_balance","user_count"],"title":"AdminCompanyResponse","description":"Company with credit balance and associated users"},"AdminCompanyUserInfo":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"type":"string","title":"Email"}},"type":"object","required":["id","email"],"title":"AdminCompanyUserInfo","description":"Minimal user info for company user list"},"AdminConversationItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"kind":{"type":"string","title":"Kind"},"external_user_id":{"type":"string","format":"uuid","title":"External User Id"},"external_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Name"},"external_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Company"},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"expert_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Name"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"has_inmail":{"type":"boolean","title":"Has Inmail","default":false},"assigned_admin_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned Admin Id"},"assigned_admin_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned Admin Name"},"last_message_preview":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Message Preview"},"last_message_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Message At"},"unread_count":{"type":"integer","title":"Unread Count","default":0}},"type":"object","required":["id","kind","external_user_id"],"title":"AdminConversationItem"},"AdminConversationsResponse":{"properties":{"conversations":{"items":{"$ref":"#/components/schemas/AdminConversationItem"},"type":"array","title":"Conversations"}},"type":"object","required":["conversations"],"title":"AdminConversationsResponse"},"AdminCreateClientRequest":{"properties":{"email":{"type":"string","title":"Email"},"password":{"type":"string","title":"Password"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"}},"type":"object","required":["email","password"],"title":"AdminCreateClientRequest","description":"Request schema for admin creating a new client account"},"AdminCreateClientResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"email":{"type":"string","title":"Email"}},"type":"object","required":["success","message","user_id","email"],"title":"AdminCreateClientResponse","description":"Response schema for newly created client account"},"AdminCreateCompanyRequest":{"properties":{"name":{"type":"string","title":"Name"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"headcount":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headcount"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"}},"type":"object","required":["name"],"title":"AdminCreateCompanyRequest","description":"Request to manually create a company"},"AdminCreateExpertRequest":{"properties":{"linkedin_url":{"type":"string","title":"Linkedin Url"}},"type":"object","required":["linkedin_url"],"title":"AdminCreateExpertRequest","description":"Request to create an expert (standalone, not linked to a project)"},"AdminCreateExpertResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"expert_name":{"type":"string","title":"Expert Name"},"is_new":{"type":"boolean","title":"Is New"},"message":{"type":"string","title":"Message"},"anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anon Code"}},"type":"object","required":["success","expert_id","expert_name","is_new","message"],"title":"AdminCreateExpertResponse","description":"Response after creating an expert"},"AdminCreateManualExpertRequest":{"properties":{"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"price":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price"},"expert_cost":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expert Cost"}},"type":"object","required":["first_name","last_name"],"title":"AdminCreateManualExpertRequest","description":"Create an expert with NO LinkedIn profile (referred by hand). The point is\nto mint a VY code (anon_code) we can hand the client. Rates have no stored\ncurrency — magnitude decides (>=10000 => KRW), matching the admin table."},"AdminCreateProjectRequest":{"properties":{"title":{"type":"string","title":"Title"},"client_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client User Id"}},"type":"object","required":["title"],"title":"AdminCreateProjectRequest","description":"Request to create a project from the admin manual-search flow."},"AdminCreateProjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"}},"type":"object","required":["id","title"],"title":"AdminCreateProjectResponse","description":"Newly created project."},"AdminCreateRevenueTransactionRequest":{"properties":{"company_id":{"type":"string","format":"uuid","title":"Company Id"},"tier_code":{"type":"string","title":"Tier Code"},"received_at":{"type":"string","format":"date","title":"Received At"},"amount_krw":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Amount Krw"},"credits_granted":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Credits Granted"},"expires_at":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expires At"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["company_id","tier_code","received_at"],"title":"AdminCreateRevenueTransactionRequest","description":"Log a bank transfer. Tier picks one of KRW_TIERS or 'CUSTOM' for PAYG."},"AdminExpertPaymentResponse":{"properties":{"payment_bank_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Name"},"payment_account_holder_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Holder Name"},"payment_account_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Number"},"payment_routing_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Routing Code"},"payment_iban":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Iban"},"payment_bank_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Country"},"payment_bank_street":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Street"},"payment_bank_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank City"},"payment_bank_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank State"},"payment_bank_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Postal Code"},"payment_holder_street":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Street"},"payment_holder_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder City"},"payment_holder_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder State"},"payment_holder_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Postal Code"},"payment_holder_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Country"},"payment_setup_complete":{"type":"boolean","title":"Payment Setup Complete","default":false},"payment_id_document_filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Id Document Filename"},"payment_id_document_uploaded":{"type":"boolean","title":"Payment Id Document Uploaded","default":false},"payment_resident_registration_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Resident Registration Number"},"payment_account_region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Region"},"payment_purged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Payment Purged At"}},"type":"object","title":"AdminExpertPaymentResponse","description":"Full (unmasked) payment info for admin view"},"AdminExpertSearchResult":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"}},"type":"object","required":["expert_id"],"title":"AdminExpertSearchResult","description":"Single expert in search results"},"AdminGuidelineFileResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"file_path":{"type":"string","title":"File Path"},"original_filename":{"type":"string","title":"Original Filename"},"is_sent":{"type":"boolean","title":"Is Sent"},"uploaded_at":{"type":"string","format":"date-time","title":"Uploaded At"}},"type":"object","required":["id","file_path","original_filename","is_sent","uploaded_at"],"title":"AdminGuidelineFileResponse","description":"A single guideline file"},"AdminGuidelineInterviewResponse":{"properties":{"interview_id":{"type":"string","format":"uuid","title":"Interview Id"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"project_title":{"type":"string","title":"Project Title"},"company_names":{"items":{"type":"string"},"type":"array","title":"Company Names","default":[]},"expert_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Name"},"expert_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Email"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"scheduled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Scheduled At"},"guidelines":{"items":{"$ref":"#/components/schemas/AdminGuidelineFileResponse"},"type":"array","title":"Guidelines","default":[]},"unsent_count":{"type":"integer","title":"Unsent Count","default":0}},"type":"object","required":["interview_id","project_id","project_title"],"title":"AdminGuidelineInterviewResponse","description":"An interview with its guideline files (for admin list)"},"AdminGuidelineListResponse":{"properties":{"interviews":{"items":{"$ref":"#/components/schemas/AdminGuidelineInterviewResponse"},"type":"array","title":"Interviews"},"total":{"type":"integer","title":"Total"},"unsent_count":{"type":"integer","title":"Unsent Count"}},"type":"object","required":["interviews","total","unsent_count"],"title":"AdminGuidelineListResponse","description":"Response for admin guidelines list"},"AdminLinkedInSearchRequest":{"properties":{"filters":{"$ref":"#/components/schemas/LinkedInSearchFilters"},"page_size":{"type":"integer","title":"Page Size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"}},"type":"object","required":["filters"],"title":"AdminLinkedInSearchRequest","description":"Request for one page of an admin LinkedIn search."},"AdminLinkedInSearchResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/LinkedInSearchResultItem"},"type":"array","title":"Items"},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"},"total_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Count"},"account_id":{"type":"string","title":"Account Id"},"seat":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Seat"},"seat_used":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seat Used"},"seat_remaining":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seat Remaining"},"fetched_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fetched Count"}},"type":"object","required":["items","account_id"],"title":"AdminLinkedInSearchResponse","description":"One page of admin LinkedIn-search results."},"AdminOutreachStats":{"properties":{"total":{"type":"integer","title":"Total"},"pending":{"type":"integer","title":"Pending"},"outreach_sent":{"type":"integer","title":"Outreach Sent"},"replied":{"type":"integer","title":"Replied"},"declined":{"type":"integer","title":"Declined"},"expert_rejected":{"type":"integer","title":"Expert Rejected","default":0},"scheduled":{"type":"integer","title":"Scheduled"},"interviewed":{"type":"integer","title":"Interviewed","default":0},"follow_up":{"type":"integer","title":"Follow Up","default":0}},"type":"object","required":["total","pending","outreach_sent","replied","declined","scheduled"],"title":"AdminOutreachStats","description":"Outreach counts for a project"},"AdminProcessPaymentRequest":{"properties":{"amount":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Amount"},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"}},"type":"object","title":"AdminProcessPaymentRequest","description":"Request to mark an interview payment as processed (or update existing)"},"AdminProjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"expert_count":{"type":"integer","title":"Expert Count"},"outreach_stats":{"$ref":"#/components/schemas/AdminOutreachStats"},"company_names":{"items":{"type":"string"},"type":"array","title":"Company Names","default":[]},"latest_outreach_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Latest Outreach At"},"latest_vq_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Latest Vq At"},"latest_vq_outreach_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Latest Vq Outreach At"}},"type":"object","required":["id","title","created_at","expert_count","outreach_stats"],"title":"AdminProjectResponse","description":"Project summary for outreach list page"},"AdminReferralCreditRow":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"expert_name":{"type":"string","title":"Expert Name"},"pending":{"additionalProperties":true,"type":"object","title":"Pending","default":{}},"total":{"type":"integer","title":"Total","default":0},"has_payment_info":{"type":"boolean","title":"Has Payment Info","default":false},"over_threshold":{"type":"boolean","title":"Over Threshold","default":false}},"type":"object","required":["expert_id","expert_name"],"title":"AdminReferralCreditRow","description":"An expert with a PENDING referral-credit balance, for the admin payout view."},"AdminSetAvailabilityRequest":{"properties":{"slots":{"items":{"type":"string","format":"date-time"},"type":"array","title":"Slots"}},"type":"object","required":["slots"],"title":"AdminSetAvailabilityRequest","description":"Request to set availability datetime slots"},"AdminSubmitAnswersRequest":{"properties":{"answers":{"items":{"$ref":"#/components/schemas/AdminAnswerItem"},"type":"array","title":"Answers"}},"type":"object","required":["answers"],"title":"AdminSubmitAnswersRequest","description":"Request to submit vetting answers on behalf of expert"},"AdminUpdateCreditsRequest":{"properties":{"credit_balance":{"type":"number","title":"Credit Balance"}},"type":"object","required":["credit_balance"],"title":"AdminUpdateCreditsRequest","description":"Request to set company credit balance (flat-rate credits, 1.0 = 1 hour)."},"AdminUpdateExpertRequest":{"properties":{"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"price":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price"},"expert_cost":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expert Cost"},"outreach_channels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Outreach Channels"}},"type":"object","title":"AdminUpdateExpertRequest","description":"Request schema for admin updating any expert's profile"},"AdminUpdateOutreachStatusRequest":{"properties":{"status":{"type":"string","title":"Status"},"email_sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Email Sent At"},"reply_received_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Reply Received At"}},"type":"object","required":["status"],"title":"AdminUpdateOutreachStatusRequest","description":"Request to update outreach status"},"AdminUpdatePEURateRequest":{"properties":{"client_rate":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Client Rate"},"expert_cost":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expert Cost"}},"type":"object","title":"AdminUpdatePEURateRequest","description":"Request to manually override PEU pricing"},"AdminUpdateScoreOverrideRequest":{"properties":{"score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Score"},"breakdown":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Breakdown"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"clear":{"type":"boolean","title":"Clear","default":false}},"type":"object","title":"AdminUpdateScoreOverrideRequest","description":"Request to override (or clear) the admin-defined score on a ProjectExpert row.\n\nSend `score=null` together with `clear=True` to remove the override and fall back\nto the auto-computed score. Otherwise pass a numeric `score` (and optionally a\n`breakdown` dict + a short `note`)."},"AdoptThreadRequest":{"properties":{"chat_id":{"type":"string","title":"Chat Id"},"lead_id":{"type":"string","format":"uuid","title":"Lead Id"},"contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contact Id"}},"type":"object","required":["chat_id","lead_id"],"title":"AdoptThreadRequest"},"AgentBulkReviewRequest":{"properties":{"candidate_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Candidate Ids"},"action":{"type":"string","title":"Action"},"reason_category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Category"},"reason_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Note"}},"type":"object","required":["candidate_ids","action"],"title":"AgentBulkReviewRequest","description":"Request to bulk review candidates"},"AgentProjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"company_names":{"items":{"type":"string"},"type":"array","title":"Company Names"},"agent_paused":{"type":"boolean","title":"Agent Paused"},"agent_priority":{"type":"integer","title":"Agent Priority","default":1},"agent_last_run":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Agent Last Run"},"agent_search_budget":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Search Budget"},"agent_profiles_used":{"type":"integer","title":"Agent Profiles Used","default":0},"agent_active_search_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Active Search Id"},"pending_count":{"type":"integer","title":"Pending Count"},"approved_count":{"type":"integer","title":"Approved Count"},"rejected_count":{"type":"integer","title":"Rejected Count"},"total_count":{"type":"integer","title":"Total Count"},"outreached_count":{"type":"integer","title":"Outreached Count","default":0},"responded_count":{"type":"integer","title":"Responded Count","default":0},"searches":{"items":{"$ref":"#/components/schemas/AgentSearchSummary"},"type":"array","title":"Searches","default":[]},"agent_per_request_cap":{"type":"integer","title":"Agent Per Request Cap","default":0},"agent_auto_extend_enabled":{"type":"boolean","title":"Agent Auto Extend Enabled","default":false}},"type":"object","required":["id","title","company_names","agent_paused","pending_count","approved_count","rejected_count","total_count"],"title":"AgentProjectResponse","description":"Response for a project in the agent sourcing list"},"AgentProjectSettingsRequest":{"properties":{"paused":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Paused"},"priority":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Priority"},"search_budget":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Search Budget"},"active_search_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Active Search Id"},"clear_active_search":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Clear Active Search"},"auto_extend_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Extend Enabled"}},"type":"object","title":"AgentProjectSettingsRequest","description":"Request to update agent settings for a project"},"AgentReasonRequest":{"properties":{"reason_category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Category"},"reason_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Note"}},"type":"object","title":"AgentReasonRequest","description":"Attach/replace the analysis-only reject reason on an already-reviewed\ncandidate, without changing status or feedback."},"AgentReviewRequest":{"properties":{"action":{"type":"string","title":"Action"},"reason_category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Category"},"reason_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Note"}},"type":"object","required":["action"],"title":"AgentReviewRequest","description":"Request to review (approve/reject/unreject) a candidate"},"AgentSearchSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"request_index":{"type":"integer","title":"Request Index"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"approved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approved At"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"geography":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Geography"},"job_roles":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Roles"},"search_companies":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search Companies"},"target_interviews":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Interviews"},"agent_profiles_used":{"type":"integer","title":"Agent Profiles Used","default":0},"agent_extend_count":{"type":"integer","title":"Agent Extend Count","default":0},"keyword_phase":{"type":"string","title":"Keyword Phase","default":"not_started"},"sourcing_mode":{"type":"string","title":"Sourcing Mode","default":"standard"},"keyword_combinator":{"type":"string","title":"Keyword Combinator","default":"AND"}},"type":"object","required":["id","request_index","created_at"],"title":"AgentSearchSummary","description":"Compact summary of an approved SearchHistory row for the active-search dropdown."},"AgentSeatStatus":{"properties":{"seat":{"type":"string","title":"Seat"},"label":{"type":"string","title":"Label"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"},"used":{"type":"integer","title":"Used"},"budget":{"type":"integer","title":"Budget"},"remaining":{"type":"integer","title":"Remaining"},"preferred":{"type":"boolean","title":"Preferred","default":false},"selectable":{"type":"boolean","title":"Selectable","default":true},"throttle_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Throttle Status"},"throttled":{"type":"boolean","title":"Throttled","default":false},"throttled_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Throttled Until"}},"type":"object","required":["seat","label","used","budget","remaining"],"title":"AgentSeatStatus","description":"Per-seat budget + throttle snapshot for the agent dashboard."},"AgentStatusResponse":{"properties":{"profiles_today":{"type":"integer","title":"Profiles Today"},"daily_budget":{"type":"integer","title":"Daily Budget"},"is_running":{"type":"boolean","title":"Is Running"},"is_paused":{"type":"boolean","title":"Is Paused"},"last_heartbeat":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Heartbeat"},"active_projects":{"type":"integer","title":"Active Projects"},"paused_projects":{"type":"integer","title":"Paused Projects"},"current_project_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Project Id"},"current_project_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Project Title"},"current_variation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Variation"},"preferred_seat":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preferred Seat"},"seats":{"items":{"$ref":"#/components/schemas/AgentSeatStatus"},"type":"array","title":"Seats","default":[]}},"type":"object","required":["profiles_today","daily_budget","is_running","is_paused","active_projects","paused_projects"],"title":"AgentStatusResponse","description":"Response for agent dashboard status"},"AllExpertResponse":{"properties":{"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"account_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Status"},"expert_status":{"type":"string","title":"Expert Status","default":"ACTIVE"},"compliance_completed_expert":{"type":"boolean","title":"Compliance Completed Expert","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"needs_review_count":{"type":"integer","title":"Needs Review Count","default":0}},"type":"object","required":["expert_id","created_at"],"title":"AllExpertResponse","description":"Response schema for expert in admin all-experts list"},"AllExpertsPage":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AllExpertResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"review_total":{"type":"integer","title":"Review Total","default":0}},"type":"object","required":["items","total"],"title":"AllExpertsPage","description":"Paginated envelope for the admin all-experts list (offset/limit)."},"ApproveExpertResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"account_status":{"type":"string","title":"Account Status"}},"type":"object","required":["success","message","user_id","account_status"],"title":"ApproveExpertResponse","description":"Response schema for approving expert"},"ArchiveProjectRequest":{"properties":{"archived":{"type":"boolean","title":"Archived"}},"type":"object","required":["archived"],"title":"ArchiveProjectRequest","description":"Request to archive/unarchive a project (reversible)"},"AssignRequest":{"properties":{"admin_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Admin Id"}},"type":"object","title":"AssignRequest"},"AttachableProject":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"title":{"type":"string","title":"Title"},"experts":{"items":{"$ref":"#/components/schemas/ExpertCard"},"type":"array","title":"Experts","default":[]}},"type":"object","required":["project_id","title"],"title":"AttachableProject","description":"A client project plus the experts they may attach from it. Powers the\nproject → expert two-step picker in the chat composer."},"AttachmentProbeEntry":{"properties":{"log_id":{"type":"string","title":"Log Id"},"received_at":{"type":"string","format":"date-time","title":"Received At"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message Id"},"sender_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Name"},"raw_attachments":{"items":{},"type":"array","title":"Raw Attachments"},"normalized":{"items":{},"type":"array","title":"Normalized"}},"type":"object","required":["log_id","received_at","raw_attachments","normalized"],"title":"AttachmentProbeEntry"},"AttachmentProbeResponse":{"properties":{"scanned":{"type":"integer","title":"Scanned"},"found":{"type":"integer","title":"Found"},"entries":{"items":{"$ref":"#/components/schemas/AttachmentProbeEntry"},"type":"array","title":"Entries"}},"type":"object","required":["scanned","found","entries"],"title":"AttachmentProbeResponse"},"AttachmentRef":{"properties":{"s3_key":{"type":"string","title":"S3 Key"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size"}},"type":"object","required":["s3_key"],"title":"AttachmentRef"},"AttachmentUrlResponse":{"properties":{"url":{"type":"string","title":"Url"}},"type":"object","required":["url"],"title":"AttachmentUrlResponse"},"Body_admin_upload_attachment_admin_chat_inbox_conversations__conversation_id__attachments_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_admin_upload_attachment_admin_chat_inbox_conversations__conversation_id__attachments_post"},"Body_send_chat_reply_admin_chat__chat_id__messages_post":{"properties":{"account_id":{"type":"string","title":"Account Id"},"text":{"type":"string","title":"Text","default":""},"files":{"items":{"type":"string","format":"binary"},"type":"array","title":"Files","default":[]}},"type":"object","required":["account_id"],"title":"Body_send_chat_reply_admin_chat__chat_id__messages_post"},"Body_upload_attachment_admin_scheduled_messages_upload_post":{"properties":{"chat_id":{"type":"string","title":"Chat Id"},"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["chat_id","file"],"title":"Body_upload_attachment_admin_scheduled_messages_upload_post"},"Body_upload_meeting_file_admin_sales_meetings_upload_file_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_meeting_file_admin_sales_meetings_upload_file_post"},"Body_upload_my_attachment_chat_conversation_attachments_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_my_attachment_chat_conversation_attachments_post"},"Body_upload_payment_id_document_expert_payment_id_document_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_payment_id_document_expert_payment_id_document_post"},"Body_upload_qa_attachment_admin_qa_attachments_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_qa_attachment_admin_qa_attachments_post"},"Body_upload_self_upload_file_interviews_upload_file_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"kind":{"type":"string","title":"Kind","default":"audio"}},"type":"object","required":["file","project_id"],"title":"Body_upload_self_upload_file_interviews_upload_file_post"},"BookInterviewRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"scheduled_at":{"type":"string","format":"date-time","title":"Scheduled At"},"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"}},"type":"object","required":["project_id","expert_id","scheduled_at"],"title":"BookInterviewRequest"},"BulkCandidatesRequest":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"action":{"type":"string","title":"Action"}},"type":"object","required":["ids","action"],"title":"BulkCandidatesRequest"},"BulkCombinationRunRequest":{"properties":{"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"op":{"type":"string","enum":["pause","resume","skip","extend"],"title":"Op"}},"type":"object","required":["run_ids","op"],"title":"BulkCombinationRunRequest","description":"Apply one lifecycle op to many keyword combinations at once.\n\nThe per-row endpoints each force-run the request, so triaging a queue of\n~190 combos one click at a time meant ~190 re-activations. The batch does\nthe status flips together and reactivates sourcing exactly once."},"BulkContactsRequest":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"action":{"type":"string","title":"Action"},"value":{"type":"string","title":"Value"}},"type":"object","required":["ids","action","value"],"title":"BulkContactsRequest"},"BulkFailedIdsRequest":{"properties":{"item_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Item Ids"}},"type":"object","required":["item_ids"],"title":"BulkFailedIdsRequest"},"BulkFailedRetryRequest":{"properties":{"item_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Item Ids"},"send_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Send At"},"tz":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tz"}},"type":"object","required":["item_ids"],"title":"BulkFailedRetryRequest"},"BulkIdsRequest":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"}},"type":"object","required":["ids"],"title":"BulkIdsRequest"},"BulkInMailExpertPreview":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"display_name":{"type":"string","title":"Display Name"},"linkedin_ok":{"type":"boolean","title":"Linkedin Ok"},"suggested_rate":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Suggested Rate"},"variables":{"additionalProperties":{"type":"string"},"type":"object","title":"Variables"},"unresolved":{"items":{"type":"string"},"type":"array","title":"Unresolved"},"subject_preview":{"type":"string","title":"Subject Preview"},"body_preview":{"type":"string","title":"Body Preview"},"blocked_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Blocked Reason"},"contacted_elsewhere_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Contacted Elsewhere At"},"contacted_elsewhere_project":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contacted Elsewhere Project"},"thread_chat_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thread Chat Id"},"thread_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thread Account Id"},"thread_account_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thread Account Label"},"thread_has_reply":{"type":"boolean","title":"Thread Has Reply","default":false},"expert_timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Timezone"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"reply":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Reply"},"match_score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Match Score"}},"type":"object","required":["expert_id","display_name","linkedin_ok","variables","unresolved","subject_preview","body_preview"],"title":"BulkInMailExpertPreview"},"BulkInMailPreviewRequest":{"properties":{"expert_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Expert Ids"},"account_id":{"type":"string","title":"Account Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"variable_overrides":{"anyOf":[{"additionalProperties":{"additionalProperties":{"type":"string"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Variable Overrides"}},"type":"object","required":["expert_ids","account_id"],"title":"BulkInMailPreviewRequest","description":"Preview a bulk InMail send: resolve per-expert variables + a rendered\nmessage for each selected expert. Read-only (no Unipile, no writes)."},"BulkInMailPreviewResponse":{"properties":{"subject":{"type":"string","title":"Subject"},"body":{"type":"string","title":"Body"},"tokens":{"items":{"$ref":"#/components/schemas/BulkInMailTokenInfo"},"type":"array","title":"Tokens"},"experts":{"items":{"$ref":"#/components/schemas/BulkInMailExpertPreview"},"type":"array","title":"Experts"},"reply_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Reply Summary"}},"type":"object","required":["subject","body","tokens","experts"],"title":"BulkInMailPreviewResponse"},"BulkInMailRetryRequest":{"properties":{"account_id":{"type":"string","title":"Account Id"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"}},"type":"object","required":["account_id"],"title":"BulkInMailRetryRequest"},"BulkInMailSendItem":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"variables":{"additionalProperties":{"type":"string"},"type":"object","title":"Variables","default":{}}},"type":"object","required":["expert_id"],"title":"BulkInMailSendItem"},"BulkInMailSendRequest":{"properties":{"account_id":{"type":"string","title":"Account Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"},"subject":{"type":"string","title":"Subject"},"body":{"type":"string","title":"Body"},"items":{"items":{"$ref":"#/components/schemas/BulkInMailSendItem"},"type":"array","title":"Items"},"reply_intel":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Reply Intel"}},"type":"object","required":["account_id","subject","body","items"],"title":"BulkInMailSendRequest"},"BulkInMailSendResponse":{"properties":{"batch_id":{"type":"string","format":"uuid","title":"Batch Id"},"total":{"type":"integer","title":"Total"},"queued":{"type":"integer","title":"Queued"},"skipped":{"type":"integer","title":"Skipped"},"blocked":{"type":"integer","title":"Blocked"}},"type":"object","required":["batch_id","total","queued","skipped","blocked"],"title":"BulkInMailSendResponse"},"BulkInMailTokenInfo":{"properties":{"name":{"type":"string","title":"Name"},"kind":{"type":"string","title":"Kind"},"editable":{"type":"boolean","title":"Editable"}},"type":"object","required":["name","kind","editable"],"title":"BulkInMailTokenInfo"},"BulkLeadsRequest":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"action":{"type":"string","title":"Action"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["ids","action"],"title":"BulkLeadsRequest"},"BulkOutreachBatchStatus":{"properties":{"batch_id":{"type":"string","format":"uuid","title":"Batch Id"},"status":{"type":"string","title":"Status"},"total":{"type":"integer","title":"Total"},"sent_count":{"type":"integer","title":"Sent Count"},"failed_count":{"type":"integer","title":"Failed Count"},"skipped_count":{"type":"integer","title":"Skipped Count"},"pending_count":{"type":"integer","title":"Pending Count"},"account_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Label"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"items":{"items":{"$ref":"#/components/schemas/BulkOutreachItemStatus"},"type":"array","title":"Items"}},"type":"object","required":["batch_id","status","total","sent_count","failed_count","skipped_count","pending_count","items"],"title":"BulkOutreachBatchStatus"},"BulkOutreachBatchSummary":{"properties":{"batch_id":{"type":"string","format":"uuid","title":"Batch Id"},"status":{"type":"string","title":"Status"},"total":{"type":"integer","title":"Total"},"sent_count":{"type":"integer","title":"Sent Count"},"failed_count":{"type":"integer","title":"Failed Count"},"skipped_count":{"type":"integer","title":"Skipped Count"},"unsent_count":{"type":"integer","title":"Unsent Count"},"account_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Label"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"}},"type":"object","required":["batch_id","status","total","sent_count","failed_count","skipped_count","unsent_count"],"title":"BulkOutreachBatchSummary","description":"Header-only row for the recent-batches list.\n\nDeliberately carries NO items — the list endpoint must not selectinload them\nor join Expert, or it becomes an egress problem on a 100-expert batch.\nDrill into GET /admin/inmail/bulk/{batch_id} for per-expert detail."},"BulkOutreachItemStatus":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"status":{"type":"string","title":"Status"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"chat_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chat Id"}},"type":"object","required":["expert_id","status"],"title":"BulkOutreachItemStatus"},"BulkSearchRequestReviewRequest":{"properties":{"request_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Request Ids"},"action":{"type":"string","enum":["approve","reject"],"title":"Action"}},"type":"object","required":["request_ids","action"],"title":"BulkSearchRequestReviewRequest","description":"Approve or reject many pending search requests in one call (the inbound\nqueue is high-volume). Per-request guards mirror the single-row endpoints;\nrequests that don't qualify are reported as skipped rather than failing the\nwhole batch."},"CancelInterviewRequest":{"properties":{"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"}},"type":"object","title":"CancelInterviewRequest"},"CandidateOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"status":{"type":"string","title":"Status"},"discovery_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Discovery Mode"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"lead_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Type"},"contact_full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Full Name"},"contact_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Title"},"contact_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Email"},"contact_linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Linkedin Url"},"score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Score"},"evidence":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Evidence"},"source_query":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Query"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","status","created_at"],"title":"CandidateOut"},"ChangePasswordRequest":{"properties":{"current_password":{"type":"string","title":"Current Password"},"new_password":{"type":"string","title":"New Password"}},"type":"object","required":["current_password","new_password"],"title":"ChangePasswordRequest","description":"Request schema for password change"},"ChannelMetric":{"properties":{"channel":{"type":"string","title":"Channel"},"value":{"type":"number","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["channel","value","count"],"title":"ChannelMetric","description":"Metric broken down by outreach channel"},"ChatMessagesResponse":{"properties":{"messages":{"items":{"$ref":"#/components/schemas/app__schemas__admin__ChatMessageItem"},"type":"array","title":"Messages"},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},"type":"object","required":["messages"],"title":"ChatMessagesResponse"},"ChatNotificationsResponse":{"properties":{"total_unread":{"type":"integer","title":"Total Unread","default":0},"chats":{"items":{"$ref":"#/components/schemas/RecentChatItem"},"type":"array","title":"Chats","default":[]}},"type":"object","title":"ChatNotificationsResponse"},"ChatRequest":{"properties":{"interview_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Interview Ids"},"message":{"type":"string","title":"Message"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"session_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Session Id"}},"type":"object","required":["interview_ids","message","project_id"],"title":"ChatRequest","description":"Request to ask a question about interview transcripts"},"CompanyFilterItem":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"mode":{"type":"string","title":"Mode","default":"current"},"title":{"type":"string","title":"Title"}},"type":"object","required":["title"],"title":"CompanyFilterItem","description":"One company entry with its own tenure mode.\n\nPer-company tenure (instead of one global mode) lets admins compose\nqueries like \"currently at Acme AND previously at Boeing\" in a single\nsearch — same semantics as LinkedIn Recruiter / Sales Nav's native UI.\n\n`id` is the Unipile company id when the admin picked from autocomplete,\nor None for free-text entries (admin typed a name that didn't need to\nresolve to a LinkedIn entity). Sales Nav accepts plain-text company\nnames natively in `company.include`/`past_company.include`; Recruiter\nhas no proven free-text company field in our codebase, so free-text\nentries are folded into the keyword string there (mode-agnostic)."},"CompanyInput":{"properties":{"type":{"type":"string","title":"Type"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"title":{"type":"string","title":"Title"},"picture_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Picture Url"}},"type":"object","required":["type","title"],"title":"CompanyInput","description":"A company in a search request — either Unipile-selected or free-text."},"CompanyRequest":{"properties":{"company":{"type":"string","title":"Company"}},"type":"object","required":["company"],"title":"CompanyRequest"},"ContactListResponse":{"properties":{"submissions":{"items":{"$ref":"#/components/schemas/ContactSubmissionDetail"},"type":"array","title":"Submissions"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["submissions","total"],"title":"ContactListResponse","description":"Response schema for admin listing all contact submissions"},"ContactSubmissionDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"source":{"type":"string","title":"Source"},"name":{"type":"string","title":"Name"},"email":{"type":"string","title":"Email"},"company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"message":{"type":"string","title":"Message"},"attachment_urls":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Attachment Urls"},"is_read":{"type":"boolean","title":"Is Read"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","source","name","email","message","is_read","created_at"],"title":"ContactSubmissionDetail","description":"Response schema for admin viewing a contact submission"},"ContactSubmissionRequest":{"properties":{"name":{"type":"string","title":"Name"},"email":{"type":"string","title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"position":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Position"},"company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"referral_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Source"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"message":{"type":"string","title":"Message"}},"type":"object","required":["name","email","message"],"title":"ContactSubmissionRequest","description":"Request schema for submitting a contact form"},"ContactSubmissionResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","message"],"title":"ContactSubmissionResponse","description":"Response schema for successful contact form submission"},"ConversationMeta":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"kind":{"type":"string","title":"Kind"},"assigned_admin_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned Admin Id"},"last_message_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Message At"},"unread_count":{"type":"integer","title":"Unread Count","default":0}},"type":"object","required":["id","kind"],"title":"ConversationMeta"},"ConversationResponse":{"properties":{"conversation":{"$ref":"#/components/schemas/ConversationMeta"},"messages":{"items":{"$ref":"#/components/schemas/app__routers__chat_inbox__ChatMessageItem"},"type":"array","title":"Messages"}},"type":"object","required":["conversation","messages"],"title":"ConversationResponse"},"CreateCombinationRunRequest":{"properties":{"phase":{"type":"string","enum":["A","B"],"title":"Phase"},"keyword_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Keyword Ids"},"position":{"type":"string","enum":["front","back"],"title":"Position","default":"front"}},"type":"object","required":["phase","keyword_ids"],"title":"CreateCombinationRunRequest","description":"Hand-build one keyword combination instead of waiting for the priority\nsequence to generate it. `keyword_ids` are entries of the phase's\nagent_keyword_set_{a|b} JSONB array (1 for a single-keyword combo, 2 for a\npair). position=\"front\" makes it the next combo the agent picks."},"CreateProjectRequest":{"properties":{"title":{"type":"string","title":"Title"}},"type":"object","required":["title"],"title":"CreateProjectRequest","description":"Request to ask a question about interview transcripts"},"DeclineExpertRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"}},"type":"object","required":["project_id","expert_id"],"title":"DeclineExpertRequest"},"DefaultExpertRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"selected_expert_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Selected Expert Ids"}},"type":"object","required":["project_id"],"title":"DefaultExpertRequest"},"DeleteExpertResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","message"],"title":"DeleteExpertResponse","description":"Response schema for deleting expert"},"DemoChatRequest":{"properties":{"interview_ids":{"items":{"type":"string"},"type":"array","title":"Interview Ids","default":[]},"message":{"type":"string","title":"Message"},"project_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language"}},"type":"object","required":["message"],"title":"DemoChatRequest"},"DemoCreate":{"properties":{"contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contact Id"},"scheduled_at":{"type":"string","format":"date-time","title":"Scheduled At"},"duration_minutes":{"type":"integer","title":"Duration Minutes","default":60},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["scheduled_at"],"title":"DemoCreate"},"DemoLoginRequest":{"properties":{"email":{"type":"string","title":"Email"},"passcode":{"type":"string","title":"Passcode"}},"type":"object","required":["email","passcode"],"title":"DemoLoginRequest"},"DemoOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"sales_lead_id":{"type":"string","format":"uuid","title":"Sales Lead Id"},"sales_lead_contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sales Lead Contact Id"},"scheduled_at":{"type":"string","format":"date-time","title":"Scheduled At"},"duration_minutes":{"type":"integer","title":"Duration Minutes"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"status":{"type":"string","title":"Status"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"}},"type":"object","required":["id","sales_lead_id","scheduled_at","duration_minutes","status"],"title":"DemoOut"},"DemoOutcomeRequest":{"properties":{"status":{"type":"string","title":"Status"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"}},"type":"object","required":["status"],"title":"DemoOutcomeRequest"},"DiscoverRequest":{"properties":{"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Count","default":10}},"type":"object","title":"DiscoverRequest"},"DraftReplyRequest":{"properties":{"extra_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extra Prompt","default":""},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"}},"type":"object","title":"DraftReplyRequest"},"DraftReplyResponse":{"properties":{"message":{"type":"string","title":"Message"}},"type":"object","required":["message"],"title":"DraftReplyResponse"},"DraftRequest":{"properties":{"lead_id":{"type":"string","format":"uuid","title":"Lead Id"},"contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contact Id"},"extra_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extra Prompt","default":""}},"type":"object","required":["lead_id"],"title":"DraftRequest"},"DraftResponse":{"properties":{"message":{"type":"string","title":"Message"}},"type":"object","required":["message"],"title":"DraftResponse"},"EditVQRequest":{"properties":{"question_text":{"type":"string","title":"Question Text"}},"type":"object","required":["question_text"],"title":"EditVQRequest"},"EnrichRequest":{"properties":{"company_name":{"type":"string","title":"Company Name"}},"type":"object","required":["company_name"],"title":"EnrichRequest"},"EnrollRequest":{"properties":{"sequence_id":{"type":"string","format":"uuid","title":"Sequence Id"}},"type":"object","required":["sequence_id"],"title":"EnrollRequest"},"ExpertBasic":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anon Code"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"},"position":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Position"},"work_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Work Start"},"work_end":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Work End"}},"type":"object","required":["id","first_name","last_name"],"title":"ExpertBasic","description":"Basic expert info for interview responses"},"ExpertCard":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anon Code"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"target_companies":{"items":{"type":"string"},"type":"array","title":"Target Companies","default":[]},"status_tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status Tier"},"status_label_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status Label Key"}},"type":"object","required":["expert_id"],"title":"ExpertCard"},"ExpertChatInfo":{"properties":{"account_id":{"type":"string","title":"Account Id"},"account_label":{"type":"string","title":"Account Label"},"chat_id":{"type":"string","title":"Chat Id"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"last_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Message"},"has_messages":{"type":"boolean","title":"Has Messages","default":false}},"type":"object","required":["account_id","account_label","chat_id"],"title":"ExpertChatInfo"},"ExpertChatsResponse":{"properties":{"chats":{"items":{"$ref":"#/components/schemas/ExpertChatInfo"},"type":"array","title":"Chats"},"prior_contact":{"items":{"$ref":"#/components/schemas/PriorContactInfo"},"type":"array","title":"Prior Contact","default":[]}},"type":"object","required":["chats"],"title":"ExpertChatsResponse"},"ExpertCompanyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_name":{"type":"string","title":"Company Name"},"company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"role_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"needs_review":{"type":"boolean","title":"Needs Review","default":false}},"type":"object","required":["id","company_name"],"title":"ExpertCompanyResponse","description":"Response schema for expert work experience"},"ExpertInterviewResponse":{"properties":{"interview_id":{"type":"string","format":"uuid","title":"Interview Id"},"scheduled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Scheduled At"},"status":{"type":"string","title":"Status"},"meeting_link":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meeting Link"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"expert_payment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Payment Status"},"expert_payment_amount":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expert Payment Amount"},"expert_payment_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Payment Currency"},"expert_payment_processed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expert Payment Processed At"},"agreed_hourly_rate":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agreed Hourly Rate"},"estimated_payout":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Payout"},"rate_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Currency"}},"type":"object","required":["interview_id","status"],"title":"ExpertInterviewResponse","description":"Interview response for experts (no project info)"},"ExpertNoteRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"notes":{"type":"string","title":"Notes"}},"type":"object","required":["project_id","notes"],"title":"ExpertNoteRequest"},"ExpertOutreachInfo":{"properties":{"user_name":{"type":"string","title":"User Name"},"status":{"type":"string","title":"Status"},"is_me":{"type":"boolean","title":"Is Me","default":false}},"type":"object","required":["user_name","status"],"title":"ExpertOutreachInfo"},"ExpertPaymentInfoResponse":{"properties":{"payment_bank_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Name"},"payment_account_holder_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Holder Name"},"payment_account_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Number"},"payment_routing_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Routing Code"},"payment_iban":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Iban"},"payment_bank_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Country"},"payment_bank_street":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Street"},"payment_bank_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank City"},"payment_bank_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank State"},"payment_bank_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Postal Code"},"payment_holder_street":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Street"},"payment_holder_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder City"},"payment_holder_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder State"},"payment_holder_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Postal Code"},"payment_holder_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Country"},"payment_setup_complete":{"type":"boolean","title":"Payment Setup Complete","default":false},"payment_id_document_filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Id Document Filename"},"payment_id_document_uploaded":{"type":"boolean","title":"Payment Id Document Uploaded","default":false},"payment_resident_registration_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Resident Registration Number"},"payment_account_region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Region"},"payment_purged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Payment Purged At"},"payment_auto_purge_enabled":{"type":"boolean","title":"Payment Auto Purge Enabled","default":false}},"type":"object","title":"ExpertPaymentInfoResponse","description":"Response schema for expert payment info (sensitive fields masked)"},"ExpertProfileResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anon Code"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"price":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price"},"price_manual":{"type":"boolean","title":"Price Manual","default":false},"expert_cost":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expert Cost"},"expert_cost_manual":{"type":"boolean","title":"Expert Cost Manual","default":false},"outreach_channels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Outreach Channels"},"work_experience":{"items":{"$ref":"#/components/schemas/ExpertCompanyResponse"},"type":"array","title":"Work Experience","default":[]},"why_match":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Why Match"},"referral_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Code"},"referral_credit_pending":{"additionalProperties":true,"type":"object","title":"Referral Credit Pending","default":{}},"referral_credit_amount":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Referral Credit Amount"}},"type":"object","required":["id"],"title":"ExpertProfileResponse","description":"Response schema for expert profile"},"ExpertReactionRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"reaction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reaction"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["project_id"],"title":"ExpertReactionRequest"},"ExpertRequest":{"properties":{"companies":{"items":{"$ref":"#/components/schemas/CompanyInput"},"type":"array","title":"Companies","default":[]},"current":{"type":"string","title":"Current"},"geography":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Geography"},"industry":{"type":"string","title":"Industry"},"jobRoles":{"items":{"type":"string"},"type":"array","title":"Jobroles"},"verifyingQuestions":{"items":{"$ref":"#/components/schemas/VerifyingQuestion"},"type":"array","title":"Verifyingquestions","default":[]},"min":{"type":"integer","title":"Min"},"max":{"type":"integer","title":"Max"},"resultCount":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resultcount"},"project_id":{"type":"string","format":"uuid","title":"Project Id"}},"type":"object","required":["current","geography","industry","jobRoles","min","max","project_id"],"title":"ExpertRequest","description":"Request to get list of experts that meet the criteria"},"ExpertRescheduleRequest":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","title":"ExpertRescheduleRequest","description":"Request schema for expert requesting a reschedule"},"ExpertResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"rank":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rank"},"score_breakdown":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Score Breakdown"},"pe_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Pe Id"},"score_override":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Score Override"},"score_breakdown_override":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Score Breakdown Override"},"score_override_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Score Override Note"},"score_override_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Score Override At"},"original_score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Original Score"},"original_breakdown":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Original Breakdown"},"price":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price"},"price_manual":{"type":"boolean","title":"Price Manual","default":false},"work_experience":{"items":{"$ref":"#/components/schemas/WorkExperience"},"type":"array","title":"Work Experience"},"search_companies":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Search Companies"},"search_company_id_map":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Search Company Id Map"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"reaction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reaction"},"outreach":{"items":{"$ref":"#/components/schemas/ExpertOutreachInfo"},"type":"array","title":"Outreach","default":[]},"ens_pricing":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Ens Pricing"}},"type":"object","required":["id","first_name","last_name","work_experience"],"title":"ExpertResponse","description":"Expert response with details"},"ExpertSignupRequest":{"properties":{"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"signup_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signup Token"},"ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ref"}},"type":"object","required":["first_name","last_name","email","password"],"title":"ExpertSignupRequest","description":"Request schema for expert signup"},"ExpertSignupResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"}},"type":"object","required":["success","message"],"title":"ExpertSignupResponse","description":"Response schema for expert signup"},"FeedbackRequest":{"properties":{"type":{"type":"string","title":"Type"},"message":{"type":"string","title":"Message"},"attachment_urls":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Attachment Urls"}},"type":"object","required":["type","message"],"title":"FeedbackRequest","description":"Request schema for in-app feedback from authenticated users"},"FileAttachmentCard":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size"},"is_image":{"type":"boolean","title":"Is Image","default":false}},"type":"object","required":["id"],"title":"FileAttachmentCard"},"GenerateInMailRequest":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"},"template_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Type","default":"first_outreach"}},"type":"object","required":["expert_id"],"title":"GenerateInMailRequest","description":"Request to auto-generate an InMail message"},"GenerateInMailResponse":{"properties":{"subject":{"type":"string","title":"Subject"},"message":{"type":"string","title":"Message"}},"type":"object","required":["subject","message"],"title":"GenerateInMailResponse","description":"Auto-generated InMail message (editable by admin)"},"GenerateRequest":{"properties":{"contact_id":{"type":"string","format":"uuid","title":"Contact Id"},"template_type":{"type":"string","title":"Template Type"}},"type":"object","required":["contact_id","template_type"],"title":"GenerateRequest"},"GenerateResponse":{"properties":{"subject":{"type":"string","title":"Subject"},"message":{"type":"string","title":"Message"}},"type":"object","required":["subject","message"],"title":"GenerateResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"HhBrandingIn":{"properties":{"brand_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brand Name"},"accent_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Accent Color"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"}},"type":"object","title":"HhBrandingIn"},"HhBulkEnrollIn":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"sequence_id":{"type":"string","format":"uuid","title":"Sequence Id"}},"type":"object","required":["ids","sequence_id"],"title":"HhBulkEnrollIn"},"HhBulkReviewIn":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"action":{"type":"string","title":"Action"}},"type":"object","required":["ids","action"],"title":"HhBulkReviewIn"},"HhBulkStageIn":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"stage":{"type":"string","title":"Stage"}},"type":"object","required":["ids","stage"],"title":"HhBulkStageIn"},"HhCandidateCreate":{"properties":{"hh_project_id":{"type":"string","format":"uuid","title":"Hh Project Id"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"current_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Company"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"public_profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Profile Url"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"shared":{"type":"boolean","title":"Shared","default":false}},"type":"object","required":["hh_project_id"],"title":"HhCandidateCreate","description":"Add a profile from manual LinkedIn search into a project's pipeline."},"HhCandidateOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"hh_project_id":{"type":"string","format":"uuid","title":"Hh Project Id"},"stage":{"type":"string","title":"Stage"},"shared":{"type":"boolean","title":"Shared"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"},"source":{"type":"string","title":"Source"},"search_history_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Search History Id"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"current_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Company"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"public_profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Profile Url"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Score"},"score_breakdown":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Score Breakdown"},"mobility_score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Mobility Score"},"mobility_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mobility Label"},"review_status":{"type":"string","title":"Review Status"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rating"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"contacted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Contacted At"},"replied_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Replied At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"suppressed":{"type":"boolean","title":"Suppressed","default":false},"suppressed_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Suppressed Reason"},"stage_changed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Stage Changed At"},"days_in_stage":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days In Stage"},"stalled":{"type":"boolean","title":"Stalled","default":false},"placement_fee":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Placement Fee"},"placement_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Placement Currency"}},"type":"object","required":["id","hh_project_id","stage","shared","source","review_status","created_at","updated_at"],"title":"HhCandidateOut"},"HhCandidateSuppressIn":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","title":"HhCandidateSuppressIn","description":"Mark a pipeline candidate do-not-contact (from the candidate drawer)."},"HhCandidateUpdate":{"properties":{"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"shared":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Shared"},"rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rating"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"placement_fee":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Placement Fee"},"placement_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Placement Currency"}},"type":"object","title":"HhCandidateUpdate"},"HhDraftIn":{"properties":{"instruction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instruction"},"template_body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Body"},"template_subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Subject"}},"type":"object","title":"HhDraftIn","description":"Ask Gemini to draft an outbound recruiting InMail grounded in the\ncandidate's profile. Optional template to adapt + a free-text instruction."},"HhDueStepOut":{"properties":{"enrollment_id":{"type":"string","format":"uuid","title":"Enrollment Id"},"hh_candidate_id":{"type":"string","format":"uuid","title":"Hh Candidate Id"},"candidate_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Candidate Name"},"candidate_headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Candidate Headline"},"sequence_name":{"type":"string","title":"Sequence Name"},"step_index":{"type":"integer","title":"Step Index"},"channel":{"type":"string","title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"next_due_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Due At"}},"type":"object","required":["enrollment_id","hh_candidate_id","sequence_name","step_index","channel"],"title":"HhDueStepOut"},"HhEnrollIn":{"properties":{"sequence_id":{"type":"string","format":"uuid","title":"Sequence Id"}},"type":"object","required":["sequence_id"],"title":"HhEnrollIn"},"HhFirmAdminOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"plan":{"type":"string","title":"Plan"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"member_count":{"type":"integer","title":"Member Count","default":0},"seat_count":{"type":"integer","title":"Seat Count","default":0}},"type":"object","required":["id","name","plan","status","created_at"],"title":"HhFirmAdminOut"},"HhFirmCreate":{"properties":{"name":{"type":"string","title":"Name"},"plan":{"type":"string","title":"Plan","default":"starter"},"owner_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Owner Email"}},"type":"object","required":["name"],"title":"HhFirmCreate"},"HhFirmSettingsIn":{"properties":{"slack_webhook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slack Webhook Url"},"send_mailbox":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Send Mailbox"}},"type":"object","title":"HhFirmSettingsIn"},"HhInboundOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"hh_candidate_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Hh Candidate Id"},"channel":{"type":"string","title":"Channel"},"sender_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Name"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text"},"intent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Intent"},"is_auto_reply":{"type":"boolean","title":"Is Auto Reply","default":false},"is_read":{"type":"boolean","title":"Is Read","default":false},"received_at":{"type":"string","format":"date-time","title":"Received At"},"hh_project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Hh Project Id"},"project_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Name"},"candidate_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Candidate Name"}},"type":"object","required":["id","channel","received_at"],"title":"HhInboundOut"},"HhInterviewBookIn":{"properties":{"slot":{"type":"string","format":"date-time","title":"Slot"}},"type":"object","required":["slot"],"title":"HhInterviewBookIn"},"HhInterviewInviteCreate":{"properties":{"proposed_slots":{"items":{"type":"string","format":"date-time"},"type":"array","title":"Proposed Slots"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["proposed_slots"],"title":"HhInterviewInviteCreate","description":"Recruiter proposes interview slots for a candidate."},"HhInterviewInviteOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"token":{"type":"string","title":"Token"},"hh_candidate_id":{"type":"string","format":"uuid","title":"Hh Candidate Id"},"proposed_slots":{"items":{"type":"string","format":"date-time"},"type":"array","title":"Proposed Slots","default":[]},"selected_slot":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Selected Slot"},"status":{"type":"string","title":"Status"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"booked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Booked At"}},"type":"object","required":["id","token","hh_candidate_id","status","created_at"],"title":"HhInterviewInviteOut"},"HhInviteIn":{"properties":{"email":{"type":"string","title":"Email"},"role":{"type":"string","title":"Role","default":"recruiter"}},"type":"object","required":["email"],"title":"HhInviteIn"},"HhKeyword":{"properties":{"text":{"type":"string","title":"Text"},"priority":{"type":"integer","title":"Priority","default":2}},"type":"object","required":["text"],"title":"HhKeyword","description":"A recruiter-reviewed search keyword with a run priority (1 = highest)."},"HhMeOut":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"member_id":{"type":"string","format":"uuid","title":"Member Id"},"firm_id":{"type":"string","format":"uuid","title":"Firm Id"},"firm_name":{"type":"string","title":"Firm Name"},"firm_plan":{"type":"string","title":"Firm Plan"},"role":{"type":"string","title":"Role"},"candidate_stages":{"items":{"type":"string"},"type":"array","title":"Candidate Stages"},"plan_limits":{"additionalProperties":{"type":"integer"},"type":"object","title":"Plan Limits","default":{}},"brand_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brand Name"},"accent_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Accent Color"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"}},"type":"object","required":["user_id","member_id","firm_id","firm_name","firm_plan","role","candidate_stages"],"title":"HhMeOut","description":"Who am I + firm context, for the /hh shell."},"HhMemberInviteIn":{"properties":{"email":{"type":"string","title":"Email"},"role":{"type":"string","title":"Role","default":"recruiter"}},"type":"object","required":["email"],"title":"HhMemberInviteIn"},"HhMemberOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"role":{"type":"string","title":"Role"},"is_you":{"type":"boolean","title":"Is You","default":false}},"type":"object","required":["id","user_id","role"],"title":"HhMemberOut"},"HhMemberRoleIn":{"properties":{"role":{"type":"string","title":"Role"}},"type":"object","required":["role"],"title":"HhMemberRoleIn"},"HhOutboundIn":{"properties":{"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"message":{"type":"string","title":"Message"},"channel":{"type":"string","title":"Channel","default":"linkedin_inmail"},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"}},"type":"object","required":["message"],"title":"HhOutboundIn"},"HhParsedFields":{"properties":{"job_roles":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Roles"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"geography":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Geography"},"employment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employment Status"},"min_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Experience"},"max_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Experience"},"companies":{"items":{"type":"string"},"type":"array","title":"Companies","default":[]},"verifying_questions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Verifying Questions","default":[]},"keywords":{"items":{"$ref":"#/components/schemas/HhKeyword"},"type":"array","title":"Keywords","default":[]}},"type":"object","title":"HhParsedFields","description":"The structured SearchHistory fields shown back to the recruiter for a\none-click confirm/edit before sourcing."},"HhPoolAddIn":{"properties":{"candidate_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Candidate Ids","default":[]},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"current_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Company"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"public_profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Profile Url"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","title":"HhPoolAddIn","description":"Add candidates to a pool. Either candidate_ids (from the pipeline — the\nserver snapshots them) or a raw member snapshot (from manual search)."},"HhProjectCreate":{"properties":{"name":{"type":"string","title":"Name"},"shared":{"type":"boolean","title":"Shared","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["name"],"title":"HhProjectCreate"},"HhProjectOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"status":{"type":"string","title":"Status"},"shared":{"type":"boolean","title":"Shared"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"candidate_count":{"type":"integer","title":"Candidate Count","default":0}},"type":"object","required":["id","name","status","shared","created_at","updated_at"],"title":"HhProjectOut"},"HhProjectShareIn":{"properties":{"hh_member_id":{"type":"string","format":"uuid","title":"Hh Member Id"}},"type":"object","required":["hh_member_id"],"title":"HhProjectShareIn"},"HhProjectSharesOut":{"properties":{"shared_with_firm":{"type":"boolean","title":"Shared With Firm"},"member_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Member Ids","default":[]}},"type":"object","required":["shared_with_firm"],"title":"HhProjectSharesOut"},"HhProjectUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"shared":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Shared"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"HhProjectUpdate"},"HhPublicInterviewOut":{"properties":{"brand_name":{"type":"string","title":"Brand Name"},"accent_color":{"type":"string","title":"Accent Color"},"proposed_slots":{"items":{"type":"string","format":"date-time"},"type":"array","title":"Proposed Slots","default":[]},"selected_slot":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Selected Slot"},"status":{"type":"string","title":"Status"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["brand_name","accent_color","status"],"title":"HhPublicInterviewOut","description":"No-login candidate view of an interview invite."},"HhRegisterIn":{"properties":{"firm_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Firm Name"},"invite_firm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Invite Firm Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"turnstile_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Turnstile Token"}},"type":"object","title":"HhRegisterIn"},"HhRequestConfirm":{"properties":{"parsed":{"$ref":"#/components/schemas/HhParsedFields"},"scoring_weights":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Scoring Weights"},"extend":{"type":"boolean","title":"Extend","default":false}},"type":"object","required":["parsed"],"title":"HhRequestConfirm","description":"Recruiter's confirmed/edited parsed fields; approving kicks off sourcing."},"HhRequestCreate":{"properties":{"hh_project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Hh Project Id"},"project_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Name"},"prompt":{"type":"string","title":"Prompt"},"target_companies":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Companies"},"must_haves":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Must Haves"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"shared":{"type":"boolean","title":"Shared","default":false},"job_roles":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Roles"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"employment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employment Status"},"min_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Experience"},"max_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Experience"}},"type":"object","required":["prompt"],"title":"HhRequestCreate"},"HhRequestOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"hh_project_id":{"type":"string","format":"uuid","title":"Hh Project Id"},"status":{"type":"string","title":"Status"},"shared":{"type":"boolean","title":"Shared"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"},"prompt":{"type":"string","title":"Prompt"},"target_companies":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Companies"},"must_haves":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Must Haves"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"parse_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parse Error"},"parsed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Parsed At"},"search_history_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Search History Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"scoring_weights":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Scoring Weights"},"candidate_count":{"type":"integer","title":"Candidate Count","default":0},"pending_count":{"type":"integer","title":"Pending Count","default":0},"parsed":{"anyOf":[{"$ref":"#/components/schemas/HhParsedFields"},{"type":"null"}]}},"type":"object","required":["id","hh_project_id","status","shared","prompt","created_at","updated_at"],"title":"HhRequestOut"},"HhSavedSearchIn":{"properties":{"name":{"type":"string","title":"Name"},"filters":{"additionalProperties":true,"type":"object","title":"Filters","default":{}},"shared":{"type":"boolean","title":"Shared","default":false}},"type":"object","required":["name"],"title":"HhSavedSearchIn"},"HhSavedSearchOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"filters":{"additionalProperties":true,"type":"object","title":"Filters","default":{}},"shared":{"type":"boolean","title":"Shared"},"alerts_enabled":{"type":"boolean","title":"Alerts Enabled","default":false},"last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Checked At"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","name","shared","created_at"],"title":"HhSavedSearchOut"},"HhSavedSearchUpdate":{"properties":{"alerts_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Alerts Enabled"},"shared":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Shared"}},"type":"object","title":"HhSavedSearchUpdate"},"HhSeatOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"seat_type":{"type":"string","title":"Seat Type"},"unipile_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unipile Account Id"},"connected":{"type":"boolean","title":"Connected","default":false},"credits":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Credits"},"budget":{"type":"integer","title":"Budget","default":0},"profiles_today":{"type":"integer","title":"Profiles Today","default":0},"remaining":{"type":"integer","title":"Remaining","default":0},"last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Checked At"}},"type":"object","required":["id","seat_type"],"title":"HhSeatOut"},"HhSequenceIn":{"properties":{"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active","default":true},"shared":{"type":"boolean","title":"Shared","default":true},"steps":{"items":{"$ref":"#/components/schemas/HhSequenceStepIn"},"type":"array","title":"Steps","default":[]}},"type":"object","required":["name"],"title":"HhSequenceIn"},"HhSequenceOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"shared":{"type":"boolean","title":"Shared"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"},"steps":{"items":{"$ref":"#/components/schemas/HhSequenceStepOut"},"type":"array","title":"Steps","default":[]},"active_enrollments":{"type":"integer","title":"Active Enrollments","default":0}},"type":"object","required":["id","name","is_active","shared"],"title":"HhSequenceOut"},"HhSequenceStepIn":{"properties":{"day_offset":{"type":"integer","title":"Day Offset","default":0},"channel":{"type":"string","title":"Channel","default":"linkedin_inmail"},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"}},"type":"object","title":"HhSequenceStepIn"},"HhSequenceStepOut":{"properties":{"order_index":{"type":"integer","title":"Order Index"},"day_offset":{"type":"integer","title":"Day Offset"},"channel":{"type":"string","title":"Channel"},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"}},"type":"object","required":["order_index","day_offset","channel"],"title":"HhSequenceStepOut"},"HhShortlistFeedbackIn":{"properties":{"item_id":{"type":"string","format":"uuid","title":"Item Id"},"feedback":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Feedback"},"comment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Comment"}},"type":"object","required":["item_id"],"title":"HhShortlistFeedbackIn"},"HhShortlistIn":{"properties":{"name":{"type":"string","title":"Name"},"hh_project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Hh Project Id"},"candidate_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Candidate Ids","default":[]}},"type":"object","required":["name"],"title":"HhShortlistIn"},"HhSuppressionIn":{"properties":{"kind":{"type":"string","title":"Kind"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Profile Url"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["kind"],"title":"HhSuppressionIn","description":"Add an off-limits company or a do-not-contact person.\n\ncompany: pass `company_name`. person: pass `linkedin_id` and/or `profile_url`\n(+ optional `full_name`)."},"HhSuppressionOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"kind":{"type":"string","title":"Kind"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Profile Url"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"source":{"type":"string","title":"Source"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","kind","source","created_at"],"title":"HhSuppressionOut"},"HhTalentPoolCreate":{"properties":{"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"shared":{"type":"boolean","title":"Shared","default":true}},"type":"object","required":["name"],"title":"HhTalentPoolCreate"},"HhTalentPoolDetailOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"shared":{"type":"boolean","title":"Shared"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"},"member_count":{"type":"integer","title":"Member Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"members":{"items":{"$ref":"#/components/schemas/HhTalentPoolMemberOut"},"type":"array","title":"Members","default":[]}},"type":"object","required":["id","name","shared","created_at","updated_at"],"title":"HhTalentPoolDetailOut"},"HhTalentPoolMemberOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"hh_candidate_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Hh Candidate Id"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"current_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Company"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"public_profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Profile Url"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","created_at"],"title":"HhTalentPoolMemberOut"},"HhTalentPoolOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"shared":{"type":"boolean","title":"Shared"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"},"member_count":{"type":"integer","title":"Member Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","name","shared","created_at","updated_at"],"title":"HhTalentPoolOut"},"HhTalentPoolUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"shared":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Shared"}},"type":"object","title":"HhTalentPoolUpdate"},"HhTemplateDraftIn":{"properties":{"instruction":{"type":"string","title":"Instruction"},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel","default":"both"}},"type":"object","required":["instruction"],"title":"HhTemplateDraftIn","description":"Ask Gemini to draft a REUSABLE outreach template ({name} placeholder) from\na free-text description."},"HhTemplateIn":{"properties":{"key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key"},"label":{"type":"string","title":"Label"},"channel":{"type":"string","title":"Channel","default":"both"},"subject":{"type":"string","title":"Subject","default":""},"body":{"type":"string","title":"Body","default":""},"append_signature":{"type":"boolean","title":"Append Signature","default":true},"is_active":{"type":"boolean","title":"Is Active","default":true},"sort_order":{"type":"integer","title":"Sort Order","default":0},"shared":{"type":"boolean","title":"Shared","default":true}},"type":"object","required":["label"],"title":"HhTemplateIn"},"HhTemplateOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","title":"Key"},"label":{"type":"string","title":"Label"},"channel":{"type":"string","title":"Channel"},"subject":{"type":"string","title":"Subject"},"body":{"type":"string","title":"Body"},"append_signature":{"type":"boolean","title":"Append Signature"},"is_active":{"type":"boolean","title":"Is Active"},"sort_order":{"type":"integer","title":"Sort Order"},"shared":{"type":"boolean","title":"Shared"},"owner_member_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner Member Id"}},"type":"object","required":["id","key","label","channel","subject","body","append_signature","is_active","sort_order","shared"],"title":"HhTemplateOut"},"InMailAccountsResponse":{"properties":{"accounts":{"items":{"$ref":"#/components/schemas/LinkedInAccountInfo"},"type":"array","title":"Accounts"}},"type":"object","required":["accounts"],"title":"InMailAccountsResponse","description":"Response listing available LinkedIn accounts with credit info"},"InMailEfficiencyResponse":{"properties":{"window_days":{"type":"integer","title":"Window Days"},"seats":{"items":{"$ref":"#/components/schemas/InMailSeatEfficiency"},"type":"array","title":"Seats"}},"type":"object","required":["window_days","seats"],"title":"InMailEfficiencyResponse"},"InMailSeatEfficiency":{"properties":{"account_id":{"type":"string","title":"Account Id"},"label":{"type":"string","title":"Label"},"sent":{"type":"integer","title":"Sent"},"replied":{"type":"integer","title":"Replied"},"no_reply":{"type":"integer","title":"No Reply"},"reply_rate":{"type":"number","title":"Reply Rate"}},"type":"object","required":["account_id","label","sent","replied","no_reply","reply_rate"],"title":"InMailSeatEfficiency","description":"Per-seat outreach ROI over the lookback window: how many credits a seat\nspent (sent) vs how many earned a reply. Low reply_rate = credits being\nwasted on no-reply sends — the signal that says 'fix targeting, don't top up'."},"InboxAttachmentItem":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size"},"unavailable":{"type":"boolean","title":"Unavailable","default":false},"downloadable":{"type":"boolean","title":"Downloadable","default":false}},"type":"object","title":"InboxAttachmentItem"},"InboxCompanyGroup":{"properties":{"company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"projects":{"items":{"$ref":"#/components/schemas/InboxProjectGroup"},"type":"array","title":"Projects"}},"type":"object","required":["projects"],"title":"InboxCompanyGroup"},"InboxContactOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"lead_id":{"type":"string","format":"uuid","title":"Lead Id"},"company_name":{"type":"string","title":"Company Name"},"outreach_status":{"type":"string","title":"Outreach Status"},"stage":{"type":"string","title":"Stage"},"funnel":{"type":"string","title":"Funnel"},"last_outbound_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Outbound At"},"last_inbound_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Inbound At"},"demo_engaged":{"type":"boolean","title":"Demo Engaged","default":false},"demo_queries":{"type":"integer","title":"Demo Queries","default":0},"demo_last_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Demo Last At"}},"type":"object","required":["id","lead_id","company_name","outreach_status","stage","funnel"],"title":"InboxContactOut","description":"One person. `outreach_status` is THIS contact's own cold-outreach status\n(auto-advanced on send/reply, admin-editable); `stage` is the parent\ncompany's pipeline stage, kept for context. Plus their own in/out activity."},"InboxContactsPage":{"properties":{"items":{"items":{"$ref":"#/components/schemas/InboxContactOut"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"InboxContactsPage"},"InboxMarkReadResponse":{"properties":{"marked":{"type":"integer","title":"Marked"}},"type":"object","required":["marked"],"title":"InboxMarkReadResponse"},"InboxMessageItem":{"properties":{"id":{"type":"string","title":"Id"},"direction":{"type":"string","title":"Direction"},"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"sender_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Name"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"is_read":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Read"},"attachments":{"anyOf":[{"items":{"$ref":"#/components/schemas/InboxAttachmentItem"},"type":"array"},{"type":"null"}],"title":"Attachments"}},"type":"object","required":["id","direction"],"title":"InboxMessageItem"},"InboxMonthGroup":{"properties":{"month_key":{"type":"string","title":"Month Key"},"month_label":{"type":"string","title":"Month Label"},"companies":{"items":{"$ref":"#/components/schemas/InboxCompanyGroup"},"type":"array","title":"Companies"}},"type":"object","required":["month_key","month_label","companies"],"title":"InboxMonthGroup"},"InboxProjectGroup":{"properties":{"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"project_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Title"},"threads":{"items":{"$ref":"#/components/schemas/InboxThreadItem"},"type":"array","title":"Threads"}},"type":"object","required":["threads"],"title":"InboxProjectGroup"},"InboxThreadItem":{"properties":{"chat_id":{"type":"string","title":"Chat Id"},"account_id":{"type":"string","title":"Account Id"},"account_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Label"},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"expert_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Name"},"expert_anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Anon Code"},"sender_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Name"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"last_message_preview":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Message Preview"},"last_message_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Message At"},"last_inbound_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Inbound At"},"unread_count":{"type":"integer","title":"Unread Count"},"has_inbound":{"type":"boolean","title":"Has Inbound","default":false},"target_company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Company Name"},"target_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Role"},"reply_classification":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reply Classification"}},"type":"object","required":["chat_id","account_id","unread_count"],"title":"InboxThreadItem"},"InboxThreadMessagesResponse":{"properties":{"chat_id":{"type":"string","title":"Chat Id"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"},"account_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Label"},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"expert_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Name"},"expert_anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Anon Code"},"expert_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Email"},"expert_linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Linkedin Url"},"expert_timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Timezone"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"target_company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Company Name"},"target_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Role"},"peu_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Peu Id"},"outreach_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outreach Status"},"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"},"interview_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Interview Id"},"interview_scheduled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Interview Scheduled At"},"pe_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Pe Id"},"showcased":{"type":"boolean","title":"Showcased","default":false},"admin_favorite":{"type":"boolean","title":"Admin Favorite","default":false},"admin_dislike":{"type":"boolean","title":"Admin Dislike","default":false},"availability":{"items":{"type":"string"},"type":"array","title":"Availability","default":[]},"messages":{"items":{"$ref":"#/components/schemas/InboxMessageItem"},"type":"array","title":"Messages"}},"type":"object","required":["chat_id","messages"],"title":"InboxThreadMessagesResponse"},"InboxThreadsResponse":{"properties":{"threads":{"items":{"$ref":"#/components/schemas/InboxThreadItem"},"type":"array","title":"Threads"},"groups":{"items":{"$ref":"#/components/schemas/InboxMonthGroup"},"type":"array","title":"Groups"}},"type":"object","required":["threads","groups"],"title":"InboxThreadsResponse"},"InboxUnreadCountResponse":{"properties":{"unread":{"type":"integer","title":"Unread"}},"type":"object","required":["unread"],"title":"InboxUnreadCountResponse"},"InmailTemplateCreate":{"properties":{"label":{"type":"string","title":"Label"},"key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key"},"description":{"type":"string","title":"Description","default":""},"channel":{"type":"string","title":"Channel","default":"inmail"},"subject":{"type":"string","title":"Subject","default":""},"body":{"type":"string","title":"Body","default":""},"is_active":{"type":"boolean","title":"Is Active","default":true},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},"type":"object","required":["label"],"title":"InmailTemplateCreate"},"InmailTemplateUpdate":{"properties":{"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},"type":"object","title":"InmailTemplateUpdate"},"InterviewDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"expert":{"anyOf":[{"$ref":"#/components/schemas/ExpertBasic"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/InterviewStatus"},"scheduled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Scheduled At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"is_self_uploaded":{"type":"boolean","title":"Is Self Uploaded","default":false},"fireflies_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fireflies Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"title_is_custom":{"type":"boolean","title":"Title Is Custom","default":false},"transcript":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"transcript_ko":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript Ko"},"transcript_en":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript En"},"summary_ko":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary Ko"},"summary_en":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary En"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"manual_duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Manual Duration Minutes"},"meeting_link":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meeting Link"},"zoom_meeting_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zoom Meeting Id"},"zoom_recording_synced":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zoom Recording Synced"},"participants":{"items":{"type":"string"},"type":"array","title":"Participants","default":[]},"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"},"availability":{"items":{"type":"string","format":"date-time"},"type":"array","title":"Availability","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"audio_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio Url"},"video_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Video Url"},"original_language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Original Language"},"audio_start_offset_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Start Offset Seconds"},"audio_end_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio End Seconds"}},"type":"object","required":["id","status","created_at","updated_at"],"title":"InterviewDetailResponse","description":"Interview detail response with fresh Fireflies media URLs"},"InterviewResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"expert":{"anyOf":[{"$ref":"#/components/schemas/ExpertBasic"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/InterviewStatus"},"scheduled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Scheduled At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"is_self_uploaded":{"type":"boolean","title":"Is Self Uploaded","default":false},"fireflies_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fireflies Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"title_is_custom":{"type":"boolean","title":"Title Is Custom","default":false},"transcript":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"transcript_ko":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript Ko"},"transcript_en":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript En"},"summary_ko":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary Ko"},"summary_en":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary En"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"manual_duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Manual Duration Minutes"},"meeting_link":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meeting Link"},"zoom_meeting_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zoom Meeting Id"},"zoom_recording_synced":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zoom Recording Synced"},"participants":{"items":{"type":"string"},"type":"array","title":"Participants","default":[]},"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"},"availability":{"items":{"type":"string","format":"date-time"},"type":"array","title":"Availability","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","status","created_at","updated_at"],"title":"InterviewResponse","description":"Interview response with expert info"},"InterviewStatus":{"type":"string","enum":["SCHEDULED","RESCHEDULE","COMPLETED","CANCELED","NO_SHOW"],"title":"InterviewStatus","description":"Interview status"},"InterviewUpdateRequest":{"properties":{"title":{"type":"string","title":"Title"}},"type":"object","required":["title"],"title":"InterviewUpdateRequest"},"JobOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"mode":{"type":"string","title":"Mode"},"status":{"type":"string","title":"Status"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params"},"result":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"}},"type":"object","required":["id","mode","status","created_at"],"title":"JobOut"},"KPIFilters":{"properties":{"companies":{"items":{},"type":"array","title":"Companies"},"projects":{"items":{},"type":"array","title":"Projects"},"client_types":{"items":{"type":"string"},"type":"array","title":"Client Types"}},"type":"object","required":["companies","projects","client_types"],"title":"KPIFilters","description":"Available filter options"},"KPIResponse":{"properties":{"revenue":{"type":"number","title":"Revenue"},"projects_created":{"type":"integer","title":"Projects Created"},"searches_conducted":{"type":"integer","title":"Searches Conducted"},"outreaches_requested":{"type":"integer","title":"Outreaches Requested"},"interviews_conducted":{"type":"integer","title":"Interviews Conducted"},"avg_interviews_per_expert":{"type":"number","title":"Avg Interviews Per Expert"},"new_experts_onboarded":{"type":"integer","title":"New Experts Onboarded"},"new_clients_onboarded":{"type":"integer","title":"New Clients Onboarded"},"new_client_companies":{"items":{},"type":"array","title":"New Client Companies"},"expert_list_to_outreach_pct":{"type":"number","title":"Expert List To Outreach Pct"},"outreach_to_response_by_channel":{"items":{"$ref":"#/components/schemas/ChannelMetric"},"type":"array","title":"Outreach To Response By Channel"},"outreach_to_onboarding_by_channel":{"items":{"$ref":"#/components/schemas/ChannelMetric"},"type":"array","title":"Outreach To Onboarding By Channel"},"avg_onboarding_time_by_channel":{"items":{"$ref":"#/components/schemas/ChannelMetric"},"type":"array","title":"Avg Onboarding Time By Channel"},"outreach_to_interview_pct":{"type":"number","title":"Outreach To Interview Pct"},"interview_cancellation_pct":{"type":"number","title":"Interview Cancellation Pct"},"avg_payment_by_role":{"items":{"$ref":"#/components/schemas/RolePaymentMetric"},"type":"array","title":"Avg Payment By Role"},"ai_qa_interactions":{"type":"integer","title":"Ai Qa Interactions"},"ai_qa_sessions":{"type":"integer","title":"Ai Qa Sessions"},"filters":{"$ref":"#/components/schemas/KPIFilters"}},"type":"object","required":["revenue","projects_created","searches_conducted","outreaches_requested","interviews_conducted","avg_interviews_per_expert","new_experts_onboarded","new_clients_onboarded","new_client_companies","expert_list_to_outreach_pct","outreach_to_response_by_channel","outreach_to_onboarding_by_channel","avg_onboarding_time_by_channel","outreach_to_interview_pct","interview_cancellation_pct","avg_payment_by_role","ai_qa_interactions","ai_qa_sessions","filters"],"title":"KPIResponse","description":"Full KPI dashboard response"},"LinkedInAccountInfo":{"properties":{"account_id":{"type":"string","title":"Account Id"},"label":{"type":"string","title":"Label"},"username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Username"},"premium_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Premium Type"},"credits_remaining":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Credits Remaining"},"credits_total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Credits Total"},"recruiter_credits":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recruiter Credits"},"sales_navigator_credits":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sales Navigator Credits"},"premium_credits":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Premium Credits"},"connected":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Connected"}},"type":"object","required":["account_id","label"],"title":"LinkedInAccountInfo","description":"One of the 3 LinkedIn accounts available for InMail"},"LinkedInFetchRequest":{"properties":{"linkedin_url":{"type":"string","title":"Linkedin Url"}},"type":"object","required":["linkedin_url"],"title":"LinkedInFetchRequest"},"LinkedInProfileResponse":{"properties":{"id":{"type":"string","title":"Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"public_profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Profile Url"},"work_experience":{"items":{"$ref":"#/components/schemas/LinkedInProfileWorkExp"},"type":"array","title":"Work Experience","default":[]}},"type":"object","required":["id"],"title":"LinkedInProfileResponse","description":"Full profile preview for one manual-search result."},"LinkedInProfileWorkExp":{"properties":{"company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company"},"company_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Id"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"start_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End Date"}},"type":"object","title":"LinkedInProfileWorkExp"},"LinkedInProjectRef":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"}},"type":"object","required":["id","title"],"title":"LinkedInProjectRef","description":"Slim project reference used by manual-search + agent-candidate dedup annotations."},"LinkedInSearchAccount":{"properties":{"id":{"type":"string","title":"Id"},"seat":{"type":"string","title":"Seat"},"label":{"type":"string","title":"Label"},"used_today":{"type":"integer","title":"Used Today"},"daily_budget":{"type":"integer","title":"Daily Budget"},"remaining":{"type":"integer","title":"Remaining"},"is_default":{"type":"boolean","title":"Is Default","default":false}},"type":"object","required":["id","seat","label","used_today","daily_budget","remaining"],"title":"LinkedInSearchAccount","description":"A selectable LinkedIn seat with its daily budget headroom."},"LinkedInSearchAccountsResponse":{"properties":{"accounts":{"items":{"$ref":"#/components/schemas/LinkedInSearchAccount"},"type":"array","title":"Accounts"}},"type":"object","required":["accounts"],"title":"LinkedInSearchAccountsResponse"},"LinkedInSearchFilters":{"properties":{"keywords":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Keywords"},"keyword_combinator":{"type":"string","title":"Keyword Combinator","default":"OR"},"job_titles":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Job Titles"},"industries":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Industries"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"min_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Experience"},"max_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Experience"},"companies":{"anyOf":[{"items":{"$ref":"#/components/schemas/CompanyFilterItem"},"type":"array"},{"type":"null"}],"title":"Companies"},"location_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Location Ids"},"location_texts":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Location Texts"},"company_sizes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Company Sizes"},"school_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"School Ids"},"function_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Function Ids"},"seniority_levels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Seniority Levels"},"tenure_in_company_min":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tenure In Company Min"},"tenure_in_company_max":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tenure In Company Max"},"tenure_in_position_min":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tenure In Position Min"},"tenure_in_position_max":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tenure In Position Max"},"network_distances":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Network Distances"},"profile_languages":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Profile Languages"},"changed_jobs":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Changed Jobs"},"posted_on_linkedin":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Posted On Linkedin"}},"type":"object","title":"LinkedInSearchFilters","description":"Filter set for the admin manual LinkedIn-search page.\n\nConfirmed-working filters map to first-class Unipile payload fields;\nindustries / job_titles are folded into the keyword string by\nunipile._build_people_search_payload — see that method for the mapping."},"LinkedInSearchResultItem":{"properties":{"id":{"type":"string","title":"Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"current_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Company"},"public_profile_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Profile Url"},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Anon Code"},"matched_by_name":{"type":"boolean","title":"Matched By Name","default":false},"in_projects":{"items":{"$ref":"#/components/schemas/LinkedInProjectRef"},"type":"array","title":"In Projects","default":[]},"pending_in_projects":{"items":{"$ref":"#/components/schemas/LinkedInProjectRef"},"type":"array","title":"Pending In Projects","default":[]}},"type":"object","required":["id"],"title":"LinkedInSearchResultItem","description":"One profile in a manual-search result page (thin preview)."},"MarkGuidelineSentResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","message"],"title":"MarkGuidelineSentResponse","description":"Response for marking a guideline file as sent/unsent"},"MeetingCompanyFacet":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_name":{"type":"string","title":"Company Name"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["id","company_name","count"],"title":"MeetingCompanyFacet"},"MeetingCreate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"meeting_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Meeting At"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"contact_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Contact Ids"},"demo_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Demo Id"},"audio_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio S3 Key"},"notes_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes S3 Key"},"notes_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes Text"}},"type":"object","title":"MeetingCreate"},"MeetingListItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"sales_lead_id":{"type":"string","format":"uuid","title":"Sales Lead Id"},"sales_lead_contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sales Lead Contact Id"},"sales_demo_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sales Demo Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"meeting_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Meeting At"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"status":{"type":"string","title":"Status"},"has_audio":{"type":"boolean","title":"Has Audio","default":false},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Title"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","sales_lead_id","status","created_at"],"title":"MeetingListItem","description":"Light row for the per-company list — NEVER carries transcript/notes/summary\nbodies (egress: this runs in the drawer on every company open)."},"MeetingOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"sales_lead_id":{"type":"string","format":"uuid","title":"Sales Lead Id"},"sales_lead_contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sales Lead Contact Id"},"sales_demo_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sales Demo Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"meeting_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Meeting At"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"status":{"type":"string","title":"Status"},"transcript":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript"},"ai_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ai Summary"},"ai_summary_en":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ai Summary En"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"notes_updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Notes Updated At"},"next_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Action"},"next_action_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Action At"},"has_audio":{"type":"boolean","title":"Has Audio","default":false},"audio_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio Url"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"participant_contact_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Participant Contact Ids"},"participant_names":{"items":{"type":"string"},"type":"array","title":"Participant Names","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","sales_lead_id","status","created_at"],"title":"MeetingOut"},"MeetingProcess":{"properties":{"audio_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio S3 Key"},"notes_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes S3 Key"},"notes_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes Text"}},"type":"object","title":"MeetingProcess","description":"(Re)attach a recording and/or existing notes to a meeting. Audio is always\ntranscribed; an uploaded notes file/text becomes the editable note; with no notes\nthe note is auto-generated from the transcript. A new notes file/text overwrites\nthe editable note, otherwise an already-edited note is preserved."},"MeetingQARequest":{"properties":{"question":{"type":"string","title":"Question"},"meeting_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Meeting Ids"}},"type":"object","required":["question"],"title":"MeetingQARequest"},"MeetingUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"meeting_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Meeting At"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"contact_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Contact Ids"},"sales_lead_contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sales Lead Contact Id"},"sales_demo_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sales Demo Id"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","title":"MeetingUpdate"},"MergeExpertsRequest":{"properties":{"canonical_expert_id":{"type":"string","format":"uuid","title":"Canonical Expert Id"},"duplicate_expert_id":{"type":"string","format":"uuid","title":"Duplicate Expert Id"}},"type":"object","required":["canonical_expert_id","duplicate_expert_id"],"title":"MergeExpertsRequest"},"MoveCombinationRunRequest":{"properties":{"position":{"type":"string","enum":["front","back"],"title":"Position","default":"front"}},"type":"object","title":"MoveCombinationRunRequest","description":"Reposition one combination within its phase's iteration order."},"NotificationItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"kind":{"type":"string","title":"Kind"},"title":{"type":"string","title":"Title"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"link":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Link"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"project_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Title"},"expert_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Label"},"is_read":{"type":"boolean","title":"Is Read"},"is_resolved":{"type":"boolean","title":"Is Resolved"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata","default":{}}},"type":"object","required":["id","kind","title","is_read","is_resolved","created_at"],"title":"NotificationItem"},"NotificationListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/NotificationItem"},"type":"array","title":"Items"},"unread_count":{"type":"integer","title":"Unread Count"}},"type":"object","required":["items","unread_count"],"title":"NotificationListResponse"},"NotificationPreferenceItem":{"properties":{"kind":{"type":"string","title":"Kind"},"email_enabled":{"type":"boolean","title":"Email Enabled"},"in_app_enabled":{"type":"boolean","title":"In App Enabled"}},"type":"object","required":["kind","email_enabled","in_app_enabled"],"title":"NotificationPreferenceItem"},"NotificationPreferencesResponse":{"properties":{"preferences":{"items":{"$ref":"#/components/schemas/NotificationPreferenceItem"},"type":"array","title":"Preferences"}},"type":"object","required":["preferences"],"title":"NotificationPreferencesResponse"},"OutreachRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"selected_candidates":{"items":{"$ref":"#/components/schemas/ExpertResponse"},"type":"array","title":"Selected Candidates"}},"type":"object","required":["project_id","selected_candidates"],"title":"OutreachRequest"},"PRBlogCreate":{"properties":{"title":{"type":"string","title":"Title"},"body":{"type":"string","title":"Body"},"meta_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Description"},"og_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Title"},"og_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Description"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"}},"type":"object","required":["title","body"],"title":"PRBlogCreate","description":"Compose an original blog post by hand (admin-authored, not AI-generated).\nRoutes through the same PENDING review queue; approving it publishes to /blog\nvia the blog publisher. `body` is markdown."},"PRBulkReviewRequest":{"properties":{"item_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Item Ids"},"action":{"type":"string","title":"Action"}},"type":"object","required":["item_ids","action"],"title":"PRBulkReviewRequest"},"PRBulkReviewResult":{"properties":{"approved":{"type":"integer","title":"Approved","default":0},"rejected":{"type":"integer","title":"Rejected","default":0},"skipped":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Skipped","default":[]}},"type":"object","title":"PRBulkReviewResult"},"PRGenerateNowRequest":{"properties":{"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"}},"type":"object","title":"PRGenerateNowRequest"},"PRItemOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"channel":{"type":"string","title":"Channel"},"status":{"type":"string","title":"Status"},"topic_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Topic Id"},"subject_archetype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject Archetype"},"generation_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Generation Model"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"body":{"type":"string","title":"Body","default":""},"meta_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Description"},"og_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Title"},"og_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Description"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"target_subreddit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Subreddit"},"source_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Name"},"source_published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Source Published At"},"anonymized":{"type":"boolean","title":"Anonymized","default":true},"scheduled_for":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Scheduled For"},"reviewed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewed By"},"reviewed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Reviewed At"},"reject_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reject Reason"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At"},"external_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Url"},"publish_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publish Error"},"display_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Display Order"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","channel","status","created_at","updated_at"],"title":"PRItemOut"},"PRItemUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"meta_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Description"},"og_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Title"},"og_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Description"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"target_subreddit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Subreddit"},"source_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Name"},"external_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Url"},"source_published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Source Published At"},"scheduled_for":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Scheduled For"},"display_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Display Order"}},"type":"object","title":"PRItemUpdate"},"PRPressCreate":{"properties":{"external_url":{"type":"string","title":"External Url"},"title":{"type":"string","title":"Title"},"source_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Name"},"source_published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Source Published At"},"meta_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Description"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"og_image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Og Image Url"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"}},"type":"object","required":["external_url","title"],"title":"PRPressCreate","description":"Add a third-party press mention by hand (admin found it). Routes through\nthe same PENDING review queue; `external_url` is the original article link."},"PRReviewRequest":{"properties":{"action":{"type":"string","title":"Action"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"override_anonymity":{"type":"boolean","title":"Override Anonymity","default":false}},"type":"object","required":["action"],"title":"PRReviewRequest"},"PRSettingsOut":{"properties":{"paused":{"type":"boolean","title":"Paused"},"force_run_requested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Force Run Requested At"},"week_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Week Start"},"counts_this_week":{"additionalProperties":true,"type":"object","title":"Counts This Week"},"last_generated":{"additionalProperties":true,"type":"object","title":"Last Generated"},"caps":{"additionalProperties":true,"type":"object","title":"Caps"},"min_hours":{"additionalProperties":true,"type":"object","title":"Min Hours"},"config":{"additionalProperties":true,"type":"object","title":"Config"},"supported_channels":{"items":{"type":"string"},"type":"array","title":"Supported Channels"}},"type":"object","required":["paused","counts_this_week","last_generated","caps","min_hours","config","supported_channels"],"title":"PRSettingsOut"},"PRSettingsUpdate":{"properties":{"paused":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Paused"},"config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Config"}},"type":"object","title":"PRSettingsUpdate"},"PRTopicCreate":{"properties":{"archetype":{"type":"string","title":"Archetype"},"angle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Angle"},"channel_scope":{"type":"string","title":"Channel Scope","default":"all"},"is_active":{"type":"boolean","title":"Is Active","default":true},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","required":["archetype"],"title":"PRTopicCreate"},"PRTopicOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"archetype":{"type":"string","title":"Archetype"},"angle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Angle"},"channel_scope":{"type":"string","title":"Channel Scope"},"is_active":{"type":"boolean","title":"Is Active"},"sort_order":{"type":"integer","title":"Sort Order"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"use_count":{"type":"integer","title":"Use Count"}},"type":"object","required":["id","archetype","channel_scope","is_active","sort_order","use_count"],"title":"PRTopicOut"},"PRTopicUpdate":{"properties":{"archetype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archetype"},"angle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Angle"},"channel_scope":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel Scope"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"PRTopicUpdate"},"PaletteExpertResult":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"}},"type":"object","required":["id","name"],"title":"PaletteExpertResult"},"PaletteProjectResult":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"}},"type":"object","required":["id","title"],"title":"PaletteProjectResult"},"PaletteSearchResponse":{"properties":{"experts":{"items":{"$ref":"#/components/schemas/PaletteExpertResult"},"type":"array","title":"Experts"},"projects":{"items":{"$ref":"#/components/schemas/PaletteProjectResult"},"type":"array","title":"Projects"}},"type":"object","required":["experts","projects"],"title":"PaletteSearchResponse"},"PendingExpertResponse":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"type":"string","title":"Email"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"account_status":{"type":"string","title":"Account Status"},"compliance_completed_expert":{"type":"boolean","title":"Compliance Completed Expert","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["user_id","expert_id","email","account_status","created_at"],"title":"PendingExpertResponse","description":"Response schema for pending expert"},"PendingFile":{"properties":{"s3_key":{"type":"string","title":"S3 Key"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name"}},"type":"object","required":["s3_key"],"title":"PendingFile","description":"A file already uploaded to S3 (via the upload endpoint), being attached\nto the message now being sent. We re-HEAD the key server-side, so only\ns3_key + a display name are trusted from the client."},"PreviewCompanyInput":{"properties":{"unipile_id":{"type":"string","title":"Unipile Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"}},"type":"object","required":["unipile_id"],"title":"PreviewCompanyInput","description":"One target company for the search-request preview (current in-form value)."},"PreviewMatchesRequest":{"properties":{"job_roles":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Roles"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"geography":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Geography"},"employment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employment Status"},"min_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Experience"},"max_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Experience"},"companies":{"items":{"$ref":"#/components/schemas/PreviewCompanyInput"},"type":"array","title":"Companies","default":[]}},"type":"object","title":"PreviewMatchesRequest","description":"Current (possibly UNSAVED) search criteria to preview before approving."},"PreviewMatchesResponse":{"properties":{"total_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Count"},"total_basis":{"type":"string","title":"Total Basis","default":"unavailable"},"approximate":{"type":"boolean","title":"Approximate","default":true},"industry_keyword_folded":{"type":"boolean","title":"Industry Keyword Folded","default":false},"company_count":{"type":"integer","title":"Company Count","default":0},"seat_used":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Seat Used"},"samples":{"items":{"$ref":"#/components/schemas/LinkedInSearchResultItem"},"type":"array","title":"Samples","default":[]}},"type":"object","title":"PreviewMatchesResponse","description":"Combined orientation total + sample profiles across all target companies."},"PricingTierCatalogResponse":{"properties":{"krw_tiers":{"items":{"$ref":"#/components/schemas/PricingTierResponse"},"type":"array","title":"Krw Tiers"}},"type":"object","required":["krw_tiers"],"title":"PricingTierCatalogResponse"},"PricingTierResponse":{"properties":{"code":{"type":"string","title":"Code"},"credits":{"type":"number","title":"Credits"},"amount_krw":{"type":"integer","title":"Amount Krw"},"per_credit_krw":{"type":"integer","title":"Per Credit Krw"},"expiry_months":{"type":"integer","title":"Expiry Months"},"label":{"type":"string","title":"Label"},"is_best":{"type":"boolean","title":"Is Best","default":false}},"type":"object","required":["code","credits","amount_krw","per_credit_krw","expiry_months","label"],"title":"PricingTierResponse"},"PriorContactInfo":{"properties":{"project_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"},"project_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Title"},"account_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Label"},"last_contacted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Contacted At"}},"type":"object","title":"PriorContactInfo","description":"One project we've previously InMailed this expert for (any seat). Lets the\nUI flag 'already contacted' — including for a DIFFERENT project — so admins\ndo a fresh per-project outreach instead of reusing the first-time intro."},"PublicScheduleRequest":{"properties":{"scheduled_at":{"type":"string","format":"date-time","title":"Scheduled At"},"recipient_timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Timezone"},"recipient_language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Language"}},"type":"object","required":["scheduled_at"],"title":"PublicScheduleRequest"},"QARequest":{"properties":{"question":{"type":"string","title":"Question"}},"type":"object","required":["question"],"title":"QARequest"},"QAResponse":{"properties":{"answer":{"type":"string","title":"Answer"}},"type":"object","required":["answer"],"title":"QAResponse"},"QaAttachmentIn":{"properties":{"s3_key":{"type":"string","title":"S3 Key"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"}},"type":"object","required":["s3_key"],"title":"QaAttachmentIn"},"QaCommentCreate":{"properties":{"body":{"type":"string","title":"Body","default":""},"verdict":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verdict"},"author_kind":{"type":"string","title":"Author Kind","default":"admin"}},"type":"object","title":"QaCommentCreate"},"QaPresignIn":{"properties":{"s3_key":{"type":"string","title":"S3 Key"}},"type":"object","required":["s3_key"],"title":"QaPresignIn"},"QaTaskItem":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"text":{"type":"string","title":"Text","default":""},"done":{"type":"boolean","title":"Done","default":false}},"type":"object","title":"QaTaskItem"},"QaTicketCreate":{"properties":{"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description","default":""},"fix":{"type":"string","title":"Fix","default":""},"category":{"type":"string","title":"Category","default":"other"},"priority":{"type":"string","title":"Priority","default":"medium"},"status":{"type":"string","title":"Status","default":"open"},"not_urgent":{"type":"boolean","title":"Not Urgent","default":false},"tasks":{"items":{"$ref":"#/components/schemas/QaTaskItem"},"type":"array","title":"Tasks","default":[]},"attachments":{"items":{"$ref":"#/components/schemas/QaAttachmentIn"},"type":"array","title":"Attachments","default":[]}},"type":"object","required":["title"],"title":"QaTicketCreate"},"QaTicketUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"fix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fix"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"priority":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Priority"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"not_urgent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Not Urgent"},"tasks":{"anyOf":[{"items":{"$ref":"#/components/schemas/QaTaskItem"},"type":"array"},{"type":"null"}],"title":"Tasks"},"attachments":{"anyOf":[{"items":{"$ref":"#/components/schemas/QaAttachmentIn"},"type":"array"},{"type":"null"}],"title":"Attachments"}},"type":"object","title":"QaTicketUpdate"},"ReachItem":{"properties":{"label":{"type":"string","title":"Label"},"kind":{"type":"string","title":"Kind"},"via":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Via"},"resolved_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolved Title"},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Count"},"count_global":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Count Global"},"region_mismatch":{"type":"boolean","title":"Region Mismatch","default":false}},"type":"object","required":["label","kind"],"title":"ReachItem","description":"One company or keyword's LinkedIn reach, for the reach-preview."},"ReachPreviewResponse":{"properties":{"geography":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Geography"},"geography_resolved":{"type":"boolean","title":"Geography Resolved","default":false},"companies":{"items":{"$ref":"#/components/schemas/ReachItem"},"type":"array","title":"Companies","default":[]},"keywords":{"items":{"$ref":"#/components/schemas/ReachItem"},"type":"array","title":"Keywords","default":[]},"all_zero":{"type":"boolean","title":"All Zero","default":false},"union_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Union Count"},"seat_used":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Seat Used"},"truncated":{"type":"boolean","title":"Truncated","default":false}},"type":"object","title":"ReachPreviewResponse","description":"Per-company + per-keyword LinkedIn reach for a search request, so admins see\nBEFORE approving whether the agent's query will find anyone. Counts are\ngeo-filtered and count-only (limit=1), on the off-agent seat."},"ReadKindsRequest":{"properties":{"kinds":{"items":{"type":"string"},"type":"array","title":"Kinds"}},"type":"object","required":["kinds"],"title":"ReadKindsRequest"},"ReallocateExpertRequest":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"source_project_id":{"type":"string","format":"uuid","title":"Source Project Id"},"destination_project_id":{"type":"string","format":"uuid","title":"Destination Project Id"}},"type":"object","required":["expert_id","source_project_id","destination_project_id"],"title":"ReallocateExpertRequest"},"RecentChatItem":{"properties":{"account_id":{"type":"string","title":"Account Id"},"account_label":{"type":"string","title":"Account Label"},"chat_id":{"type":"string","title":"Chat Id"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"last_message_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Message Text"},"unread_count":{"type":"integer","title":"Unread Count","default":0},"attendee_names":{"items":{"type":"string"},"type":"array","title":"Attendee Names","default":[]},"expert_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Id"},"expert_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expert Name"}},"type":"object","required":["account_id","account_label","chat_id"],"title":"RecentChatItem"},"ReferralCreate":{"properties":{"referred_lead_id":{"type":"string","format":"uuid","title":"Referred Lead Id"},"referrer_lead_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Referrer Lead Id"},"referrer_contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Referrer Contact Id"},"referrer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referrer Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["referred_lead_id"],"title":"ReferralCreate"},"ReferralOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"referred_lead_id":{"type":"string","format":"uuid","title":"Referred Lead Id"},"referred_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referred Company"},"referrer_lead_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Referrer Lead Id"},"referrer_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referrer Company"},"referrer_contact_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Referrer Contact Id"},"referrer_contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referrer Contact Name"},"referrer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referrer Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","referred_lead_id","created_at"],"title":"ReferralOut"},"RejectExpertResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"account_status":{"type":"string","title":"Account Status"}},"type":"object","required":["success","message","user_id","account_status"],"title":"RejectExpertResponse","description":"Response schema for rejecting expert"},"ReplySuggestion":{"properties":{"intent":{"type":"string","title":"Intent"},"message":{"type":"string","title":"Message"}},"type":"object","required":["intent","message"],"title":"ReplySuggestion"},"RequestMoreSlotsRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"},"preferred_times":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preferred Times"}},"type":"object","required":["project_id","expert_id"],"title":"RequestMoreSlotsRequest"},"RequestRescheduleRequest":{"properties":{"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"}},"type":"object","title":"RequestRescheduleRequest"},"RescheduleInterviewRequest":{"properties":{"new_scheduled_at":{"type":"string","format":"date-time","title":"New Scheduled At"},"outreach_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outreach User Id"}},"type":"object","required":["new_scheduled_at"],"title":"RescheduleInterviewRequest"},"ResetPasswordRequest":{"properties":{"email":{"type":"string","title":"Email"}},"type":"object","required":["email"],"title":"ResetPasswordRequest","description":"Request schema for sending password reset email"},"RetryRequest":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"send_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Send At"},"tz":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tz"}},"type":"object","required":["ids"],"title":"RetryRequest"},"RevenueTransactionCreateResponse":{"properties":{"transaction":{"$ref":"#/components/schemas/RevenueTransactionResponse"},"company_credit_balance":{"type":"number","title":"Company Credit Balance"}},"type":"object","required":["transaction","company_credit_balance"],"title":"RevenueTransactionCreateResponse"},"RevenueTransactionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"tier_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier Code"},"currency":{"type":"string","title":"Currency"},"amount_krw":{"type":"integer","title":"Amount Krw"},"credits_granted":{"type":"number","title":"Credits Granted"},"credits_remaining":{"type":"number","title":"Credits Remaining"},"received_at":{"type":"string","format":"date","title":"Received At"},"expires_at":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expires At"},"is_expired":{"type":"boolean","title":"Is Expired"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_by_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Email"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","currency","amount_krw","credits_granted","credits_remaining","received_at","is_expired","created_at"],"title":"RevenueTransactionResponse"},"RolePaymentMetric":{"properties":{"role":{"type":"string","title":"Role"},"avg_price":{"type":"number","title":"Avg Price"},"expert_count":{"type":"integer","title":"Expert Count"}},"type":"object","required":["role","avg_price","expert_count"],"title":"RolePaymentMetric","description":"Average expert payment by job role"},"RunRequest":{"properties":{"task_key":{"type":"string","title":"Task Key"},"model_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Model Ids"},"judge":{"type":"boolean","title":"Judge","default":true}},"type":"object","required":["task_key"],"title":"RunRequest"},"SalesContactIn":{"properties":{"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_primary":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Primary"},"outreach_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outreach Status"},"followup_threshold_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Followup Threshold Days"}},"type":"object","title":"SalesContactIn"},"SalesContactOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Id"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_primary":{"type":"boolean","title":"Is Primary","default":false},"outreach_status":{"type":"string","title":"Outreach Status","default":"Not Contacted"},"followup_threshold_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Followup Threshold Days"}},"type":"object","required":["id"],"title":"SalesContactOut"},"SalesLeadCreate":{"properties":{"company_name":{"type":"string","title":"Company Name"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"linkedin_company_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Company Url"},"source_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Url"},"lead_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Type"},"lead_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Source"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"owner_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner User Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"followup_threshold_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Followup Threshold Days"},"contacts":{"anyOf":[{"items":{"$ref":"#/components/schemas/SalesContactIn"},"type":"array"},{"type":"null"}],"title":"Contacts"}},"type":"object","required":["company_name"],"title":"SalesLeadCreate"},"SalesLeadOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_name":{"type":"string","title":"Company Name"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"linkedin_company_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Company Url"},"source_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Url"},"lead_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Type"},"lead_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Source"},"stage":{"type":"string","title":"Stage"},"funnel":{"type":"string","title":"Funnel"},"owner_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner User Id"},"owner_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Owner Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"ai_assessment":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ai Assessment"},"followup_threshold_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Followup Threshold Days"},"manual_last_contact_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Manual Last Contact At"},"lost_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lost Reason"},"lost_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lost Notes"},"lost_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lost At"},"notion_synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Notion Synced At"},"notion_sync_dirty":{"type":"boolean","title":"Notion Sync Dirty","default":true},"notion_sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notion Sync Error"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"contacts":{"items":{"$ref":"#/components/schemas/SalesContactOut"},"type":"array","title":"Contacts","default":[]},"contact_count":{"type":"integer","title":"Contact Count","default":0},"last_outbound_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Outbound At"},"last_inbound_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Inbound At"},"last_outbound_channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Outbound Channel"},"demo_engaged":{"type":"boolean","title":"Demo Engaged","default":false}},"type":"object","required":["id","company_name","stage","funnel","created_at","updated_at"],"title":"SalesLeadOut"},"SalesLeadUpdate":{"properties":{"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"linkedin_company_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Company Url"},"source_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Url"},"lead_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Type"},"lead_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lead Source"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"owner_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Owner User Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"followup_threshold_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Followup Threshold Days"},"manual_last_contact_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Manual Last Contact At"},"lost_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lost Reason"},"lost_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lost Notes"}},"type":"object","title":"SalesLeadUpdate","description":"Partial update — only fields present in the request body are applied\n(exclude_unset). Set a nullable field to null to clear it."},"SalesLeadsPage":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SalesLeadOut"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"SalesLeadsPage"},"SalesMetaOut":{"properties":{"cold_outreach_stages":{"items":{"type":"string"},"type":"array","title":"Cold Outreach Stages"},"sales_pipeline_stages":{"items":{"type":"string"},"type":"array","title":"Sales Pipeline Stages"},"lead_types":{"items":{"type":"string"},"type":"array","title":"Lead Types"},"lead_sources":{"items":{"type":"string"},"type":"array","title":"Lead Sources"},"lost_reasons":{"items":{"type":"string"},"type":"array","title":"Lost Reasons"},"signal_kinds":{"items":{"type":"string"},"type":"array","title":"Signal Kinds"},"countries":{"items":{"type":"string"},"type":"array","title":"Countries","default":[]}},"type":"object","required":["cold_outreach_stages","sales_pipeline_stages","lead_types","lead_sources","lost_reasons","signal_kinds"],"title":"SalesMetaOut","description":"Vocabularies the board UI renders from (no hardcoding on the frontend)."},"ScheduleCreate":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ScheduleItem"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"ScheduleCreate"},"ScheduleItem":{"properties":{"channel":{"type":"string","title":"Channel"},"body":{"type":"string","title":"Body"},"send_at":{"type":"string","title":"Send At"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"},"chat_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chat Id"},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"from_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From Email"},"tz":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tz"},"force":{"type":"boolean","title":"Force","default":false},"attachments":{"anyOf":[{"items":{"$ref":"#/components/schemas/AttachmentRef"},"type":"array"},{"type":"null"}],"title":"Attachments"}},"type":"object","required":["channel","body","send_at"],"title":"ScheduleItem"},"SchedulePatch":{"properties":{"send_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Send At"},"tz":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tz"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"}},"type":"object","title":"SchedulePatch"},"SelfUploadInterviewRequest":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id"},"title":{"type":"string","title":"Title"},"audio_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio S3 Key"},"transcript_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript S3 Key"},"audio_file_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio File Path"},"audio_original_filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Audio Original Filename"},"transcript_file_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript File Path"},"transcript_original_filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transcript Original Filename"}},"type":"object","required":["project_id","title"],"title":"SelfUploadInterviewRequest","description":"Request for client self-upload of interview audio/transcript.\n\nFiles are uploaded to S3 first (POST /interviews/upload-file) and referenced\nhere by their S3 key. The *_file_path fields are the legacy Supabase paths,\nkept for backward compatibility with older clients."},"SendChatMessageResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message Id"}},"type":"object","required":["success"],"title":"SendChatMessageResponse"},"SendEmailRequest":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"subject":{"type":"string","title":"Subject"},"message":{"type":"string","title":"Message"},"from_email":{"type":"string","title":"From Email"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"}},"type":"object","required":["expert_id","subject","message","from_email"],"title":"SendEmailRequest","description":"Request to send an email to an expert"},"SendEmailResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"email_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email Id"}},"type":"object","required":["success","message"],"title":"SendEmailResponse"},"SendExpertsEmailRequest":{"properties":{"recipient_email":{"type":"string","title":"Recipient Email"},"sender_key":{"type":"string","title":"Sender Key"},"subject":{"type":"string","title":"Subject"},"html":{"type":"string","title":"Html"},"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text"},"client_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client User Id"},"expert_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Expert Ids"}},"type":"object","required":["recipient_email","sender_key","subject","html"],"title":"SendExpertsEmailRequest","description":"Send the (edited) client expert-profile email directly, via Resend."},"SendExpertsEmailResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"email_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email Id"}},"type":"object","required":["success"],"title":"SendExpertsEmailResponse"},"SendInMailRequest":{"properties":{"expert_id":{"type":"string","format":"uuid","title":"Expert Id"},"account_id":{"type":"string","title":"Account Id"},"subject":{"type":"string","title":"Subject"},"message":{"type":"string","title":"Message"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"force":{"type":"boolean","title":"Force","default":false},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"}},"type":"object","required":["expert_id","account_id","subject","message"],"title":"SendInMailRequest","description":"Request to send an InMail"},"SendInMailResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"chat_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chat Id"}},"type":"object","required":["success","message"],"title":"SendInMailResponse","description":"Response after sending InMail"},"SendMessageRequest":{"properties":{"body":{"type":"string","title":"Body"},"expert_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Expert Ids"},"files":{"anyOf":[{"items":{"$ref":"#/components/schemas/PendingFile"},"type":"array"},{"type":"null"}],"title":"Files"}},"type":"object","required":["body"],"title":"SendMessageRequest"},"SendRequest":{"properties":{"lead_id":{"type":"string","format":"uuid","title":"Lead Id"},"contact_id":{"type":"string","format":"uuid","title":"Contact Id"},"channel":{"type":"string","title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"type":"string","title":"Body"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"},"from_mailbox":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From Mailbox"}},"type":"object","required":["lead_id","contact_id","channel","body"],"title":"SendRequest"},"SeqSendRequest":{"properties":{"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"type":"string","title":"Body"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"},"from_mailbox":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From Mailbox"}},"type":"object","required":["body"],"title":"SeqSendRequest"},"SeqStepIn":{"properties":{"channel":{"type":"string","title":"Channel"},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"},"day_offset":{"type":"integer","title":"Day Offset","default":0}},"type":"object","required":["channel"],"title":"SeqStepIn"},"SeqStepOut":{"properties":{"order_index":{"type":"integer","title":"Order Index"},"channel":{"type":"string","title":"Channel"},"template_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Key"},"day_offset":{"type":"integer","title":"Day Offset"}},"type":"object","required":["order_index","channel","day_offset"],"title":"SeqStepOut"},"SequenceCreate":{"properties":{"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"steps":{"items":{"$ref":"#/components/schemas/SeqStepIn"},"type":"array","title":"Steps"}},"type":"object","required":["name","steps"],"title":"SequenceCreate"},"SequenceOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"steps":{"items":{"$ref":"#/components/schemas/SeqStepOut"},"type":"array","title":"Steps"}},"type":"object","required":["id","name","is_active","steps"],"title":"SequenceOut"},"ShareExpertsDraftRequest":{"properties":{"expert_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Expert Ids"},"recipient_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Email"},"client_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client User Id"},"language":{"type":"string","title":"Language","default":"en"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"}},"type":"object","required":["expert_ids"],"title":"ShareExpertsDraftRequest","description":"Generate a copy-pastable client email draft for the selected experts.\n\nrecipient_email is the address the admin intends to send to (an identifier;\nmay differ from the client's registered email). client_user_id is the client\naccount the interview is attributed to on booking — optional, so an admin can\ngenerate a draft on a project with no client user yet (booking still attributes\nto the project's clients via ProjectUser)."},"SignalOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"sales_lead_id":{"type":"string","format":"uuid","title":"Sales Lead Id"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"kind":{"type":"string","title":"Kind"},"headline":{"type":"string","title":"Headline"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"signal_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Signal Date"},"score":{"type":"integer","title":"Score"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","sales_lead_id","kind","headline","score","status","created_at"],"title":"SignalOut"},"SignalStatusRequest":{"properties":{"status":{"type":"string","title":"Status"}},"type":"object","required":["status"],"title":"SignalStatusRequest"},"SubmitAnswerRequest":{"properties":{"answer_text":{"type":"string","title":"Answer Text"}},"type":"object","required":["answer_text"],"title":"SubmitAnswerRequest","description":"Request schema for submitting vetting answer"},"SubmitAnswerResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"answer_id":{"type":"string","format":"uuid","title":"Answer Id"},"answered_at":{"type":"string","format":"date-time","title":"Answered At"}},"type":"object","required":["success","message","answer_id","answered_at"],"title":"SubmitAnswerResponse","description":"Response schema for submitting vetting answer"},"SuggestRepliesRequest":{"properties":{"extra_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extra Prompt","default":""},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id"}},"type":"object","title":"SuggestRepliesRequest","description":"Same inputs as a single draft; the only difference is the response shape."},"SuggestRepliesResponse":{"properties":{"no_reply_needed":{"type":"boolean","title":"No Reply Needed","default":false},"suggestions":{"items":{"$ref":"#/components/schemas/ReplySuggestion"},"type":"array","title":"Suggestions"}},"type":"object","required":["suggestions"],"title":"SuggestRepliesResponse"},"TemplateCreate":{"properties":{"label":{"type":"string","title":"Label"},"key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Key"},"channel":{"type":"string","title":"Channel","default":"both"},"subject":{"type":"string","title":"Subject","default":""},"body":{"type":"string","title":"Body","default":""},"append_signature":{"type":"boolean","title":"Append Signature","default":true},"is_active":{"type":"boolean","title":"Is Active","default":true},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","required":["label"],"title":"TemplateCreate"},"TemplateOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","title":"Key"},"label":{"type":"string","title":"Label"},"channel":{"type":"string","title":"Channel"},"subject":{"type":"string","title":"Subject"},"body":{"type":"string","title":"Body"},"append_signature":{"type":"boolean","title":"Append Signature"},"is_active":{"type":"boolean","title":"Is Active"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","key","label","channel","subject","body","append_signature","is_active","sort_order"],"title":"TemplateOut"},"TemplateUpdate":{"properties":{"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"append_signature":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Append Signature"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"TemplateUpdate"},"ThreadMessage":{"properties":{"direction":{"type":"string","title":"Direction"},"channel":{"type":"string","title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text"},"at":{"type":"string","format":"date-time","title":"At"},"sender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender"},"account":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account"},"reply_classification":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reply Classification"}},"type":"object","required":["direction","channel","at"],"title":"ThreadMessage"},"TranslateTextsRequest":{"properties":{"texts":{"items":{"type":"string"},"type":"array","title":"Texts"},"target_lang":{"type":"string","title":"Target Lang"}},"type":"object","required":["texts","target_lang"],"title":"TranslateTextsRequest"},"TriageItem":{"properties":{"contact_id":{"type":"string","format":"uuid","title":"Contact Id"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"company_name":{"type":"string","title":"Company Name"},"channel":{"type":"string","title":"Channel"},"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text"},"intent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Intent"},"sentiment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sentiment"},"close_likelihood":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Close Likelihood"},"received_at":{"type":"string","format":"date-time","title":"Received At"}},"type":"object","required":["contact_id","company_name","channel","received_at"],"title":"TriageItem"},"TrialReviewRequest":{"properties":{"trial_id":{"type":"string","title":"Trial Id"},"decision":{"type":"string","title":"Decision"},"reason_category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Category"}},"type":"object","required":["trial_id","decision"],"title":"TrialReviewRequest","description":"Blinded off-queue review for the operator-parity experiment (Phase 3C). Writes only\nagent_review_trial; never mutates the live candidate status."},"UnreadCountResponse":{"properties":{"unread":{"type":"integer","title":"Unread"}},"type":"object","required":["unread"],"title":"UnreadCountResponse"},"UpdateAvailabilityRequest":{"properties":{"slots":{"items":{"type":"string","format":"date-time"},"type":"array","title":"Slots"}},"type":"object","required":["slots"],"title":"UpdateAvailabilityRequest","description":"Request schema for updating expert availability"},"UpdateExperienceRequest":{"properties":{"company_linkedin_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Linkedin Id"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"company_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Id"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"role_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"}},"type":"object","title":"UpdateExperienceRequest","description":"Request schema for updating work experience"},"UpdateExpertPaymentRequest":{"properties":{"payment_bank_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Name"},"payment_account_holder_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Holder Name"},"payment_account_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Number"},"payment_routing_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Routing Code"},"payment_iban":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Iban"},"payment_bank_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Country"},"payment_bank_street":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Street"},"payment_bank_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank City"},"payment_bank_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank State"},"payment_bank_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Bank Postal Code"},"payment_holder_street":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Street"},"payment_holder_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder City"},"payment_holder_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder State"},"payment_holder_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Postal Code"},"payment_holder_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Holder Country"},"payment_resident_registration_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Resident Registration Number"},"payment_account_region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Account Region"}},"type":"object","title":"UpdateExpertPaymentRequest","description":"Request schema for updating expert payment info"},"UpdateExpertProfileRequest":{"properties":{"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"headline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Headline"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"linkedin_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Linkedin Url"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"}},"type":"object","title":"UpdateExpertProfileRequest","description":"Request schema for updating expert profile"},"UpdateKeywordCombinatorRequest":{"properties":{"combinator":{"type":"string","enum":["AND","OR"],"title":"Combinator"}},"type":"object","required":["combinator"],"title":"UpdateKeywordCombinatorRequest","description":"Set SearchHistory.keyword_combinator (admin, changeable mid-run)."},"UpdateNotificationPreferenceRequest":{"properties":{"email_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Email Enabled"},"in_app_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"In App Enabled"}},"type":"object","title":"UpdateNotificationPreferenceRequest"},"UpdateProjectRequest":{"properties":{"title":{"type":"string","title":"Title"}},"type":"object","required":["title"],"title":"UpdateProjectRequest","description":"Request to update a project"},"UpdateSourcingModeRequest":{"properties":{"mode":{"type":"string","enum":["standard","no_company","no_keywords","broad"],"title":"Mode"}},"type":"object","required":["mode"],"title":"UpdateSourcingModeRequest","description":"Set SearchHistory.sourcing_mode (admin, changeable mid-run)."},"UpdateUserProfileRequest":{"properties":{"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"country_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country Code"},"country_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country Name"},"contact_preference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Preference"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"language_preference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language Preference"},"tutorial_completed_client":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tutorial Completed Client"},"tutorial_completed_expert":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tutorial Completed Expert"},"compliance_completed_expert":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Compliance Completed Expert"}},"type":"object","title":"UpdateUserProfileRequest","description":"Request schema for updating user profile (User table fields)"},"UploadResult":{"properties":{"s3_key":{"type":"string","title":"S3 Key"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"size":{"type":"integer","title":"Size"}},"type":"object","required":["s3_key","size"],"title":"UploadResult"},"UserInfoResponse":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"email":{"type":"string","title":"Email"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"user_type":{"type":"string","title":"User Type"},"account_status":{"type":"string","title":"Account Status"},"expert_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Expert Id"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"tutorial_completed_client":{"type":"boolean","title":"Tutorial Completed Client","default":false},"tutorial_completed_expert":{"type":"boolean","title":"Tutorial Completed Expert","default":false},"compliance_completed_expert":{"type":"boolean","title":"Compliance Completed Expert","default":false}},"type":"object","required":["user_id","email","user_type","account_status"],"title":"UserInfoResponse","description":"Response schema for /users/me endpoint"},"UserProfileResponse":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"email":{"type":"string","title":"Email"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"country_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country Code"},"country_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country Name"},"contact_preference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Preference"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"language_preference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language Preference"},"user_type":{"type":"string","title":"User Type"},"account_status":{"type":"string","title":"Account Status"},"tutorial_completed_client":{"type":"boolean","title":"Tutorial Completed Client","default":false},"tutorial_completed_expert":{"type":"boolean","title":"Tutorial Completed Expert","default":false},"compliance_completed_expert":{"type":"boolean","title":"Compliance Completed Expert","default":false},"compliance_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Compliance Completed At"}},"type":"object","required":["user_id","email","user_type","account_status"],"title":"UserProfileResponse","description":"Response schema for user profile (User table fields)"},"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"},"VerifyingQuestion":{"properties":{"q":{"type":"string","title":"Q"},"subs":{"items":{"type":"string"},"type":"array","title":"Subs","default":[]}},"type":"object","required":["q"],"title":"VerifyingQuestion","description":"A single verifying question with optional sub-questions.\n\nEach sub-question stands on its own (treated as an individual question\ndownstream) while remembering its parent via list ordering."},"VettingQuestionResponse":{"properties":{"question_id":{"type":"string","format":"uuid","title":"Question Id"},"question_text":{"type":"string","title":"Question Text"},"asked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Asked At"},"answer_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Answer Id"},"answer_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Answer Text"},"answered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Answered At"},"project_anon_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Anon Code"}},"type":"object","required":["question_id","question_text"],"title":"VettingQuestionResponse","description":"Response schema for a vetting question"},"WebhookLogEntry":{"properties":{"id":{"type":"string","title":"Id"},"received_at":{"type":"string","format":"date-time","title":"Received At"},"path":{"type":"string","title":"Path"},"signature_ok":{"type":"boolean","title":"Signature Ok"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"headers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Headers"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"parsed":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parsed"}},"type":"object","required":["id","received_at","path","signature_ok"],"title":"WebhookLogEntry"},"WebhookLogResponse":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/WebhookLogEntry"},"type":"array","title":"Entries"}},"type":"object","required":["entries"],"title":"WebhookLogResponse"},"WorkExperience":{"properties":{"company_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Id"},"company_name":{"type":"string","title":"Company Name"},"company_location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Location"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"start_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End Date"},"tenure":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tenure"}},"type":"object","required":["company_name"],"title":"WorkExperience"},"app__routers__chat_inbox__ChatMessageItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"sender_role":{"type":"string","title":"Sender Role"},"body":{"type":"string","title":"Body"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"is_self":{"type":"boolean","title":"Is Self"},"attachments":{"items":{"$ref":"#/components/schemas/ExpertCard"},"type":"array","title":"Attachments","default":[]},"file_attachments":{"items":{"$ref":"#/components/schemas/FileAttachmentCard"},"type":"array","title":"File Attachments","default":[]}},"type":"object","required":["id","sender_role","body","created_at","is_self"],"title":"ChatMessageItem"},"app__routers__chat_inbox__MarkReadResponse":{"properties":{"ok":{"type":"boolean","title":"Ok","default":true}},"type":"object","title":"MarkReadResponse"},"app__schemas__admin__ChatMessageItem":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text"},"sender_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Name"},"sender_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Id"},"is_self":{"type":"boolean","title":"Is Self","default":false},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"}},"type":"object","title":"ChatMessageItem"},"app__schemas__contact__MarkReadResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","message"],"title":"MarkReadResponse","description":"Response schema for marking a submission as read"}}}}