"use strict";
/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
    var ownKeys = function(o) {
        ownKeys = Object.getOwnPropertyNames || function (o) {
            var ar = [];
            for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
            return ar;
        };
        return ownKeys(o);
    };
    return function (mod) {
        if (mod && mod.__esModule) return mod;
        var result = {};
        if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
        __setModuleDefault(result, mod);
        return result;
    };
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.GetAllFeedbackResponse$ = exports.GetAllFeedbackResponse$outboundSchema = exports.GetAllFeedbackResponse$inboundSchema = exports.NegativeFeedback$ = exports.NegativeFeedback$outboundSchema = exports.NegativeFeedback$inboundSchema = exports.GetAllFeedbackResponseReasons$ = exports.GetAllFeedbackResponseReasons$outboundSchema = exports.GetAllFeedbackResponseReasons$inboundSchema = exports.GetAllFeedbackResponseNegativeFeedbackType$ = exports.GetAllFeedbackResponseNegativeFeedbackType$outboundSchema = exports.GetAllFeedbackResponseNegativeFeedbackType$inboundSchema = exports.PositiveFeedback$ = exports.PositiveFeedback$outboundSchema = exports.PositiveFeedback$inboundSchema = exports.Reasons$ = exports.Reasons$outboundSchema = exports.Reasons$inboundSchema = exports.GetAllFeedbackResponseType$ = exports.GetAllFeedbackResponseType$outboundSchema = exports.GetAllFeedbackResponseType$inboundSchema = exports.GetAllFeedbackResponseNegativeFeedbackType = exports.GetAllFeedbackResponseType = void 0;
exports.reasonsToJSON = reasonsToJSON;
exports.reasonsFromJSON = reasonsFromJSON;
exports.positiveFeedbackToJSON = positiveFeedbackToJSON;
exports.positiveFeedbackFromJSON = positiveFeedbackFromJSON;
exports.getAllFeedbackResponseReasonsToJSON = getAllFeedbackResponseReasonsToJSON;
exports.getAllFeedbackResponseReasonsFromJSON = getAllFeedbackResponseReasonsFromJSON;
exports.negativeFeedbackToJSON = negativeFeedbackToJSON;
exports.negativeFeedbackFromJSON = negativeFeedbackFromJSON;
exports.getAllFeedbackResponseToJSON = getAllFeedbackResponseToJSON;
exports.getAllFeedbackResponseFromJSON = getAllFeedbackResponseFromJSON;
const z = __importStar(require("zod"));
const schemas_js_1 = require("../../lib/schemas.js");
const conversation_js_1 = require("./conversation.js");
const message_js_1 = require("./message.js");
exports.GetAllFeedbackResponseType = {
    Positive: "positive",
    Negative: "negative",
};
exports.GetAllFeedbackResponseNegativeFeedbackType = {
    Positive: "positive",
    Negative: "negative",
};
/** @internal */
exports.GetAllFeedbackResponseType$inboundSchema = z.nativeEnum(exports.GetAllFeedbackResponseType);
/** @internal */
exports.GetAllFeedbackResponseType$outboundSchema = exports.GetAllFeedbackResponseType$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var GetAllFeedbackResponseType$;
(function (GetAllFeedbackResponseType$) {
    /** @deprecated use `GetAllFeedbackResponseType$inboundSchema` instead. */
    GetAllFeedbackResponseType$.inboundSchema = exports.GetAllFeedbackResponseType$inboundSchema;
    /** @deprecated use `GetAllFeedbackResponseType$outboundSchema` instead. */
    GetAllFeedbackResponseType$.outboundSchema = exports.GetAllFeedbackResponseType$outboundSchema;
})(GetAllFeedbackResponseType$ || (exports.GetAllFeedbackResponseType$ = GetAllFeedbackResponseType$ = {}));
/** @internal */
exports.Reasons$inboundSchema = z.object({
    label: z.string(),
    details: z.string(),
});
/** @internal */
exports.Reasons$outboundSchema = z.object({
    label: z.string(),
    details: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var Reasons$;
(function (Reasons$) {
    /** @deprecated use `Reasons$inboundSchema` instead. */
    Reasons$.inboundSchema = exports.Reasons$inboundSchema;
    /** @deprecated use `Reasons$outboundSchema` instead. */
    Reasons$.outboundSchema = exports.Reasons$outboundSchema;
})(Reasons$ || (exports.Reasons$ = Reasons$ = {}));
function reasonsToJSON(reasons) {
    return JSON.stringify(exports.Reasons$outboundSchema.parse(reasons));
}
function reasonsFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.Reasons$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Reasons' from JSON`);
}
/** @internal */
exports.PositiveFeedback$inboundSchema = z.object({
    id: z.string(),
    type: exports.GetAllFeedbackResponseType$inboundSchema,
    messageId: z.string(),
    createdAt: z.string(),
    reasons: z.nullable(z.array(z.lazy(() => exports.Reasons$inboundSchema))).optional(),
    userProperties: z.nullable(z.record(z.any())).optional(),
    conversation: conversation_js_1.Conversation$inboundSchema,
    message: message_js_1.Message$inboundSchema,
});
/** @internal */
exports.PositiveFeedback$outboundSchema = z.object({
    id: z.string(),
    type: exports.GetAllFeedbackResponseType$outboundSchema,
    messageId: z.string(),
    createdAt: z.string(),
    reasons: z.nullable(z.array(z.lazy(() => exports.Reasons$outboundSchema))).optional(),
    userProperties: z.nullable(z.record(z.any())).optional(),
    conversation: conversation_js_1.Conversation$outboundSchema,
    message: message_js_1.Message$outboundSchema,
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var PositiveFeedback$;
(function (PositiveFeedback$) {
    /** @deprecated use `PositiveFeedback$inboundSchema` instead. */
    PositiveFeedback$.inboundSchema = exports.PositiveFeedback$inboundSchema;
    /** @deprecated use `PositiveFeedback$outboundSchema` instead. */
    PositiveFeedback$.outboundSchema = exports.PositiveFeedback$outboundSchema;
})(PositiveFeedback$ || (exports.PositiveFeedback$ = PositiveFeedback$ = {}));
function positiveFeedbackToJSON(positiveFeedback) {
    return JSON.stringify(exports.PositiveFeedback$outboundSchema.parse(positiveFeedback));
}
function positiveFeedbackFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.PositiveFeedback$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PositiveFeedback' from JSON`);
}
/** @internal */
exports.GetAllFeedbackResponseNegativeFeedbackType$inboundSchema = z
    .nativeEnum(exports.GetAllFeedbackResponseNegativeFeedbackType);
/** @internal */
exports.GetAllFeedbackResponseNegativeFeedbackType$outboundSchema = exports.GetAllFeedbackResponseNegativeFeedbackType$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var GetAllFeedbackResponseNegativeFeedbackType$;
(function (GetAllFeedbackResponseNegativeFeedbackType$) {
    /** @deprecated use `GetAllFeedbackResponseNegativeFeedbackType$inboundSchema` instead. */
    GetAllFeedbackResponseNegativeFeedbackType$.inboundSchema = exports.GetAllFeedbackResponseNegativeFeedbackType$inboundSchema;
    /** @deprecated use `GetAllFeedbackResponseNegativeFeedbackType$outboundSchema` instead. */
    GetAllFeedbackResponseNegativeFeedbackType$.outboundSchema = exports.GetAllFeedbackResponseNegativeFeedbackType$outboundSchema;
})(GetAllFeedbackResponseNegativeFeedbackType$ || (exports.GetAllFeedbackResponseNegativeFeedbackType$ = GetAllFeedbackResponseNegativeFeedbackType$ = {}));
/** @internal */
exports.GetAllFeedbackResponseReasons$inboundSchema = z.object({
    label: z.string(),
    details: z.string(),
});
/** @internal */
exports.GetAllFeedbackResponseReasons$outboundSchema = z.object({
    label: z.string(),
    details: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var GetAllFeedbackResponseReasons$;
(function (GetAllFeedbackResponseReasons$) {
    /** @deprecated use `GetAllFeedbackResponseReasons$inboundSchema` instead. */
    GetAllFeedbackResponseReasons$.inboundSchema = exports.GetAllFeedbackResponseReasons$inboundSchema;
    /** @deprecated use `GetAllFeedbackResponseReasons$outboundSchema` instead. */
    GetAllFeedbackResponseReasons$.outboundSchema = exports.GetAllFeedbackResponseReasons$outboundSchema;
})(GetAllFeedbackResponseReasons$ || (exports.GetAllFeedbackResponseReasons$ = GetAllFeedbackResponseReasons$ = {}));
function getAllFeedbackResponseReasonsToJSON(getAllFeedbackResponseReasons) {
    return JSON.stringify(exports.GetAllFeedbackResponseReasons$outboundSchema.parse(getAllFeedbackResponseReasons));
}
function getAllFeedbackResponseReasonsFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetAllFeedbackResponseReasons$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetAllFeedbackResponseReasons' from JSON`);
}
/** @internal */
exports.NegativeFeedback$inboundSchema = z.object({
    id: z.string(),
    type: exports.GetAllFeedbackResponseNegativeFeedbackType$inboundSchema,
    messageId: z.string(),
    createdAt: z.string(),
    reasons: z.nullable(z.array(z.lazy(() => exports.GetAllFeedbackResponseReasons$inboundSchema))).optional(),
    userProperties: z.nullable(z.record(z.any())).optional(),
    conversation: conversation_js_1.Conversation$inboundSchema,
    message: message_js_1.Message$inboundSchema,
});
/** @internal */
exports.NegativeFeedback$outboundSchema = z.object({
    id: z.string(),
    type: exports.GetAllFeedbackResponseNegativeFeedbackType$outboundSchema,
    messageId: z.string(),
    createdAt: z.string(),
    reasons: z.nullable(z.array(z.lazy(() => exports.GetAllFeedbackResponseReasons$outboundSchema))).optional(),
    userProperties: z.nullable(z.record(z.any())).optional(),
    conversation: conversation_js_1.Conversation$outboundSchema,
    message: message_js_1.Message$outboundSchema,
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var NegativeFeedback$;
(function (NegativeFeedback$) {
    /** @deprecated use `NegativeFeedback$inboundSchema` instead. */
    NegativeFeedback$.inboundSchema = exports.NegativeFeedback$inboundSchema;
    /** @deprecated use `NegativeFeedback$outboundSchema` instead. */
    NegativeFeedback$.outboundSchema = exports.NegativeFeedback$outboundSchema;
})(NegativeFeedback$ || (exports.NegativeFeedback$ = NegativeFeedback$ = {}));
function negativeFeedbackToJSON(negativeFeedback) {
    return JSON.stringify(exports.NegativeFeedback$outboundSchema.parse(negativeFeedback));
}
function negativeFeedbackFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.NegativeFeedback$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'NegativeFeedback' from JSON`);
}
/** @internal */
exports.GetAllFeedbackResponse$inboundSchema = z.object({
    positiveFeedbackCount: z.number(),
    negativeFeedbackCount: z.number(),
    positiveFeedback: z.array(z.lazy(() => exports.PositiveFeedback$inboundSchema)),
    negativeFeedback: z.array(z.lazy(() => exports.NegativeFeedback$inboundSchema)),
});
/** @internal */
exports.GetAllFeedbackResponse$outboundSchema = z.object({
    positiveFeedbackCount: z.number(),
    negativeFeedbackCount: z.number(),
    positiveFeedback: z.array(z.lazy(() => exports.PositiveFeedback$outboundSchema)),
    negativeFeedback: z.array(z.lazy(() => exports.NegativeFeedback$outboundSchema)),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var GetAllFeedbackResponse$;
(function (GetAllFeedbackResponse$) {
    /** @deprecated use `GetAllFeedbackResponse$inboundSchema` instead. */
    GetAllFeedbackResponse$.inboundSchema = exports.GetAllFeedbackResponse$inboundSchema;
    /** @deprecated use `GetAllFeedbackResponse$outboundSchema` instead. */
    GetAllFeedbackResponse$.outboundSchema = exports.GetAllFeedbackResponse$outboundSchema;
})(GetAllFeedbackResponse$ || (exports.GetAllFeedbackResponse$ = GetAllFeedbackResponse$ = {}));
function getAllFeedbackResponseToJSON(getAllFeedbackResponse) {
    return JSON.stringify(exports.GetAllFeedbackResponse$outboundSchema.parse(getAllFeedbackResponse));
}
function getAllFeedbackResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetAllFeedbackResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetAllFeedbackResponse' from JSON`);
}
//# sourceMappingURL=getallfeedbackresponse.js.map