"use strict";
/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.Conversations = void 0;
const conversationsCreate_js_1 = require("../funcs/conversationsCreate.js");
const conversationsCreateConversationResponse_js_1 = require("../funcs/conversationsCreateConversationResponse.js");
const conversationsDelete_js_1 = require("../funcs/conversationsDelete.js");
const conversationsGenerateName_js_1 = require("../funcs/conversationsGenerateName.js");
const conversationsList_js_1 = require("../funcs/conversationsList.js");
const conversationsRetrieve_js_1 = require("../funcs/conversationsRetrieve.js");
const conversationsUpdate_js_1 = require("../funcs/conversationsUpdate.js");
const sdks_js_1 = require("../lib/sdks.js");
const fp_js_1 = require("../types/fp.js");
class Conversations extends sdks_js_1.ClientSDK {
    /**
     * List conversations
     *
     * @remarks
     * Retrieves a paginated list of conversations in your workspace. Conversations are returned sorted by creation date (newest first). Use pagination parameters to efficiently navigate through large collections.
     */
    async list(limit, startingAfter, endingBefore, entityId, options) {
        return (0, fp_js_1.unwrapAsync)((0, conversationsList_js_1.conversationsList)(this, limit, startingAfter, endingBefore, entityId, options));
    }
    /**
     * Create conversation
     *
     * @remarks
     * Creates a new conversation in the workspace. Conversations serve as containers for organizing related messages and interactions. Each conversation is assigned a unique identifier and timestamps for tracking.
     */
    async create(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, conversationsCreate_js_1.conversationsCreate)(this, request, options));
    }
    /**
     * Generate conversation name
     *
     * @remarks
     * Generates a display name for a conversation using AI based on the provided context. Updates the conversation with the generated name and sets generatingTitle to false.
     */
    async generateName(requestBody, conversationId, options) {
        return (0, fp_js_1.unwrapAsync)((0, conversationsGenerateName_js_1.conversationsGenerateName)(this, requestBody, conversationId, options));
    }
    /**
     * Retrieve conversation
     *
     * @remarks
     * Retrieves detailed information about a specific conversation identified by its unique ID. Returns the complete conversation object including metadata and timestamps.
     */
    async retrieve(conversationId, options) {
        return (0, fp_js_1.unwrapAsync)((0, conversationsRetrieve_js_1.conversationsRetrieve)(this, conversationId, options));
    }
    /**
     * Update conversation
     *
     * @remarks
     * Modifies an existing conversation's properties. Only the fields provided in the request body will be updated; all other fields remain unchanged. Changes are applied immediately.
     */
    async update(requestBody, conversationId, options) {
        return (0, fp_js_1.unwrapAsync)((0, conversationsUpdate_js_1.conversationsUpdate)(this, requestBody, conversationId, options));
    }
    /**
     * Delete conversation
     *
     * @remarks
     * Permanently removes a conversation from the workspace
     */
    async delete(conversationId, options) {
        return (0, fp_js_1.unwrapAsync)((0, conversationsDelete_js_1.conversationsDelete)(this, conversationId, options));
    }
    /**
     * Create internal response
     *
     * @remarks
     * Creates a response for a freeform conversation without an agent. Uses a default model for generation.
     */
    async createConversationResponse(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, conversationsCreateConversationResponse_js_1.conversationsCreateConversationResponse)(this, request, options));
    }
}
exports.Conversations = Conversations;
//# sourceMappingURL=conversations.js.map