Sweep Ai Agents API

The Ai Agents API from Sweep — 42 operation(s) for ai agents.

Business capability
Artificial Intelligence Management BC-610.60

Operations 49

GET /ai-agents #
POST /ai-agents #
PATCH /ai-agents/{agentId}/name #
PATCH /ai-agents/{agentId}/user-instructions #
PATCH /ai-agents/{agentId}/system-instructions #
PATCH /ai-agents/{agentId}/configurations #
DELETE /ai-agents/{agentId} #
POST /ai-agents/{agentId}/files/upload-url #
POST /ai-agents/{agentId}/files/confirm-upload #
DELETE /ai-agents/{agentId}/files/{fileId} #
GET /ai-agents/{agentId}/files/{fileId}/download-url #
GET /ai-agents/{agentId}/files/{fileId}/preview #
POST /ai-agents/{agentId}/chats/{chatId}/add-to-agent #
POST /ai-agents/{agentId}/chats #
GET /ai-agents/{agentId}/chats #
PATCH /ai-agents/chats/{chatId} #
GET /ai-agents/chats/{chatId} #
DELETE /ai-agents/chats/{chatId} #
DELETE /ai-agents/stream/{id} #
GET /ai-agents/stream/{id} #
POST /ai-agents/{agentId}/chats/{chatId}/mcp-tool-approval #
PATCH /ai-agents/chats/{chatId}/name #
PATCH /ai-agents/chats/{chatId}/favorite #
GET /ai-agents/monitoring/{agentId}/metadata-elements #
GET /ai-agents/monitoring/{agentId}/issues #
PATCH /ai-agents/monitoring/{agentId}/issues/{issueId} #
POST /ai-agents/{agentId}/folders #
GET /ai-agents/{agentId}/folders #
PATCH /ai-agents/{agentId}/folders/{folderId}/name #
DELETE /ai-agents/{agentId}/folders/{folderId} #
PATCH /ai-agents/{agentId}/chats/{chatId}/folder #
GET /ai-agents/chats #
GET /ai-agents/{agentId}/chats/sfdc #
GET /ai-agents/chats/search #
DELETE /ai-agents/chats/{chatId}/messages/{messageIndex} #
POST /ai-agents/chats/{chatId}/feedback/{runId} #
POST /ai-agents/{agentId}/best-practices #
DELETE /ai-agents/{agentId}/best-practices #
GET /ai-agents/{agentId}/artifacts #
GET /ai-agents/artifacts/by-artifact-id/{artifactId}/versions #
GET /ai-agents/artifacts/shared/{id} Resolve a company-share link. `:id` may be a logical artifactId (stable) or a legacy version UUID. Returns the currently shared version for that family, or the latest version when #
GET /ai-agents/artifacts/{versionId} #
PATCH /ai-agents/artifacts/{id}/share #
PATCH /ai-agents/artifacts/{id}/public #
GET /ai-agents/artifacts/{id}/public-url-token #
GET /ai-agents/table-artifacts/{tableId} #
GET /ai-agents/build-definitions/{buildDefinitionId} #
POST /ai-agents/process-mining/{funnelMapId} #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/sweep-ai-agents-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no email required.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

sweep-ai-agents-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Sweep Ai Agents API
  description: This is a publicly available Sweep API.
  version: '0.1'
  contact: {}
servers:
- url: https://api.sweep.io
  description: Sweep production API — the host this document was harvested from (GET /api-json); /health responds here
