"use strict";
/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.Deployments = void 0;
const deploymentsGetConfig_js_1 = require("../funcs/deploymentsGetConfig.js");
const deploymentsInvoke_js_1 = require("../funcs/deploymentsInvoke.js");
const deploymentsList_js_1 = require("../funcs/deploymentsList.js");
const deploymentsStream_js_1 = require("../funcs/deploymentsStream.js");
const sdks_js_1 = require("../lib/sdks.js");
const fp_js_1 = require("../types/fp.js");
const metrics_js_1 = require("./metrics.js");
class Deployments extends sdks_js_1.ClientSDK {
    get metrics() {
        return (this._metrics ?? (this._metrics = new metrics_js_1.Metrics(this._options)));
    }
    /**
     * Invoke
     *
     * @remarks
     * Invoke a deployment with a given payload
     */
    async invoke(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, deploymentsInvoke_js_1.deploymentsInvoke)(this, request, options));
    }
    /**
     * List all deployments
     *
     * @remarks
     * Returns a list of your deployments. The deployments are returned sorted by creation date, with the most recent deployments appearing first.
     */
    async list(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, deploymentsList_js_1.deploymentsList)(this, request, options));
    }
    /**
     * Get config
     *
     * @remarks
     * Retrieve the deployment configuration
     */
    async getConfig(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, deploymentsGetConfig_js_1.deploymentsGetConfig)(this, request, options));
    }
    /**
     * Stream
     *
     * @remarks
     * Stream deployment generation. Only supported for completions and chat completions.
     */
    async stream(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, deploymentsStream_js_1.deploymentsStream)(this, request, options));
    }
}
exports.Deployments = Deployments;
//# sourceMappingURL=deployments.js.map