openapi: 3.0.3 info: title: Binarly Assistant API version: 4.275.2 security: - auth: [] tags: - name: Assistant paths: /api/v4/assistant/chats: get: summary: List Assistant chats operationId: ListChats x-permission: '' tags: - Assistant responses: '200': description: success content: application/json: schema: $ref: '#/components/schemas/Chats' '401': $ref: '#/components/responses/Unauthorized' '403': $ref: '#/components/responses/Forbidden' '500': $ref: '#/components/responses/InternalServerError' post: summary: Create Assistant chat operationId: CreateChat x-permission: '' tags: - Assistant responses: '201': description: success content: application/json: schema: $ref: '#/components/schemas/Chat' '401': $ref: '#/components/responses/Unauthorized' '403': $ref: '#/components/responses/Forbidden' '500': $ref: '#/components/responses/InternalServerError' /api/v4/assistant/chats/{chatId}: delete: summary: Delete Assistant chat operationId: DeleteChat x-permission: '' tags: - Assistant parameters: - name: chatId in: path description: Assistant chat ID required: true schema: $ref: '#/components/schemas/ULID' responses: '200': description: success content: application/json: schema: $ref: '#/components/schemas/Chat' '401': $ref: '#/components/responses/Unauthorized' '403': $ref: '#/components/responses/Forbidden' '404': $ref: '#/components/responses/NotFound' '500': $ref: '#/components/responses/InternalServerError' '502': $ref: '#/components/responses/BadGateway' /api/v4/assistant/chats/{chatId}/dialogs: get: summary: Get Assistant chat history operationId: ListChatDialogs x-permission: '' tags: - Assistant parameters: - name: chatId in: path description: Assistant chat ID required: true schema: $ref: '#/components/schemas/ULID' responses: '200': description: success content: application/json: schema: $ref: '#/components/schemas/ChatDialogs' '401': $ref: '#/components/responses/Unauthorized' '403': $ref: '#/components/responses/Forbidden' '404': $ref: '#/components/responses/NotFound' '500': $ref: '#/components/responses/InternalServerError' '502': $ref: '#/components/responses/BadGateway' /api/v4/assistant/chats/{chatId}/dialogs:sendCommand: post: summary: Send Command to Chat operationId: SendCommandToChat x-permission: '' x-pass-resource-ids: resourceType: Product permission: products.view tags: - Assistant parameters: - name: chatId in: path description: Assistant chat ID required: true schema: $ref: '#/components/schemas/ULID' - name: purpose in: query description: Chat purpose schema: type: string - name: command in: query description: Command schema: type: string - name: findingId in: query description: Finding Id schema: $ref: '#/components/schemas/ULID' requestBody: content: application/json: schema: $ref: '#/components/schemas/ChatRequest' responses: '200': description: success content: application/json: schema: $ref: '#/components/schemas/ChatDialogs' '400': $ref: '#/components/responses/BadRequest' '401': $ref: '#/components/responses/Unauthorized' '403': $ref: '#/components/responses/Forbidden' '404': $ref: '#/components/responses/NotFound' '500': $ref: '#/components/responses/InternalServerError' '502': $ref: '#/components/responses/BadGateway' /api/v4/assistant/chats/{chatId}/suggestions: get: summary: Get Assistant suggestions for finding operationId: ListSuggestions x-permission: '' x-pass-resource-ids: resourceType: Product permission: products.view tags: - Assistant parameters: - name: chatId in: path description: Assistant chat ID required: true schema: $ref: '#/components/schemas/ULID' - name: findingId in: query description: Finding Id required: true schema: $ref: '#/components/schemas/ULID' responses: '200': description: success content: application/json: schema: $ref: '#/components/schemas/Suggestions' '400': $ref: '#/components/responses/BadRequest' '401': $ref: '#/components/responses/Unauthorized' '403': $ref: '#/components/responses/Forbidden' '404': $ref: '#/components/responses/NotFound' '500': $ref: '#/components/responses/InternalServerError' '502': $ref: '#/components/responses/BadGateway' components: responses: Forbidden: description: Forbidden content: application/json: schema: $ref: '#/components/schemas/ForbiddenErrorResponse' NotFound: description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' Unauthorized: description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' BadRequest: description: Bad request content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' BadGateway: description: Bad Gateway content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' InternalServerError: description: Internal server error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' schemas: Suggestions: $ref: '#/components/schemas/WithSuggestions' ErrorDetail: type: object required: - error properties: reason: type: string x-go-type-skip-optional-pointer: true field: type: string x-go-type-skip-optional-pointer: true service: type: string x-go-type-skip-optional-pointer: true ChatRequest: allOf: - $ref: '#/components/schemas/WithChatRequest' ChatDialogs: $ref: '#/components/schemas/WithChatDialogs' WithChats: type: object required: - chats properties: chats: type: array items: $ref: '#/components/schemas/Chat' WithChatDialogs: type: object required: - chatDialogs properties: chatDialogs: type: array items: $ref: '#/components/schemas/ChatDialog' nullable: true WithChatRequest: type: object required: - request properties: request: type: string ForbiddenErrorResponse: type: object required: - message - permission - resourceName properties: message: type: string permission: type: string resourceName: type: string details: type: array items: $ref: '#/components/schemas/ErrorDetail' Chat: allOf: - $ref: '#/components/schemas/WithId' ErrorResponse: required: - message type: object properties: message: type: string readOnly: true x-go-type-skip-optional-pointer: true details: type: array items: $ref: '#/components/schemas/ErrorDetail' Chats: $ref: '#/components/schemas/WithChats' WithSuggestions: type: object required: - suggestions properties: suggestions: type: array items: $ref: '#/components/schemas/Suggestion' nullable: true ULID: type: string format: ulid minLength: 26 maxLength: 26 example: 01ARZ3NDEKTSV4RRFFQ69G5FAV x-go-type: ulid.ULID x-go-type-import: path: github.com/oklog/ulid/v2 ChatDialog: type: object required: - authorType - message - createTime properties: authorType: type: string message: type: string createTime: type: string WithId: type: object required: - id properties: id: readOnly: true allOf: - $ref: '#/components/schemas/ULID' Suggestion: type: object required: - suggestion - command - findingId properties: suggestion: type: string command: type: string findingId: type: string securitySchemes: auth: type: http scheme: bearer bearerFormat: JWT