tags:
- name: Ai Agents
paths:
  /ai-agents:
    get:
      operationId: AiAgentsController_getAgents
      parameters: []
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
    post:
      operationId: AiAgentsController_createAgent
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateAgentDto'
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AiAgent'
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/name:
    patch:
      operationId: AiAgentsController_renameAgent
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EditAgentNameDto'
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/user-instructions:
    patch:
      operationId: AiAgentsController_editAgentUserInstructions
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EditAgentUserInstructionsDto'
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/system-instructions:
    patch:
      operationId: AiAgentsController_editAgentSystemInstructions
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EditAgentSystemInstructionsDto'
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/configurations:
    patch:
      operationId: AiAgentsController_patchAgentConfigurations
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PatchAgentConfigurationsDto'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AiAgent'
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}:
    delete:
      operationId: AiAgentsController_deleteAgent
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/files/upload-url:
    post:
      operationId: AiAgentsController_generateFileUploadUrl
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GenerateFileUploadUrlDto'
      responses:
        '201':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/files/confirm-upload:
    post:
      operationId: AiAgentsController_confirmFileUpload
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ConfirmFileUploadDto'
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/files/{fileId}:
    delete:
      operationId: AiAgentsController_deleteAgentFile
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: fileId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/files/{fileId}/download-url:
    get:
      operationId: AiAgentsController_generateFileDownloadUrl
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: fileId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/files/{fileId}/preview:
    get:
      operationId: AiAgentsController_generateFilePreview
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: fileId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/chats/{chatId}/add-to-agent:
    post:
      operationId: AiAgentsController_addChatToAgentFiles
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/chats:
    post:
      operationId: AiAgentsController_createChat
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: pythonExperimental
        required: true
        in: query
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ChatMessageDto'
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
    get:
      operationId: AiAgentsController_getAiChats
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/chats/{chatId}:
    patch:
      operationId: AiAgentsController_sendMessage
      parameters:
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      - name: pythonExperimental
        required: true
        in: query
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ChatMessageDto'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
    get:
      operationId: AiAgentsController_getChat
      parameters:
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
    delete:
      operationId: AiAgentsController_deleteChat
      parameters:
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: boolean
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/stream/{id}:
    delete:
      operationId: AiAgentsController_cancelStream
      parameters:
      - name: id
        required: true
        in: path
        schema:
          type: string
      - name: useRedis
        required: true
        in: query
        schema:
          type: string
      - name: chatId
        required: true
        in: query
        schema:
          type: string
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
    get:
      operationId: AiAgentsController_streamChatResponse
      parameters:
      - name: id
        required: true
        in: path
        schema:
          type: string
      - name: useRedis
        required: true
        in: query
        schema:
          type: string
      - name: chatId
        required: true
        in: query
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/chats/{chatId}/mcp-tool-approval:
    post:
      operationId: AiAgentsController_handleMcpToolApproval
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/McpToolApprovalDto'
      responses:
        '201':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/chats/{chatId}/name:
    patch:
      operationId: AiAgentsController_rename
      parameters:
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: boolean
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/chats/{chatId}/favorite:
    patch:
      operationId: AiAgentsController_setIsFavorite
      parameters:
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: boolean
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/monitoring/{agentId}/metadata-elements:
    get:
      operationId: AiAgentsController_getMonitoringMetadataElements
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/monitoring/{agentId}/issues:
    get:
      operationId: AiAgentsController_getMonitoringV2PotentialIssues
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/monitoring/{agentId}/issues/{issueId}:
    patch:
      operationId: AiAgentsController_setMonitoringIssueStatus
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: issueId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateIssueDto'
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/folders:
    post:
      operationId: AiAgentsController_createFolder
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
    get:
      operationId: AiAgentsController_getFolders
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/folders/{folderId}/name:
    patch:
      operationId: AiAgentsController_renameFolder
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: folderId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: boolean
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/folders/{folderId}:
    delete:
      operationId: AiAgentsController_deleteFolder
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: folderId
        required: true
        in: path
        schema:
          type: string
      - name: deleteChats
        required: true
        in: query
        schema:
          type: boolean
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: boolean
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/chats/{chatId}/folder:
    patch:
      operationId: AiAgentsController_setChatFolder
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: boolean
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/chats:
    get:
      operationId: AiAgentsController_getAiChatsDeprecated
      parameters:
      - name: agentId
        required: true
        in: query
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/chats/sfdc:
    get:
      operationId: AiAgentsController_getSupportSalesforceChats
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/chats/search:
    get:
      operationId: AiAgentsController_searchDeprecated
      parameters:
      - name: term
        required: true
        in: query
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/AiChat'
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/chats/search:
    get:
      operationId: AiAgentsController_search
      parameters:
      - name: term
        required: true
        in: query
        schema:
          type: string
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/AiChat'
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/chats/{chatId}/messages/{messageIndex}:
    delete:
      operationId: AiAgentsController_deleteChatMessagePair
      parameters:
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      - name: messageIndex
        required: true
        in: path
        schema:
          type: number
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DeleteAiChatMessagePairDto'
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/chats/{chatId}/feedback/{runId}:
    post:
      operationId: AiAgentsController_submitFeedback
      parameters:
      - name: chatId
        required: true
        in: path
        schema:
          type: string
      - name: runId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SubmitFeedbackDto'
      responses:
        '201':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/best-practices:
    post:
      operationId: AiAgentsController_addBestPracticesToAgent
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ManageBestPracticesDto'
      responses:
        '201':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
    delete:
      operationId: AiAgentsController_removeBestPracticesFromAgent
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ManageBestPracticesDto'
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/{agentId}/artifacts:
    get:
      operationId: AiAgentsController_getArtifacts
      parameters:
      - name: agentId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/artifacts/by-artifact-id/{artifactId}/versions:
    get:
      operationId: AiAgentsController_getArtifactVersionsSummaries
      parameters:
      - name: artifactId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/artifacts/shared/{id}:
    get:
      operationId: AiAgentsController_getSharedArtifact
      parameters:
      - name: id
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AiArtifact'
      security:
      - bearer: []
      summary: 'Resolve a company-share link. `:id` may be a logical artifactId (stable) or a

        legacy version UUID. Returns the currently shared version for that family,

        or the latest version when nothing is shared and the caller is the creator.'
      tags:
      - Ai Agents
  /ai-agents/artifacts/{versionId}:
    get:
      operationId: AiAgentsController_getArtifact
      parameters:
      - name: versionId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AiArtifact'
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/artifacts/{id}/share:
    patch:
      operationId: AiAgentsController_shareArtifact
      parameters:
      - name: id
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/artifacts/{id}/public:
    patch:
      operationId: AiAgentsController_setArtifactPublic
      parameters:
      - name: id
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/artifacts/{id}/public-url-token:
    get:
      operationId: AiAgentsController_getArtifactPublicToken
      parameters:
      - name: id
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/table-artifacts/{tableId}:
    get:
      operationId: AiAgentsController_getTableArtifact
      parameters:
      - name: tableId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AiTableArtifact'
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/build-definitions/{buildDefinitionId}:
    get:
      operationId: AiAgentsController_getBuildDefinition
      parameters:
      - name: buildDefinitionId
        required: true
        in: path
        schema:
          type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AiBuildDefinition'
      security:
      - bearer: []
      tags:
      - Ai Agents
  /ai-agents/process-mining/{funnelMapId}:
    post:
      operationId: AiAgentsController_processMiningSingleRequest
      parameters:
      - name: funnelMapId
        required: true
        in: path
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ProcessMiningAgentDto'
      responses:
        '201':
          description: ''
      security:
      - bearer: []
      tags:
      - Ai Agents
