{"openapi":"3.0.0","paths":{"/v1/team-member-invites":{"get":{"description":"Fetches all the team member invites associated with the team or workspace.","operationId":"PublicV1TeamMemberInvitesController_findTeamMemberInvitesForV1Api","parameters":[{"name":"workspaceId","required":false,"in":"query","schema":{"type":"string"}},{"name":"isAccepted","required":false,"in":"query","description":"Indicates whether the invitation has been accepted. Set to true if the user accepted the invitation and is now a team member.","schema":{"example":true,"type":"boolean"}},{"name":"role","required":false,"in":"query","description":"Role to assign to the invited user (either TEAM_MEMBER or CLIENT).","schema":{"example":"CLIENT","type":"string","enum":["TEAM_MEMBER","CLIENT"]}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TeamMemberInviteDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all team member invites","tags":["Team Member Invites"]},"post":{"description":"Creates a new invite for a user to join the workspace.","operationId":"PublicV1TeamMemberInvitesController_createUserInviteForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUserInvitePublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamMemberInviteDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new user invite","tags":["Team Member Invites"]}},"/v1/team-member-invites/generate-client-signup-link":{"post":{"description":"Creates an invite for a client and returns the signup link. The link uses the team's configured website URL.","operationId":"PublicV1TeamMemberInvitesController_generateClientSignupLinkForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateClientSignupLinkPublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientSignupLinkDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Generate a client signup link","tags":["Team Member Invites"]}},"/v1/team-member-invites/{id}":{"delete":{"description":"Deletes a team member invite by its ID.","operationId":"PublicV1TeamMemberInvitesController_deleteTeamMemberInviteForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a team member invite","tags":["Team Member Invites"]}},"/v1/team-members":{"get":{"description":"Fetches all the team members associated with the team or workspace.","operationId":"PublicV1TeamMembersController_findTeamMembersForV1Api","parameters":[{"name":"workspaceId","required":false,"in":"query","description":"The unique identifier (UUID) of the workspace to search for team members.","schema":{"example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb","type":"string"}},{"name":"roles","required":false,"in":"query","description":"Roles (TEAM_MEMBER or CLIENT).","schema":{"example":["CLIENT"],"type":"array","items":{"type":"string","enum":["OWNER","SUPER_ADMIN","SUPPORT","TEAM_MEMBER","CLIENT"]}}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TeamMemberDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all team members","tags":["Team Members"]},"delete":{"description":"Deletes a team member from the workspace.","operationId":"PublicV1TeamMembersController_deleteTeamMemberForV1Api","parameters":[{"name":"id","required":true,"in":"query","description":"The unique identifier (UUID) of the user to be deleted.","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"workspaceId","required":true,"in":"query","description":"The unique identifier (UUID) of the workspace from which the team member should be deleted.","schema":{"example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb","type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a team member","tags":["Team Members"]}},"/v1/email-bison/tags":{"get":{"description":"Fetches all Email Bison tags for the specified workspace.","operationId":"PublicV1EmailBisonController_findEmailBisonTagsForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/EmailBisonTagDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get Email Bison tags","tags":["Email Bison"]}},"/v1/linkedin/accounts":{"get":{"description":"Get a paginated collection of LinkedIn accounts. Get up to 100 accounts per request.","operationId":"PublicV1LinkedInController_findAccountsForV1Api","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":true,"in":"query","description":"The workspace ID","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"search","required":false,"in":"query","description":"Search term to filter accounts by firstName, lastName, or email","schema":{"example":"elliot","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LinkedinAccountDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get LinkedIn accounts","tags":["LinkedIn"]}},"/v1/linkedin/conversations":{"get":{"description":"Fetches paginated list of LinkedIn conversations for the specified workspace.","operationId":"PublicV1LinkedInController_findConversationsForV1Api","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":true,"in":"query","description":"The workspace ID","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"linkedInAccountId","required":false,"in":"query","description":"Filter by LinkedIn account ID","schema":{"example":156653,"type":"number"}},{"name":"folder","required":false,"in":"query","description":"Filter by folder","schema":{"type":"string","enum":["INBOX","DONE","TRASH","DELETED"]}},{"name":"tagIds","required":false,"in":"query","description":"Filter by tag IDs","schema":{"type":"array","items":{"type":"string"}}},{"name":"seen","required":false,"in":"query","description":"Filter by seen status (true = seen, false = unseen)","schema":{"example":false,"type":"boolean"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LinkedInConversationDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get LinkedIn conversations","tags":["LinkedIn"]}},"/v1/linkedin/conversations/{id}":{"get":{"description":"Fetches a specific LinkedIn conversation by its ID.","operationId":"PublicV1LinkedInController_findConversationByIdForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Conversation identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkedInConversationDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get LinkedIn conversation by ID","tags":["LinkedIn"]}},"/v1/linkedin/conversations/{conversationId}/messages":{"get":{"description":"Fetches paginated messages for the specified LinkedIn conversation.","operationId":"PublicV1LinkedInController_findMessagesByConversationForV1Api","parameters":[{"name":"conversationId","required":true,"in":"path","description":"Conversation identifier","schema":{"type":"string"}},{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LinkedInMessageDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get messages for a LinkedIn conversation","tags":["LinkedIn"]}},"/v1/linkedin/conversations/{conversationId}":{"patch":{"description":"Updates folder, tags, seen status, or lead link for a LinkedIn conversation.","operationId":"PublicV1LinkedInController_updateConversationForV1Api","parameters":[{"name":"conversationId","required":true,"in":"path","description":"Conversation identifier","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateLinkedInConversationPublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkedInConversationDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update a LinkedIn conversation","tags":["LinkedIn"]}},"/v1/linkedin/conversation-reminders":{"post":{"description":"Creates a new reminder for a LinkedIn conversation.","operationId":"PublicV1LinkedInController_createConversationReminderForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateLinkedInConversationReminderPublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkedInConversationReminderDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a LinkedIn conversation reminder","tags":["LinkedIn"]}},"/v1/linkedin/tags":{"get":{"description":"Get a list of LinkedIn tags for the specified workspace.","operationId":"PublicV1LinkedInController_findTagsForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"The workspace ID","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/LinkedInTagDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get LinkedIn tags","tags":["LinkedIn"]}},"/v1/linkedin/send-message":{"post":{"description":"Sends a message to the specified LinkedIn conversation.","operationId":"PublicV1LinkedInController_sendMessageForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendLinkedInMessageInput"}}}},"responses":{"200":{"description":"Message sent successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkedInMessageDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Send a LinkedIn message","tags":["LinkedIn"]}},"/v1/mailboxes":{"get":{"description":"Retrieves a paginated list of mailboxes based on the provided filters.","operationId":"PublicV1MailboxesController_findMailboxesForV1Api","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":false,"in":"query","description":"The unique identifier (UUID) of the workspace to filter the mailboxes.","schema":{"example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb","type":"string"}},{"name":"email","required":false,"in":"query","description":"Email address associated with the mailbox","schema":{"example":"user@example.com","type":"string"}},{"name":"currentConnectionStatus","required":false,"in":"query","description":"An array of connection statuses to filter by, represented by the ConnectionType enum.","schema":{"example":["CONNECTED","GATHERING","DISCONNECTED"],"type":"array","items":{"type":"string","enum":["INITIALIZING","CONNECTED","DISCONNECTED","GATHERING","RECONNECTING","DELETING"]}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/MailboxDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all mailboxes","tags":["Mailboxes"]}},"/v1/mailboxes/connect-imap":{"post":{"operationId":"PublicV1MailboxesController_addMailboxForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateMailboxPublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailboxDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new IMAP mailbox for a specific workspace","tags":["Mailboxes"]}},"/v1/mailboxes/imap-bulk":{"post":{"operationId":"PublicV1MailboxesController_imapBulkUpload","parameters":[],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/ImapBulkUploadCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MailboxImportResultDto"}},"example":true}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"tags":["Mailboxes"]}},"/v1/mailboxes/{id}/reconnect":{"patch":{"description":"Reconnects the specified IMAP mailbox account.","operationId":"PublicV1MailboxesController_reconnectImapAccountForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReconnectMailboxPublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailboxDto"},"example":true}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Reconnect an existing IMAP mailbox","tags":["Mailboxes"]}},"/v1/mailboxes/{id}":{"delete":{"description":"Permanently deletes the specified IMAP mailbox account for a workspace.","operationId":"PublicV1MailboxesController_deleteMailboxForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete an IMAP mailbox account","tags":["Mailboxes"]}},"/v1/crm/opportunities":{"get":{"operationId":"PublicV1OpportunitiesController_findOpportunitiesForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"The unique identifier of the workspace where the opportunities are located.","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"threadId","required":false,"in":"query","description":"Filter by email thread ID.","schema":{"example":"8b2a8c40-7f4b-4f5a-9419-73a08b7d6f2e","type":"string"}},{"name":"linkedinConversationId","required":false,"in":"query","description":"Filter by LinkedIn conversation ID.","schema":{"example":"a1b2c3d4-e5f6-7890-abcd-ef1234567890","type":"string"}},{"name":"stageId","required":false,"in":"query","description":"Filter by opportunity stage ID.","schema":{"example":"7c82c0a0-6d42-4a1c-8a52-64d99aef1a34","type":"string"}},{"name":"page","required":false,"in":"query","description":"Page number for pagination.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"perStage","required":false,"in":"query","description":"Number of opportunities to load per stage.","schema":{"minimum":1,"maximum":100,"default":25,"example":25,"type":"integer"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedOpportunitiesDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get opportunities with pagination","tags":["Opportunities"]},"post":{"operationId":"PublicV1OpportunitiesController_createOpportunityForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateOpportunityPublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpportunityDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new opportunity","tags":["Opportunities"]}},"/v1/crm/opportunities/stage-summaries":{"get":{"operationId":"PublicV1OpportunitiesController_findStageSummariesForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OpportunityStageSummaryDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get total value and count per stage","tags":["Opportunities"]}},"/v1/crm/opportunities/{id}":{"get":{"operationId":"PublicV1OpportunitiesController_findOpportunityForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpportunityDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Find a specific opportunity by ID","tags":["Opportunities"]},"patch":{"operationId":"PublicV1OpportunitiesController_updateOpportunityForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateOpportunityCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpportunityDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update an existing opportunity","tags":["Opportunities"]},"delete":{"operationId":"PublicV1OpportunitiesController_deleteOpportunityForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete an opportunity by ID","tags":["Opportunities"]}},"/v1/crm/opportunities/details/{id}":{"get":{"operationId":"PublicV1OpportunitiesController_findOpportunityDetailsForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpportunityDetailsDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get opportunity details including the last communication dates","tags":["Opportunities"]}},"/v1/crm/stages":{"get":{"description":"Retrieves a list of opportunity stages associated with the specified workspace.","operationId":"PublicV1OpportunityStagesController_findOpportunityStagesForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"The ID of the workspace for which opportunity stages are being retrieved.","schema":{"example":"a1b2c3d4-e5f6-7890-ab12-34567890cdef","type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OpportunityStageDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get opportunity stages","tags":["Opportunity Stages"]},"post":{"description":"Creates a new opportunity stage associated with the specified workspace.","operationId":"PublicV1OpportunityStagesController_createOpportunityStage","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateOpportunityStagePublicV1InternalInput"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpportunityStageDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create an opportunity stage","tags":["Opportunity Stages"]}},"/v1/crm/stages/{id}":{"patch":{"description":"Updates an existing opportunity stage identified by the provided ID.","operationId":"PublicV1OpportunityStagesController_updateOpportunityStageForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateOpportunityStageCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpportunityStageDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update an opportunity stage","tags":["Opportunity Stages"]},"delete":{"description":"Permanently deletes the opportunity stage identified by the provided ID.","operationId":"PublicV1OpportunityStagesController_deleteOpportunityStageForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete an opportunity stage","tags":["Opportunity Stages"]}},"/v1/webhooks":{"get":{"description":"Fetches all webhooks for the specified workspace.","operationId":"PublicV1WebhooksController_findWebhooksForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"ID of the workspace to find webhooks for","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"isEnabled","required":false,"in":"query","description":"Filter by enabled status","schema":{"example":true,"type":"boolean"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all webhooks","tags":["Webhooks"]},"post":{"description":"Creates a new webhook for the specified workspace.","operationId":"PublicV1WebhooksController_createWebhookForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateWebhookPublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new webhook","tags":["Webhooks"]}},"/v1/webhooks/{id}":{"get":{"description":"Fetches a specific webhook by its ID.","operationId":"PublicV1WebhooksController_findWebhookByIdForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Webhook identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get webhook by ID","tags":["Webhooks"]},"patch":{"description":"Updates an existing webhook.","operationId":"PublicV1WebhooksController_updateWebhookForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Webhook identifier","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateWebhookPublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update a webhook","tags":["Webhooks"]},"delete":{"description":"Deletes a webhook by its ID.","operationId":"PublicV1WebhooksController_deleteWebhookForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Webhook identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a webhook","tags":["Webhooks"]}},"/v1/events":{"get":{"description":"Fetches all available webhook event types for the specified workspace.","operationId":"PublicV1EventsController_findEventsForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"Workspace ID","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"category","required":false,"in":"query","schema":{"type":"string","enum":["SYSTEM","LINKEDIN"]}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/EventPublicDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all events","tags":["Events"]}},"/v1/integrations/{type}":{"get":{"description":"Fetches an integration by its type for the specified workspace.","operationId":"PublicV1IntegrationsController_findIntegrationForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","schema":{"type":"string"}},{"name":"type","required":true,"in":"path","description":"The type of integration to find","schema":{"enum":["EMAIL_BISON","HEY_REACH"],"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get integration by type","tags":["Integrations"]}},"/v1/integrations":{"post":{"description":"Creates a new integration for the specified workspace.","operationId":"PublicV1IntegrationsController_createIntegrationForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIntegrationInput"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create integration","tags":["Integrations"]}},"/v1/integrations/{id}":{"patch":{"description":"Updates the settings of an existing integration.","operationId":"PublicV1IntegrationsController_updateIntegrationForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Integration identifier","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateIntegrationPublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update integration settings","tags":["Integrations"]}},"/v1/workspaces":{"get":{"operationId":"PublicV1WorkspacesController_findWorkspacesForV1Api","parameters":[],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WorkspaceDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all workspaces","tags":["Workspaces & ClientBox"]},"post":{"operationId":"PublicV1WorkspacesController_createWorkspaceForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateWorkspacePublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new workspace","tags":["Workspaces & ClientBox"]}},"/v1/workspaces/short":{"get":{"operationId":"PublicV1WorkspacesController_findWorkspacesShortInfoForV1Api","parameters":[],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WorkspaceShortInfoDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List workspace IDs and names","tags":["Workspaces & ClientBox"]}},"/v1/workspaces/analytics":{"get":{"description":"Returns aggregated analytics for the specified date range. Includes metrics like sends, replies, bounces, reply rates, etc. For deals, returns {value, count} representing total amount and number of deals.","operationId":"PublicV1WorkspacesController_findWorkspaceAnalyticsForV1Api","parameters":[{"name":"workspaceId","required":false,"in":"query","description":"Workspace ID to get analytics for. If not provided, returns analytics for all accessible workspaces.","schema":{"example":"550e8400-e29b-41d4-a716-446655440000","type":"string"}},{"name":"startDateTime","required":true,"in":"query","description":"Start of the date-time range (ISO 8601 format)","schema":{"example":"2025-01-01T00:00:00Z","type":"string"}},{"name":"endDateTime","required":true,"in":"query","description":"End of the date-time range (ISO 8601 format). Maximum period is 6 months.","schema":{"example":"2025-01-31T23:59:59Z","type":"string"}}],"responses":{"200":{"description":"Aggregated analytics summary","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceAnalyticsSummaryDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get workspace analytics summary","tags":["Workspaces & ClientBox"]}},"/v1/workspaces/settings":{"get":{"description":"Returns settings for label management, opportunities board, LinkedIn inbox, and email visibility.","operationId":"PublicV1WorkspacesController_findWorkspaceClientSettingsForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"ID of the workspace to find client settings for","schema":{"example":"550e8400-e29b-41d4-a716-446655440000","type":"string"}}],"responses":{"200":{"description":"Workspace client settings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceClientSettingsDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get workspace client settings","tags":["Workspaces & ClientBox"]}},"/v1/workspaces/settings/{workspaceId}":{"patch":{"description":"Update settings for label management, opportunities board, LinkedIn inbox, and email visibility.","operationId":"PublicV1WorkspacesController_updateWorkspaceClientSettingsForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"path","description":"Workspace ID","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateWorkspaceClientSettingsPublicV1Input"}}}},"responses":{"200":{"description":"Updated workspace client settings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceClientSettingsDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update workspace client settings","tags":["Workspaces & ClientBox"]}},"/v1/workspaces/{id}":{"patch":{"description":"Updates the details of the workspace identified by the provided ID.","operationId":"PublicV1WorkspacesController_updateWorkspaceForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Workspace identifier","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateWorkspacePublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkspaceDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update a specific workspace","tags":["Workspaces & ClientBox"]},"delete":{"description":"Permanently deletes the workspace identified by the provided ID.","operationId":"PublicV1WorkspacesController_deleteWorkspaceForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Workspace identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a workspace","tags":["Workspaces & ClientBox"]}},"/v1/warmups/tags":{"get":{"description":"Retrieves a list of warmup tags associated with the specified workspace.","operationId":"PublicV1WarmupTagsController_findWarmupTags","parameters":[{"name":"workspaceId","required":false,"in":"query","description":"The ID of the workspace from which to retrieve warmup tags.","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WarmupTagPublicDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get warmup tags","tags":["Warmup Tags"]},"post":{"description":"Creates a new warmup tag associated with the specified workspace.","operationId":"PublicV1WarmupTagsController_createWarmupTagForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateWarmupTagCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WarmupTagPublicDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a warmup tag","tags":["Warmup Tags"]}},"/v1/warmups/tags/bulk":{"post":{"description":"Creates multiple warmup tags associated with the specified workspace.","operationId":"PublicV1WarmupTagsController_createWarmupTagsForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateWarmupTagsCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WarmupTagPublicDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create multiple warmup tags","tags":["Warmup Tags"]}},"/v1/warmups/tags/{id}":{"delete":{"description":"Permanently deletes the warmup tag identified by the provided ID.","operationId":"PublicV1WarmupTagsController_deleteWarmupTagForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a warmup tag","tags":["Warmup Tags"]}},"/v1/labels":{"get":{"description":"Fetches all labels for the given team based on the provided filters.","operationId":"PublicV1ThreadLabelsController_findThreadLabelsForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"The ID of the workspace for which thread labels are being retrieved.","schema":{"example":"a1b2c3d4-e5f6-7890-ab12-34567890cdef","type":"string"}},{"name":"isClient","required":false,"in":"query","schema":{"example":true,"type":"boolean"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ThreadLabelDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all labels","tags":["Thread Labels"]},"post":{"description":"Creates a new thread label for the specified workspace.","operationId":"PublicV1ThreadLabelsController_createThreadLabelForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateThreadLabelPublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadLabelDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new thread label","tags":["Thread Labels"]}},"/v1/labels/short":{"get":{"description":"Retrieves a condensed version of labels with only essential fields (e.g., id and name) based on the provided filters.","operationId":"PublicV1ThreadLabelsController_findThreadLabelsShortInfoForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"The ID of the workspace for which thread labels are being retrieved.","schema":{"example":"a1b2c3d4-e5f6-7890-ab12-34567890cdef","type":"string"}},{"name":"isClient","required":false,"in":"query","schema":{"example":true,"type":"boolean"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ThreadLabelShortInfoDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get labels with minimal label details","tags":["Thread Labels"]}},"/v1/labels/bulk":{"post":{"description":"Creates multiple thread labels in bulk for the specified workspace.","operationId":"PublicV1ThreadLabelsController_createThreadLabelsForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateThreadLabelsPublicV1Input"}}}},"responses":{"201":{"description":"IDs of the created labels.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/"}},"example":["1f684e24-ef21-4544-a4a9-c994e2a6d2cf"]}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Bulk create thread labels","tags":["Thread Labels"]}},"/v1/labels/{id}":{"patch":{"description":"Updates an existing thread label for the specified ID. Note: A maximum of 3 labels can be marked as favourite per workspace.","operationId":"PublicV1ThreadLabelsController_updateThreadLabelForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateThreadLabelPublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadLabelDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"409":{"description":"Only 3 favourite labels are allowed per workspace"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update thread label","tags":["Thread Labels"]},"delete":{"description":"Deletes a thread label by its ID for the specified workspace.","operationId":"PublicV1ThreadLabelsController_deleteThreadLabelForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete thread label","tags":["Thread Labels"]}},"/v1/campaigns":{"get":{"operationId":"PublicV1CampaignsController_findCampaigns","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":true,"in":"query","description":"Workspace whose campaigns to list.","schema":{"example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890","type":"string"}},{"name":"statuses","required":false,"in":"query","description":"Filter by lifecycle status (any-of match). Combined with `excludeStatuses` as include-minus-exclude: a status present in both yields no rows.","examples":["draft","active","paused","pausing","activating","disabled","completed","archived"],"schema":{"example":["active","paused"],"type":"array","items":{"type":"string","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"]}}},{"name":"excludeStatuses","required":false,"in":"query","description":"Exclude campaigns with these lifecycle statuses (none-of match). Applied after `statuses` (exclude wins on overlap); e.g. pass `archived` to hide archived campaigns.","examples":["draft","active","paused","pausing","activating","disabled","completed","archived"],"schema":{"example":["archived"],"type":"array","items":{"type":"string","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"]}}},{"name":"types","required":false,"in":"query","description":"Filter by campaign type (any-of match).","examples":["COLD","EVERGREEN","SUB_SEQUENCE"],"schema":{"example":["COLD"],"type":"array","items":{"type":"string","enum":["COLD","EVERGREEN","SUB_SEQUENCE"]}}},{"name":"priorities","required":false,"in":"query","description":"Filter by priority (any-of match).","examples":["CRITICAL","HIGH","MEDIUM","LOW","NONE"],"schema":{"example":["HIGH","CRITICAL"],"type":"array","items":{"type":"string","enum":["CRITICAL","HIGH","MEDIUM","LOW","NONE"]}}},{"name":"groupIds","required":false,"in":"query","description":"Filter by campaign group IDs (any-of match).","schema":{"example":["b1c2d3e4-f5a6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}}},{"name":"search","required":false,"in":"query","description":"Case-insensitive substring match on campaign name.","schema":{"example":"outbound","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CampaignSummaryDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List campaigns","tags":["Campaigns"]},"post":{"operationId":"PublicV1CampaignsController_create","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCampaignPublicV1Input"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a draft campaign","tags":["Campaigns"]}},"/v1/campaigns/{campaignId}":{"get":{"operationId":"PublicV1CampaignsController_findOne","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignDetailDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get a campaign with steps","tags":["Campaigns"]},"patch":{"description":"Edits settings; publish a draft by sending status=\"paused\". Editing settings/steps on an ACTIVE campaign returns 409 — pause first.","operationId":"PublicV1CampaignsController_update","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateCampaignPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update a campaign","tags":["Campaigns"]},"delete":{"operationId":"PublicV1CampaignsController_remove","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted."},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a campaign","tags":["Campaigns"]}},"/v1/campaigns/{campaignId}/steps":{"get":{"operationId":"PublicV1CampaignsController_findSteps","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CampaignStepDetailDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List campaign steps","tags":["Campaigns"]}},"/v1/campaigns/{campaignId}/schedule":{"get":{"operationId":"PublicV1CampaignsController_findSchedule","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignScheduleDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get campaign sending schedule","tags":["Campaigns"]}},"/v1/campaigns/{campaignId}/duplicate":{"post":{"operationId":"PublicV1CampaignsController_duplicate","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Duplicate a campaign as a draft","tags":["Campaigns"]}},"/v1/campaigns/{campaignId}/activate":{"post":{"description":"PAUSED→ACTIVE. Returns 409 if not ready (COLD/EVERGREEN need ≥1 mailbox and ≥1 enrolled lead).","operationId":"PublicV1CampaignsController_activate","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Activate a campaign","tags":["Campaigns"]}},"/v1/campaigns/{campaignId}/pause":{"post":{"operationId":"PublicV1CampaignsController_pause","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Pause a campaign (ACTIVE→PAUSED)","tags":["Campaigns"]}},"/v1/campaigns/{campaignId}/archive":{"post":{"description":"PAUSED→ARCHIVED. Returns 409 if the campaign is not paused.","operationId":"PublicV1CampaignsController_archive","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Archive a campaign","tags":["Campaigns"]}},"/v1/campaign-steps":{"get":{"operationId":"PublicV1CampaignStepsController_findSteps","parameters":[{"name":"campaignId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CampaignStepDetailDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List steps for a campaign","tags":["Campaign Steps"]},"post":{"operationId":"PublicV1CampaignStepsController_createSteps","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCampaignStepsPublicV1Input"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceStepDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create steps for a campaign (campaign must be paused or draft)","tags":["Campaign Steps"]},"put":{"description":"Steps with `id` matching existing steps are updated in-place; steps without `id` are inserted; existing steps not in the array are deleted.","operationId":"PublicV1CampaignStepsController_updateSteps","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateCampaignStepsPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceStepDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Replace all steps for a campaign (full replacement, campaign must be paused or draft)","tags":["Campaign Steps"]}},"/v1/campaign-steps/variants/{variantId}":{"patch":{"operationId":"PublicV1CampaignStepsController_updateVariant","parameters":[{"name":"variantId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateVariantPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceStepVariantDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update a variant","tags":["Campaign Steps"]},"delete":{"operationId":"PublicV1CampaignStepsController_deleteVariant","parameters":[{"name":"variantId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted."},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a variant","tags":["Campaign Steps"]}},"/v1/campaign-steps/variants/{variantId}/toggle":{"post":{"operationId":"PublicV1CampaignStepsController_toggleVariant","parameters":[{"name":"variantId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ToggleVariantInput"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceStepVariantDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Toggle a variant active/inactive","tags":["Campaign Steps"]}},"/v1/campaign-steps/{stepId}/variants":{"get":{"operationId":"PublicV1CampaignStepsController_listVariants","parameters":[{"name":"stepId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceStepVariantDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List variants for a step","tags":["Campaign Steps"]},"post":{"operationId":"PublicV1CampaignStepsController_createVariant","parameters":[{"name":"stepId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateVariantPublicV1Input"}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceStepVariantDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Add a variant to a step (campaign must be paused or draft)","tags":["Campaign Steps"]}},"/v1/campaign-steps/{stepId}":{"delete":{"operationId":"PublicV1CampaignStepsController_deleteStep","parameters":[{"name":"stepId","required":true,"in":"path","schema":{"type":"string"}},{"name":"campaignId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted."},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a step from a campaign (campaign must be paused or draft)","tags":["Campaign Steps"]}},"/v1/campaigns/preview-leads":{"post":{"description":"Returns totalUniqueLeads / blockedLeadCount / eligibleLeadCount for the resolved list selection. Pass excludeCampaignId when editing an existing campaign so its own enrolled leads are not counted as conflicts.","operationId":"PublicV1CampaignLeadsController_previewLeads","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreviewCampaignLeadsPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreviewCampaignLeadsResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Preview eligible lead count for a list selection","tags":["Campaign Leads"]}},"/v1/campaigns/{campaignId}/leads":{"get":{"description":"Paginated. Filter by status, replyType, tagIds, leadEmail, or a free-text search. Only progresses with a CRM lead (leadId IS NOT NULL) are returned.","operationId":"PublicV1CampaignLeadsController_findProgresses","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}},{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"status","required":false,"in":"query","description":"Repeat to pass multiple values, e.g. ?status=pending&status=in_progress. OR-match: a row matches if its status is in the list.","schema":{"type":"array","items":{"type":"string","enum":["pending","in_progress","paused","completed_replied","completed_sent","cancelled","failed","bounced"]}}},{"name":"replyType","required":false,"in":"query","description":"Repeat to pass multiple values, e.g. ?replyType=positive&replyType=negative. OR-match on the lead's first-reply classification. Useful for the Positive-replies chip filter.","schema":{"type":"array","items":{"type":"string","enum":["none","auto","positive","negative","neutral","unclassified"]}}},{"name":"tagIds","required":false,"in":"query","description":"Repeat to pass multiple values, e.g. ?tagIds=<uuid>&tagIds=<uuid>. OR-match: a row matches if it carries any of the listed tags.","schema":{"type":"array","items":{"type":"string"}}},{"name":"leadEmail","required":false,"in":"query","schema":{"format":"email","type":"string"}},{"name":"search","required":false,"in":"query","description":"Case-insensitive substring match across lead name, company name, and lead email.","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SequenceProgressDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List enrolled leads (sequence progresses) for a campaign","tags":["Campaign Leads"]},"post":{"description":"Enrols the given CRM lead ids (COLD/EVERGREEN only — no list resolution). Campaign must be ACTIVE or PAUSED.","operationId":"PublicV1CampaignLeadsController_addLeadsByIds","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddLeadsByIdsPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddListsToCampaignResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Enrol explicit lead ids into a campaign","tags":["Campaign Leads"]},"delete":{"description":"Cancels the selected sequence progresses. Selection may be explicit progressIds or a criteria filter mirroring GET /campaigns/:id/leads. Campaign must be ACTIVE or PAUSED.","operationId":"PublicV1CampaignLeadsController_removeLeads","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RemoveLeadsPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RemoveLeadsFromCampaignResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Remove (cancel) leads from a campaign","tags":["Campaign Leads"]}},"/v1/campaigns/{campaignId}/lists":{"post":{"description":"Resolves the listSelection to a concrete set of list ids and appends only the lists not already attached (no replace). Campaign must be ACTIVE or PAUSED.","operationId":"PublicV1CampaignLeadsController_addLists","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddListsPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddListsToCampaignResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Append lists to an active or paused campaign","tags":["Campaign Leads"]}},"/v1/campaigns/{campaignId}/leads/{leadId}/pause":{"post":{"description":"Moves the lead's progress to PAUSED and cancels any pending Bull send job. Only PENDING or IN_PROGRESS progresses can be paused.","operationId":"PublicV1CampaignLeadsController_pauseSubscriber","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}},{"name":"leadId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceProgressDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Pause a single enrolled lead","tags":["Campaign Leads"]}},"/v1/campaigns/{campaignId}/leads/{leadId}/resume":{"post":{"description":"Moves the lead's progress from PAUSED back to IN_PROGRESS and re-schedules the next step. Only PAUSED progresses can be resumed.","operationId":"PublicV1CampaignLeadsController_resumeSubscriber","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}},{"name":"leadId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceProgressDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Resume a paused enrolled lead","tags":["Campaign Leads"]}},"/v1/campaigns/{campaignId}/mailboxes":{"get":{"description":"Paginated list of mailboxes in the campaign's sending pool. Supports search, filter chips (connectionStatus, bounceRate, replyRate, domain, providerType), and sort.","operationId":"PublicV1CampaignMailboxesController_findMailboxes","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}},{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"search","required":false,"in":"query","description":"Free-text substring match against mailbox email, first name, or last name. Resolved via the accounts service before the campaign_accounts query.","schema":{"type":"string"}},{"name":"connectionStatus","required":false,"in":"query","description":"Filter to mailboxes with this connection status (resolved via accounts hydration). Use `DISCONNECTED` for the Disconnected chip.","schema":{"type":"string","enum":["INITIALIZING","CONNECTED","DISCONNECTED","GATHERING","RECONNECTING","DELETING"]}},{"name":"minBounceRate","required":false,"in":"query","description":"Strict lower bound on the mailbox's bounce rate as a percentage 0..100. For the `Bounce > 3%` chip pass `3`; for `Bounce > 5%` pass `5`. When the UI lets the user select multiple bounce chips, send the **minimum** of the selected thresholds — the looser bound subsumes the stricter ones (e.g. `> 3%` and `> 5%` selected → pass `3`). Only mailboxes with `sent > 0` are eligible.","schema":{"minimum":0,"maximum":100,"type":"number"}},{"name":"maxReplyRate","required":false,"in":"query","description":"Strict upper bound on the mailbox's reply rate as a percentage 0..100. For the `Reply Rate < 1%` chip pass `1`; for `Reply Rate < 3%` pass `3`. When the UI lets the user select multiple reply-rate chips, send the **maximum** of the selected thresholds — the looser bound subsumes the stricter ones (e.g. `< 1%` and `< 3%` selected → pass `3`). Only mailboxes with `sent > 0` are eligible.","schema":{"minimum":0,"maximum":100,"type":"number"}},{"name":"domain","required":false,"in":"query","description":"Filter to mailboxes whose email domain matches one of these (e.g. `gmail.com`). Resolved via accounts hydration.","schema":{"type":"array","items":{"type":"string"}}},{"name":"providerType","required":false,"in":"query","description":"Filter to mailboxes of these provider types (e.g. `GOOGLE_GMAIL`, `MICROSOFT_OUTLOOK`, `IMAP_SMTP`). Resolved via accounts hydration.","schema":{"type":"array","items":{"type":"string"}}},{"name":"sortBy","required":false,"in":"query","description":"`createdAt` (default) sorts on `campaign_accounts.created_at`. `email` and `connectionStatus` are resolved via the accounts service — a slim sort-keys RPC pulls the keys for the whole campaign, JS sorts, then we page over `campaign_accounts` preserving that order. Pair with `sortOrder`.","schema":{"default":"createdAt","type":"string","enum":["createdAt","email","connectionStatus"]}},{"name":"sortOrder","required":false,"in":"query","description":"Sort direction. Defaults to `DESC` (matches the historical newest-first ordering). For `email` you almost certainly want `ASC` (A→Z).","schema":{"default":"DESC","type":"string","enum":["ASC","DESC"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CampaignMailboxDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List mailboxes attached to a campaign","tags":["Campaign Mailboxes"]},"post":{"description":"Appends mailboxes to the campaign's sending pool. Only mailboxes not already attached are inserted (no replace, no detach). Campaign must be ACTIVE or PAUSED.","operationId":"PublicV1CampaignMailboxesController_attachMailboxes","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttachCampaignMailboxesPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttachCampaignMailboxesResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Attach mailboxes to an active or paused campaign","tags":["Campaign Mailboxes"]},"delete":{"description":"Removes the selected mailboxes from the campaign's sending pool. On ACTIVE campaigns, refuses if the delete would leave zero mailboxes (409 MUST_KEEP_AT_LEAST_ONE_MAILBOX). Campaign must be ACTIVE or PAUSED.","operationId":"PublicV1CampaignMailboxesController_detachMailboxes","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkDetachCampaignMailboxesPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkDetachCampaignMailboxesResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Detach mailboxes from an active or paused campaign","tags":["Campaign Mailboxes"]}},"/v1/campaigns/{campaignId}/mailboxes/{mailboxId}/pause":{"post":{"description":"Flips the paused state for the mailbox and runs per-mailbox handover so active leads are reassigned to healthy peers. Already-paused mailboxes are a no-op. Campaign must be ACTIVE or PAUSED.","operationId":"PublicV1CampaignMailboxesController_pauseMailbox","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}},{"name":"mailboxId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkPauseCampaignMailboxesResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Pause a single mailbox within a campaign","tags":["Campaign Mailboxes"]}},"/v1/campaigns/{campaignId}/mailboxes/{mailboxId}/resume":{"post":{"description":"Unpauses the mailbox so it can resume sending. Already-active mailboxes are silently skipped. Campaign must be ACTIVE or PAUSED.","operationId":"PublicV1CampaignMailboxesController_resumeMailbox","parameters":[{"name":"campaignId","required":true,"in":"path","schema":{"type":"string"}},{"name":"mailboxId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkResumeCampaignMailboxesResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Resume a single paused mailbox within a campaign","tags":["Campaign Mailboxes"]}},"/v1/crm/companies":{"get":{"description":"Retrieves a paginated list of the companies based on the provided filters.","operationId":"PublicV1CrmCompaniesController_findCompanies","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":true,"in":"query","description":"Workspace ID the company belongs to","schema":{"example":"workspace_123","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CompanyDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Retrieve companies","tags":["CRM Companies"]},"post":{"operationId":"PublicV1CrmCompaniesController_createCompany","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCompanyPublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new company","tags":["CRM Companies"]}},"/v1/crm/companies/{id}":{"get":{"operationId":"PublicV1CrmCompaniesController_findCompanyById","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Find company by ID","tags":["CRM Companies"]},"patch":{"description":"Updates an existing company for the specified ID.","operationId":"PublicV1CrmCompaniesController_updateCompany","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateCompanyCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update company","tags":["CRM Companies"]},"delete":{"description":"Permanently deletes a company by its ID. Note: This will also delete all leads associated with the company.","operationId":"PublicV1CrmCompaniesController_deleteCompany","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete company","tags":["CRM Companies"]}},"/v1/crm/leads":{"get":{"description":"Retrieves a paginated list of the leads based on the provided filters.","operationId":"PublicV1CrmLeadsController_findLeads","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":false,"in":"query","description":"Workspace ID the lead belongs to","schema":{"example":"550e8400-e29b-41d4-a716-446655440000","type":"string"}},{"name":"listIds","required":false,"in":"query","description":"Filter leads by list IDs (returns leads in ANY of the lists)","schema":{"example":["550e8400-e29b-41d4-a716-446655440002"],"type":"array","items":{"type":"string"}}},{"name":"tagIds","required":false,"in":"query","description":"Filter leads by tag IDs (returns leads with ANY of the tags)","schema":{"example":["550e8400-e29b-41d4-a716-446655440003"],"type":"array","items":{"type":"string"}}},{"name":"search","required":false,"in":"query","description":"Full-text search across name, email, domain, company name, and custom variable values","schema":{"example":"john","type":"string"}},{"name":"campaignStatus","required":false,"in":"query","description":"Filter by campaign status","schema":{"example":"active","type":"string","enum":["active","completed","not_contacted"]}},{"name":"unassignedToLists","required":false,"in":"query","description":"When true, returns only leads that are not assigned to any list. Ignored when listIds is provided.","schema":{"example":true,"type":"boolean"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LeadDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Retrieve leads","tags":["CRM Leads"]},"post":{"operationId":"PublicV1CrmLeadsController_createLead","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateLeadPublicV1Input"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new lead","tags":["CRM Leads"]}},"/v1/crm/leads/import":{"post":{"description":"Validates the CSV synchronously and enqueues it for background processing. Returns the LeadImport with status = \"queued\". Poll GET /v1/crm/leads/imports/:id for progress and final results. Maximum 50,000 rows per file. The CSV must contain an email column.","operationId":"PublicV1CrmLeadsController_importLeads","parameters":[],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file","workspaceId"],"properties":{"file":{"type":"string","format":"binary","description":"CSV file with lead data (max 50,000 rows)"},"workspaceId":{"type":"string","format":"uuid"},"mapping":{"type":"string","description":"JSON object mapping CSV column headers to lead fields. Must include an \"email\" target. Known fields: email, firstName, lastName, name, jobTitle, phoneNumber, linkedinProfileUrl, companyDomain, companyName. Anything else is treated as a custom variable name (found or auto-created).","example":"{\"Full Name\":\"name\",\"Work Email\":\"email\",\"Role\":\"jobTitle\",\"Industry\":\"Industry\"}"},"listId":{"type":"string","format":"uuid","description":"List ID to assign all imported leads to"},"tagIds":{"type":"string","description":"JSON array of tag IDs to assign to all imported leads"}}}}}},"responses":{"202":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadImportDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Start an async lead import from a CSV file","tags":["CRM Leads"]}},"/v1/crm/leads/bulk":{"post":{"description":"Validates the records synchronously and enqueues them for background processing. Returns a LeadImport with status = \"queued\". Poll GET /v1/crm/leads/imports/:id for progress and final results. Maximum 5,000 records per request. Each record must be mappable to at least an email.","operationId":"PublicV1CrmLeadsController_importLeadsFromJson","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportLeadsFromJsonPublicV1Input"}}}},"responses":{"202":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadImportDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Start an async lead import from a JSON array","tags":["CRM Leads"]}},"/v1/crm/leads/imports/{id}":{"get":{"description":"Returns current status, progress, and final results (counts, errors, auto-created custom variables) of an import started via POST /v1/crm/leads/import.","operationId":"PublicV1CrmLeadsController_findLeadImportById","parameters":[{"name":"id","required":true,"in":"path","description":"LeadImport ID","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadImportDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get the status of a lead import","tags":["CRM Leads"]}},"/v1/crm/leads/imports":{"get":{"description":"Returns the most recent imports for a workspace (newest first). Useful for polling import history or recovering after an integration restart.","operationId":"PublicV1CrmLeadsController_findLeadImports","parameters":[{"name":"workspaceId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/LeadImportDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"List recent lead imports","tags":["CRM Leads"]}},"/v1/crm/leads/{id}":{"get":{"operationId":"PublicV1CrmLeadsController_findLeadById","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Find lead by ID","tags":["CRM Leads"]},"patch":{"description":"Updates an existing lead for the specified ID.","operationId":"PublicV1CrmLeadsController_updateLead","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateLeadCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update lead","tags":["CRM Leads"]},"delete":{"description":"Permanently deletes a lead by its ID.","operationId":"PublicV1CrmLeadsController_deleteLead","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete lead","tags":["CRM Leads"]}},"/v1/crm/leads/{id}/tags/{tagId}":{"put":{"description":"Assigns a tag to the specified lead.","operationId":"PublicV1CrmLeadsController_addTagToLead","parameters":[{"name":"id","required":true,"in":"path","description":"Lead ID","schema":{"type":"string"}},{"name":"tagId","required":true,"in":"path","description":"Tag ID","schema":{"type":"string"}}],"responses":{"200":{"description":""},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Add tag to lead","tags":["CRM Leads"]},"delete":{"description":"Removes a tag from the specified lead.","operationId":"PublicV1CrmLeadsController_removeTagFromLead","parameters":[{"name":"id","required":true,"in":"path","description":"Lead ID","schema":{"type":"string"}},{"name":"tagId","required":true,"in":"path","description":"Tag ID","schema":{"type":"string"}}],"responses":{"200":{"description":""},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Remove tag from lead","tags":["CRM Leads"]}},"/v1/crm/leads/{id}/lists/{listId}":{"put":{"description":"Adds the specified lead to a list.","operationId":"PublicV1CrmLeadsController_addLeadToList","parameters":[{"name":"id","required":true,"in":"path","description":"Lead ID","schema":{"type":"string"}},{"name":"listId","required":true,"in":"path","description":"List ID","schema":{"type":"string"}}],"responses":{"200":{"description":""},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Add lead to list","tags":["CRM Leads"]},"delete":{"description":"Removes the specified lead from a list.","operationId":"PublicV1CrmLeadsController_removeLeadFromList","parameters":[{"name":"id","required":true,"in":"path","description":"Lead ID","schema":{"type":"string"}},{"name":"listId","required":true,"in":"path","description":"List ID","schema":{"type":"string"}}],"responses":{"200":{"description":""},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Remove lead from list","tags":["CRM Leads"]}},"/v1/crm/custom-variables":{"get":{"description":"Fetches all custom variables based on the provided filters.","operationId":"PublicV1CrmCustomVariablesController_findCustomVariables","parameters":[{"name":"assignedEntityType","required":false,"in":"query","description":"Entity type this custom variable belongs to","schema":{"example":"lead","type":"string","enum":["lead","company"]}},{"name":"workspaceId","required":true,"in":"query","description":"Workspace ID this custom variable belongs to","schema":{"format":"uuid","type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CustomVariableDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all custom variables","tags":["CRM Custom Variables"]},"post":{"description":"Creates a new custom variable for the specified workspace.","operationId":"PublicV1CrmCustomVariablesController_createCustomVariable","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateCustomVariableCommonInput"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomVariableDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new custom variable","tags":["CRM Custom Variables"]}},"/v1/crm/custom-variables/{id}":{"delete":{"description":"Deletes a custom variable by its ID.","operationId":"PublicV1CrmCustomVariablesController_deleteCustomVariable","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete custom variable","tags":["CRM Custom Variables"]}},"/v1/crm/tags":{"get":{"description":"Retrieves all tags for the workspace.","operationId":"PublicV1CrmTagsController_findTags","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"Workspace ID to find tags for","schema":{"example":"workspace_123","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TagDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Retrieve tags","tags":["CRM Tags"]},"post":{"operationId":"PublicV1CrmTagsController_createTag","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTagCommonInput"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TagDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new tag","tags":["CRM Tags"]}},"/v1/crm/tags/{id}":{"delete":{"description":"Permanently deletes a user-created tag. System tags cannot be deleted.","operationId":"PublicV1CrmTagsController_deleteTag","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete tag","tags":["CRM Tags"]}},"/v1/crm/tags/{id}/leads":{"put":{"description":"Assigns the specified tag to a selection of leads (by IDs or criteria). The tag must belong to your team. Lead selection is scoped to your team.","operationId":"PublicV1CrmTagsController_setTagLeads","parameters":[{"name":"id","required":true,"in":"path","description":"Tag ID","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadSelectionCommonInput"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"example":{"affectedCount":3}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Bulk assign a tag to leads","tags":["CRM Tags"]},"delete":{"description":"Removes the specified tag from a selection of leads (by IDs or criteria). The tag must belong to your team. Lead selection is scoped to your team.","operationId":"PublicV1CrmTagsController_unsetTagLeads","parameters":[{"name":"id","required":true,"in":"path","description":"Tag ID","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadSelectionCommonInput"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"example":{"affectedCount":3}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Bulk remove a tag from leads","tags":["CRM Tags"]}},"/v1/crm/lists":{"get":{"description":"Retrieves all lists for the workspace with lead counts.","operationId":"PublicV1CrmListsController_findLists","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"Workspace ID to find lists for","schema":{"example":"workspace_123","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ListDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Retrieve lists","tags":["CRM Lists"]},"post":{"operationId":"PublicV1CrmListsController_createList","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateListCommonInput"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new list","tags":["CRM Lists"]}},"/v1/crm/lists/{id}":{"get":{"operationId":"PublicV1CrmListsController_findListById","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Find list by ID","tags":["CRM Lists"]},"patch":{"description":"Updates an existing list (e.g. rename).","operationId":"PublicV1CrmListsController_updateList","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateListCommonInput"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update list","tags":["CRM Lists"]},"delete":{"description":"Permanently deletes a list. Leads that are only in this list will also be deleted.","operationId":"PublicV1CrmListsController_deleteList","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete list","tags":["CRM Lists"]}},"/v1/crm/lists/{id}/leads":{"put":{"description":"Adds a selection of leads (by IDs or criteria) to the specified list. The list must belong to your team. Lead selection is scoped to your team.","operationId":"PublicV1CrmListsController_setListLeads","parameters":[{"name":"id","required":true,"in":"path","description":"List ID","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadSelectionCommonInput"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"example":{"affectedCount":3}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Bulk add leads to a list","tags":["CRM Lists"]},"delete":{"description":"Removes a selection of leads (by IDs or criteria) from the specified list. Leads that have no remaining list membership are also deleted. The list must belong to your team.","operationId":"PublicV1CrmListsController_removeLeadsFromList","parameters":[{"name":"id","required":true,"in":"path","description":"List ID","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadSelectionCommonInput"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"example":{"removedCount":3,"deletedCount":1}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Bulk remove leads from a list","tags":["CRM Lists"]}},"/v1/reminders":{"get":{"description":"Fetches all thread reminders based on the provided filters for the workspace.","operationId":"PublicV1ThreadRemindersController_findRemindersForV1Api","parameters":[{"name":"workspaceId","required":false,"in":"query","description":"The ID of the workspace where the thread reminders belong.","schema":{"example":"b8a7a0be-dbe9-4e7b-b0f7-cf1c767b8a3c","type":"string"}},{"name":"threadId","required":false,"in":"query","description":"The ID of the thread to fetch reminders for.","schema":{"example":"d3f7a1bc-9c2e-4f1a-8b9c-1234567890ab","type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ThreadReminderDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all thread reminders","tags":["Reminders"]},"post":{"description":"Creates a new thread reminder for the specified workspace.","operationId":"PublicV1ThreadRemindersController_createThreadReminderForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateThreadReminderCommonInput"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadReminderDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new thread reminder","tags":["Reminders"]}},"/v1/reminders/{id}":{"delete":{"description":"Deletes the thread reminder by its ID.","operationId":"PublicV1ThreadRemindersController_deleteReminderForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a thread reminder","tags":["Reminders"]}},"/v1/threads":{"get":{"description":"Fetches all threads based on the provided filters for the specified workspace.","operationId":"PublicV1ThreadsController_findThreadsForV1Api","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"assignmentFilter","required":false,"in":"query","description":"Filter threads by assignment status. ALL_ASSIGNED = all assigned threads, UNASSIGNED = no assignee, USER = specific user (requires assignedUserId)","schema":{"example":"all_assigned","type":"string","enum":["all_assigned","unassigned","user"]}},{"name":"assignedUserId","required":false,"in":"query","description":"Filter by specific user ID. Required when assignmentFilter = USER. If omitted with USER filter, defaults to current user.","schema":{"example":"550e8400-e29b-41d4-a716-446655440000","type":"string"}},{"name":"workspaceId","required":true,"in":"query","description":"The ID of the workspace where the threads are located.","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"seen","required":false,"in":"query","description":"If true, only return threads that have been seen (read); if false, return only unseen (unread) threads.","schema":{"example":true,"type":"boolean"}},{"name":"labelsIds","required":false,"in":"query","description":"An array of label IDs to filter threads by specific labels. If not provided, threads will not be filtered by labels.","schema":{"example":["labelId1","labelId2"],"type":"array","items":{"type":"string"}}},{"name":"sequenceIds","required":false,"in":"query","description":"An array of campaign (sequence) IDs to filter threads by. Threads belonging to ANY of these campaigns are returned. If omitted, threads are not filtered by campaign.","schema":{"example":["8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"],"type":"array","items":{"type":"string"}}},{"name":"folder","required":true,"in":"query","description":"The folder in which to search for threads. Possible values are the predefined folders such as INBOX, SENT, DRAFT, etc.","schema":{"example":"INBOX","type":"string","enum":["INBOX","DONE","WARMUPS","DRAFT","SENT","TRASH","REMINDERS","SEQUENCES","HARD_BOUNCES","SOFT_BOUNCES"]}},{"name":"hasLabels","required":false,"in":"query","description":"Filter threads by label presence: set to `true` to fetch only threads with labels, or `false` to fetch only threads without labels.","schema":{"example":false,"type":"boolean"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ThreadInfoDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all threads","tags":["Threads"]}},"/v1/threads/search":{"get":{"description":"Fetches threads based on the provided filters with pagination support.","operationId":"PublicV1ThreadsController_searchThreadsForV1Api","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":false,"in":"query","description":"Workspace ID to filter threads by","schema":{"example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb","type":"string"}},{"name":"email","required":false,"in":"query","description":"Lead email address to look for (in from or to)","schema":{"example":"alice@example.com","type":"string"}},{"name":"hasLabels","required":false,"in":"query","description":"Filter threads by label presence: set to `true` to fetch only threads with labels, or `false` to fetch only threads without labels.","schema":{"example":false,"type":"boolean"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ThreadSearchResultDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Search threads","tags":["Threads"]}},"/v1/threads/{id}/messages":{"get":{"operationId":"PublicV1ThreadsController_findEmailMessagesByThreadIdForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/EmailMessageDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get email messages for a specific thread","tags":["Threads"]}},"/v1/threads/bulk":{"patch":{"description":"Bulk update up to 50 threads. Supports updating folder, labels, seen status, and assignment.","operationId":"PublicV1ThreadsController_updateThreadsForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateThreadsPublicV1Input"}}}},"responses":{"200":{"description":"IDs of the threads that were updated.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/"}},"example":["1f684e24-ef21-4544-a4a9-c994e2a6d2cf"]}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update multiple threads at once","tags":["Threads"]}},"/v1/threads/{id}":{"patch":{"operationId":"PublicV1ThreadsController_updateThreadForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateThreadPublicV1Input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadInfoDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update a specific thread","tags":["Threads"]},"delete":{"operationId":"PublicV1ThreadsController_deleteThreadForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Permanently deletes an email thread, removing it from all folders and making it irretrievable","tags":["Threads"]}},"/v1/threads/{id}/labels/{labelId}":{"delete":{"operationId":"PublicV1ThreadsController_removeLabelFromThreadForV1Api","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"labelId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadInfoDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Remove a label from a thread","tags":["Threads"]}},"/v1/email-messages/{id}/attachments":{"get":{"description":"Fetches all attachments associated with the specified email message.","operationId":"PublicV1EmailMessagesController_getEmailMessageAttachments","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Success"},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get email message attachments","tags":["Email Messages"]}},"/v1/email-messages/send":{"post":{"description":"Sends an email message along with optional attachments. Note: File attachments are only supported via direct API calls, not through MCP.","operationId":"PublicV1EmailMessagesController_sendEmailMessage","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendEmailMessagePayloadPublicV1Input"}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateEmailMessageResponseDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Send email message","tags":["Email Messages"]}},"/v1/email-messages/drafts":{"post":{"description":"Creates a new draft email message that can be sent later using the send draft endpoint. Note: File attachments are only supported via direct API calls, not through MCP.","operationId":"PublicV1EmailMessagesController_createDraftForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveDraftPublicV1Input"}}}},"responses":{"201":{"description":"Draft created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateEmailMessageResponseDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a draft email","tags":["Email Messages"]}},"/v1/email-messages/drafts/{id}/send":{"post":{"description":"Sends an existing draft email by its ID.","operationId":"PublicV1EmailMessagesController_sendDraftForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"The unique identifier (UUID) of the draft email to send","schema":{"type":"string"}}],"responses":{"200":{"description":"Draft sent successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateEmailMessageResponseDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Send a draft email","tags":["Email Messages"]}},"/v1/email-messages/drafts/{id}":{"delete":{"description":"Permanently deletes a draft email by its ID. The draft is also removed from the mail provider.","operationId":"PublicV1EmailMessagesController_discardDraftForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"The unique identifier (UUID) of the draft email to discard","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Discard a draft email","tags":["Email Messages"]}},"/v1/subsequences":{"get":{"deprecated":true,"description":"Fetches all subsequences for the specified workspace. Supports filtering by status and draft state. Deprecated — use /v1/campaigns instead.","operationId":"PublicV1SubsequencesController_findSubsequences","parameters":[{"name":"workspaceId","required":true,"in":"query","description":"UUID of the workspace to filter sequences by","schema":{"format":"uuid","example":"d7b7f89d-1aef-4414-9e68-d671b57a3b42","type":"string"}},{"name":"status","required":false,"in":"query","description":"Sequence status","schema":{"example":"activating","type":"string","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"]}},{"name":"isDraft","required":false,"in":"query","description":"DEPRECATED — filter by `status: \"draft\"` instead. Mirror only.","deprecated":true,"schema":{"type":"boolean"}}],"responses":{"200":{"description":"List of subsequences","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all subsequences","tags":["Subsequences"]},"post":{"deprecated":true,"description":"Creates a new email subsequence with optional initial steps.\n\n**Best Practices:**\n- Set `sendingStartTime` and `sendingEndTime` to respect recipient working hours\n- Use `sendingDays` to avoid weekends for B2B subsequences\n- Set appropriate `timezone` for your target audience\n- Include initial `steps` with proper `order` values (1, 2, 3, ...)\n- Use `status: \"draft\"` to configure before activating (`isDraft: true` still accepted but deprecated)\n\nDeprecated — use /v1/campaigns instead.","operationId":"PublicV1SubsequencesController_createSubsequence","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSequencePublicV1Input"}}}},"responses":{"201":{"description":"Subsequence created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"409":{"description":"Subsequence name already exists"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create a new subsequence","tags":["Subsequences"]}},"/v1/subsequences/{id}":{"get":{"deprecated":true,"description":"Fetches a specific subsequence by its ID, including its configuration and statistics. Deprecated — use /v1/campaigns instead.","operationId":"PublicV1SubsequencesController_findSubsequenceById","parameters":[{"name":"id","required":true,"in":"path","description":"Subsequence UUID","schema":{"type":"string"}}],"responses":{"200":{"description":"Subsequence details","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get subsequence by ID","tags":["Subsequences"]},"patch":{"deprecated":true,"description":"Updates an existing subsequence.\n\n**Important Notes:**\n- Scheduling fields (`sendingStartTime`, `sendingEndTime`, `sendingDays`, `timezone`) can only be updated when subsequence is PAUSED or draft\n- Set `status: \"PAUSING\"` to pause and cancel pending emails\n- Set `status: \"ACTIVATING\"` to resume and reschedule emails\n\nDeprecated — use /v1/campaigns instead.","operationId":"PublicV1SubsequencesController_updateSubsequence","parameters":[{"name":"id","required":true,"in":"path","description":"Subsequence UUID","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateSequencePublicV1Input"}}}},"responses":{"200":{"description":"Subsequence updated successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SequenceDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update a subsequence","tags":["Subsequences"]},"delete":{"deprecated":true,"description":"Deletes a subsequence and cancels all pending scheduled emails. Contacts will be unsubscribed. Deprecated — use /v1/campaigns instead.","operationId":"PublicV1SubsequencesController_deleteSubsequence","parameters":[{"name":"id","required":true,"in":"path","description":"Subsequence UUID","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a subsequence","tags":["Subsequences"]}},"/v1/subsequences/subscribe":{"post":{"deprecated":true,"description":"Subscribes a thread to a subsequence, scheduling all subsequence step emails to be sent automatically. Deprecated — use /v1/campaigns instead.","operationId":"PublicV1SubsequencesController_subscribeToSubsequence","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscribeToSequencePublicV1Input"}}}},"responses":{"201":{"description":"Thread successfully subscribed to subsequence","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscribeToSequenceResultDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Subscribe a thread to a subsequence","tags":["Subsequences"]}},"/v1/subsequences/unsubscribe":{"post":{"deprecated":true,"description":"Unsubscribes a thread from a subsequence, canceling all pending scheduled emails. Deprecated — use /v1/campaigns instead.","operationId":"PublicV1SubsequencesController_unsubscribeFromSubsequence","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnsubscribeFromSequencePublicV1Input"}}}},"responses":{"200":{"description":"Thread successfully unsubscribed from subsequence","content":{"application/json":{"schema":{"type":"boolean"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Unsubscribe a thread from a subsequence","tags":["Subsequences"]}},"/v1/subsequence-steps":{"get":{"deprecated":true,"description":"Fetches all steps for the specified subsequence, ordered by their position. Deprecated — use /v1/campaign-steps instead.","operationId":"PublicV1SubsequenceStepsController_findSubsequenceSteps","parameters":[{"name":"sequenceId","required":true,"in":"query","description":"UUID of the sequence to filter sequence steps by","schema":{"format":"uuid","example":"d7b7f89d-1aef-4414-9e68-d671b57a3b42","type":"string"}}],"responses":{"200":{"description":"List of subsequence steps","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceStepDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all steps for a subsequence","tags":["Subsequence Steps"]},"post":{"deprecated":true,"description":"Creates new steps for a subsequence.\n\n**Important:** Subsequence must be PAUSED or in draft mode to add steps.\n\n**Best Practices for Steps:**\n- Each step needs a unique `order` value (1, 2, 3, ...)\n- First step typically has `delayValue: 0` (sends immediately)\n- Use minimum 1 day delay between subsequent steps\n- Template variables: `{{FIRST_NAME}}`, `{{LAST_NAME}}`, `{{COMPANY_NAME}}`, etc.\n\nDeprecated — use /v1/campaign-steps instead.","operationId":"PublicV1SubsequenceStepsController_createSubsequenceSteps","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSequenceStepsPublicV1Input"}}}},"responses":{"201":{"description":"Steps created successfully","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceStepDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Create subsequence steps","tags":["Subsequence Steps"]},"put":{"deprecated":true,"description":"Updates all steps for a subsequence using full replacement strategy.\n\n**Important:** Subsequence must be PAUSED or in draft mode to update steps.\n\n**How it works:**\n- Steps with `id` matching existing steps are updated\n- Steps without `id` are created as new\n- Existing steps NOT in the request are deleted (scheduled emails cancelled)\n\n**Example:** To reorder steps 1,2,3 to 2,1,3:\n```json\n{\n  \"subsequenceId\": \"...\",\n  \"steps\": [\n    { \"id\": \"step-2-id\", \"order\": 1, ... },\n    { \"id\": \"step-1-id\", \"order\": 2, ... },\n    { \"id\": \"step-3-id\", \"order\": 3, ... }\n  ]\n}\n```\n\nDeprecated — use /v1/campaign-steps instead.","operationId":"PublicV1SubsequenceStepsController_updateSubsequenceSteps","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateSequenceStepsPublicV1Input"}}}},"responses":{"200":{"description":"Steps updated successfully","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SequenceStepDto"}}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Update subsequence steps (full replacement)","tags":["Subsequence Steps"]}},"/v1/subsequence-steps/{stepId}":{"delete":{"deprecated":true,"description":"Deletes a single step from a subsequence.\n\n**Important:** Subsequence must be PAUSED or in draft mode to delete steps.\n\nDeleting a step will:\n- Cancel any scheduled (unsent) emails for this step\n- Automatically reorder remaining steps\n\nDeprecated — use /v1/campaign-steps instead.","operationId":"PublicV1SubsequenceStepsController_deleteSubsequenceStep","parameters":[{"name":"stepId","required":true,"in":"path","description":"Step UUID to delete","schema":{"type":"string"}},{"name":"subsequenceId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Delete a subsequence step","tags":["Subsequence Steps"]}},"/v1/blocklist":{"get":{"description":"Fetches all blocklist entries for the specified workspace.","operationId":"PublicV1BlocklistController_findBlocklistEntriesForV1Api","parameters":[{"name":"page","required":true,"in":"query","description":"The current page number to retrieve.","schema":{"minimum":1,"default":1,"example":1,"type":"integer"}},{"name":"take","required":true,"in":"query","description":"The number of records to retrieve per page, with a maximum of 150.","schema":{"minimum":1,"maximum":150,"default":25,"example":25,"type":"integer"}},{"name":"workspaceId","required":true,"in":"query","description":"Workspace ID","schema":{"example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","type":"string"}},{"name":"search","required":false,"in":"query","description":"Search by email or domain","schema":{"example":"example.com","type":"string"}},{"name":"type","required":false,"in":"query","description":"Filter by type","schema":{"type":"string","enum":["EMAIL","DOMAIN"]}},{"name":"source","required":false,"in":"query","description":"Filter by source","schema":{"type":"string","enum":["HOTHAWK","EMAIL_BISON","CLIENT_BOX"]}},{"name":"sort","required":false,"in":"query","examples":{"byCreatedAt":{"value":[{"field":"createdAt","order":"DESC"}]},"byValue":{"value":[{"field":"value","order":"ASC"}]},"bySource":{"value":[{"field":"source","order":"ASC"}]},"byType":{"value":[{"field":"type","order":"ASC"}]},"byAddedByName":{"value":[{"field":"addedByName","order":"ASC"}]}},"schema":{"type":"array","items":{"$ref":"#/components/schemas/SortBlocklistEntriesInput"}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PageInput"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/BlocklistEntryDto"}}}}]}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get all blocklist entries","tags":["Blocklist"]},"post":{"description":"Add an email or domain to the blocklist.","operationId":"PublicV1BlocklistController_createBlocklistEntryForV1Api","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBlocklistEntryCommonInput"}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlocklistEntryDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Add to blocklist","tags":["Blocklist"]}},"/v1/blocklist/counts":{"get":{"description":"Returns count of entries per source for filter pills.","operationId":"PublicV1BlocklistController_getBlocklistSourceCountsForV1Api","parameters":[{"name":"workspaceId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlocklistSourceCountsDto"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Get blocklist source counts","tags":["Blocklist"]}},"/v1/blocklist/{id}":{"delete":{"description":"Remove a blocklist entry by ID.","operationId":"PublicV1BlocklistController_deleteBlocklistEntryForV1Api","parameters":[{"name":"id","required":true,"in":"path","description":"Blocklist entry ID","schema":{"type":"string"}},{"name":"workspaceId","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted the entity. Returns the ID of the deleted entity.","content":{"application/json":{"schema":{"type":"string","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"}}}},"400":{"description":"Bad Request - Invalid inputs or request data"},"403":{"description":"Forbidden - Wrong API Key or access denied"},"404":{"description":"Not Found - Resource not found"},"429":{"description":"Too Many Requests - Rate limit exceeded or monthly API quota reached"}},"security":[{"bearer":[]}],"summary":"Remove from blocklist","tags":["Blocklist"]}}},"info":{"title":"Public API","description":"<a class=\"openapi-link\" href=\"https://api.hothawk.ai/docs/public-json\" target=\"_blank\">OpenAPI JSON Spec</a>\n\nPublic routes for external use.\n\n### Authentication with API Keys\nTo access certain endpoints, you need to use an API key. You can generate your API key on the Settings page:\n[Generate API Key](https://app.hothawk.ai/settings/api-keys)\n\nAPI keys are issued at the account level, not at the workspace level. A single API key grants access to all workspaces associated with that account.\n\n### How to Use the API Key\nOnce you have your API key, you need to pass it in the **Authorization** header as follows:\n`Authorization: Bearer <your-api-key>`\n\n### Testing the API with Swagger UI\n1. Press **Authorize** in the Swagger UI.\n2. Enter your API key and click **Authorize**.\n3. After authorizing, press **Try it out** for any endpoint you wish to test.\n4. Fill in all required fields and press **Execute**.\n5. You will receive all the necessary data, including:\n   - Response data\n   - cURL command\n   - Request URL\n   - Possible response codes\n   - Schemas for specific queries (at the bottom of the page).\n\n### API Response Schemas\nAt the bottom of the page, you will find **schemas** that define the structure of the responses for different queries.\nYou can use these schemas to understand the data format and request/response patterns for the API endpoints.\n\n### Rate Limits\n**Rate Limit: 120 requests per minute**\nIf you exceed the limit, you will receive a **429 Too Many Requests** response with an error message explaining that the rate limit has been exceeded.\n\n### Example API Requests:\n- **GET** /v1/workspaces -> Fetches all team workspaces.\n- **GET** /v1/labels -> Fetches labels.\n- **PATCH** /v1/threads/{id} -> Updates a specific thread and assigns labels.\n- **POST** /v1/email-messages/send -> Sends a reply or forwards an email.\n","version":"1.0","contact":{}},"tags":[],"servers":[],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http"}},"schemas":{"TeamMemberInviteDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the user invitation, in UUID format.","example":"d572ec85-82be-4b7f-91ff-1d3870fd87c2"},"firstName":{"type":"string","description":"The first name of the invited client (optional).","nullable":true,"example":"John"},"lastName":{"type":"string","description":"The last name of the invited client (optional).","nullable":true,"example":"Doe"},"role":{"type":"array","description":"Role assigned to the user invite","example":"CLIENT","items":{"type":"string","enum":["OWNER","SUPER_ADMIN","SUPPORT","TEAM_MEMBER","CLIENT"]}},"email":{"type":"string","description":"Email address of the invited user.","example":"john.doe@example.com"},"isAccepted":{"type":"boolean","description":"Indicates if the invitation was accepted by the user.","example":true},"hasAccessToAllWorkspaces":{"type":"boolean","description":"If true, the user will have access to all workspaces","example":false},"accessibleWorkspaceIds":{"description":"List of workspace IDs the user will have access to when access is not global.","example":["d1f8b00d-5aef-4d2f-b5fd-49d00e93cfa1","4b22e6f9-81e7-48f4-a41c-eef97990dd4c"],"type":"array","items":{"type":"string"}},"invitedById":{"type":"string","description":"Unique identifier of the user who sent the invitation, in UUID format.","example":"c7b4c9f8-83b4-40c5-b593-cf0328bb6ff6"},"invitedByName":{"type":"string","description":"Full name of the user who sent the invitation.","example":"Alice Johnson"},"teamId":{"type":"string","description":"Unique identifier of the team the invited user will join, in UUID format.","example":"f51b69c1-1e59-4b92-84b5-8e3e7b16e6e9"},"userId":{"type":"string","description":"Unique identifier of the user that was invited, in UUID format.","example":"f51b69c1-1e59-4b92-84b5-8e3e7b16e6e9"}},"required":["id","firstName","lastName","role","email","isAccepted","hasAccessToAllWorkspaces","accessibleWorkspaceIds","invitedById","invitedByName","teamId","userId"]},"CreateUserInvitePublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","description":"The unique identifier of the workspace.","example":"a25c5bbf-6f12-4c12-9a34-ffcd7a234f11"},"firstName":{"type":"string","description":"The first name of the invited user (optional).","nullable":true,"example":"John"},"lastName":{"type":"string","description":"The last name of the invited user (optional).","nullable":true,"example":"Doe"},"email":{"type":"string","description":"Email address of the user to be invited.","example":"user@example.com"},"role":{"type":"string","description":"Role to assign to the invited user (either TEAM_MEMBER or CLIENT).","example":"CLIENT","enum":["TEAM_MEMBER","CLIENT"]}},"required":["workspaceId","firstName","lastName","email","role"]},"GenerateClientSignupLinkPublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","description":"The unique identifier of the workspace.","example":"a25c5bbf-6f12-4c12-9a34-ffcd7a234f11"},"email":{"type":"string","description":"Email address of the client to be invited.","example":"client@example.com"},"firstName":{"type":"string","description":"The first name of the invited client.","example":"John"},"lastName":{"type":"string","description":"The last name of the invited client.","example":"Doe"}},"required":["workspaceId","email"]},"ClientSignupLinkDto":{"type":"object","properties":{"inviteId":{"type":"string","description":"The unique identifier of the invite.","example":"6f645516-b11f-4b12-90f0-4e4504074ee9"},"signupLink":{"type":"string","description":"The full signup link for the client.","example":"https://app-eyries.werdevs.agency/invite/6f645516-b11f-4b12-90f0-4e4504074ee9"}},"required":["inviteId","signupLink"]},"TeamMemberDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the user, in UUID format.","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"firstName":{"type":"string","description":"The first name of the user.","example":"John"},"lastName":{"type":"string","description":"The last name of the user.","example":"Doe"},"email":{"type":"string","description":"The email address associated with the user.","example":"john.doe@example.com"},"roles":{"type":"array","description":"Roles assigned to the user","default":["TEAM_MEMBER"],"example":["OWNER","TEAM_MEMBER"],"items":{"type":"string","enum":["OWNER","SUPER_ADMIN","SUPPORT","TEAM_MEMBER","CLIENT"]}},"hasAccessToAllWorkspaces":{"type":"boolean","description":"Whether the user has access to all workspaces in the team","example":false},"accessibleWorkspaceIds":{"description":"List of workspace IDs the user has access to","example":["e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"],"type":"array","items":{"type":"string"}}},"required":["id","firstName","lastName","email","roles","hasAccessToAllWorkspaces","accessibleWorkspaceIds"]},"EmailBisonTagDto":{"type":"object","properties":{"id":{"type":"number","example":12},"name":{"type":"string","example":"Google"},"default":{"type":"boolean","example":true}},"required":["id","name","default"]},"PageMetaInput":{"type":"object","properties":{"itemsCount":{"type":"number","description":"Total number of items across all pages.","example":100},"pagesCount":{"type":"number","description":"Total number of pages calculated based on the number of items and items per page.","example":10},"currentPage":{"type":"number","description":"The current page number being viewed. Optional field that defaults to 1 if not provided.","example":2}},"required":["itemsCount","pagesCount"]},"PageInput":{"type":"object","properties":{"data":{"description":"List of items in the current page.","type":"array","items":{"type":"object"}},"meta":{"description":"Metadata related to pagination, such as total items and pages.","allOf":[{"$ref":"#/components/schemas/PageMetaInput"}]}},"required":["data","meta"]},"LinkedinAccountDto":{"type":"object","properties":{"id":{"type":"number","example":156653,"description":"LinkedIn internal ID"},"firstName":{"type":"string","example":"Elliot","description":"First name of the account"},"lastName":{"type":"string","example":"Thomas","description":"Last name of the account"},"email":{"type":"string","example":"elliot@domain.com","description":"Email of the account"},"profileUrl":{"type":"string","example":"https://www.linkedin.com/in/elliot-hothawk","description":"LinkedIn profile URL"},"isAuthValid":{"type":"boolean","example":true,"description":"Whether the account authentication is valid"},"isActiveInCampaign":{"type":"boolean","example":true,"description":"Whether the account is active in a campaign"}},"required":["id","firstName","lastName","profileUrl","isAuthValid","isActiveInCampaign"]},"LinkedInTagColorDto":{"type":"object","properties":{"id":{"type":"string","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","description":"Tag color ID"},"name":{"type":"string","example":"Blue","description":"Color name"},"color":{"type":"string","example":"#3B82F6","description":"Text color hex code"},"bgColor":{"type":"string","example":"#DBEAFE","description":"Background color hex code"}},"required":["id","name","color","bgColor"]},"LinkedInTagDto":{"type":"object","properties":{"id":{"type":"string","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","description":"Tag ID"},"name":{"type":"string","example":"Hot Lead","description":"Tag name"},"isFavourite":{"type":"boolean","example":false,"description":"Whether the tag is marked as favourite"},"color":{"description":"Tag color details","allOf":[{"$ref":"#/components/schemas/LinkedInTagColorDto"}]},"createdAt":{"format":"date-time","type":"string","description":"Created timestamp"},"updatedAt":{"format":"date-time","type":"string","description":"Updated timestamp"}},"required":["id","name","isFavourite","createdAt","updatedAt"]},"LinkedInStoredAccountDto":{"type":"object","properties":{"id":{"type":"string","example":"550e8400-e29b-41d4-a716-446655440000","description":"Internal UUID"},"externalId":{"type":"number","example":156653,"description":"External HeyReach account ID"},"workspaceId":{"type":"string","example":"550e8400-e29b-41d4-a716-446655440000","description":"Workspace ID"},"firstName":{"type":"string","example":"Elliot","description":"First name of the account owner"},"lastName":{"type":"string","example":"Thomas","description":"Last name of the account owner"},"email":{"type":"string","example":"elliot@domain.com","description":"Email address"},"profileUrl":{"type":"string","example":"https://www.linkedin.com/in/elliot-hothawk","description":"LinkedIn profile URL"},"isAuthValid":{"type":"boolean","example":true,"description":"Whether the account authentication is valid"},"isActiveInCampaign":{"type":"boolean","example":true,"description":"Whether the account is active in a campaign"},"createdAt":{"format":"date-time","type":"string","example":"2024-01-15T10:30:00Z","description":"Account creation timestamp"}},"required":["id","externalId","workspaceId","isAuthValid","isActiveInCampaign","createdAt"]},"LinkedInCampaignDto":{"type":"object","properties":{"campaignId":{"type":"number","example":12345,"description":"Campaign ID from HeyReach"},"campaignName":{"type":"string","example":"Q1 Outreach","description":"Campaign name"},"campaignStatus":{"type":"string","example":"ACTIVE","description":"Campaign status"},"leadStatus":{"type":"string","example":"REPLIED","description":"Lead status in campaign"}},"required":["campaignId","campaignName","campaignStatus","leadStatus"]},"LinkedInConversationDto":{"type":"object","properties":{"id":{"type":"string","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","description":"Conversation ID"},"externalId":{"type":"string","example":"conv_12345","description":"External conversation ID from LinkedIn integration"},"workspaceId":{"type":"string","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","description":"Workspace ID"},"linkedInAccountId":{"type":"number","example":156653,"description":"LinkedIn account ID from HeyReach integration"},"leadLinkedInId":{"type":"string","example":"urn:li:member:123456789","description":"LinkedIn ID of the lead/contact"},"leadFirstName":{"type":"string","example":"John","description":"Lead first name"},"leadLastName":{"type":"string","example":"Doe","description":"Lead last name"},"leadProfileUrl":{"type":"string","example":"https://www.linkedin.com/in/johndoe","description":"Lead LinkedIn profile URL"},"leadImageUrl":{"type":"string","example":"https://media.licdn.com/xyz.jpg","description":"Lead profile image URL"},"leadHeadline":{"type":"string","example":"Software Engineer at TechCorp","description":"Lead headline"},"seen":{"type":"boolean","example":false,"description":"Whether the conversation has been viewed"},"isDone":{"type":"boolean","example":false,"description":"Whether the conversation is marked as done"},"deletedAt":{"format":"date-time","type":"string","description":"Timestamp when the conversation was soft-deleted"},"lastMessageDate":{"format":"date-time","type":"string","description":"Timestamp of the last message"},"lastMessageText":{"type":"string","example":"Thanks for reaching out!","description":"Preview of the last message"},"tags":{"description":"Tags associated with this conversation","type":"array","items":{"$ref":"#/components/schemas/LinkedInTagDto"}},"linkedInAccount":{"description":"LinkedIn account associated with this conversation","allOf":[{"$ref":"#/components/schemas/LinkedInStoredAccountDto"}]},"leadId":{"type":"string","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","description":"CRM Lead ID"},"campaigns":{"description":"Campaigns associated with this conversation","type":"array","items":{"$ref":"#/components/schemas/LinkedInCampaignDto"}},"createdAt":{"format":"date-time","type":"string","description":"Created timestamp"},"updatedAt":{"format":"date-time","type":"string","description":"Updated timestamp"},"hasActiveOpportunity":{"type":"boolean","example":false,"description":"Whether this conversation has an active opportunity"}},"required":["id","externalId","workspaceId","linkedInAccountId","leadLinkedInId","seen","isDone","createdAt","updatedAt","hasActiveOpportunity"]},"LinkedInMessageDto":{"type":"object","properties":{"id":{"type":"string","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","description":"Message ID"},"externalId":{"type":"string","example":"a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4","description":"External message ID"},"conversationId":{"type":"string","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74","description":"Conversation ID"},"senderLinkedInId":{"type":"string","example":"urn:li:member:123456789","description":"LinkedIn ID of the sender"},"content":{"type":"string","example":"Hello, I would like to connect with you.","description":"Message content"},"sentAt":{"format":"date-time","type":"string","description":"When the message was sent"},"folder":{"type":"string","enum":["INBOX","SENT"],"example":"INBOX","description":"Message folder"},"createdAt":{"format":"date-time","type":"string","description":"Created timestamp"},"updatedAt":{"format":"date-time","type":"string","description":"Updated timestamp"}},"required":["id","externalId","conversationId","folder","createdAt","updatedAt"]},"UpdateLinkedInConversationPublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","description":"The workspace ID","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"folder":{"type":"string","description":"Per-user folder state","enum":["INBOX","DONE","TRASH","DELETED"],"example":"DONE"},"tagIds":{"description":"Replace all conversation tags with these tag IDs","example":["e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"],"type":"array","items":{"type":"string"}},"seen":{"type":"boolean","description":"Mark the conversation as seen/unseen","example":true},"leadId":{"type":"string","description":"Link conversation to a CRM lead","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"}},"required":["workspaceId"]},"CreateLinkedInConversationReminderPublicV1Input":{"type":"object","properties":{"conversationId":{"type":"string","description":"The ID (UUID) of the conversation this reminder is linked to.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"workspaceId":{"type":"string","description":"The workspace ID (UUID) where the conversation belongs.","example":"b8a7a0be-dbe9-4e7b-b0f7-cf1c767b8a3c"},"dueAt":{"format":"date-time","type":"string","description":"The exact date and time when the reminder will be triggered.","example":"2025-03-15T10:00:00Z"},"period":{"type":"number","description":"The time duration before the reminder is triggered, measured in the unit defined by the periodUnit.","example":3},"periodUnit":{"type":"string","enum":["DAY","WEEK","MONTH"],"description":"Defines the time unit for the period before the reminder is triggered. Choose from DAY, WEEK, or MONTH.","example":"DAY"},"intent":{"type":"string","enum":["follow_up_after_send","follow_up_conversation"],"description":"Specifies the intent or purpose of the reminder.","example":"follow_up_after_send"}},"required":["conversationId","workspaceId","dueAt","intent"]},"LinkedInConversationReminderDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the reminder, in UUID format.","example":"9e8a574f-5589-4db4-b1b0-9e6cbd92457a"},"name":{"type":"string","description":"Optional name/title of the reminder.","example":"Follow up with client"},"dueAt":{"format":"date-time","type":"string","description":"The date when the reminder will be triggered.","example":"2025-03-20T10:00:00.000Z"},"conversationId":{"type":"string","description":"The conversation ID this reminder is linked to.","example":"c6f5a29c-3435-4c7e-bc4a-dfe45db99113"},"status":{"type":"string","enum":["inactive","active","completed"],"description":"Current status of the reminder (inactive, active, or completed).","example":"inactive"},"intent":{"type":"string","enum":["follow_up_after_send","follow_up_conversation"],"description":"The intent/purpose of the reminder.","example":"follow_up_after_send"},"period":{"type":"number","description":"Time duration before the reminder is triggered.","example":2},"periodUnit":{"type":"string","enum":["DAY","WEEK","MONTH"],"description":"The time unit (DAY, WEEK, MONTH) for the period before the reminder.","example":"DAY"},"createdAt":{"format":"date-time","type":"string","description":"Date when the reminder was created","example":"2026-01-10T14:22:31.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"Date when the reminder was last updated","example":"2026-01-12T09:11:03.000Z"}},"required":["id","dueAt","conversationId","status","intent","period","periodUnit","createdAt","updatedAt"]},"SendLinkedInMessageInput":{"type":"object","properties":{"conversationId":{"type":"string","description":"Conversation ID to send message to"},"message":{"type":"string","description":"Message text to send","example":"Hello, how are you?"}},"required":["conversationId","message"]},"MailboxDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the mailbox, in UUID format.","example":"a7c0ec05-1b6a-4f5e-a33d-123456789abc"},"currentConnectionStatus":{"type":"string","enum":["INITIALIZING","CONNECTED","DISCONNECTED","GATHERING","RECONNECTING","DELETING"],"description":"The current status of the mailbox’s connection, represented by the ConnectionType enum. Each value reflects the operational state of the mailbox:\n  \n  - \"INITIALIZING\": The mailbox has just been added to the system. It is undergoing initial setup and configuration to establish a connection. Emails cannot be sent or received during this state.\n  \n  - \"CONNECTED\": The mailbox is fully connected and operational. It can send and receive emails as expected, and there are no issues with the connection.\n  \n  - \"DISCONNECTED\": The mailbox is disconnected from the system, either due to an error or because the connection was manually terminated. In this state, the mailbox is unable to send or receive emails. The connection may need to be re-established.\n  \n  - \"GATHERING\": The mailbox is retrieving older emails, such as when it is initially configured or when a mailbox is being synchronized with historical data. During this process, the mailbox may not be able to receive new messages until the gathering is completed.","example":"CONNECTED"},"firstName":{"type":"string","description":"First name of the mailbox holder.","example":"John"},"lastName":{"type":"string","description":"Last name of the mailbox holder.","example":"Doe"},"fullName":{"type":"string","description":"Full name of the mailbox holder, typically a combination of first and last names.","example":"John Doe"},"email":{"type":"string","description":"Email address associated with the mailbox.","example":"john.doe@example.com"},"domain":{"type":"string","description":"The domain of the mailbox’s email address.","example":"example.com"},"type":{"type":"string","enum":["IMAP_SMTP","GOOGLE_GMAIL","MICROSOFT_OUTLOOK"],"description":"The type of email mailbox.","example":"IMAP_SMTP | GOOGLE_GMAIL | OUTLOOK"},"teamId":{"type":"string","description":"Unique identifier of the team associated with the mailbox, in UUID format.","example":"d8f9b27b-6c9d-4d53-8912-9bc9a19dce19"},"msAppIndex":{"type":"number","example":1},"workspaceId":{"type":"string","description":"Unique identifier of the workspace associated with the mailbox, in UUID format.","example":"c9e48ab4-42f7-463e-b15e-bc786f73f25d"},"connectionId":{"type":"string","description":"Unique identifier of the connection for this mailbox, in UUID format.","example":"e6a71f5a-bd23-42a4-bd4f-9123456789de"},"lastSentDate":{"format":"date-time","type":"string","description":"The date when the last email was sent by the system, formatted as a timestamp.","example":"2025-03-05T13:40:33.000Z"},"lastReceivedDate":{"format":"date-time","type":"string","description":"The date when the last email was received by the system, formatted as a timestamp.","example":"2025-03-04T09:20:45.000Z"},"accountGroupId":{"type":"string","description":"The ID of the account group this account belongs to, or null if unassigned"},"campaignDailyLimit":{"type":"number","description":"Maximum number of campaign emails this mailbox can send per day. Warmup emails are counted separately under `warmupDailyLimit`. Null = unlimited. Enforced at send time when sending sequence emails.","example":50,"nullable":true},"warmupDailyLimit":{"type":"number","description":"Maximum number of warmup emails this mailbox can send per day. Independent budget from `campaignDailyLimit`. Null = unlimited. Currently schema-only — not enforced at send time yet.","example":10,"nullable":true}},"required":["id","currentConnectionStatus","firstName","lastName","fullName","email","domain","type","teamId","msAppIndex","workspaceId","connectionId","lastSentDate","lastReceivedDate","accountGroupId"]},"CreateMailboxPublicV1Input":{"type":"object","properties":{"firstName":{"type":"string","description":"The first name of the mailbox owner (optional).","nullable":true,"example":"John"},"lastName":{"type":"string","description":"The last name of the mailbox owner (optional).","nullable":true,"example":"Doe"},"email":{"type":"string","description":"The email address associated with the IMAP mailbox.","example":"user@example.com"},"workspaceId":{"type":"string","description":"The ID of the workspace where the mailbox is being created, in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"imapUsername":{"type":"string","description":"The username used for the IMAP connection.","example":"imapUser@example.com"},"imapPassword":{"type":"string","description":"The password used for the IMAP connection.","example":"yourIMAPPassword"},"imapHost":{"type":"string","description":"The IMAP server host address.","example":"imap.example.com"},"imapPort":{"type":"number","description":"The IMAP server port number.","example":993},"smtpUsername":{"type":"string","description":"The username used for the SMTP connection.","example":"smtpUser@example.com"},"smtpPassword":{"type":"string","description":"The password used for the SMTP connection.","example":"yourSMTPPassword"},"smtpHost":{"type":"string","description":"The SMTP server host address.","example":"smtp.example.com"},"smtpPort":{"type":"number","description":"The SMTP server port number.","example":587}},"required":["firstName","lastName","email","workspaceId","imapUsername","imapPassword","imapHost","imapPort","smtpUsername","smtpPassword","smtpHost","smtpPort"]},"ImapBulkUploadCommonInput":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace ID"},"csv":{"type":"string","format":"binary","description":"CSV file with mailbox credentials. Required columns: email, imapHost, imapPort, imapPassword, imapUsername, smtpHost, smtpPort, smtpPassword, smtpUsername. Optional columns: fullName (or firstName and lastName separately)."}},"required":["workspaceId","csv"]},"MailboxImportResultDto":{"type":"object","properties":{"email":{"type":"string","example":"user@example.com","description":"Mailbox email address"},"status":{"type":"string","enum":["success","error"],"example":"error","description":"Processing status for this mailbox"},"accountId":{"type":"string","example":"b3b2e8b6-4f1e-4f2a-9c1d-9f3b7e2a1234","description":"Created account ID (present only on success)"},"error":{"type":"string","example":"ECONNREFUSED 157.230.67.179:587","description":"Error message (present only on error)"}},"required":["email","status"]},"ReconnectMailboxPublicV1Input":{"type":"object","properties":{"id":{"type":"string","description":"The unique identifier of the mailbox that should be reconnected in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"imapUsername":{"type":"string","description":"The username used for the IMAP connection.","example":"user@example.com"},"imapPassword":{"type":"string","description":"The password used for the IMAP connection.","example":"yourIMAPPassword"},"imapHost":{"type":"string","description":"The IMAP server host address.","example":"imap.example.com"},"imapPort":{"type":"number","description":"The IMAP server port number.","example":993},"smtpUsername":{"type":"string","description":"The username used for the SMTP connection.","example":"user@example.com"},"smtpPassword":{"type":"string","description":"The password used for the SMTP connection.","example":"yourSMTPPassword"},"smtpHost":{"type":"string","description":"The SMTP server host address.","example":"smtp.example.com"},"smtpPort":{"type":"number","description":"The SMTP server port number.","example":587}},"required":["id","imapUsername","imapPassword","imapHost","imapPort","smtpUsername","smtpPassword","smtpHost","smtpPort"]},"OpportunityClientType":{"type":"object","properties":{"name":{"type":"string","description":"The name of the client associated with the opportunity.","example":"John Doe"},"email":{"type":"string","description":"The email address of the client associated with the opportunity.","example":"john.doe@example.com"}},"required":["name","email"]},"CurrencyDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the currency, in UUID format.","example":"7a3a9932-34f3-48f0-ae67-f7bd1e839e93"},"name":{"type":"string","description":"Name of the currency.","example":"US Dollar"},"symbol":{"type":"string","description":"Symbol of the currency.","example":"$"},"code":{"type":"string","description":"ISO code of the currency.","example":"USD"}},"required":["id","name","symbol","code"]},"OpportunityStageColorDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the opportunity stage color, in UUID format.","example":"9c2f5db3-bce7-4629-98ba-731b2706d56f"},"name":{"type":"string","description":"The name of the color (e.g., \"Red\", \"Green\", \"Blue\").","example":"Green"},"color":{"type":"string","description":"Hexadecimal color code representing the stage color (e.g., \"#FF0000\" for red).","example":"#28a745"},"textColor":{"type":"string","description":"Hexadecimal color code for the text color used in the stage color (e.g., \"#FFFFFF\" for white).","example":"#FFFFFF"},"bgColor":{"type":"string","description":"Hexadecimal color code for the background color associated with the stage (e.g., \"#00FF00\" for green).","example":"#28a745"}},"required":["id","name","color","textColor","bgColor"]},"OpportunityStageDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the opportunity stage, in UUID format.","example":"9c2f5db3-bce7-4629-98ba-731b2706d56f"},"name":{"type":"string","description":"The name of the opportunity stage (e.g., \"Lead\", \"Negotiation\", \"Closed\").","example":"Negotiation"},"order":{"type":"number","description":"The order or position of the stage in the workflow, used for sorting.","example":2},"isDefault":{"type":"boolean","description":"Indicates whether this stage is the default stage (e.g., the starting stage in the workflow).","example":true},"isPermanent":{"type":"boolean","description":"Indicates whether the stage is permanent and cannot be deleted or modified.","example":false},"isVisible":{"type":"boolean","description":"Indicates whether this stage is visible to users (if false, it may be hidden).","example":true},"color":{"description":"The color associated with the opportunity stage for visual representation.","allOf":[{"$ref":"#/components/schemas/OpportunityStageColorDto"}]},"createdAt":{"format":"date-time","type":"string","description":"The date and time when the opportunity stage was created.","example":"2025-03-10T15:30:00Z"},"updatedAt":{"format":"date-time","type":"string","description":"The date and time when the opportunity stage was last updated.","example":"2025-03-10T15:30:00Z"}},"required":["id","name","order","isDefault","isPermanent","isVisible","color","createdAt","updatedAt"]},"OpportunityDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the opportunity, in UUID format.","example":"e6c90c4e-576b-44c4-a8f4-f92fd1c14b02"},"clients":{"description":"List of clients associated with the opportunity, with each client containing their name and email.","example":[{"name":"John Doe","email":"john.doe@example.com"},{"name":"Jane Smith","email":"jane.smith@example.com"}],"type":"array","items":{"$ref":"#/components/schemas/OpportunityClientType"}},"companyName":{"type":"string","description":"The company name associated with the opportunity.","example":"Acme Corp"},"currencyId":{"type":"string","description":"Unique identifier for the currency used in this opportunity, in UUID format.","example":"f1a4c34f-5b9b-4d1f-9c77-bf2be562bbab"},"threadId":{"type":"string","description":"Unique identifier for the email thread associated with this opportunity, in UUID format.","example":"8b2a8c40-7f4b-4f5a-9419-73a08b7d6f2e"},"linkedinConversationId":{"type":"string","description":"Unique identifier for the LinkedIn conversation associated with this opportunity, in UUID format.","example":"a1b2c3d4-e5f6-7890-abcd-ef1234567890"},"currency":{"description":"Details about the currency used for the opportunity.","allOf":[{"$ref":"#/components/schemas/CurrencyDto"}]},"stageId":{"type":"string","description":"Unique identifier for the stage the opportunity is in, in UUID format.","example":"7c82c0a0-6d42-4a1c-8a52-64d99aef1a34"},"value":{"type":"number","description":"The value of the opportunity, if applicable.","example":50000},"frequency":{"type":"string","description":"The frequency with which this opportunity is expected to occur.","enum":["ONE_TIME","MONTHLY","ANNUAL"],"example":"MONTHLY"},"order":{"type":"number","description":"The order in which the opportunity appears relative to others.","example":1},"stage":{"description":"Details about the current stage of the opportunity.","allOf":[{"$ref":"#/components/schemas/OpportunityStageDto"}]},"createdAt":{"format":"date-time","type":"string","description":"Timestamp indicating when the opportunity was created.","example":"2025-04-10T12:00:00Z"},"updatedAt":{"format":"date-time","type":"string","description":"Timestamp indicating when the opportunity was last updated.","example":"2025-05-10T12:30:00Z"},"wonDate":{"format":"date-time","type":"string","description":"The timestamp when the opportunity was moved to a stage marked as Won. Used for won analytics tracking.","example":"2025-06-10T12:30:00Z"},"lostDate":{"format":"date-time","type":"string","description":"The timestamp when the opportunity was moved to a stage marked as Lost. Used for lost analytics tracking.","example":"2025-07-10T12:30:00Z"}},"required":["id","clients","companyName","currencyId","currency","stageId","value","frequency","order","stage","createdAt","updatedAt","wonDate","lostDate"]},"PaginatedOpportunitiesDto":{"type":"object","properties":{"data":{"description":"List of opportunities.","type":"array","items":{"$ref":"#/components/schemas/OpportunityDto"}},"hasMore":{"type":"boolean","description":"Indicates whether more opportunities are available for loading.","example":true}},"required":["data","hasMore"]},"OpportunityStageSummaryDto":{"type":"object","properties":{"stageId":{"type":"string","description":"The stage ID.","example":"7c82c0a0-6d42-4a1c-8a52-64d99aef1a34"},"totalValue":{"type":"number","description":"Total value of all opportunities in this stage.","example":50000},"count":{"type":"number","description":"Number of opportunities in this stage.","example":42}},"required":["stageId","totalValue","count"]},"OpportunityDetailsDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the opportunity, represented as a UUID.","example":"5f8d0a44-29a4-43d2-a31e-4e8c1c899ff6"},"clients":{"description":"List of clients associated with the opportunity.","example":[{"name":"Client A","email":"client.a@example.com"},{"name":"Client B","email":"client.b@example.com"}],"type":"array","items":{"$ref":"#/components/schemas/OpportunityClientType"}},"companyName":{"type":"string","description":"Name of the company associated with the opportunity.","example":"Acme Corporation"},"createdAt":{"format":"date-time","type":"string","description":"The date and time when the opportunity was created. It is represented in ISO 8601 format.","example":"2025-03-11T10:30:00.000Z"},"lastReceivedDate":{"format":"date-time","type":"string","description":"The date and time of the last email or communication received. If no communications were received, this field will be null.","nullable":true,"example":"2025-03-10T14:45:00.000Z"},"lastSentDate":{"format":"date-time","type":"string","description":"The date and time of the last email or communication sent. If no communications were sent, this field will be null.","nullable":true,"example":"2025-03-09T09:20:00.000Z"}},"required":["id","clients","companyName","createdAt","lastReceivedDate","lastSentDate"]},"CreateOpportunityPublicV1Input":{"type":"object","properties":{"clients":{"description":"List of clients associated with the opportunity.","example":[{"name":"Client A","email":"client.a@example.com"},{"name":"Client B","email":"client.b@example.com"}],"type":"array","items":{"$ref":"#/components/schemas/OpportunityClientType"}},"companyName":{"type":"string","description":"The name of the company associated with the opportunity.","example":"Acme Corp"},"stageId":{"type":"string","description":"The unique identifier of the stage this opportunity is currently in.","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"value":{"type":"number","description":"The value of the opportunity, typically representing the potential revenue.","example":15000},"frequency":{"type":"string","description":"The frequency with which the opportunity is expected to repeat, if applicable.","enum":["ONE_TIME","MONTHLY","ANNUAL"],"example":"MONTHLY"},"threadId":{"type":"string","description":"The ID of the email thread this opportunity is linked to. REQUIRED: Provide exactly one of threadId OR linkedinConversationId (not both).","example":"f9b14988-d4b6-44c8-bc0d-4a5475ac98a0"},"linkedinConversationId":{"type":"string","description":"The ID of the LinkedIn conversation this opportunity is linked to. REQUIRED: Provide exactly one of threadId OR linkedinConversationId (not both).","example":"a1b2c3d4-e5f6-7890-abcd-ef1234567890"},"workspaceId":{"type":"string","description":"The unique identifier of the workspace where the opportunity belongs.","example":"b4a8296b-d207-4535-b82e-dc5ed632850d"}},"required":["clients","companyName","stageId","workspaceId"]},"UpdateOpportunityCommonInput":{"type":"object","properties":{"companyName":{"type":"string","description":"The name of the company associated with the opportunity.","example":"Acme Corp"},"stageId":{"type":"string","description":"The unique identifier of the stage this opportunity is currently in.","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"value":{"type":"number","description":"The value of the opportunity, typically representing the potential revenue.","example":10000},"frequency":{"type":"string","description":"The frequency with which the opportunity is expected to repeat, if applicable.","enum":["ONE_TIME","MONTHLY","ANNUAL"],"example":"MONTHLY"}}},"CreateOpportunityStagePublicV1InternalInput":{"type":"object","properties":{"name":{"type":"string","description":"The name of the opportunity stage.","example":"Initial Contact"},"workspaceId":{"type":"string","description":"The unique identifier of the workspace where the opportunity stage will be created.","example":"b4a8296b-d207-4535-b82e-dc5ed632850d"},"colorName":{"type":"string","enum":["Light grey","Grey","Brown","Purple","Orange","Red","Pink","Yellow","Blue","Green"],"example":"Yellow|Green|Brown|Blue|Purple|Orange|Red|Pink"}},"required":["name","workspaceId","colorName"]},"UpdateOpportunityStageCommonInput":{"type":"object","properties":{"name":{"type":"string","description":"The name of the opportunity stage. If provided, this will update the name of the stage.","example":"Qualified Lead"},"isVisible":{"type":"boolean","description":"Indicates whether the stage is visible to users. Set to true to make the stage visible, false to hide it.","example":true}}},"WebhookDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the webhook"},"name":{"type":"string","description":"Display name of the webhook"},"destinationUrl":{"type":"string","description":"URL where webhook payloads will be sent"},"eventId":{"type":"string","description":"ID of the event that triggers this webhook"},"isEnabled":{"type":"boolean","description":"Whether this webhook is currently active"},"labelId":{"type":"string","description":"ID of the label to filter events (if applicable)"},"tagId":{"type":"string","description":"ID of the tag to filter events (if applicable)"},"teamId":{"type":"string","description":"ID of the team this webhook belongs to"},"workspaceId":{"type":"string","description":"ID of the workspace this webhook belongs to"},"memberId":{"type":"string"},"fromOpportunityStageId":{"type":"string","description":"ID of the opportunity stage the deal is moving FROM (for Deal Stage Changed event)"},"toOpportunityStageId":{"type":"string","description":"ID of the opportunity stage the deal is moving TO (for Deal Stage Changed event)"}},"required":["id","name","destinationUrl","eventId","isEnabled","labelId","tagId","teamId","workspaceId"]},"CreateWebhookPublicV1Input":{"type":"object","properties":{"name":{"type":"string","description":"Display name of the webhook","example":"My Webhook"},"destinationUrl":{"type":"string","description":"URL where webhook payloads will be sent","example":"https://example.com/webhook"},"workspaceId":{"type":"string","description":"ID of the workspace this webhook belongs to","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"eventId":{"type":"string","description":"ID of the event that triggers this webhook","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"labelId":{"type":"string","description":"ID of the label to filter events (if applicable)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"tagId":{"type":"string","description":"ID of the tag to filter events (if applicable)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"memberId":{"type":"string","description":"ID of the member to filter events (if applicable)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"fromOpportunityStageId":{"type":"string","description":"ID of the opportunity stage the deal is moving FROM (for Deal Stage Changed event)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"toOpportunityStageId":{"type":"string","description":"ID of the opportunity stage the deal is moving TO (for Deal Stage Changed event)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"}},"required":["name","destinationUrl","workspaceId","eventId"]},"UpdateWebhookPublicV1Input":{"type":"object","properties":{"name":{"type":"string","description":"Display name of the webhook","example":"My Updated Webhook"},"destinationUrl":{"type":"string","description":"URL where webhook payloads will be sent","example":"https://example.com/webhook"},"eventId":{"type":"string","description":"ID of the event that triggers this webhook","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"labelId":{"type":"string","description":"ID of the label to filter events (if applicable)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"tagId":{"type":"string","description":"ID of the tag to filter events (if applicable)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"memberId":{"type":"string","description":"ID of the member to filter events (if applicable)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"isEnabled":{"type":"boolean","description":"Whether this webhook is currently active","example":true},"fromOpportunityStageId":{"type":"string","description":"ID of the opportunity stage the deal is moving FROM (for Deal Stage Changed event)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"toOpportunityStageId":{"type":"string","description":"ID of the opportunity stage the deal is moving TO (for Deal Stage Changed event)","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"}}},"EventPublicDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the event"},"name":{"type":"string","description":"Display name of the event"},"order":{"type":"number","description":"Sort order for displaying events"},"type":{"type":"string","description":"Type of webhook event","enum":["THREAD_ASSIGNED","SPECIFIC_LABEL_ADDED","ANY_LABEL_ADDED","OPPORTUNITY_CREATED","OPPORTUNITY_WON","OPPORTUNITY_LOST","MAILBOX_DISCONNECTED","MAILBOX_RECONNECTED","EMAIL_SENT","EMAIL_SENT_TO_LEAD_WITH_LABEL","EMAIL_FROM_LEAD_WITH_LABEL","EMAIL_RECEIVED","EMAIL_BOUNCED","DEAL_STAGE_CHANGE","DEAL_MOVES_SPECIFIC_STAGES","LINKEDIN_MESSAGE_RECEIVED","LINKEDIN_MESSAGE_SENT","LINKEDIN_CONVERSATION_TAG_ADDED","SUBSEQUENCE_SUBSCRIBED","SUBSEQUENCE_COMPLETED","CAMPAIGN_FIRST_EMAIL_SENT","CAMPAIGN_LEAD_REPLIED","CAMPAIGN_STATUS_CHANGED","CAMPAIGN_LEAD_COMPLETED_NO_REPLY","CAMPAIGN_BOUNCE_RATE_EXCEEDED"]},"category":{"type":"string","description":"Category the event belongs to","enum":["SYSTEM","LINKEDIN"]},"description":{"type":"string","description":"Detailed description of what triggers this event"},"helpInfo":{"type":"string","description":"Additional help information for configuring this event"},"requiredFields":{"description":"Fields that must be provided when creating a webhook for this event","example":["labelId"],"type":"array","items":{"type":"string"}}},"required":["id","name","order","type","category","description","helpInfo","requiredFields"]},"IntegrationSettingsDto":{"type":"object","properties":{"isEmailBisonBlacklistManagementEnabled":{"type":"boolean","example":true,"nullable":true},"isEmailBisonFullSyncCompleted":{"type":"boolean","example":false,"nullable":true,"description":"Whether a full EB blocklist sync has completed. Reset when sync is re-enabled."}},"required":["isEmailBisonBlacklistManagementEnabled","isEmailBisonFullSyncCompleted"]},"IntegrationDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the integration, in UUID format.","example":"7a3a9932-34f3-48f0-ae67-f7bd1e839e93"},"apiUrl":{"type":"string","example":"https://dedi.emailbison.co"},"apiKey":{"type":"string","example":"144|zsCrF6QUooogblT8114z59Avr7gGlokv1AgJSdhZb919a7dc@"},"type":{"type":"string","enum":["EMAIL_BISON","HEY_REACH"],"example":"EMAIL_BISON"},"settings":{"$ref":"#/components/schemas/IntegrationSettingsDto"},"workspaceId":{"type":"string","description":"Unique identifier of the workspace associated with the integration, in UUID format.","example":"cdf0ec05-2e6c-4092-aae3-bfd2292eecaa"},"teamId":{"type":"string","description":"Unique identifier of the team associated with the integration, in UUID format.","example":"cdf0ec05-2e6c-4092-aae3-bfd2292eecaa"},"createdAt":{"format":"date-time","type":"string","description":"The date and time when the integration was created.","example":"2023-01-15T12:00:00.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"The date and time when the integration was last updated.","example":"2025-03-05T14:00:00.000Z"},"updatedById":{"type":"string","example":"cdf0ec05-2e6c-4092-aae3-bfd2292eecaa"}},"required":["id","apiUrl","apiKey","type","settings","workspaceId","teamId","createdAt","updatedAt","updatedById"]},"CreateIntegrationInput":{"type":"object","properties":{"workspaceId":{"type":"string","example":"550e8400-e29b-41d4-a716-446655440000"},"type":{"type":"string","enum":["EMAIL_BISON","HEY_REACH"],"examples":["EMAIL_BISON","HEY_REACH"]},"apiUrl":{"type":"string","example":"https://api.example.com"},"apiKey":{"type":"string","example":"your-api-key"}},"required":["workspaceId","type","apiUrl","apiKey"]},"UpdateIntegrationSettingsPublicV1Input":{"type":"object","properties":{"isEmailBisonBlacklistManagementEnabled":{"type":"boolean","description":"Enable or disable Email Bison blacklist management"}}},"UpdateIntegrationPublicV1Input":{"type":"object","properties":{"settings":{"$ref":"#/components/schemas/UpdateIntegrationSettingsPublicV1Input"}}},"ClientSettingsEmailLabelDto":{"type":"object","properties":{"labelId":{"type":"string","description":"UUID of the email label"}},"required":["labelId"]},"WorkspaceClientSettingsDto":{"type":"object","properties":{"id":{"type":"string","description":"UUID of the client settings row"},"isOpportunitiesBoardEnabled":{"type":"boolean","example":false},"isLabelManagementEnabled":{"type":"boolean","example":false},"isLinkedInInboxEnabled":{"type":"boolean","example":false},"isBlocklistEnabled":{"type":"boolean","description":"Enable or disable blocklist for this workspace","example":false},"workspaceId":{"type":"string","description":"UUID of the workspace this settings belongs to"},"emailVisibilityMode":{"type":"string","description":"How client emails are visible","enum":["ALL","LABELS"]},"emailLabels":{"description":"List of email labels visible to the client","type":"array","items":{"$ref":"#/components/schemas/ClientSettingsEmailLabelDto"}}},"required":["id","isOpportunitiesBoardEnabled","isLabelManagementEnabled","isLinkedInInboxEnabled","isBlocklistEnabled","workspaceId","emailVisibilityMode","emailLabels"]},"WorkspaceDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the workspace, in UUID format.","example":"fe5a9932-1079-4680-a997-e87db4dc3413"},"name":{"type":"string","description":"Name of the workspace.","example":"Marketing Team Workspace"},"opportunitiesCurrencyId":{"type":"string","description":"Unique identifier of the currency used for opportunities, in UUID format.","example":"ab5e9034-2e8d-45b0-b933-8ad95dfc7912"},"opportunitiesCurrency":{"description":"Details about the currency used for opportunities.","allOf":[{"$ref":"#/components/schemas/CurrencyDto"}]},"clientSettings":{"description":"Details about the client settings.","allOf":[{"$ref":"#/components/schemas/WorkspaceClientSettingsDto"}]},"teamId":{"type":"string","description":"Unique identifier of the team associated with the workspace, in UUID format.","example":"cdf0ec05-2e6c-4092-aae3-bfd2292eecaa"},"isSendDisconnectNotification":{"type":"boolean","description":"Indicates if a notification should be sent when the user's account is disconnected from HotHawk. If true, a notification will be triggered upon disconnection.","example":true},"isAiCategorisationEnabled":{"type":"boolean","example":true},"isSendReceivedNewNotification":{"type":"boolean","description":"Indicates if a notification should be sent to the user when a new email is received. If true, the user will be notified whenever a new email arrives.","example":true},"defaultComposeMailboxId":{"type":"string","description":"Unique identifier of the default mailbox used for composing emails, in UUID format.","example":"adf7b334-2bc5-42a3-b934-76a67fd1e8ef"},"lastNewMessageNotificationDate":{"format":"date-time","type":"string","description":"The date and time when the last notification for a new message was sent.","example":"2025-03-05T13:40:33.000Z"},"lastDisableWebhookNotificationDate":{"format":"date-time","type":"string","description":"The date and time when the last webhook disable notification was sent.","example":"2025-03-05T13:40:33.000Z"},"createdAt":{"format":"date-time","type":"string","description":"The date and time when the workspace was created.","example":"2023-01-15T12:00:00.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"The date and time when the workspace was last updated.","example":"2025-03-05T14:00:00.000Z"},"emailAssignmentMode":{"type":"string","description":"The email assignment mode for the workspace","enum":["default","round_robin","account_groups","unassigned_pool"],"example":"default"}},"required":["id","name","opportunitiesCurrencyId","opportunitiesCurrency","clientSettings","teamId","isSendDisconnectNotification","isAiCategorisationEnabled","isSendReceivedNewNotification","defaultComposeMailboxId","lastNewMessageNotificationDate","lastDisableWebhookNotificationDate","createdAt","updatedAt","emailAssignmentMode"]},"WorkspaceShortInfoDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the workspace, in UUID format.","example":"fe5a9932-1079-4680-a997-e87db4dc3413"},"name":{"type":"string","description":"Name of the workspace.","example":"Marketing Team Workspace"}},"required":["id","name"]},"MetricValueDto":{"type":"object","properties":{"value":{"type":"number","description":"Sum of values","example":1500},"count":{"type":"number","description":"Count of data points","example":30}},"required":["value","count"]},"WorkspaceAnalyticsSummaryDto":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace ID"},"UNIQUE_CONTACTS_REACHED":{"type":"number","description":"Unique contacts reached","example":120},"UNIQUE_POSITIVE_REPLIES":{"type":"number","description":"Unique positive replies","example":45},"TOTAL_SENDS":{"type":"number","description":"Total emails sent","example":500},"TOTAL_MANUAL_FOLLOW_UPS":{"type":"number","description":"Total manual follow-ups","example":25},"CAMPAIGN_SENDS":{"type":"number","description":"Sends the campaign engine dispatched (automated sequence steps)","example":3420},"CAMPAIGN_FIRST_SENDS":{"type":"number","description":"Campaign sends that were the lead's first contact (step 0)","example":980},"CAMPAIGN_FOLLOWUP_SENDS":{"type":"number","description":"Derived: campaign follow-up sends = CAMPAIGN_SENDS - CAMPAIGN_FIRST_SENDS","example":2440},"MANUAL_SENDS":{"type":"number","description":"Sends a rep dispatched manually from the HotHawk inbox on a non-campaign thread","example":77},"MANUAL_FIRST_SENDS":{"type":"number","description":"Manual (non-campaign) sends that were the lead's first send","example":41},"EXTERNAL_SENDS":{"type":"number","description":"Derived: external sends (Gmail/Outlook direct, parser-observed) = TOTAL_SENDS - CAMPAIGN_SENDS - MANUAL_SENDS","example":20},"UNIQUE_HUMAN_REPLIES":{"type":"number","description":"Unique human replies","example":60},"FIRST_REPLIES":{"type":"number","description":"Derived: first reply per lead, any type = UNIQUE_HUMAN_REPLIES + first-OOO","example":72},"OOO_FIRST_REPLIES":{"type":"number","description":"Derived: first replies that were an OOO/auto-reply = FIRST_REPLIES - UNIQUE_HUMAN_REPLIES","example":12},"FOLLOWUP_REPLIES":{"type":"number","description":"Derived: follow-up replies (a lead's replies beyond the first), as a single total — not split by human/OOO. = TOTAL_HUMAN_REPLIES - UNIQUE_HUMAN_REPLIES","example":2},"TOTAL_HUMAN_REPLIES":{"type":"number","description":"Total human replies","example":80},"TOTAL_AUTOMATED_REPLIES":{"type":"number","description":"Total automated replies","example":15},"SOFT_BOUNCES":{"type":"number","description":"Soft bounces count","example":5},"HARD_BOUNCES":{"type":"number","description":"Hard bounces count","example":2},"WARMUP_EMAILS_SENT":{"type":"number","description":"Warmup emails sent","example":100},"WARMUP_EMAILS_RECEIVED":{"type":"number","description":"Warmup emails received","example":95},"DEALS_CREATED":{"type":"number","description":"Deals created","example":10},"DEALS_WON":{"description":"Deals won (value: total amount, count: number of deals)","allOf":[{"$ref":"#/components/schemas/MetricValueDto"}]},"DEALS_LOST":{"description":"Deals lost (value: total amount, count: number of deals)","allOf":[{"$ref":"#/components/schemas/MetricValueDto"}]},"AVG_SPEED_TO_LEAD_MINUTES":{"type":"number","description":"Average speed to lead in minutes","example":50},"LINKEDIN_MESSAGES_SENT":{"type":"number","description":"LinkedIn messages sent","example":50},"LINKEDIN_MESSAGES_RECEIVED":{"type":"number","description":"LinkedIn messages received","example":30},"LINKEDIN_AVG_RESPONSE_TIME_MINUTES":{"type":"number","description":"LinkedIn average response time in minutes","example":45}},"required":["workspaceId"]},"UpdateWorkspaceClientSettingsPublicV1Input":{"type":"object","properties":{"isOpportunitiesBoardEnabled":{"type":"boolean","description":"Enable or disable the opportunities board for this workspace","example":true},"isLabelManagementEnabled":{"type":"boolean","description":"Enable or disable label management for this workspace","example":true},"isLinkedInInboxEnabled":{"type":"boolean","description":"Enable or disable LinkedIn inbox for this workspace","example":false},"isBlocklistEnabled":{"type":"boolean","description":"Enable or disable blocklist for this workspace","example":false},"emailVisibilityMode":{"type":"string","description":"How client emails are visible","enum":["ALL","LABELS"],"example":"ALL"},"emailLabelIds":{"description":"List of email label IDs visible to the client","example":["uuid-label-1","uuid-label-2"],"type":"array","items":{"type":"array"}}}},"CreateWorkspacePublicV1Input":{"type":"object","properties":{"name":{"type":"string","description":"The name of the workspace being created.","example":"Marketing Team Workspace"},"currencyCode":{"type":"string","enum":["USD","CAD","EUR","AED","AFN","ALL","AMD","ARS","AUD","AZN","BAM","BDT","BGN","BHD","BIF","BND","BOB","BRL","BWP","BYR","BZD","CDF","CHF","CLP","CNY","COP","CRC","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","GBP","GEL","GHS","GNF","GTQ","HKD","HNL","HRK","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KHR","KMF","KRW","KWD","KZT","LBP","LKR","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MOP","MUR","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PHP","PKR","PLN","PYG","QAR","RON","RSD","RWF","SAR","SDG","SEK","SGD","SOS","SYP","THB","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","UYU","UZS","VEF","VND","XAF","XOF","YER","ZAR","ZMK"],"description":"The currency code associated with the workspace. This will define the default currency for transactions and financial operations within the workspace.","example":"USD|CAD|EUR|AED|AFN|ALL|AMD|ARS|AUD|AZN"}},"required":["name","currencyCode"]},"UpdateWorkspacePublicV1Input":{"type":"object","properties":{"isSendDisconnectNotification":{"type":"boolean","description":"Indicates whether an email should be sent to the user when their account is disconnected from HotHawk. If enabled, a notification will be triggered upon disconnection.","example":true},"isSendReceivedNewNotification":{"type":"boolean","description":"Indicates whether an email should be sent to the user when a new email is received. If enabled, the user will receive a notification whenever a new email arrives in their inbox.","example":true},"defaultComposeMailboxId":{"type":"string","description":"The ID (UUID) of the default mailbox to be used for composing emails.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf","nullable":true},"emailAssignmentMode":{"type":"string","description":"The email assignment mode for the workspace. Determines how incoming emails are assigned to users.","enum":["default","round_robin","account_groups","unassigned_pool"],"example":"default"},"isAiCategorisationEnabled":{"type":"boolean","description":"Indicates whether AI-based categorization is enabled for the workspace. When enabled, incoming emails will be automatically categorized using AI.","example":true}},"required":["isSendReceivedNewNotification"]},"WarmupTagPublicDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the warmup tag in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"value":{"type":"string","description":"The value or name of the warmup tag.","example":"Important Tag"}},"required":["id","value"]},"CreateWarmupTagCommonInput":{"type":"object","properties":{"value":{"type":"string","description":"The value of the warmup tag.","example":"Initial Warmup"},"workspaceId":{"type":"string","description":"The ID of the workspace where the warmup tag is being created.","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"}},"required":["value","workspaceId"]},"CreateWarmupTagsCommonInput":{"type":"object","properties":{"tags":{"description":"List of warmup tag values to be created.","example":["Initial Warmup","Second Stage Warmup"],"type":"array","items":{"type":"string"}},"workspaceId":{"type":"string","description":"The ID of the workspace where the warmup tags are being created.","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"}},"required":["tags","workspaceId"]},"ThreadLabelColorDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the color, in UUID format.","example":"a7b7cdb9-bc7d-4b4d-b4f9-7a8395b5b6c7"},"name":{"type":"string","description":"The name of the color (e.g., \"Red\", \"Blue\", etc.).","example":"Red"},"color":{"type":"string","description":"The hexadecimal color code representing the color (e.g., \"#FF5733\").","example":"#FF5733"},"bgColor":{"type":"string","description":"The background color associated with the label (hexadecimal format, e.g., \"#F0F0F0\").","example":"#F0F0F0"}},"required":["id","name","color","bgColor"]},"ThreadLabelDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the thread label, in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"emailBisonTags":{"example":[{"id":1,"name":"Interested"}],"type":"array","items":{"type":"string"}},"colorId":{"type":"string","description":"Unique identifier of the color associated with the label, in UUID format.","example":"c4b8ed9d-dc75-4f27-8d1f-93ff9d697b6d"},"name":{"type":"string","description":"The name of the thread label.","example":"Important"},"prompt":{"type":"string","description":"Instructional text describing when to apply this label to a reply message.","example":"When the reply is upbeat or shows forward momentum (e.g. \"Sounds good,\" \"Send me the video,\" \"Let's move ahead\")"},"defaultPrompt":{"type":"string","description":"The original default value of the prompt, used to reset or compare user-edited prompts.","example":"When the reply is upbeat or shows forward momentum (e.g. \"Sounds good,\" \"Send me the video,\" \"Let's move ahead\")"},"order":{"type":"number","description":"The order of the label, used for sorting.","example":1},"teamId":{"type":"string","description":"Unique identifier of the team to which this label belongs.","example":"5e91c0c3-2121-4a4a-9a74-6bb927b7c4fa"},"workspaceId":{"type":"string","description":"Unique identifier of the workspace to which this label is assigned.","example":"8a19a199-e1b0-47ac-bd19-c3cf75bfa8e7"},"isFavourite":{"type":"boolean","description":"Indicates whether the label is marked as a favorite.","example":true},"isVisible":{"type":"boolean","example":true},"sentiment":{"type":"string","enum":["POSITIVE","NEGATIVE","NEUTRAL"],"examples":["POSITIVE","NEGATIVE","NEUTRAL"]},"type":{"type":"string","enum":["EMAIL_BISON","AI_CATEGORISATION","BLOCKLIST"]},"color":{"description":"Details of the color associated with this thread label.","allOf":[{"$ref":"#/components/schemas/ThreadLabelColorDto"}]}},"required":["id","colorId","name","prompt","defaultPrompt","order","teamId","workspaceId","isFavourite","isVisible","sentiment","type","color"]},"ThreadLabelShortInfoDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the thread label, in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"name":{"type":"string","description":"The name of the thread label.","example":"Important"}},"required":["id","name"]},"CreateThreadLabelPublicV1Input":{"type":"object","properties":{"sentiment":{"type":"string","enum":["POSITIVE","NEGATIVE","NEUTRAL"],"examples":["POSITIVE","NEGATIVE","NEUTRAL"]},"prompt":{"type":"string","maxLength":200,"description":"","example":""},"workspaceId":{"type":"string","description":"The unique identifier of the workspace where the label is being created.","example":"a25c5bbf-6f12-4c12-9a34-ffcd7a234f11"},"name":{"type":"string","description":"The name of the thread label. Should be short and descriptive, with a maximum length of 20 characters.","maxLength":20,"example":"Important"},"colorName":{"type":"string","enum":["Dark grey","Grey","Teal","Purple","Orange","Red","Pink","Yellow","Green"],"example":"Yellow | Green | Teal | Purple | Orange | Red | Pink","description":"The color name of the label. If not provided or null, a random color will be assigned automatically."}},"required":["sentiment","workspaceId","name"]},"ThreadLabelInput":{"type":"object","properties":{"name":{"type":"string","description":"The name of the thread label. It should be concise and descriptive.","example":"Important"},"sentiment":{"type":"string","enum":["POSITIVE","NEGATIVE","NEUTRAL"],"examples":["POSITIVE","NEGATIVE","NEUTRAL"]},"prompt":{"type":"string","maxLength":200,"description":"","example":""},"colorName":{"type":"string","enum":["Dark grey","Grey","Teal","Purple","Orange","Red","Pink","Yellow","Green"],"example":"Yellow | Green | Teal | Purple | Orange | Red | Pink","description":"The color name of the label. If not provided or is null, a random color will be assigned automatically."}},"required":["name","sentiment"]},"CreateThreadLabelsPublicV1Input":{"type":"object","properties":{"labels":{"description":"An array of thread labels to be created for the workspace.","example":[{"name":"Important","sentiment":"POSITIVE","colorName":"Red"},{"name":"Follow-Up","sentiment":"NEUTRAL","colorName":"Yellow"}],"type":"array","items":{"$ref":"#/components/schemas/ThreadLabelInput"}},"workspaceId":{"type":"string","description":"The unique identifier of the workspace where the labels are being created.","example":"a25c5bbf-6f12-4c12-9a34-ffcd7a234f11"}},"required":["labels","workspaceId"]},"EmailBisonTagInput":{"type":"object","properties":{}},"UpdateThreadLabelPublicV1Input":{"type":"object","properties":{"name":{"type":"string","maxLength":20,"description":"The name of the thread label. It can be updated to a new value, but it must not exceed 20 characters.","example":"Important"},"prompt":{"type":"string","maxLength":200,"description":"","example":""},"isFavourite":{"type":"boolean","description":"Indicates whether the label is marked as a favorite. If true, the label will be flagged as favorite.","example":true},"emailBisonTags":{"description":"Email Bison tags to associate with this label","example":[{"id":1,"name":"Interested"}],"type":"array","items":{"$ref":"#/components/schemas/EmailBisonTagInput"}}}},"CampaignSummaryDto":{"type":"object","properties":{"id":{"type":"string","description":"Campaign UUID.","example":"a1b2c3d4-e5f6-7890-abcd-ef1234567890"},"name":{"type":"string","description":"Human-readable campaign name (unique per workspace).","example":"Q2 outbound — North America"},"status":{"type":"string","description":"Lifecycle status. `draft` while never-published; flips to `paused` on publish.","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"],"nullable":true,"example":"draft","examples":["draft","active","paused","pausing","activating","disabled","completed","archived"]},"pauseReason":{"type":"string","description":"Reason the campaign is paused, when the system forced the pause. `null` for user-initiated pauses (or non-paused campaigns). When non-null, resume is blocked until the underlying cause is fixed — currently only `TRIGGER_LABEL_DELETED`, which requires assigning a new `triggerLabelId` before activating.","enum":["TRIGGER_LABEL_DELETED"],"nullable":true,"example":null,"examples":[null,"TRIGGER_LABEL_DELETED"]},"type":{"type":"string","description":"Campaign type — drives sending semantics.","enum":["COLD","EVERGREEN","SUB_SEQUENCE"],"nullable":true,"example":"COLD","examples":["COLD","EVERGREEN","SUB_SEQUENCE"]},"priority":{"type":"string","description":"Sending priority relative to other campaigns in the workspace.","enum":["CRITICAL","HIGH","MEDIUM","LOW","NONE"],"example":"MEDIUM","examples":["CRITICAL","HIGH","MEDIUM","LOW","NONE"]},"groupId":{"type":"string","description":"Optional campaign group this campaign is assigned to.","nullable":true,"example":"b1c2d3e4-f5a6-7890-abcd-ef1234567890"},"statsTotalLeads":{"type":"number","description":"Total leads ever enrolled in this campaign.","example":1240},"statsActiveLeads":{"type":"number","description":"Leads currently being processed.","example":312},"statsCompletedLeads":{"type":"number","description":"Leads that have finished the sequence.","example":800},"statsCompletedLeadsWithReply":{"type":"number","description":"Leads that completed and replied at least once.","example":142},"statsTotalSends":{"type":"number","description":"Total messages sent (including follow-ups).","example":4310},"statsUniqueLeadsContacted":{"type":"number","description":"Distinct lead addresses contacted.","example":1198},"statsBouncedLeads":{"type":"number","description":"Leads that hit a hard bounce.","example":28},"statsPositiveReplies":{"type":"number","description":"Replies classified as positive intent.","example":87},"createdAt":{"format":"date-time","type":"string","example":"2026-04-15T10:30:00.000Z"}},"required":["id","name","status","pauseReason","type","priority","groupId","statsTotalLeads","statsActiveLeads","statsCompletedLeads","statsCompletedLeadsWithReply","statsTotalSends","statsUniqueLeadsContacted","statsBouncedLeads","statsPositiveReplies","createdAt"]},"EmailAttachmentDto":{"type":"object","properties":{"id":{"type":"string"},"filename":{"type":"string"},"contentType":{"type":"string"},"blobUrl":{"type":"string"},"statusCode":{"type":"number"},"statusText":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"workspaceId":{"type":"string"},"messageId":{"type":"string"},"emailTemplateId":{"type":"string"},"teamId":{"type":"string"}},"required":["id","filename","contentType","blobUrl","statusCode","statusText","createdAt","updatedAt","workspaceId","messageId","emailTemplateId","teamId"]},"SequenceStepVariantDto":{"type":"object","properties":{"id":{"type":"string","description":"Variant UUID.","example":"f1a2b3c4-d5e6-7890-abcd-ef1234567890"},"stepId":{"type":"string","description":"Sequence step this variant belongs to.","example":"a9b8c7d6-e5f4-3210-9876-543210fedcba"},"label":{"type":"string","description":"Variant label, unique per step (typically `A`, `B`, `C`, ...).","example":"A"},"subject":{"type":"string","description":"Email subject. `null` means inherit from step or thread context.","nullable":true,"example":"Following up on our last conversation"},"body":{"type":"string","description":"HTML body of the email.","example":"<p>Hi {{firstName}}, just checking in...</p>"},"isActive":{"type":"boolean","description":"Whether this variant is eligible to be picked when scheduling new sends. Inactive variants keep their stats but stop receiving new traffic.","example":true},"statsEmailsSent":{"type":"number","description":"Total emails sent using this variant.","example":412},"statsEmailsReplied":{"type":"number","description":"Replies received on this variant.","example":38},"statsEmailsBounced":{"type":"number","description":"Hard bounces on this variant.","example":4},"attachments":{"description":"Attachments associated with this variant.","type":"array","items":{"$ref":"#/components/schemas/EmailAttachmentDto"}},"createdAt":{"format":"date-time","type":"string","example":"2026-04-15T10:30:00.000Z"},"updatedAt":{"format":"date-time","type":"string","example":"2026-04-28T14:22:00.000Z"}},"required":["id","stepId","label","subject","body","isActive","statsEmailsSent","statsEmailsReplied","statsEmailsBounced","createdAt","updatedAt"]},"CampaignStepSummaryDto":{"type":"object","properties":{"id":{"type":"string"},"order":{"type":"number","example":1,"description":"Step order in the sequence, must be unique per sequence"},"delayValue":{"type":"number","description":"Numeric value of the delay before the step is triggered (paired with `delayUnit`).","example":3},"delayUnit":{"type":"string","description":"Unit of time for the delay.","enum":["DAY","WEEK","MONTH"],"example":"DAY"},"sequenceId":{"type":"string","example":"c50416b8-5f0f-4d58-b7c5-7e0f4f65f672","description":"ID of the parent sequence (campaign) this step belongs to."},"sendAsNewThread":{"type":"boolean","description":"When true, this step starts a new email thread instead of replying in the existing one. No-op for step 0.","example":false,"default":false},"statsEmailsSent":{"type":"number","example":120,"default":0},"statsEmailsReplied":{"type":"number","example":45,"default":0},"statsEmailsScheduled":{"type":"number","example":30,"default":0},"statsReplyRate":{"type":"number","example":25.5},"variants":{"description":"Variants attached to this step. Each variant includes its attachments.","type":"array","items":{"$ref":"#/components/schemas/SequenceStepVariantDto"}},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","order","sequenceId","sendAsNewThread","statsEmailsSent","statsEmailsReplied","statsEmailsScheduled","statsReplyRate","createdAt","updatedAt"]},"CampaignDetailDto":{"type":"object","properties":{"id":{"type":"string","description":"Campaign UUID.","example":"a1b2c3d4-e5f6-7890-abcd-ef1234567890"},"workspaceId":{"type":"string","description":"Workspace this campaign belongs to.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"name":{"type":"string","description":"Human-readable campaign name (unique per workspace).","example":"Q2 outbound — North America"},"status":{"type":"string","description":"Lifecycle status. `draft` while never-published; flips to `paused` on publish.","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"],"nullable":true,"example":"draft","examples":["draft","active","paused","pausing","activating","disabled","completed","archived"]},"pauseReason":{"type":"string","description":"Reason the campaign is paused, when the system forced the pause. `null` for user-initiated pauses (or non-paused campaigns). When non-null, resume is blocked until the underlying cause is fixed — currently only `TRIGGER_LABEL_DELETED`, which requires assigning a new `triggerLabelId` before activating.","enum":["TRIGGER_LABEL_DELETED"],"nullable":true,"example":null,"examples":[null,"TRIGGER_LABEL_DELETED"]},"isDraft":{"type":"boolean","description":"DEPRECATED — mirror of `status === \"draft\"`. Use `status` going forward.","example":true,"deprecated":true},"type":{"type":"string","description":"Campaign type — drives sending semantics.","enum":["COLD","EVERGREEN","SUB_SEQUENCE"],"nullable":true,"example":"COLD","examples":["COLD","EVERGREEN","SUB_SEQUENCE"]},"priority":{"type":"string","description":"Sending priority relative to other campaigns in the workspace.","enum":["CRITICAL","HIGH","MEDIUM","LOW","NONE"],"example":"MEDIUM","examples":["CRITICAL","HIGH","MEDIUM","LOW","NONE"]},"leadPriority":{"type":"string","description":"Order in which leads are processed within the campaign. `null` = split evenly between new leads and follow-ups (no preference).","enum":["NEW_LEADS_FIRST","CONTINUE_FOLLOWUPS_FIRST","BALANCED"],"nullable":true,"example":"NEW_LEADS_FIRST","examples":["NEW_LEADS_FIRST","CONTINUE_FOLLOWUPS_FIRST","BALANCED"]},"dailySendLimit":{"type":"number","description":"Maximum emails sent per day across all mailboxes. `null` = unlimited.","nullable":true,"example":250},"startDate":{"format":"date-time","type":"string","description":"When sending should begin. `null` means \"start immediately\" once the campaign is activated.","nullable":true,"example":"2026-05-01T09:00:00.000Z"},"completedAt":{"format":"date-time","type":"string","description":"Timestamp the campaign reached COMPLETED. `null` while still running.","nullable":true,"example":null},"groupId":{"type":"string","description":"Optional campaign group this campaign is assigned to.","nullable":true,"example":"b1c2d3e4-f5a6-7890-abcd-ef1234567890"},"triggerLabelId":{"type":"string","description":"For SUB_SEQUENCE campaigns: the thread label that triggers enrolment when applied. Null/absent for COLD/EVERGREEN.","nullable":true,"example":"f1a2b3c4-d5e6-7890-abcd-ef1234567890"},"triggerDelayInMinutes":{"type":"number","description":"For SUB_SEQUENCE campaigns: minutes to wait after the trigger label is applied before scheduling step 0. Null/absent for COLD/EVERGREEN.","nullable":true,"example":60},"timezone":{"type":"string","description":"IANA timezone in which sending windows are interpreted.","nullable":true,"example":"America/New_York"},"sendingStartTime":{"type":"string","description":"Daily sending window start (HH:mm, in `timezone`).","nullable":true,"example":"09:00"},"sendingEndTime":{"type":"string","description":"Daily sending window end (HH:mm, in `timezone`).","nullable":true,"example":"17:00"},"sendingDays":{"type":"array","description":"Days of week on which sending may occur.","nullable":true,"example":["monday","tuesday","wednesday","thursday","friday"],"examples":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"],"items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"statsTotalLeads":{"type":"number","description":"Total leads ever enrolled in this campaign.","example":1240},"statsActiveLeads":{"type":"number","description":"Leads currently being processed.","example":312},"statsCompletedLeads":{"type":"number","description":"Leads that have finished the sequence.","example":800},"statsCompletedLeadsWithReply":{"type":"number","description":"Leads that completed and replied at least once.","example":142},"statsTotalSends":{"type":"number","description":"Total messages sent (including follow-ups).","example":4310},"statsUniqueLeadsContacted":{"type":"number","description":"Distinct lead addresses contacted.","example":1198},"statsBouncedLeads":{"type":"number","description":"Leads that hit a hard bounce.","example":28},"statsPositiveReplies":{"type":"number","description":"Replies classified as positive intent.","example":87},"holidayIds":{"description":"Ids of holidays attached to this campaign.","example":["c1d2e3f4-a5b6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}},"accountIds":{"description":"Account UUIDs (mailboxes) attached to this campaign. Each entry maps to a row in `campaign_accounts`.","example":["a1b2c3d4-e5f6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}},"listIds":{"description":"CRM list UUIDs attached to this campaign. Each entry maps to a row in `campaign_lists`.","example":["e1f2a3b4-c5d6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}},"createdAt":{"format":"date-time","type":"string","example":"2026-04-15T10:30:00.000Z"},"updatedAt":{"format":"date-time","type":"string","example":"2026-04-28T14:22:00.000Z"},"steps":{"description":"Sequence steps in their trimmed form. The heavy fields (emailName, emailContent, emailAttachments) are dropped; variants retain their attachments.","type":"array","items":{"$ref":"#/components/schemas/CampaignStepSummaryDto"}}},"required":["id","workspaceId","name","status","pauseReason","isDraft","type","priority","leadPriority","dailySendLimit","startDate","completedAt","groupId","timezone","sendingStartTime","sendingEndTime","sendingDays","statsTotalLeads","statsActiveLeads","statsCompletedLeads","statsCompletedLeadsWithReply","statsTotalSends","statsUniqueLeadsContacted","statsBouncedLeads","statsPositiveReplies","createdAt","updatedAt"]},"CampaignStepAttachmentDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"filename":{"type":"string"},"contentType":{"type":"string"},"blobUrl":{"type":"string","nullable":true}},"required":["id","filename","contentType"]},"CampaignStepVariantDetailDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"label":{"type":"string","description":"A, B, C, …"},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"isActive":{"type":"boolean"},"attachments":{"type":"array","items":{"$ref":"#/components/schemas/CampaignStepAttachmentDto"}}},"required":["id","label","body","isActive","attachments"]},"CampaignStepDetailDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"order":{"type":"number"},"delayValue":{"type":"number","nullable":true},"delayUnit":{"type":"string","enum":["DAY","WEEK","MONTH"],"nullable":true},"sendAsNewThread":{"type":"boolean"},"variants":{"type":"array","items":{"$ref":"#/components/schemas/CampaignStepVariantDetailDto"}}},"required":["id","order","sendAsNewThread","variants"]},"CampaignScheduleDto":{"type":"object","properties":{"timezone":{"type":"string"},"sendingStartTime":{"type":"string","example":"09:00"},"sendingEndTime":{"type":"string","example":"17:00"},"sendingDays":{"type":"array","items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}}},"required":["timezone","sendingStartTime","sendingEndTime","sendingDays"]},"CampaignStepVariantInput":{"type":"object","properties":{"id":{"type":"string","description":"Variant id when updating an existing variant. Omit to insert a new variant; the server allocates the next free label (A, B, C, …).","format":"uuid"},"subject":{"type":"string","description":"Email subject line for this variant. `null` clears.","nullable":true},"body":{"type":"string","description":"Email body (HTML or plain text)."},"isActive":{"type":"boolean","description":"Whether the variant is eligible for round-robin selection. The step must always have at least one active variant.","default":true},"attachmentIds":{"description":"Email attachment ids to associate with this variant (replace semantics). All ids must belong to the campaign workspace.","type":"array","items":{"type":"string","format":"uuid"}}}},"CampaignStepNestedPublicV1Input":{"type":"object","properties":{"id":{"type":"string","description":"Step id when updating an existing step (preserves stats). Omit to insert a new step.","format":"uuid"},"order":{"type":"number","description":"Position of the step within the campaign. Legacy data is 0-based (first step has `order = 0`); new campaigns may use either convention — the scheduler resolves the entry-point job to the lowest-order step.","example":0},"delayValue":{"type":"number","description":"Delay before sending this step relative to the previous step.","example":2},"delayUnit":{"type":"string","description":"Delay unit.","enum":["DAY","WEEK","MONTH"],"example":"DAY"},"sendAsNewThread":{"type":"boolean","description":"Whether to send this step in a brand-new email thread instead of replying on the existing one.","default":false},"variants":{"description":"Optional A/B/C variants for this step. When present in a draft campaign, the server fully replaces variants for this step (deletes existing, inserts these). Existing entries with an `id` are updated in place.","type":"array","items":{"$ref":"#/components/schemas/CampaignStepVariantInput"}},"emailName":{"type":"string","description":"Deprecated — retained only for backward compatibility. Step names are managed internally and this value is not part of the current public contract.","nullable":true,"deprecated":true},"emailContent":{"type":"string","description":"Deprecated — retained only for backward compatibility. Provide step bodies via `variants` instead.","deprecated":true}},"required":["order"]},"MailboxSelectionCriteriaCommonInput":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace scope for the criteria query.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"search":{"type":"string","description":"Case-insensitive substring match on mailbox email/name.","example":"sales@"},"groupIds":{"description":"Restrict to mailboxes assigned to any of these account groups.","example":["b1c2d3e4-f5a6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}},"domain":{"description":"Restrict to mailboxes whose email domain is one of these (mirrors the picker filter).","example":["gmail.com","acme.com"],"type":"array","items":{"type":"string"}},"currentConnectionStatus":{"type":"array","description":"Restrict to mailboxes in any of these connection states. Mirrors the picker filter — when omitted the resolver defaults to `[CONNECTED, GATHERING]`, matching what the picker shows by default.","example":["CONNECTED","GATHERING"],"items":{"type":"string","enum":["INITIALIZING","CONNECTED","DISCONNECTED","GATHERING","RECONNECTING","DELETING"]}},"excludeAccountIds":{"description":"\"Select all matching except these\" — account UUIDs to subtract from the criteria match.","example":["c1d2e3f4-a5b6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}}},"required":["workspaceId"]},"MailboxSelectionCommonInput":{"type":"object","properties":{"selectionType":{"type":"string","description":"How mailboxes are selected. `ids` — explicit list of account UUIDs in `accountIds`. `criteria` — server-side filter resolved against the accounts service. Either path resolves to a concrete account set and replaces `campaign_accounts` for this campaign.","enum":["ids","criteria"],"example":"ids","examples":["ids","criteria"]},"accountIds":{"description":"Required when `selectionType = \"ids\"`. List of account UUIDs to attach to this campaign.","example":["a1b2c3d4-e5f6-7890-abcd-ef1234567890","a2b3c4d5-e6f7-8901-bcde-f23456789012"],"type":"array","items":{"type":"string"}},"criteria":{"description":"Required when `selectionType = \"criteria\"`. Server resolves matching mailboxes via the accounts service at request time and replaces the campaign's mailbox set with the result.","allOf":[{"$ref":"#/components/schemas/MailboxSelectionCriteriaCommonInput"}]}},"required":["selectionType"]},"ListSelectionCriteriaCommonInput":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace scope for the criteria query.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"search":{"type":"string","description":"Case-insensitive substring match on list name.","example":"eu outbound"},"excludeListIds":{"description":"\"Select all matching except these\" — list IDs to subtract from the criteria match.","example":["c1d2e3f4-a5b6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}}},"required":["workspaceId"]},"ListSelectionCommonInput":{"type":"object","properties":{"selectionType":{"type":"string","description":"How CRM lists are selected. `ids` — explicit list of list UUIDs in `listIds`. `criteria` — server-side filter described by `criteria`. The server resolves either path to a concrete set of list IDs and replaces `campaign_lists` for this campaign.","enum":["ids","criteria"],"example":"ids","examples":["ids","criteria"]},"listIds":{"description":"Required when `selectionType = \"ids\"`. List of list UUIDs to attach to this campaign.","example":["a1b2c3d4-e5f6-7890-abcd-ef1234567890","a2b3c4d5-e6f7-8901-bcde-f23456789012"],"type":"array","items":{"type":"string"}},"criteria":{"description":"Required when `selectionType = \"criteria\"`. Server resolves matching lists via the CRM service at request time and replaces the campaign's list set with the result.","allOf":[{"$ref":"#/components/schemas/ListSelectionCriteriaCommonInput"}]}},"required":["selectionType"]},"CreateCampaignPublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace this campaign belongs to.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"name":{"type":"string","description":"Human-readable campaign name (unique per workspace).","example":"Q2 outbound — North America","minLength":1,"maxLength":255},"type":{"type":"string","description":"Campaign type — drives sending semantics.","enum":["COLD","EVERGREEN","SUB_SEQUENCE"],"nullable":true},"groupId":{"type":"string","description":"Optional campaign group this campaign belongs to.","nullable":true,"format":"uuid"},"triggerLabelId":{"type":"string","description":"Optional label that auto-enrolls threads into this sub-sequence when applied. Manual thread assignment is always available for SUB_SEQUENCE campaigns regardless of this value.","nullable":true,"format":"uuid"},"triggerDelayInMinutes":{"type":"number","description":"Delay between the trigger firing and the first send, in minutes.","nullable":true},"timezone":{"type":"string","description":"IANA timezone in which sending windows are interpreted.","nullable":true,"example":"America/New_York"},"sendingStartTime":{"type":"string","description":"Daily sending window start (HH:mm).","nullable":true,"example":"09:00"},"sendingEndTime":{"type":"string","description":"Daily sending window end (HH:mm).","nullable":true,"example":"17:00"},"sendingDays":{"type":"array","description":"Days of week on which sending may occur.","items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"startDate":{"type":"string","description":"When sending should begin. `null` means start immediately upon activation.","nullable":true,"example":"2026-05-01T09:00:00.000Z"},"dailySendLimit":{"type":"number","description":"Maximum emails per day across all attached mailboxes. `null` or `0` = unlimited.","nullable":true},"priority":{"type":"string","description":"Sending priority relative to other campaigns.","enum":["CRITICAL","HIGH","MEDIUM","LOW","NONE"]},"leadPriority":{"type":"string","description":"Order in which leads are processed within the campaign. Omit (or pass `null`) to split evenly between new leads and follow-ups.","enum":["NEW_LEADS_FIRST","CONTINUE_FOLLOWUPS_FIRST","BALANCED"],"nullable":true},"steps":{"description":"Sequence steps. Full-replace semantics on draft campaigns: existing steps with a matching `id` are updated, new entries are inserted, omitted steps are deleted. Rejected (`409`) once `isDraft` is `false`.","type":"array","items":{"$ref":"#/components/schemas/CampaignStepNestedPublicV1Input"}},"holidayIds":{"description":"Holiday ids to attach. Full-replace: ids absent here are detached, ids new here are attached. All ids must belong to the same workspace.","type":"array","items":{"type":"string","format":"uuid"}},"mailboxSelection":{"description":"Mailbox selection (replace semantics). Either explicit `accountIds` or a `criteria` query the server resolves at request time. Resolved set replaces `campaign_accounts` for this campaign.","allOf":[{"$ref":"#/components/schemas/MailboxSelectionCommonInput"}]},"listSelection":{"description":"List selection (replace semantics). Either explicit `listIds` or a `criteria` query the server resolves via the CRM service. Resolved set replaces `campaign_lists` for this campaign.","allOf":[{"$ref":"#/components/schemas/ListSelectionCommonInput"}]},"allowLeadsInMultiple":{"type":"boolean","description":"Per-operation enrolment intent (NOT stored on the campaign). When `false` (default), the create-time enrolment pass skips leads already enrolled in another non-terminal campaign in this workspace. When `true`, all resolved leads are enrolled regardless of overlap. Only meaningful when this create triggers an enrolment (status `active` or `paused` with a non-empty `listSelection`).","default":false},"status":{"type":"string","description":"Initial status. Frontend submits `draft` for incomplete forms (saved partial). Omit (or pass `active`) for ready-to-fire campaigns — backend will enrol leads and dispatch the activate Bull job. `paused` enrols leads without firing.","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"],"default":"active"}},"required":["workspaceId","name"]},"CampaignStepDto":{"type":"object","properties":{"id":{"type":"string"},"order":{"type":"number","example":1,"description":"Step order in the sequence, must be unique per sequence"},"emailName":{"type":"string","example":"Email 1","description":"Name of the email"},"emailContent":{"type":"string","example":"Hello {{FIRST_NAME}}, thanks for joining!","description":"Body content of the email, supports templating variables"},"delayValue":{"type":"number","description":"The numeric value of the delay before the action is triggered. For example, \"3\" with a unit of \"DAY\" means a delay of 3 days.","example":3},"delayUnit":{"type":"string","description":"The unit of time used for the delay (e.g., DAY, WEEK, MONTH).","enum":["DAY","WEEK","MONTH"],"example":"DAY"},"emailAttachments":{"type":"array","items":{"$ref":"#/components/schemas/EmailAttachmentDto"}},"sequenceId":{"type":"string","example":"c50416b8-5f0f-4d58-b7c5-7e0f4f65f672","description":"ID of the parent sequence this step belongs to"},"statsEmailsSent":{"type":"number","description":"Total number of emails that have been sent in the sequence.","example":120,"default":0},"statsEmailsReplied":{"type":"number","description":"Total number of emails that have received replies.","example":45,"default":0},"statsEmailsScheduled":{"type":"number","description":"Total number of emails scheduled to be sent.","example":30,"default":0},"statsReplyRate":{"type":"number","description":"Reply rate as a percentage (e.g., 25 for 25%).","example":25.5},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"variants":{"description":"Variants attached to this step. Empty means the step still uses its scalar `emailContent` (variant A is created lazily on first send).","type":"array","items":{"$ref":"#/components/schemas/SequenceStepVariantDto"}}},"required":["id","order","emailName","emailContent","emailAttachments","sequenceId","statsEmailsSent","statsEmailsReplied","statsEmailsScheduled","statsReplyRate","createdAt","updatedAt"]},"CampaignSkippedLeadDto":{"type":"object","properties":{"leadId":{"type":"string","description":"CRM lead UUID that was excluded from this campaign.","example":"a1b2c3d4-e5f6-7890-abcd-ef1234567890"},"conflictingCampaignId":{"type":"string","description":"Non-terminal campaign that already enrolled this lead, causing the skip. The skip happens because this operation was submitted with `allowLeadsInMultiple = false`.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"conflictingCampaignName":{"type":"string","description":"Name of the conflicting campaign — for the toast message.","example":"Q1 Outbound — North America"}},"required":["leadId","conflictingCampaignId","conflictingCampaignName"]},"CampaignEnrolmentResultDto":{"type":"object","properties":{"enrolledCount":{"type":"number","description":"Number of leads inserted as PENDING in this request.","example":1240},"skippedLeads":{"description":"Leads excluded by the cross-campaign uniqueness rule. Empty when the operation was submitted with `allowLeadsInMultiple = true` or no conflicts existed.","type":"array","items":{"$ref":"#/components/schemas/CampaignSkippedLeadDto"}}},"required":["enrolledCount","skippedLeads"]},"CampaignDto":{"type":"object","properties":{"id":{"type":"string","description":"Campaign UUID.","example":"a1b2c3d4-e5f6-7890-abcd-ef1234567890"},"workspaceId":{"type":"string","description":"Workspace this campaign belongs to.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"name":{"type":"string","description":"Human-readable campaign name (unique per workspace).","example":"Q2 outbound — North America"},"status":{"type":"string","description":"Lifecycle status. `draft` while never-published; flips to `paused` on publish.","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"],"nullable":true,"example":"draft","examples":["draft","active","paused","pausing","activating","disabled","completed","archived"]},"pauseReason":{"type":"string","description":"Reason the campaign is paused, when the system forced the pause. `null` for user-initiated pauses (or non-paused campaigns). When non-null, resume is blocked until the underlying cause is fixed — currently only `TRIGGER_LABEL_DELETED`, which requires assigning a new `triggerLabelId` before activating.","enum":["TRIGGER_LABEL_DELETED"],"nullable":true,"example":null,"examples":[null,"TRIGGER_LABEL_DELETED"]},"isDraft":{"type":"boolean","description":"DEPRECATED — mirror of `status === \"draft\"`. Use `status` going forward.","example":true,"deprecated":true},"type":{"type":"string","description":"Campaign type — drives sending semantics.","enum":["COLD","EVERGREEN","SUB_SEQUENCE"],"nullable":true,"example":"COLD","examples":["COLD","EVERGREEN","SUB_SEQUENCE"]},"priority":{"type":"string","description":"Sending priority relative to other campaigns in the workspace.","enum":["CRITICAL","HIGH","MEDIUM","LOW","NONE"],"example":"MEDIUM","examples":["CRITICAL","HIGH","MEDIUM","LOW","NONE"]},"leadPriority":{"type":"string","description":"Order in which leads are processed within the campaign. `null` = split evenly between new leads and follow-ups (no preference).","enum":["NEW_LEADS_FIRST","CONTINUE_FOLLOWUPS_FIRST","BALANCED"],"nullable":true,"example":"NEW_LEADS_FIRST","examples":["NEW_LEADS_FIRST","CONTINUE_FOLLOWUPS_FIRST","BALANCED"]},"dailySendLimit":{"type":"number","description":"Maximum emails sent per day across all mailboxes. `null` = unlimited.","nullable":true,"example":250},"startDate":{"format":"date-time","type":"string","description":"When sending should begin. `null` means \"start immediately\" once the campaign is activated.","nullable":true,"example":"2026-05-01T09:00:00.000Z"},"completedAt":{"format":"date-time","type":"string","description":"Timestamp the campaign reached COMPLETED. `null` while still running.","nullable":true,"example":null},"groupId":{"type":"string","description":"Optional campaign group this campaign is assigned to.","nullable":true,"example":"b1c2d3e4-f5a6-7890-abcd-ef1234567890"},"triggerLabelId":{"type":"string","description":"For SUB_SEQUENCE campaigns: the thread label that triggers enrolment when applied. Null/absent for COLD/EVERGREEN.","nullable":true,"example":"f1a2b3c4-d5e6-7890-abcd-ef1234567890"},"triggerDelayInMinutes":{"type":"number","description":"For SUB_SEQUENCE campaigns: minutes to wait after the trigger label is applied before scheduling step 0. Null/absent for COLD/EVERGREEN.","nullable":true,"example":60},"timezone":{"type":"string","description":"IANA timezone in which sending windows are interpreted.","nullable":true,"example":"America/New_York"},"sendingStartTime":{"type":"string","description":"Daily sending window start (HH:mm, in `timezone`).","nullable":true,"example":"09:00"},"sendingEndTime":{"type":"string","description":"Daily sending window end (HH:mm, in `timezone`).","nullable":true,"example":"17:00"},"sendingDays":{"type":"array","description":"Days of week on which sending may occur.","nullable":true,"example":["monday","tuesday","wednesday","thursday","friday"],"examples":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"],"items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"statsTotalLeads":{"type":"number","description":"Total leads ever enrolled in this campaign.","example":1240},"statsActiveLeads":{"type":"number","description":"Leads currently being processed.","example":312},"statsCompletedLeads":{"type":"number","description":"Leads that have finished the sequence.","example":800},"statsCompletedLeadsWithReply":{"type":"number","description":"Leads that completed and replied at least once.","example":142},"statsTotalSends":{"type":"number","description":"Total messages sent (including follow-ups).","example":4310},"statsUniqueLeadsContacted":{"type":"number","description":"Distinct lead addresses contacted.","example":1198},"statsBouncedLeads":{"type":"number","description":"Leads that hit a hard bounce.","example":28},"statsPositiveReplies":{"type":"number","description":"Replies classified as positive intent.","example":87},"steps":{"description":"Sequence steps with their variants. Populated on create/update/find responses.","type":"array","items":{"$ref":"#/components/schemas/CampaignStepDto"}},"holidayIds":{"description":"Ids of holidays attached to this campaign.","example":["c1d2e3f4-a5b6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}},"accountIds":{"description":"Account UUIDs (mailboxes) attached to this campaign. Each entry maps to a row in `campaign_accounts`.","example":["a1b2c3d4-e5f6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}},"listIds":{"description":"CRM list UUIDs attached to this campaign. Each entry maps to a row in `campaign_lists`.","example":["e1f2a3b4-c5d6-7890-abcd-ef1234567890"],"type":"array","items":{"type":"string"}},"enrolment":{"description":"Result of the lead enrolment that ran in this request. Populated only on create/update responses where the listSelection actually drove enrolment (publish, or a list-set change on a published campaign). Find/list responses omit it.","allOf":[{"$ref":"#/components/schemas/CampaignEnrolmentResultDto"}]},"createdAt":{"format":"date-time","type":"string","example":"2026-04-15T10:30:00.000Z"},"updatedAt":{"format":"date-time","type":"string","example":"2026-04-28T14:22:00.000Z"}},"required":["id","workspaceId","name","status","pauseReason","isDraft","type","priority","leadPriority","dailySendLimit","startDate","completedAt","groupId","timezone","sendingStartTime","sendingEndTime","sendingDays","statsTotalLeads","statsActiveLeads","statsCompletedLeads","statsCompletedLeadsWithReply","statsTotalSends","statsUniqueLeadsContacted","statsBouncedLeads","statsPositiveReplies","createdAt","updatedAt"]},"UpdateCampaignPublicV1Input":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":255},"type":{"type":"string","enum":["COLD","EVERGREEN","SUB_SEQUENCE"],"nullable":true},"groupId":{"type":"string","nullable":true,"format":"uuid"},"triggerLabelId":{"type":"string","nullable":true,"format":"uuid"},"triggerDelayInMinutes":{"type":"number","nullable":true},"timezone":{"type":"string","nullable":true,"example":"America/New_York"},"sendingStartTime":{"type":"string","nullable":true,"example":"09:00"},"sendingEndTime":{"type":"string","nullable":true,"example":"17:00"},"sendingDays":{"type":"array","items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"startDate":{"type":"string","nullable":true},"dailySendLimit":{"type":"number","description":"`null` or `0` = unlimited.","nullable":true},"priority":{"type":"string","enum":["CRITICAL","HIGH","MEDIUM","LOW","NONE"]},"leadPriority":{"type":"string","enum":["NEW_LEADS_FIRST","CONTINUE_FOLLOWUPS_FIRST","BALANCED"]},"steps":{"description":"Sequence steps. Full-replace semantics; only allowed while `isDraft` is true. Returns `409` after publish.","type":"array","items":{"$ref":"#/components/schemas/CampaignStepNestedPublicV1Input"}},"holidayIds":{"description":"Holiday ids to attach. Full-replace of the campaign's holiday set.","type":"array","items":{"type":"string","format":"uuid"}},"isDraft":{"type":"boolean","description":"DEPRECATED — set `status: \"paused\"` to publish instead. Setting `isDraft: false` still works (triggers strict validation; `422` on failure). Setting `true` once published is rejected.","deprecated":true},"status":{"type":"string","description":"Lifecycle transition. Use `paused` to pause an active campaign or `active` to resume a paused one (must already be published). Other values rejected.","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"]},"mailboxSelection":{"description":"Mailbox selection (replace semantics). Provided block replaces `campaign_accounts` for this campaign wholesale.","allOf":[{"$ref":"#/components/schemas/MailboxSelectionCommonInput"}]},"listSelection":{"description":"List selection (replace semantics). Provided block replaces `campaign_lists` for this campaign wholesale.","allOf":[{"$ref":"#/components/schemas/ListSelectionCommonInput"}]},"allowLeadsInMultiple":{"type":"boolean","description":"Per-operation enrolment intent (NOT stored on the campaign). Only consulted when this update triggers an enrolment pass (publish, or a `listSelection` change on a non-draft campaign). When `false` (default), conflicting leads are skipped; when `true`, all resolved leads are enrolled regardless of overlap."}}},"SequenceDto":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"accessRoles":{"type":"array","items":{"type":"string","enum":["OWNER","SUPER_ADMIN","SUPPORT","TEAM_MEMBER","CLIENT"]}},"status":{"type":"string","description":"Current status of the sequence.","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"],"example":"active"},"isDraft":{"type":"boolean","description":"DEPRECATED — mirror of `status === \"draft\"`. Use `status` going forward.","deprecated":true},"sendingStartTime":{"type":"string","example":"08:00"},"sendingEndTime":{"type":"string","example":"17:00"},"sendingDays":{"type":"array","items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"timezone":{"type":"string","example":"America/New_York"},"triggerLabelId":{"type":"string","description":"Label ID that triggers this sequence (if any).","example":"l3b12f1df-5232-4f77-a0f1-21e7c8a3e5d2","nullable":true},"triggerDelayInMinutes":{"type":"number","description":"Delay before trigger is activated, in minutes.","example":30,"nullable":true},"teamId":{"type":"string","format":"uuid"},"workspaceId":{"type":"string","format":"uuid"},"statsTotalLeads":{"type":"number","description":"Total number of leads added to the sequence.","example":120},"statsActiveLeads":{"type":"number","description":"Number of leads currently active in the sequence.","example":45},"statsCompletedLeads":{"type":"number","description":"Number of leads who have completed the sequence.","example":60},"statsCompletedLeadsWithReply":{"type":"number","description":"Number of leads who have completed the sequence with a reply.","example":60},"statsReplyRate":{"type":"number","description":"Reply rate as a percentage (e.g., 25 for 25%).","example":25.5},"triggerLabel":{"description":"Sending trigger for the sequence.","allOf":[{"$ref":"#/components/schemas/ThreadLabelDto"}]},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","name","status","teamId","workspaceId","statsTotalLeads","statsActiveLeads","statsCompletedLeads","statsCompletedLeadsWithReply","statsReplyRate","triggerLabel","createdAt","updatedAt"]},"CampaignStepPublicV1Input":{"type":"object","properties":{"id":{"type":"string","description":"Step id when updating an existing step (preserves stats). Omit to insert a new step.","format":"uuid"},"order":{"type":"number","description":"Position of the step within the campaign. Legacy data is 0-based (first step has `order = 0`); new campaigns may use either convention — the scheduler resolves the entry-point job to the lowest-order step.","example":0},"delayValue":{"type":"number","description":"Delay before sending this step relative to the previous step.","example":2},"delayUnit":{"type":"string","description":"Delay unit.","enum":["DAY","WEEK","MONTH"],"example":"DAY"},"sendAsNewThread":{"type":"boolean","description":"Whether to send this step in a brand-new email thread instead of replying on the existing one.","default":false},"emailName":{"type":"string","description":"Deprecated — retained only for backward compatibility. Step names are managed internally and this value is not part of the current public contract.","nullable":true,"deprecated":true},"emailContent":{"type":"string","description":"Deprecated — retained only for backward compatibility. Set step bodies via the /v1/campaign-steps/:stepId/variants endpoints instead.","deprecated":true}},"required":["order"]},"CreateCampaignStepsPublicV1Input":{"type":"object","properties":{"campaignId":{"type":"string","description":"Campaign (sequence) id to add steps to.","format":"uuid"},"steps":{"description":"Steps to create. Each step must include at least `order`. Step bodies are set via the /v1/campaign-steps/:stepId/variants endpoints — inline `variants` are not accepted here.","type":"array","items":{"$ref":"#/components/schemas/CampaignStepPublicV1Input"}}},"required":["campaignId","steps"]},"SequenceStepDto":{"type":"object","properties":{"id":{"type":"string"},"order":{"type":"number","example":1,"description":"Step order in the sequence, must be unique per sequence"},"emailName":{"type":"string","example":"Email 1","description":"Name of the email"},"emailContent":{"type":"string","example":"Hello {{FIRST_NAME}}, thanks for joining!","description":"Body content of the email, supports templating variables"},"delayValue":{"type":"number","description":"The numeric value of the delay before the action is triggered. For example, \"3\" with a unit of \"DAY\" means a delay of 3 days.","example":3},"delayUnit":{"type":"string","description":"The unit of time used for the delay (e.g., DAY, WEEK, MONTH).","enum":["DAY","WEEK","MONTH"],"example":"DAY"},"emailAttachments":{"type":"array","items":{"$ref":"#/components/schemas/EmailAttachmentDto"}},"sequenceId":{"type":"string","example":"c50416b8-5f0f-4d58-b7c5-7e0f4f65f672","description":"ID of the parent sequence this step belongs to"},"statsEmailsSent":{"type":"number","description":"Total number of emails that have been sent in the sequence.","example":120,"default":0},"statsEmailsReplied":{"type":"number","description":"Total number of emails that have received replies.","example":45,"default":0},"statsEmailsScheduled":{"type":"number","description":"Total number of emails scheduled to be sent.","example":30,"default":0},"statsReplyRate":{"type":"number","description":"Reply rate as a percentage (e.g., 25 for 25%).","example":25.5},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","order","emailName","emailContent","emailAttachments","sequenceId","statsEmailsSent","statsEmailsReplied","statsEmailsScheduled","statsReplyRate","createdAt","updatedAt"]},"UpdateCampaignStepsPublicV1Input":{"type":"object","properties":{"campaignId":{"type":"string","description":"Campaign (sequence) id whose steps are being replaced.","format":"uuid"},"steps":{"description":"Complete list of steps (full replacement). Steps with `id` are updated in-place; steps without `id` are inserted; existing steps not present are deleted. Inline `variants` are not accepted here — use the /variants endpoints instead.","type":"array","items":{"$ref":"#/components/schemas/CampaignStepPublicV1Input"}}},"required":["campaignId","steps"]},"UpdateVariantPublicV1Input":{"type":"object","properties":{"body":{"type":"string","description":"New HTML body. Omit to leave unchanged.","example":"<p>Updated copy with new CTA...</p>"},"subject":{"type":"string","description":"New subject line. Omit to leave unchanged.","example":"Quick question about your team","maxLength":2000},"isActive":{"type":"boolean","description":"Toggle active status. Omit to leave unchanged.","example":false}}},"ToggleVariantInput":{"type":"object","properties":{"isActive":{"type":"boolean","description":"Target active state. `true` makes the variant eligible for new sends; `false` keeps stats but stops new traffic.","example":true}},"required":["isActive"]},"CreateVariantPublicV1Input":{"type":"object","properties":{"body":{"type":"string","description":"HTML body of the email.","example":"<p>Hi {{firstName}}, just checking in...</p>"},"subject":{"type":"string","description":"Email subject. Omit to inherit from step or thread context.","example":"Following up on our last conversation","maxLength":2000},"isActive":{"type":"boolean","description":"Whether the variant is eligible to receive new traffic. Defaults to `true`.","example":true}},"required":["body"]},"PreviewCampaignLeadsPublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace whose lists / campaigns to check against.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"listSelection":{"description":"Same shape used in campaign create/update. Either explicit `listIds` or a `criteria` query the server resolves via the CRM service.","allOf":[{"$ref":"#/components/schemas/ListSelectionCommonInput"}]},"excludeCampaignId":{"type":"string","description":"When previewing for an existing campaign edit, pass its id so its own enrolled leads are not counted as conflicts against itself. Omit on create.","example":"d1e2f3a4-b5c6-7890-abcd-ef1234567890"},"allowLeadsInMultiple":{"type":"boolean","description":"Caller's enrolment intent. When `true`, `blockedLeadCount` is `0` and `eligibleLeadCount === totalUniqueLeads` (overlap is explicitly allowed). When `false` (default), leads already enrolled in another non-terminal campaign in this workspace are counted as blocked.","default":false}},"required":["workspaceId","listSelection"]},"PreviewCampaignLeadsResultDto":{"type":"object","properties":{"totalUniqueLeads":{"type":"number","description":"Distinct lead count behind the resolved list set, before exclusivity filtering. Reflects what the user picked, not what would be enrolled.","example":1248},"blockedLeadCount":{"type":"number","description":"How many of `totalUniqueLeads` are currently enrolled in another non-terminal campaign in this workspace and would be skipped at enrol time *if* the operation is submitted with `allowLeadsInMultiple = false`. Always `0` when the request set `allowLeadsInMultiple = true`. `excludeCampaignId` (when provided) opts that campaign out of the conflict check.","example":37},"eligibleLeadCount":{"type":"number","description":"`totalUniqueLeads - blockedLeadCount`. The headline number for the campaign-create review step.","example":1211},"eligibilityCheckSkipped":{"type":"boolean","description":"Set to `true` when the workspace has too many active enrolments to compute the blocked count cheaply; in that case `blockedLeadCount` is `0` and `eligibleLeadCount === totalUniqueLeads`. The enrol-time skip remains the safety net.","example":false}},"required":["totalUniqueLeads","blockedLeadCount","eligibleLeadCount"]},"TagRefDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string","example":"VIP"},"type":{"type":"string","enum":["system","user"],"example":"user"}},"required":["id","name","type"]},"SequenceProgressDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"sequenceId":{"type":"string","format":"uuid"},"threadId":{"type":"string","format":"uuid","nullable":true},"contactId":{"type":"string","format":"uuid","nullable":true},"leadId":{"type":"string","format":"uuid","nullable":true},"leadEmail":{"type":"string","nullable":true},"leadName":{"type":"string","nullable":true},"assignedAccountId":{"type":"string","format":"uuid","nullable":true},"nextSendAt":{"format":"date-time","type":"string","description":"Next scheduled send moment for this lead. Mirrors what Bull will fire; null if paused, completed, or otherwise not scheduled.","nullable":true},"currentStepOrder":{"type":"number","description":"Order of the step whose Bull job is currently delayed or just sent for this lead.","nullable":true},"status":{"type":"string","enum":["pending","in_progress","paused","completed_replied","completed_sent","cancelled","failed","bounced"]},"companyId":{"type":"string","description":"CRM company UUID, denormalized at enrolment.","format":"uuid","nullable":true},"companyName":{"type":"string","description":"CRM company name, denormalized at enrolment.","nullable":true},"tagIds":{"description":"CRM tag UUIDs assigned to the lead, denormalized at enrolment.","type":"array","items":{"type":"string","format":"uuid"}},"tags":{"description":"Hydrated `tagIds` (id + name) for UI rendering. Populated by `GET /campaigns/:id/progresses`; omitted by RPC callers that work off `tagIds` directly.","type":"array","items":{"$ref":"#/components/schemas/TagRefDto"}},"replyType":{"type":"string","enum":["none","auto","positive","negative","neutral","unclassified"],"description":"Dominant reply classification on the lead's campaign thread. Recompute precedence: POSITIVE > NEGATIVE > NEUTRAL > UNCLASSIFIED > AUTO > NONE."},"sentCount":{"type":"number","description":"Successful sends to this lead in this campaign. Excludes bounces and setup failures.","minimum":0},"repliesCount":{"type":"number","description":"All inbound messages received from the lead on this campaign's thread.","minimum":0},"humanRepliesCount":{"type":"number","description":"Inbound replies that do NOT match auto-reply or OOO label names. `repliesCount - humanRepliesCount` ≈ auto/OOO noise.","minimum":0},"positiveRepliesCount":{"type":"number","description":"Inbound replies that landed on a thread carrying a POSITIVE-sentiment label.","minimum":0},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"sequence":{"description":"Populated only when the relation is loaded.","allOf":[{"$ref":"#/components/schemas/SequenceDto"}]}},"required":["id","sequenceId","status","tagIds","replyType","sentCount","repliesCount","humanRepliesCount","positiveRepliesCount","createdAt","updatedAt"]},"AddListsPublicV1Input":{"type":"object","properties":{"listSelection":{"description":"Same `listSelection` shape used by `POST /campaigns/lists-eligibility` and `PATCH /campaigns/:id`. Resolved server-side to a concrete set of list ids; only the lists not already attached to the campaign are appended (no replace).","allOf":[{"$ref":"#/components/schemas/ListSelectionCommonInput"}]},"allowLeadsInMultiple":{"type":"boolean","description":"Per-operation enrolment intent for this append (NOT stored). When `false` (default), leads already enrolled in another non-terminal campaign in this workspace are skipped. When `true`, every lead behind the newly added lists is enrolled regardless of overlap.","default":false}},"required":["listSelection"]},"AddListsToCampaignResultDto":{"type":"object","properties":{"addedListIds":{"description":"Lists actually attached by this request (selection minus already-attached). Empty when every requested list was already on the campaign.","type":"array","items":{"type":"string","format":"uuid"}},"enrolledCount":{"type":"number","description":"Leads enrolled into the campaign as PENDING `sequence_progress` rows. Excludes leads already enrolled in this campaign and leads filtered out by the cross-campaign uniqueness rule.","example":1240},"skippedLeads":{"description":"Leads excluded by the cross-campaign uniqueness rule. Empty when no conflicts existed.","type":"array","items":{"$ref":"#/components/schemas/CampaignSkippedLeadDto"}}},"required":["addedListIds","enrolledCount","skippedLeads"]},"AddLeadsByIdsPublicV1Input":{"type":"object","properties":{"leadIds":{"type":"array","items":{"type":"string","format":"uuid"}},"sourceThreadId":{"type":"string","description":"OOO source thread to detach from its original campaign after enrolment.","format":"uuid"},"allowLeadsInMultiple":{"type":"boolean","default":false}},"required":["leadIds"]},"CampaignProgressSelectionCriteriaCommonInput":{"type":"object","properties":{"status":{"type":"array","description":"OR-match on sequence_progress.status.","items":{"type":"string","enum":["pending","in_progress","paused","completed_replied","completed_sent","cancelled","failed","bounced"]}},"replyType":{"type":"array","description":"OR-match on the lead's first-reply classification.","items":{"type":"string","enum":["none","auto","positive","negative","neutral","unclassified"]}},"tagIds":{"description":"OR-match: row matches if its denormalized `tag_ids` overlaps the listed tags.","type":"array","items":{"type":"string","format":"uuid"}},"leadEmail":{"type":"string","format":"email"},"search":{"type":"string","description":"Case-insensitive substring match across lead name, company name, and lead email."},"excludeProgressIds":{"description":"\"Select all except these\" — sequence_progress IDs to drop from the criteria match.","type":"array","items":{"type":"string","format":"uuid"}}}},"CampaignProgressSelectionCommonInput":{"type":"object","properties":{"selectionType":{"type":"string","enum":["ids","criteria"],"description":"How progresses are selected. `ids` — explicit `progressIds`. `criteria` — server-side filter resolved against `sequence_progress`."},"progressIds":{"description":"Required when `selectionType = \"ids\"`. `sequence_progress.id` values.","type":"array","items":{"type":"string","format":"uuid"}},"criteria":{"description":"Required when `selectionType = \"criteria\"`.","allOf":[{"$ref":"#/components/schemas/CampaignProgressSelectionCriteriaCommonInput"}]}},"required":["selectionType"]},"RemoveLeadsPublicV1Input":{"type":"object","properties":{"selection":{"description":"Selection of enrolled progresses to cancel. Either explicit `progressIds` (`sequence_progress.id`) or a `criteria` filter mirroring `GET /campaigns/:id/leads` (status, replyType, tagIds, leadEmail, search, excludeProgressIds).","allOf":[{"$ref":"#/components/schemas/CampaignProgressSelectionCommonInput"}]}},"required":["selection"]},"RemoveLeadsFromCampaignResultDto":{"type":"object","properties":{"cancelledCount":{"type":"number","description":"`sequence_progress` rows flipped to CANCELLED. Excludes rows already in a terminal state (COMPLETED_*, CANCELLED, FAILED) and leads that had no row on this campaign.","example":42},"cancelledScheduledJobs":{"type":"number","description":"Bull scheduled-email jobs removed during cleanup — `<sequenceId>:<leadId>:<currentStepOrder>` for COLD/EVERGREEN, or one per scheduled `email_messages` row for SUB_SEQUENCE.","example":42},"deletedScheduledMessages":{"type":"number","description":"Scheduled `email_messages` rows hard-deleted during cleanup. Always `0` for COLD/EVERGREEN (no DB rows exist for unsent COLD/EVERGREEN sends).","example":38}},"required":["cancelledCount","cancelledScheduledJobs","deletedScheduledMessages"]},"CampaignMailboxDto":{"type":"object","properties":{"id":{"type":"string","description":"Synthetic per-row identifier (`<campaignId>:<accountId>`). Stable, globally unique across campaigns — intended as the FE row key. Not a DB primary key; do not use in routes."},"accountId":{"type":"string","format":"uuid"},"email":{"type":"string","nullable":true},"firstName":{"type":"string","nullable":true},"lastName":{"type":"string","nullable":true},"type":{"type":"string","description":"Provider type — `GOOGLE_GMAIL` / `MICROSOFT_OUTLOOK` / `IMAP_SMTP`.","nullable":true},"currentConnectionStatus":{"type":"string","description":"Connection status from accounts service (`CONNECTED` / `DISCONNECTED` / `INITIALIZING` / `GATHERING` / `RECONNECTING` / `DELETING`).","nullable":true},"sends":{"type":"number","description":"Messages dispatched by this mailbox in this campaign (per-message — a lead receiving 3 steps contributes 3 sends).","minimum":0},"totalReplies":{"type":"number","description":"Distinct leads that replied at least once on threads assigned to this mailbox (per-lead, capped at 1). Frozen on lead-completion: a late inbound on a completed/cancelled/failed/bounced lead does not change this counter (only label changes can revise after completion).","minimum":0},"humanReplies":{"type":"number","description":"Distinct leads whose first reply was not classified as auto-reply / OOO (per-lead, capped at 1).","minimum":0},"replyRate":{"type":"number","description":"(totalReplies / sends) * 100. Returned as a percentage 0..100. 0 when sends is 0. Bounded by leads/sends — typically <100% for multi-step campaigns, which is the standard cold-outreach reply rate.","minimum":0,"maximum":100},"positiveReplies":{"type":"number","description":"Distinct leads whose first reply was classified positive (per-lead, capped at 1).","minimum":0},"bounces":{"type":"number","description":"Distinct leads that bounced on this mailbox (per-lead, capped at 1 — one bounce terminates the lead's sequence progress).","minimum":0},"bounceRate":{"type":"number","description":"(bounces / sends) * 100. Returned as a percentage 0..100. 0 when sends is 0.","minimum":0,"maximum":100},"dailyCapacity":{"type":"number","description":"Effective per-day campaign send cap for this mailbox in this campaign — the mailbox's own `account.campaignDailyLimit`. `null` = unlimited. Warmup capacity is excluded.","nullable":true,"example":50},"dailyCapacityUsed":{"type":"number","description":"Mailbox's sends so far today (in the campaign timezone) counted toward its daily cap — the real-time value the send gate checks against `dailyCapacity`. Pair with `dailyCapacity` to render `used/cap` (e.g. 3/10). `null` only when the live counter could not be read; the FE then falls back to showing just `dailyCapacity`.","nullable":true,"minimum":0,"example":3},"pausedAt":{"type":"string","description":"ISO timestamp at which this mailbox was paused for this campaign only. `null` = active. Paused mailboxes are skipped by the send pipeline and visually de-emphasized in the FE.","nullable":true,"example":"2026-05-17T12:00:00.000Z"}},"required":["id","accountId","sends","totalReplies","humanReplies","replyRate","positiveReplies","bounces","bounceRate"]},"AttachCampaignMailboxesPublicV1Input":{"type":"object","properties":{"mailboxSelection":{"description":"Same `mailboxSelection` shape used by `POST /campaigns` and `PATCH /campaigns/:id`. Resolved server-side to a concrete account set; only the accounts not already attached to the campaign are inserted (no replace, no detach).","allOf":[{"$ref":"#/components/schemas/MailboxSelectionCommonInput"}]}},"required":["mailboxSelection"]},"AttachCampaignMailboxesResultDto":{"type":"object","properties":{"requested":{"type":"number","description":"Number of accounts the selection resolved to (after dedup, before diffing against existing `campaign_accounts`).","example":12},"attachedAccountIds":{"description":"Accounts inserted into `campaign_accounts` by this request (selection minus already-attached). Empty when every requested account was already on the campaign.","type":"array","items":{"type":"string","format":"uuid"}},"alreadyAttached":{"type":"number","description":"Accounts skipped because they were already attached to this campaign. Pre-existing per-(campaign, mailbox) state (`paused_at`, `daily_send_limit`, counters) is preserved.","example":3}},"required":["requested","attachedAccountIds","alreadyAttached"]},"CampaignMailboxSelectionCriteriaCommonInput":{"type":"object","properties":{"search":{"type":"string","description":"Case-insensitive substring match on mailbox email / firstName / lastName. Resolved via the accounts service before the campaign_accounts query."},"connectionStatus":{"type":"string","enum":["INITIALIZING","CONNECTED","DISCONNECTED","GATHERING","RECONNECTING","DELETING"],"description":"Restrict to mailboxes with this connection status."},"minBounceRate":{"type":"number","description":"Strict lower bound on the mailbox bounce rate as a percentage 0..100. Only mailboxes with `sent > 0` match. Combine multiple chips by sending the minimum threshold (looser bound subsumes the stricter).","minimum":0,"maximum":100},"maxReplyRate":{"type":"number","description":"Strict upper bound on the mailbox human reply rate as a percentage 0..100. Only mailboxes with `sent > 0` match. Combine multiple chips by sending the maximum threshold (looser bound subsumes the stricter).","minimum":0,"maximum":100},"domain":{"description":"Restrict to mailboxes whose email domain matches one of these. Resolved via accounts hydration.","type":"array","items":{"type":"string"}},"providerType":{"description":"Restrict to mailboxes of these provider types (e.g. `GOOGLE_GMAIL`, `MICROSOFT_OUTLOOK`, `IMAP_SMTP`). Resolved via accounts hydration.","type":"array","items":{"type":"string"}},"excludeAccountIds":{"description":"\"Select all matching except these\" — account UUIDs to subtract from the criteria match.","type":"array","items":{"type":"string"}}}},"CampaignMailboxSelectionCommonInput":{"type":"object","properties":{"selectionType":{"type":"string","enum":["ids","criteria"],"description":"How mailboxes are selected. `ids` — explicit `accountIds`. `criteria` — server-side filter mirroring `GET /campaigns/:id/mailboxes` resolved against `campaign_accounts`."},"accountIds":{"description":"Required when `selectionType = \"ids\"`. Account UUIDs (from `campaign_accounts.account_id`). UUIDs not attached to this campaign are silently dropped.","type":"array","items":{"type":"string","format":"uuid"}},"criteria":{"description":"Required when `selectionType = \"criteria\"`.","allOf":[{"$ref":"#/components/schemas/CampaignMailboxSelectionCriteriaCommonInput"}]}},"required":["selectionType"]},"BulkDetachCampaignMailboxesPublicV1Input":{"type":"object","properties":{"selection":{"description":"Selection of attached mailboxes to detach (DELETE the `campaign_accounts` row). Same shape as bulk-pause.","allOf":[{"$ref":"#/components/schemas/CampaignMailboxSelectionCommonInput"}]}},"required":["selection"]},"BulkDetachCampaignMailboxesResultDto":{"type":"object","properties":{"requested":{"type":"number","minimum":0},"detached":{"type":"number","minimum":0},"attempted":{"type":"number","minimum":0},"reassigned":{"type":"number","minimum":0},"noPeer":{"type":"number","minimum":0},"lostRace":{"type":"number","minimum":0}},"required":["requested","detached","attempted","reassigned","noPeer","lostRace"]},"BulkPauseCampaignMailboxesResultDto":{"type":"object","properties":{"requested":{"type":"number","minimum":0},"paused":{"type":"number","minimum":0},"alreadyPaused":{"type":"number","minimum":0},"attempted":{"type":"number","minimum":0},"reassigned":{"type":"number","minimum":0},"noPeer":{"type":"number","minimum":0},"lostRace":{"type":"number","minimum":0}},"required":["requested","paused","alreadyPaused","attempted","reassigned","noPeer","lostRace"]},"BulkResumeCampaignMailboxesResultDto":{"type":"object","properties":{"requested":{"type":"number","minimum":0},"resumed":{"type":"number","minimum":0},"alreadyActive":{"type":"number","minimum":0}},"required":["requested","resumed","alreadyActive"]},"CompanyDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique company identifier","format":"uuid"},"name":{"type":"string","description":"Company name","nullable":true,"example":"Acme Inc"},"domain":{"type":"string","description":"Company domain","example":"acme.com"},"logo":{"type":"string","description":"Company logo URL","nullable":true,"example":"https://cdn.acme.com/logo.png"},"websiteUrl":{"type":"string","description":"Company website URL","nullable":true,"example":"https://acme.com"},"officePhoneNumber":{"type":"string","description":"Company office phone number","nullable":true,"example":"+49 89 123456"},"customVariables":{"type":"object","description":"Custom variables mapped by customVariableId → value","example":{"cvar-uuid-1":"google","cvar-uuid-2":42},"additionalProperties":true},"workspaceId":{"type":"string","description":"Workspace identifier","format":"uuid"},"teamId":{"type":"string","description":"Team identifier","format":"uuid"},"createdAt":{"format":"date-time","type":"string","description":"Date when the company was created","example":"2026-01-05T10:01:00.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"Date when the company was last updated","example":"2026-01-14T16:45:12.000Z"}},"required":["id","name","domain","logo","websiteUrl","officePhoneNumber","customVariables","workspaceId","teamId","createdAt","updatedAt"]},"CreateCompanyPublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb","description":"Workspace ID the company belongs to"},"name":{"type":"string","example":"OpenAI","description":"Company name"},"domain":{"type":"string","example":"openai.com","description":"Company domain"},"officePhoneNumber":{"type":"string","example":"+1-555-123-4567","description":"Company office phone number"},"customVariables":{"type":"object","description":"Custom variables values mapped by customVariableId. Keys must be valid CustomVariable IDs for this workspace and entity type.","example":{"c1a2b3d4-1111-2222-3333-444455556666":"google","a9f8e7d6-aaaa-bbbb-cccc-ddddeeeeffff":"saas","123e4567-e89b-12d3-a456-426614174000":42}}},"required":["workspaceId","name","domain"]},"UpdateCompanyCommonInput":{"type":"object","properties":{"name":{"type":"string","description":"Company name","example":"Acme Inc."},"domain":{"type":"string","description":"Company domain (primary domain name)","example":"acme.com"},"websiteUrl":{"type":"string","description":"Company website URL","example":"https://acme.com"},"officePhoneNumber":{"type":"string","description":"Office phone number","example":"+1 415 555 9876"},"customVariables":{"type":"object","description":"Custom variables mapped by customVariableId → value. Keys must be valid CustomVariable IDs for this workspace and entity type.","example":{"e12a4567-aaaa-bbbb-cccc-123456789000":"Enterprise","f98b7654-1111-2222-3333-444455556666":250}}}},"TagDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique tag identifier","format":"uuid"},"name":{"type":"string","description":"Tag name (max 20 characters)","example":"VIP","maxLength":20},"type":{"type":"string","description":"Tag type (system tags cannot be deleted)","enum":["system","user"],"example":"user"},"workspaceId":{"type":"string","description":"Workspace identifier","format":"uuid"},"teamId":{"type":"string","description":"Team identifier","format":"uuid"},"createdAt":{"format":"date-time","type":"string","description":"Date when the tag was created","example":"2026-01-10T14:22:31.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"Date when the tag was last updated","example":"2026-01-12T09:11:03.000Z"}},"required":["id","name","type","workspaceId","teamId","createdAt","updatedAt"]},"ListDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique list identifier","format":"uuid"},"name":{"type":"string","description":"List name","example":"Hot Leads"},"workspaceId":{"type":"string","description":"Workspace identifier","format":"uuid"},"teamId":{"type":"string","description":"Team identifier","format":"uuid"},"createdAt":{"format":"date-time","type":"string","description":"Date when the list was created","example":"2026-01-10T14:22:31.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"Date when the list was last updated","example":"2026-01-12T09:11:03.000Z"},"leadCount":{"type":"number","description":"Number of leads in the list","example":42}},"required":["id","name","workspaceId","teamId","createdAt","updatedAt"]},"LeadDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique lead identifier","format":"uuid"},"name":{"type":"string","description":"Lead full name (deprecated, use firstName/lastName)","nullable":true,"example":"John Doe"},"firstName":{"type":"string","description":"Lead first name","nullable":true,"example":"John"},"lastName":{"type":"string","description":"Lead last name","nullable":true,"example":"Doe"},"email":{"type":"string","description":"Lead email address","example":"john.doe@example.com","nullable":true},"linkedinProfileUrl":{"type":"string","description":"LinkedIn profile URL","example":"https://www.linkedin.com/in/johndoe","nullable":true},"jobTitle":{"type":"string","description":"Lead job title","nullable":true,"example":"QA Engineer"},"phoneNumber":{"type":"string","description":"Lead phone number","nullable":true,"example":"+1 415 555 2671"},"customVariables":{"type":"object","description":"Custom variables mapped by customVariableId → value","example":{"cvar-uuid-1":"google","cvar-uuid-2":42},"additionalProperties":true},"workspaceId":{"type":"string","description":"Workspace identifier","format":"uuid"},"teamId":{"type":"string","description":"Team identifier","format":"uuid"},"companyId":{"type":"string","description":"Associated company identifier","format":"uuid","nullable":true},"createdAt":{"format":"date-time","type":"string","description":"Date when the lead was created","example":"2026-01-10T14:22:31.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"Date when the lead was last updated","example":"2026-01-12T09:11:03.000Z"},"campaignStatus":{"type":"string","description":"Campaign status of the lead","enum":["active","completed","not_contacted"],"example":"not_contacted"},"company":{"description":"Associated company","allOf":[{"$ref":"#/components/schemas/CompanyDto"}]},"tags":{"description":"Tags assigned to this lead","type":"array","items":{"$ref":"#/components/schemas/TagDto"}},"lists":{"description":"Lists this lead belongs to","type":"array","items":{"$ref":"#/components/schemas/ListDto"}}},"required":["id","name","firstName","lastName","email","linkedinProfileUrl","jobTitle","phoneNumber","customVariables","workspaceId","teamId","companyId","createdAt","updatedAt","campaignStatus"]},"LeadImportErrorDto":{"type":"object","properties":{"row":{"type":"number","example":1,"description":"1-indexed CSV data row (excluding header)"},"message":{"type":"string","example":"Public/disposable email domain is not allowed"}},"required":["row","message"]},"LeadImportDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"status":{"type":"string","enum":["queued","processing","completed","failed"],"example":"processing"},"filename":{"type":"string","example":"contacts-q4.csv","nullable":true},"totalRows":{"type":"number","example":10000},"processedRows":{"type":"number","example":3245},"createdCount":{"type":"number","example":2900},"updatedCount":{"type":"number","example":340},"failedCount":{"type":"number","example":5},"errors":{"type":"array","items":{"$ref":"#/components/schemas/LeadImportErrorDto"}},"createdCustomVariableIds":{"description":"IDs of custom variables that were auto-created during this import (from unrecognized CSV columns).","type":"array","items":{"type":"string"}},"listId":{"type":"string","format":"uuid","nullable":true,"description":"List the leads were assigned to, if any."},"tagIds":{"description":"Tags applied to all imported leads.","type":"array","items":{"type":"string"}},"createdById":{"type":"string","format":"uuid"},"createdByName":{"type":"string","example":"Diana Matvienko","nullable":true},"errorMessage":{"type":"string","description":"Whole-job failure reason (CSV could not be parsed, etc.). Only set when status = \"failed\".","nullable":true},"startedAt":{"format":"date-time","type":"string","nullable":true},"finishedAt":{"format":"date-time","type":"string","nullable":true},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","status","totalRows","processedRows","createdCount","updatedCount","failedCount","errors","createdCustomVariableIds","tagIds","createdById","createdAt","updatedAt"]},"ImportLeadsFromJsonPublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace ID the leads will belong to.","example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb"},"records":{"type":"array","description":"Array of raw records (key/value string pairs). Maximum 5,000 rows. Each record must contain at least one of: email, linkedinProfileUrl.","items":{"type":"object","additionalProperties":{"type":"string"}}},"mapping":{"type":"object","description":"Mapping of record keys to lead fields. If omitted, auto-detection is used. Must include an \"email\" target. Known targets: email, firstName, lastName, name, jobTitle, phoneNumber, linkedinProfileUrl, companyDomain, companyName. Unknown targets are treated as custom variable names.","additionalProperties":{"type":"string"},"example":{"Full Name":"name","Work Email":"email","Role":"jobTitle"}},"listId":{"type":"string","description":"List ID to assign all imported leads to (must belong to your workspace).","example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb"},"tagIds":{"description":"Tag IDs to assign to all imported leads (must belong to your workspace).","example":["c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb"],"type":"array","items":{"type":"string"}}},"required":["workspaceId","records"]},"CreateLeadPublicV1Input":{"type":"object","properties":{"workspaceId":{"type":"string","example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb","description":"Workspace ID the lead belongs to"},"companyId":{"type":"string","example":"c6b74d9e-4f4a-46e0-bb72-0b7d9d6f03bb","description":"Company to link the lead to (optional)."},"email":{"type":"string","example":"john.doe@example.com","description":"Lead email address (unique per company)"},"name":{"type":"string","example":"John Doe","description":"Lead full name"},"linkedinProfileUrl":{"type":"string","example":"https://www.linkedin.com/in/johndoe","description":"LinkedIn profile URL"},"jobTitle":{"type":"string","example":"Software Engineer","description":"Lead job title"},"phoneNumber":{"type":"string","example":"+1-555-123-4567","description":"Lead phone number"},"customVariables":{"type":"object","description":"Custom variables values mapped by customVariableId. Keys must be valid CustomVariable IDs for this workspace and entity type.","example":{"c1a2b3d4-1111-2222-3333-444455556666":"google","a9f8e7d6-aaaa-bbbb-cccc-ddddeeeeffff":"saas","123e4567-e89b-12d3-a456-426614174000":42}}},"required":["workspaceId","email","name"]},"UpdateLeadCommonInput":{"type":"object","properties":{"firstName":{"type":"string","description":"Lead first name","example":"John"},"lastName":{"type":"string","description":"Lead last name","example":"Doe"},"email":{"type":"string","description":"Lead email address","example":"john.doe@example.com"},"linkedinProfileUrl":{"type":"string","description":"LinkedIn profile URL","example":"https://www.linkedin.com/in/johndoe"},"phoneNumber":{"type":"string","description":"Lead phone number (E.164 or free-form string)","example":"+1 415 555 2671"},"customVariables":{"type":"object","description":"Custom variables values mapped by customVariableId. Keys must be valid CustomVariable IDs for this workspace and entity type.","example":{"c1a2b3d4-1111-2222-3333-444455556666":"google","a9f8e7d6-aaaa-bbbb-cccc-ddddeeeeffff":"saas","123e4567-e89b-12d3-a456-426614174000":42}}}},"CustomVariableDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique custom variable identifier","format":"uuid"},"name":{"type":"string","description":"Human-readable custom variable name","example":"Industry"},"assignedEntityType":{"type":"string","description":"Entity type this variable is assigned to","enum":["lead","company"],"example":"lead"},"workspaceId":{"type":"string","description":"Workspace identifier","format":"uuid"},"teamId":{"type":"string","description":"Team identifier","format":"uuid"},"createdAt":{"format":"date-time","type":"string","description":"Date when the custom variable was created","example":"2026-01-01T08:30:00.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"Date when the custom variable was last updated","example":"2026-01-13T12:20:45.000Z"}},"required":["id","name","assignedEntityType","workspaceId","teamId","createdAt","updatedAt"]},"CreateCustomVariableCommonInput":{"type":"object","properties":{"name":{"type":"string","description":"Human-readable name of the custom variable","example":"Industry"},"assignedEntityType":{"type":"string","description":"Entity type this custom variable belongs to","enum":["lead","company"],"example":"lead"},"workspaceId":{"type":"string","description":"Workspace ID this custom variable belongs to","format":"uuid"}},"required":["name","assignedEntityType","workspaceId"]},"CreateTagCommonInput":{"type":"object","properties":{"name":{"type":"string","example":"VIP","description":"Name of the tag (max 20 characters)","maxLength":20},"workspaceId":{"type":"string","example":"workspace_123","description":"Workspace ID the tag belongs to"}},"required":["name","workspaceId"]},"LeadSelectionCriteriaCommonInput":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace scope for the criteria query"},"search":{"type":"string","description":"Free-text search across name, email, company"},"listIds":{"description":"Filter by list IDs","type":"array","items":{"type":"string"}},"tagIds":{"description":"Filter by tag IDs","type":"array","items":{"type":"string"}},"campaignStatus":{"type":"string","description":"Campaign status filter"},"excludeLeadIds":{"description":"\"Select all except these\" — applied after the criteria match","type":"array","items":{"type":"string"}},"unassignedToLists":{"type":"boolean","description":"When true, restricts to leads not assigned to any list. false / omitted apply no list-assignment filter. Ignored when listIds is provided."}},"required":["workspaceId"]},"LeadSelectionCommonInput":{"type":"object","properties":{"selectionType":{"type":"string","enum":["ids","criteria"],"description":"How leads are selected. \"ids\" — explicit IDs in leadIds. \"criteria\" — server-side filter in criteria."},"leadIds":{"description":"Required when selectionType = \"ids\".","type":"array","items":{"type":"string"}},"criteria":{"description":"Required when selectionType = \"criteria\".","allOf":[{"$ref":"#/components/schemas/LeadSelectionCriteriaCommonInput"}]}},"required":["selectionType"]},"CreateListCommonInput":{"type":"object","properties":{"name":{"type":"string","example":"Hot Leads","description":"Name of the list"},"workspaceId":{"type":"string","example":"workspace_123","description":"Workspace ID the list belongs to"}},"required":["name","workspaceId"]},"UpdateListCommonInput":{"type":"object","properties":{"name":{"type":"string","example":"Hot Leads Updated","description":"New name for the list"}}},"ThreadReminderDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the reminder, in UUID format.","example":"9e8a574f-5589-4db4-b1b0-9e6cbd92457a"},"name":{"type":"string","description":"Optional name/title of the reminder.","example":"Follow up with client"},"dueAt":{"format":"date-time","type":"string","description":"The date when the reminder will be triggered.","example":"2025-03-20T10:00:00.000Z"},"threadId":{"type":"string","description":"The thread ID this reminder is linked to.","example":"c6f5a29c-3435-4c7e-bc4a-dfe45db99113"},"status":{"type":"string","enum":["inactive","active","completed"],"description":"Current status of the reminder (inactive, active, or completed).","example":"inactive"},"intent":{"type":"string","enum":["follow_up_after_send","follow_up_thread"],"description":"The intent/purpose of the reminder.","example":"follow_up_after_send"},"period":{"type":"number","description":"Time duration before the reminder is triggered.","example":2},"periodUnit":{"type":"string","enum":["DAY","WEEK","MONTH"],"description":"The time unit (DAY, WEEK, MONTH) for the period before the reminder.","example":"DAY"},"createdAt":{"format":"date-time","type":"string","description":"Date when the reminder was created","example":"2026-01-10T14:22:31.000Z"},"updatedAt":{"format":"date-time","type":"string","description":"Date when the reminder was last updated","example":"2026-01-12T09:11:03.000Z"}},"required":["id","dueAt","threadId","status","intent","period","periodUnit","createdAt","updatedAt"]},"ReminderIntentCommonEnum":{"type":"string","enum":["follow_up_after_send","follow_up_thread"],"description":"Specifies the intent or purpose of the reminder. Valid values: \"follow_up_after_send\" (remind to follow up after sending an email), \"follow_up_thread\" (remind to follow up on a thread)."},"CreateThreadReminderCommonInput":{"type":"object","properties":{"threadId":{"type":"string","description":"The ID (UUID) of the thread this reminder is linked to. This is a unique identifier of the thread.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"workspaceId":{"type":"string","description":"The workspace ID (UUID) where the thread belongs. This links the reminder to a specific workspace.","example":"b8a7a0be-dbe9-4e7b-b0f7-cf1c767b8a3c"},"dueAt":{"format":"date-time","type":"string","description":"The exact date and time when the reminder will be triggered.","example":"2025-03-15T10:00:00Z"},"period":{"type":"number","description":"The time duration before the reminder is triggered, measured in the unit defined by the periodUnit.","example":3},"periodUnit":{"type":"string","enum":["DAY","WEEK","MONTH"],"description":"Defines the time unit for the period before the reminder is triggered. Choose from DAY, WEEK, or MONTH.","example":"DAY"},"intent":{"description":"Specifies the intent or purpose of the reminder. Valid values: \"follow_up_after_send\" (remind to follow up after sending an email), \"follow_up_thread\" (remind to follow up on a thread).","examples":["follow_up_after_send","follow_up_thread"],"allOf":[{"$ref":"#/components/schemas/ReminderIntentCommonEnum"}]}},"required":["threadId","workspaceId","dueAt","intent"]},"WarmupTagDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the warmup tag in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"value":{"type":"string","description":"The value or name of the warmup tag.","example":"Important Tag"},"workspaceId":{"type":"string","description":"Unique identifier of the workspace associated with the warmup tag in UUID format.","example":"bf12ab4e-3c56-4a21-9a74-4b318d4e0348"},"createdAt":{"format":"date-time","type":"string","description":"The date and time when the warmup tag was created.","example":"2025-01-01T12:00:00Z"}},"required":["id","value","workspaceId","createdAt"]},"ThreadInfoDto":{"type":"object","properties":{"id":{"type":"string"},"accountId":{"type":"string","description":"The unique identifier of the account associated with the thread."},"threadId":{"type":"string","description":"The thread ID from the original mailbox or the ID of the first message in the thread (used for threading conversations)."},"fromEmail":{"type":"string","description":"The email address of the sender of the thread.","example":"sender@example.com"},"fromName":{"type":"string","description":"The name of the sender of the thread.","example":"John Doe"},"seen":{"type":"boolean","description":"Indicates whether the thread has been seen (read) by the user."},"hasDraft":{"type":"boolean","description":"Indicates whether there is a draft message in the thread."},"subject":{"type":"string","description":"The subject of the email thread."},"to":{"description":"An array of recipients for the thread, including their names and email addresses.","example":[{"name":"Jane Doe","address":"jane@example.com"},{"name":"Mark Smith","address":"mark@example.com"}],"type":"array","items":{"type":"string"}},"reminderStatus":{"type":"string","enum":["none","inactive","active"],"description":"Current status of the reminder (none, inactive or active).","example":"none"},"createdAt":{"format":"date-time","type":"string","description":"The date and time when the thread was created."},"date":{"format":"date-time","type":"string","description":"The date when the thread was created or the latest update occurred."},"lastSentDate":{"format":"date-time","type":"string","description":"The date and time of the last sent message in the thread, if applicable."},"lastReceivedDate":{"format":"date-time","type":"string","description":"The date and time of the last received message in the thread."},"status":{"type":"string","description":"The current status of the thread, if applicable.","enum":["NOT_INTERESTED","ACTIVE_OPPORTUNITY"]},"isDone":{"type":"boolean","description":"Indicates whether the thread is marked as \"done\" by the user."},"userFolder":{"type":"string","description":"The folder state for the current user (INBOX, DONE, TRASH). Only present for per-user folder queries.","enum":["INBOX","DONE","TRASH","DELETED","SENT"],"example":"INBOX"},"deletedAt":{"format":"date-time","type":"string","description":"The date and time when the thread was deleted, if applicable.","example":null},"labels":{"description":"An array of labels associated with the thread.","type":"array","items":{"$ref":"#/components/schemas/ThreadLabelDto"}},"warmupTagId":{"type":"string","description":"The ID of the warmup tag associated with the thread, if applicable."},"warmupTag":{"description":"Details about the warmup tag associated with the thread, if applicable.","allOf":[{"$ref":"#/components/schemas/WarmupTagDto"}]},"sequenceId":{"type":"string","description":"The ID of the sequence this message is associated with, if any.","example":"a1b2c3d4-e5f6-7890-1234-56789abcdef0"},"sequenceProgressStatus":{"type":"string","description":"The progress status of the sequence this message is associated with, if any.","example":"in_progress","enum":["pending","in_progress","paused","completed_replied","completed_sent","cancelled","failed","bounced"]},"sequenceType":{"type":"string","description":"The campaign type of the sequence this thread is associated with, if any.","example":"COLD","enum":["COLD","EVERGREEN","SUB_SEQUENCE"]},"contactId":{"type":"string","description":"The ID of the contact this message belongs to, if any.","example":"f0e1d2c3-b4a5-6789-0123-456789abcdef"},"assignedUserId":{"type":"string","description":"The ID of the user assigned to this thread.","example":"a1b2c3d4-e5f6-7890-1234-56789abcdef0"}},"required":["id","accountId","threadId","fromEmail","fromName","seen","hasDraft","subject","to","reminderStatus","createdAt","date","lastReceivedDate","isDone","labels"]},"EmailMessageDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the the message, in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"inReplyTo":{"type":"string","description":"The messageId of the email being replied to, from the original email system.","example":"<CAMcfhb4CQRCJ-NWG+Mss=Sihqj-vR_-OZjWBsBvYht3+p=p+Zg@mail.gmail.com>","nullable":true},"isForwarded":{"type":"boolean","description":"Indicates whether the message is a forwarded message. If true, the message was forwarded to other recipients.","example":false},"messageId":{"type":"string","description":"The unique message ID as provided by the original mailbox.","example":"<messageId@saiheyinc.com>"},"folderName":{"type":"string","enum":["INBOX","Sent","Spam","Draft"],"description":"The folder where the message is currently stored. Can be one of: INBOX, Sent, Draft, Spam.","example":"INBOX"},"fromName":{"type":"string","description":"The name of the sender as displayed in the email.","example":"John Doe"},"fromEmail":{"type":"string","description":"The email address of the sender.","example":"johndoe@example.com"},"content":{"type":"string","description":"The content of the email message. This includes the body text of the email.","example":"Hello, this is a sample email content."},"seen":{"type":"boolean","description":"Indicates if the email has been read.","example":true},"to":{"description":"An array of recipient objects, including their names and email addresses.","example":[{"name":"Jane Doe","address":"janedoe@example.com"}],"type":"array","items":{"type":"string"}},"cc":{"description":"An array of CC (carbon copy) recipients, including their names and email addresses.","example":[{"name":"Manager","address":"manager@example.com"}],"type":"array","items":{"type":"string"}},"bcc":{"description":"An array of BCC (blind carbon copy) recipients, including their names and email addresses.","example":[{"name":"Assistant","address":"assistant@example.com"}],"type":"array","items":{"type":"string"}},"subject":{"type":"string","description":"The subject line of the email message.","example":"Meeting Reminder"},"threadId":{"type":"string","description":"The ID of the thread that the message belongs to. This is used for grouping related messages together.","example":"28e3f53c-f48c-4ac5-b11c-189a5fbbc1e1"},"accountId":{"type":"string","description":"The account ID associated with the message. This identifies which email account the message belongs to.","example":"37d957c1-f120-410f-9f07-a5d879fa5f8b"},"date":{"format":"date-time","type":"string","description":"The date and time when the email message was sent.","example":"2025-03-05T13:40:33.000Z"},"sentByName":{"type":"string","description":"The name of the user or system that sent the message on behalf of the original sender.","example":"Assistant Bot"},"workspaceId":{"type":"string","description":"Workspace ID to which this email belongs.","example":"6f2e7d8b-438d-4b26-994f-7e13b6eae534"},"warmupTagId":{"type":"string","description":"Warmup tag ID assigned to this email.","example":"c8765432-21de-fedc-0987-6543210fedcb"},"attachments":{"description":"Array of file attachments in the email (optional).","example":[{"filename":"report.pdf","contentType":"application/pdf"},{"filename":"image.png","contentType":"image/png"}],"type":"array","items":{"type":"string"}}},"required":["id","messageId","folderName","fromEmail","seen","to","subject","accountId","date","workspaceId"]},"ThreadSearchResultDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the thread, in UUID format.","example":"1f684e24-ef21-4544-a4a9-c994e2a6d2cf"},"fromName":{"type":"string","description":"The name of the sender as displayed in the email.","example":"John Doe"},"fromEmail":{"type":"string","description":"The email address of the sender.","example":"johndoe@example.com"},"to":{"description":"An array of recipient objects, including their names and email addresses.","example":[{"name":"Jane Doe","address":"janedoe@example.com"}],"type":"array","items":{"type":"string"}},"subject":{"type":"string","description":"The subject line of the email message.","example":"Meeting Reminder"},"date":{"format":"date-time","type":"string","description":"The date and time when the email message was sent.","example":"2025-03-05T13:40:33.000Z"},"workspaceId":{"type":"string","description":"Unique identifier of the workspace to which this thread is assigned.","example":"8a19a199-e1b0-47ac-bd19-c3cf75bfa8e7"},"messages":{"description":"An array of messages associated with the thread.","type":"array","items":{"$ref":"#/components/schemas/EmailMessageDto"}}},"required":["id","fromEmail","to","subject","date","workspaceId","messages"]},"UpdateThreadsPublicV1Input":{"type":"object","properties":{"ids":{"description":"An array of thread IDs (UUID format) to update. Maximum 50 threads per request.","example":["fe5a9932-1079-4680-a997-e87db4dc3413","de3a5a31-4422-4e84-a618-32d5cfa48f5b"],"maxItems":50,"type":"array","items":{"type":"string"}},"folder":{"type":"string","description":"The folder to move the threads to. Use DONE to mark as complete, TRASH to delete, INBOX to restore.","example":"DONE","enum":["INBOX","DONE","TRASH","DELETED","SENT"]},"labelIds":{"description":"Array of label IDs (UUID format) to add to the threads. These labels will be associated with each thread.","example":["fe5a9932-1079-4680-a997-e87db4dc3413","d1234567-1234-1234-1234-123456789abc"],"type":"array","items":{"type":"string"}},"seen":{"type":"boolean","description":"Mark all threads as seen or unseen.","example":true},"assignedUserId":{"type":"string","description":"The ID of the user to assign to these threads. Set to null to unassign.","example":"a1b2c3d4-e5f6-7890-1234-56789abcdef0"}},"required":["ids"]},"UpdateThreadPublicV1Input":{"type":"object","properties":{"folder":{"type":"string","description":"The folder to move the thread to. Use DONE to mark as complete, TRASH to delete, INBOX to restore.","example":"DONE","enum":["INBOX","DONE","TRASH","DELETED","SENT"]},"isDone":{"type":"boolean","description":"Deprecated: Use folder field instead. Indicates if the thread is marked as \"done\".","example":true,"deprecated":true},"labelIds":{"description":"Array of label IDs (UUID format) to add to the thread. These labels will be associated with the thread, allowing for better organization and filtering.","example":["fe5a9932-1079-4680-a997-e87db4dc3413","d1234567-1234-1234-1234-123456789abc"],"type":"array","items":{"type":"string"}},"seen":{"type":"boolean","description":"Indicates whether the thread has been marked as seen by the user. If true, the thread will be marked as read.","example":false},"assignedUserId":{"type":"string","description":"The ID of the user assigned to this thread.","example":"a1b2c3d4-e5f6-7890-1234-56789abcdef0"}}},"SendEmailMessagePayloadPublicV1Input":{"type":"object","properties":{"accountId":{"type":"string","description":"The account ID associated with the email account from which the email is being sent.","example":"43b873a7-c12c-448b-b0bd-648c3a0f0b8a"},"to":{"type":"object","description":"List of recipient email addresses.","example":["recipient@example.com","Bob <bob@example.com>",{"name":"Helen","address":"hellen@gmail.com"}]},"cc":{"type":"object","description":"List of email addresses to receive a carbon copy (CC) of the email.","example":["recipient@example.com","Bob <bob@example.com>",{"name":"Helen","address":"hellen@gmail.com"}],"nullable":true},"bcc":{"type":"object","description":"List of email addresses to receive a blind carbon copy (BCC) of the email.","example":["recipient@example.com","Bob <bob@example.com>",{"name":"Helen","address":"hellen@gmail.com"}],"nullable":true},"subject":{"type":"string","description":"The subject line of the email.","example":"Holiday Schedule Reminder"},"html":{"type":"string","description":"HTML version of the email content. Required for Microsoft accounts (e.g., Outlook) to render properly. If not provided, the email may not display as expected.","example":"<p>Hello, this is an HTML email!</p>","nullable":true},"text":{"type":"string","description":"Plain-text version of the email content. For Gmail, while it may not be strictly required, it is important for accessibility, deliverability, and fallback support.","example":"Hello, this is a plain-text version of the email!","nullable":true},"prevHotHawkMessageId":{"type":"string","description":"The id of the previous email","example":"43b873a7-c12c-448b-b0bd-648c3a0f0b8a","nullable":true},"attachments":{"description":"An array of attachments to be included with the email. Each attachment can either be a custom object or a file uploaded using Multer.","nullable":true,"type":"array","items":{"type":"string"}}},"required":["accountId","to","subject","html"]},"CreateEmailMessageResponseDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the email message (UUID).","example":"fe5a9932-1079-4680-a997-e87db4dc3413"},"threadId":{"type":"string","description":"Unique identifier of the thread to which this message belongs (UUID).","example":"e8fd93f5-1f7a-4e48-b7f8-6d13cfe5d2af"},"accountId":{"type":"string","description":"The ID of the account that sent or received the email (UUID).","example":"43b873a7-c12c-448b-b0bd-648c3a0f0b8a"},"workspaceId":{"type":"string","description":"The workspace ID associated with the email message (UUID).","example":"fd39ddc4-ddb0-46f5-a504-1ef1576a3260"},"isForwarded":{"type":"boolean","description":"Indicates whether the message is a forwarded message.","example":true},"content":{"type":"string","description":"The content of the email message. Can be a string or null.","example":"<p>Hello, world!</p>","nullable":true},"fromName":{"type":"string","description":"The name of the sender of the email.","example":"John Doe"},"fromEmail":{"type":"string","description":"The email address of the sender.","example":"john.doe@example.com"},"to":{"description":"List of recipients (To) of the email.","example":[{"name":"Jane Doe","address":"jane.doe@example.com"}],"type":"array","items":{"type":"string"}},"cc":{"description":"List of CC recipients of the email. Can be null.","example":[{"name":"John Smith","address":"john.smith@example.com"}],"nullable":true,"type":"array","items":{"type":"string"}},"bcc":{"description":"List of BCC recipients of the email. Can be null.","example":[{"name":"Alice Johnson","address":"alice.johnson@example.com"}],"nullable":true,"type":"array","items":{"type":"string"}},"subject":{"type":"string","description":"The subject of the email.","example":"Meeting Reminder"},"date":{"format":"date-time","type":"string","description":"Date the email message was sent.","example":"2025-03-05T13:40:33.000Z"},"seen":{"type":"boolean","description":"Indicates if the email has been seen by the recipient.","example":false},"messageId":{"type":"string","description":"The message ID assigned by the mail server.","example":"<36d236ca-be75-4845-94bb-slw79-8a45670006d3@saiheyinc.com>"},"sentByName":{"type":"string","description":"Name of the user who sent the email on behalf of the account.","example":"John Admin"},"attachments":{"description":"List of attachments associated with the email, if any.","example":[{"filename":"report.pdf","contentType":"application/pdf"}],"nullable":true,"type":"array","items":{"type":"string"}},"inReplyTo":{"type":"string","description":"The message ID to which this email is a reply (if applicable).","example":"<36d236ca-be75-4845-94bb-slw79-8a45670006d3@saiheyinc.com>","nullable":true},"msInternetMessageId":{"type":"string","description":"Microsoft Internet Message ID, if applicable.","example":"<abc-123@example.com>","nullable":true},"folderName":{"type":"string","description":"The folder where the email is located (e.g., INBOX, Sent, Spam).","example":"INBOX"},"createdAt":{"format":"date-time","type":"string","description":"Date when the email was created in the system.","example":"2025-03-05T13:40:33.000Z"},"warmupTagId":{"type":"string","description":"The ID of the warmup tag associated with this email.","example":"c2d6bd3a-1db1-4b7e-8410-b4b1a6372a8e","nullable":true}},"required":["id","threadId","accountId","workspaceId","isForwarded","fromName","fromEmail","to","subject","date","seen","messageId","sentByName","folderName","createdAt"]},"SaveDraftPublicV1Input":{"type":"object","properties":{"accountId":{"type":"string","description":"The account ID associated with the email account from which the email is being sent.","example":"43b873a7-c12c-448b-b0bd-648c3a0f0b8a"},"to":{"type":"object","description":"List of recipient email addresses.","example":["recipient@example.com","Bob <bob@example.com>",{"name":"Helen","address":"hellen@gmail.com"}]},"cc":{"type":"object","description":"List of email addresses to receive a carbon copy (CC) of the email.","example":["recipient@example.com","Bob <bob@example.com>",{"name":"Helen","address":"hellen@gmail.com"}],"nullable":true},"bcc":{"type":"object","description":"List of email addresses to receive a blind carbon copy (BCC) of the email.","example":["recipient@example.com","Bob <bob@example.com>",{"name":"Helen","address":"hellen@gmail.com"}],"nullable":true},"subject":{"type":"string","description":"The subject line of the email.","example":"Holiday Schedule Reminder"},"html":{"type":"string","description":"HTML version of the email content. Required for Microsoft accounts (e.g., Outlook) to render properly. If not provided, the email may not display as expected.","example":"<p>Hello, this is an HTML email!</p>","nullable":true},"text":{"type":"string","description":"Plain-text version of the email content. For Gmail, while it may not be strictly required, it is important for accessibility, deliverability, and fallback support.","example":"Hello, this is a plain-text version of the email!","nullable":true},"prevHotHawkMessageId":{"type":"string","description":"The id of the previous email","example":"43b873a7-c12c-448b-b0bd-648c3a0f0b8a","nullable":true},"attachments":{"description":"An array of attachments to be included with the draft. Each attachment can either be a custom object or a file uploaded using Multer.","nullable":true,"type":"array","items":{"type":"string"}}},"required":["accountId","to","subject","html"]},"CreateStepInSequenceInput":{"type":"object","properties":{"emailName":{"type":"string","example":"Email 1","description":"Name of the email"},"order":{"type":"number","example":2,"description":"Order of the email"},"emailContent":{"type":"string","example":"Hello {{FIRST_NAME}}, thanks for joining!","description":"Body content of the email, supports templating variables"},"delayValue":{"type":"number","description":"Amount of delay before the action (optional).","example":5,"nullable":true},"delayUnit":{"type":"string","description":"Unit of time for the delay (e.g., days, weeks).","enum":["DAY","WEEK","MONTH"],"example":"DAY","nullable":true},"emailAttachments":{"type":"array","items":{"$ref":"#/components/schemas/EmailAttachmentDto"}}},"required":["emailName","order","emailContent"]},"CreateSequencePublicV1Input":{"type":"object","properties":{"name":{"type":"string"},"isActive":{"type":"boolean"},"isDraft":{"type":"boolean","description":"DEPRECATED — set `status: \"draft\"` instead. Mirror only.","deprecated":true},"sendingStartTime":{"type":"string","example":"08:00"},"sendingEndTime":{"type":"string","example":"17:00"},"sendingDays":{"type":"array","items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"timezone":{"type":"string","example":"America/New_York"},"workspaceId":{"type":"string","format":"uuid"},"triggerLabelId":{"type":"string","description":"Label ID that triggers this sequence (if any).","example":"l3b12f1df-5232-4f77-a0f1-21e7c8a3e5d2","nullable":true},"triggerDelayInMinutes":{"type":"number","description":"Delay before trigger is activated, in minutes.","example":30,"nullable":true},"steps":{"description":"Initial sequence steps to create with the sequence. Each step must have an `order` field. Can be added/modified later via sequence-steps endpoints.","type":"array","items":{"$ref":"#/components/schemas/CreateStepInSequenceInput"}}},"required":["name","workspaceId"]},"UpdateSequencePublicV1Input":{"type":"object","properties":{"name":{"type":"string"},"isDraft":{"type":"boolean","description":"DEPRECATED — use `status` instead. Setting `isDraft: false` still triggers activation for back-compat.","deprecated":true},"status":{"type":"string","description":"Sequence status","enum":["draft","active","paused","pausing","activating","disabled","completed","archived"],"example":"activating"},"sendingStartTime":{"type":"string","example":"08:00"},"sendingEndTime":{"type":"string","example":"17:00"},"sendingDays":{"type":"array","items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"timezone":{"type":"string","example":"America/New_York"},"triggerLabelId":{"type":"string","description":"Label ID that triggers this sequence (if any).","example":"l3b12f1df-5232-4f77-a0f1-21e7c8a3e5d2","nullable":true},"triggerDelayInMinutes":{"type":"number","description":"Delay before trigger is activated, in minutes.","example":30,"nullable":true}}},"SubscribeToSequencePublicV1Input":{"type":"object","properties":{"sequenceId":{"type":"string","description":"The sequence ID to subscribe the thread to","format":"uuid"},"threadId":{"type":"string","description":"The thread ID to subscribe to the sequence","format":"uuid"}},"required":["sequenceId","threadId"]},"SubscribeToSequenceResultDto":{"type":"object","properties":{"sequenceId":{"type":"string","description":"Sequence ID"},"sequenceName":{"type":"string","description":"Sequence name"},"threadId":{"type":"string","description":"Thread ID"},"threadSubject":{"type":"string","description":"Thread subject"},"leadEmail":{"type":"string","description":"Lead email address"}},"required":["sequenceId","sequenceName","threadId","threadSubject","leadEmail"]},"UnsubscribeFromSequencePublicV1Input":{"type":"object","properties":{"threadId":{"type":"string","description":"The thread ID to unsubscribe from its sequence","format":"uuid"}},"required":["threadId"]},"CreateSequenceStepsPublicV1Input":{"type":"object","properties":{"sequenceId":{"type":"string","description":"ID of the sequence to add steps to","format":"uuid"},"steps":{"description":"Steps to create. Each step must have `order`, `emailName`, and `emailContent`.","type":"array","items":{"$ref":"#/components/schemas/CreateStepInSequenceInput"}}},"required":["sequenceId","steps"]},"UpdateStepPublicV1Input":{"type":"object","properties":{"id":{"type":"string","description":"ID of existing step (omit to create new step)","format":"uuid"},"order":{"type":"number","example":1,"description":"Order/position of this step in the sequence (1-based, must be unique)"},"emailName":{"type":"string","example":"Follow-up Email","description":"Display name for this step"},"emailContent":{"type":"string","example":"Hi {{FIRST_NAME}}, just following up on my previous email...","description":"Email body content with optional template variables"},"delayValue":{"type":"number","example":3,"description":"Delay value before sending (relative to previous step)","minimum":0},"delayUnit":{"type":"string","enum":["DAY","WEEK","MONTH"],"example":"DAY","description":"Unit for delay (DAY, WEEK, MONTH)"}},"required":["order","emailName","emailContent"]},"UpdateSequenceStepsPublicV1Input":{"type":"object","properties":{"sequenceId":{"type":"string","description":"ID of the sequence to update steps for","format":"uuid"},"steps":{"description":"Complete list of steps for the sequence (full replacement)","type":"array","items":{"$ref":"#/components/schemas/UpdateStepPublicV1Input"}}},"required":["sequenceId","steps"]},"BlocklistEntryDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the blocklist entry"},"workspaceId":{"type":"string","description":"Workspace ID"},"type":{"type":"string","description":"Entry type","enum":["EMAIL","DOMAIN"]},"value":{"type":"string","description":"Email address or domain"},"source":{"type":"string","description":"Source of the entry","enum":["HOTHAWK","EMAIL_BISON","CLIENT_BOX"]},"addedByName":{"type":"string","description":"Name of user who added the entry"},"addedByUserId":{"type":"string","description":"User ID who added the entry"},"externalId":{"type":"string","description":"External ID for third-party sync"},"createdAt":{"format":"date-time","type":"string","description":"Date when entry was created"}},"required":["id","workspaceId","type","value","source","createdAt"]},"SortBlocklistEntriesInput":{"type":"object","properties":{"field":{"type":"string","enum":["value","source","type","addedByName","createdAt"],"example":"createdAt","examples":["value","source","type","addedByName","createdAt"]},"order":{"type":"string","enum":["ASC","DESC"],"example":"DESC","examples":["ASC","DESC"]}},"required":["field","order"]},"BlocklistSourceCountsDto":{"type":"object","properties":{"HOTHAWK":{"type":"number","description":"Count of HotHawk entries"},"EMAIL_BISON":{"type":"number","description":"Count of EmailBison entries"},"CLIENT_BOX":{"type":"number","description":"Count of Clientbox entries"},"total":{"type":"number","description":"Total count"}},"required":["HOTHAWK","EMAIL_BISON","CLIENT_BOX","total"]},"CreateBlocklistEntryCommonInput":{"type":"object","properties":{"workspaceId":{"type":"string","description":"Workspace ID","example":"e8a0a56d-f9a2-4fa0-a4f9-3d00a051ed74"},"type":{"type":"string","description":"Entry type","enum":["EMAIL","DOMAIN"],"example":"EMAIL"},"value":{"type":"string","description":"Email address or domain to blocklist","examples":{"email":{"value":"spam@example.com","summary":"Email address"},"domain":{"value":"spammer.com","summary":"Domain"}}}},"required":["workspaceId","type","value"]}}}}