components:
  schemas:
    BestPractice:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        severity:
          type: object
        text:
          type: string
        isSystem:
          type: boolean
        applicableDomain:
          type: string
          enum:
          - MetadataMonitoring
          - BusinessProcess
        applicableResourceType:
          type: string
        accountId:
          type: string
        account:
          $ref: '#/components/schemas/Account'
        createdById:
          type: string
        createdBy:
          $ref: '#/components/schemas/User'
        updatedById:
          type: string
        updatedBy:
          $ref: '#/components/schemas/User'
        createdAt:
          format: date-time
          type: string
        updatedAt:
          format: date-time
          type: string
      required:
      - id
      - name
      - severity
      - text
      - isSystem
      - applicableDomain
      - applicableResourceType
      - accountId
      - account
      - createdById
      - createdBy
      - updatedById
      - updatedBy
      - createdAt
      - updatedAt
    SweepFieldReference:
      type: object
      properties:
        fieldIds:
          type: array
          items:
            type: string
        fieldSource:
          type: string
      required:
      - fieldIds
    FunnelDetailsDto:
      type: object
      properties:
        leadingObject:
          $ref: '#/components/schemas/LeadingObjectDto'
        stages:
          type: array
          items:
            $ref: '#/components/schemas/SweepStage'
        _firstStageId:
          type: string
        plugins:
          default: {}
          allOf:
          - $ref: '#/components/schemas/FunnelPluginsDto'
        funnelLinks:
          type: array
          items:
            $ref: '#/components/schemas/FunnelLinkDto'
        stageMetadata:
          type: array
          items:
            type: object
      required:
      - leadingObject
      - stages
      - plugins
    AiAgentBestPractice:
      type: object
      properties:
        aiAgentId:
          type: string
        bestPracticeId:
          type: string
        aiAgent:
          $ref: '#/components/schemas/AiAgent'
        bestPractice:
          $ref: '#/components/schemas/BestPractice'
        createdAt:
          format: date-time
          type: string
      required:
      - aiAgentId
      - bestPracticeId
      - aiAgent
      - bestPractice
      - createdAt
    SweepAssignmentRule:
      type: object
      properties:
        assignmentId:
          type: string
        ruleName:
          type: string
        assignedTo:
          type: string
        assignedToType:
          type: string
        criteriaLogic:
          type: string
        criteria:
          type: array
          items:
            type: object
      required:
      - assignmentId
      - ruleName
      - assignedTo
      - assignedToType
      - criteriaLogic
      - criteria
    IncludeConfigurationDto:
      type: object
      properties:
        name:
          type: string
        type:
          type: string
      required:
      - name
      - type
    User:
      type: object
      properties:
        id:
          type: string
        sub:
          type: string
        email:
          type: string
        account:
          $ref: '#/components/schemas/Account'
        preferences:
          type: object
        name:
          type: string
        emoji:
          type: string
        imageUrl:
          type: string
        jobTitle:
          type: string
        roleGroup:
          $ref: '#/components/schemas/RoleGroup'
        roleGroupId:
          type: string
        createdAt:
          format: date-time
          type: string
        updatedAt:
          format: date-time
          type: string
        deletedAt:
          format: date-time
          type: string
        lastSeen:
          format: date-time
          type: string
      required:
      - id
      - sub
      - email
      - account
      - preferences
      - name
      - emoji
      - imageUrl
      - jobTitle
      - roleGroup
      - roleGroupId
      - createdAt
      - updatedAt
    SweepExitCriteria:
      type: object
      properties:
        _exitCriteriaId:
          type: string
        _nextStageId:
          type: string
        isAutoMoveToNextStage:
          type: boolean
        guidance:
          type: string
        criteria:
          type: array
          items:
            type: object
        criteriaLogic:
          type: string
      required:
      - _exitCriteriaId
      - criteria
      - criteriaLogic
    AiProjectPrompt:
      type: object
      properties:
        id:
          type: string
        promptTitle:
          type: string
        promptText:
          type: string
        mode:
          type: string
          enum:
          - none
          - researchMode
          - buildMode
          - multiOrgMode
          - artifactMode
        isCompleted:
          type: boolean
        completedById:
          type:
          - string
          - 'null'
        completedAt:
          format: date-time
          type:
          - string
          - 'null'
        projectId:
          type: string
        project:
          $ref: '#/components/schemas/AiProject'
      required:
      - id
      - promptTitle
      - promptText
      - mode
      - isCompleted
      - completedById
      - completedAt
      - projectId
      - project
    FunnelLinkDto:
      type: object
      properties:
        _id:
          type: string
        _type:
          type: string
          enum:
          - salesforce
          - thirdParty
          - recordType
          - hubspot
          - metadataElement
        funnelId:
          type: string
        stageId:
          type: string
      required:
      - _id
      - _type
      - funnelId
    ProcessMiningAgentDto:
      type: object
      properties:
        message:
          $ref: '#/components/schemas/AiChatMessageDto'
      required:
      - message
    AiAgent:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        type:
          enum:
          - Documentation
          - Process Optimization
          - MonitoringV2
          - Permissions
          - Support
          type: string
        contextComponents:
          type: object
        userInstructions:
          type: string
        systemInstructions:
          type: string
        projectId:
          type:
          - string
          - 'null'
        project:
          allOf:
          - $ref: '#/components/schemas/AiProject'
        orgId:
          type: string
        org:
          $ref: '#/components/schemas/Org'
        files:
          type: array
          items:
            $ref: '#/components/schemas/AiAgentFile'
       

# --- truncated at 32 KB (59 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/sweep/refs/heads/main/openapi/sweep-ai-agents-api-openapi.yml