"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.CreateResultForLineItemResponse$ = exports.CreateResultForLineItemResponse$outboundSchema = exports.CreateResultForLineItemResponse$inboundSchema = exports.CreateResultForLineItemSourcedIdPairs$ = exports.CreateResultForLineItemSourcedIdPairs$outboundSchema = exports.CreateResultForLineItemSourcedIdPairs$inboundSchema = exports.CreateResultForLineItemRequest$ = exports.CreateResultForLineItemRequest$outboundSchema = exports.CreateResultForLineItemRequest$inboundSchema = exports.CreateResultForLineItemRequestBody$ = exports.CreateResultForLineItemRequestBody$outboundSchema = exports.CreateResultForLineItemRequestBody$inboundSchema = void 0;
exports.createResultForLineItemRequestBodyToJSON = createResultForLineItemRequestBodyToJSON;
exports.createResultForLineItemRequestBodyFromJSON = createResultForLineItemRequestBodyFromJSON;
exports.createResultForLineItemRequestToJSON = createResultForLineItemRequestToJSON;
exports.createResultForLineItemRequestFromJSON = createResultForLineItemRequestFromJSON;
exports.createResultForLineItemSourcedIdPairsToJSON = createResultForLineItemSourcedIdPairsToJSON;
exports.createResultForLineItemSourcedIdPairsFromJSON = createResultForLineItemSourcedIdPairsFromJSON;
exports.createResultForLineItemResponseToJSON = createResultForLineItemResponseToJSON;
exports.createResultForLineItemResponseFromJSON = createResultForLineItemResponseFromJSON;
const z = __importStar(require("zod"));
const primitives_js_1 = require("../../lib/primitives.js");
const schemas_js_1 = require("../../lib/schemas.js");
const components = __importStar(require("../components/index.js"));
/** @internal */
exports.CreateResultForLineItemRequestBody$inboundSchema = z.object({
    results: z.array(components.Result$inboundSchema),
});
/** @internal */
exports.CreateResultForLineItemRequestBody$outboundSchema = z.object({
    results: z.array(components.Result$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateResultForLineItemRequestBody$;
(function (CreateResultForLineItemRequestBody$) {
    /** @deprecated use `CreateResultForLineItemRequestBody$inboundSchema` instead. */
    CreateResultForLineItemRequestBody$.inboundSchema = exports.CreateResultForLineItemRequestBody$inboundSchema;
    /** @deprecated use `CreateResultForLineItemRequestBody$outboundSchema` instead. */
    CreateResultForLineItemRequestBody$.outboundSchema = exports.CreateResultForLineItemRequestBody$outboundSchema;
})(CreateResultForLineItemRequestBody$ || (exports.CreateResultForLineItemRequestBody$ = CreateResultForLineItemRequestBody$ = {}));
function createResultForLineItemRequestBodyToJSON(createResultForLineItemRequestBody) {
    return JSON.stringify(exports.CreateResultForLineItemRequestBody$outboundSchema.parse(createResultForLineItemRequestBody));
}
function createResultForLineItemRequestBodyFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateResultForLineItemRequestBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateResultForLineItemRequestBody' from JSON`);
}
/** @internal */
exports.CreateResultForLineItemRequest$inboundSchema = z.object({
    sourcedId: z.string(),
    RequestBody: z.lazy(() => exports.CreateResultForLineItemRequestBody$inboundSchema),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "RequestBody": "requestBody",
    });
});
/** @internal */
exports.CreateResultForLineItemRequest$outboundSchema = z.object({
    sourcedId: z.string(),
    requestBody: z.lazy(() => exports.CreateResultForLineItemRequestBody$outboundSchema),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        requestBody: "RequestBody",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateResultForLineItemRequest$;
(function (CreateResultForLineItemRequest$) {
    /** @deprecated use `CreateResultForLineItemRequest$inboundSchema` instead. */
    CreateResultForLineItemRequest$.inboundSchema = exports.CreateResultForLineItemRequest$inboundSchema;
    /** @deprecated use `CreateResultForLineItemRequest$outboundSchema` instead. */
    CreateResultForLineItemRequest$.outboundSchema = exports.CreateResultForLineItemRequest$outboundSchema;
})(CreateResultForLineItemRequest$ || (exports.CreateResultForLineItemRequest$ = CreateResultForLineItemRequest$ = {}));
function createResultForLineItemRequestToJSON(createResultForLineItemRequest) {
    return JSON.stringify(exports.CreateResultForLineItemRequest$outboundSchema.parse(createResultForLineItemRequest));
}
function createResultForLineItemRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateResultForLineItemRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateResultForLineItemRequest' from JSON`);
}
/** @internal */
exports.CreateResultForLineItemSourcedIdPairs$inboundSchema = z.object({
    suppliedSourcedId: z.string(),
    allocatedSourcedId: z.string(),
});
/** @internal */
exports.CreateResultForLineItemSourcedIdPairs$outboundSchema = z.object({
    suppliedSourcedId: z.string(),
    allocatedSourcedId: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateResultForLineItemSourcedIdPairs$;
(function (CreateResultForLineItemSourcedIdPairs$) {
    /** @deprecated use `CreateResultForLineItemSourcedIdPairs$inboundSchema` instead. */
    CreateResultForLineItemSourcedIdPairs$.inboundSchema = exports.CreateResultForLineItemSourcedIdPairs$inboundSchema;
    /** @deprecated use `CreateResultForLineItemSourcedIdPairs$outboundSchema` instead. */
    CreateResultForLineItemSourcedIdPairs$.outboundSchema = exports.CreateResultForLineItemSourcedIdPairs$outboundSchema;
})(CreateResultForLineItemSourcedIdPairs$ || (exports.CreateResultForLineItemSourcedIdPairs$ = CreateResultForLineItemSourcedIdPairs$ = {}));
function createResultForLineItemSourcedIdPairsToJSON(createResultForLineItemSourcedIdPairs) {
    return JSON.stringify(exports.CreateResultForLineItemSourcedIdPairs$outboundSchema.parse(createResultForLineItemSourcedIdPairs));
}
function createResultForLineItemSourcedIdPairsFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateResultForLineItemSourcedIdPairs$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateResultForLineItemSourcedIdPairs' from JSON`);
}
/** @internal */
exports.CreateResultForLineItemResponse$inboundSchema = z.object({
    sourcedIdPairs: z.lazy(() => exports.CreateResultForLineItemSourcedIdPairs$inboundSchema),
});
/** @internal */
exports.CreateResultForLineItemResponse$outboundSchema = z.object({
    sourcedIdPairs: z.lazy(() => exports.CreateResultForLineItemSourcedIdPairs$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateResultForLineItemResponse$;
(function (CreateResultForLineItemResponse$) {
    /** @deprecated use `CreateResultForLineItemResponse$inboundSchema` instead. */
    CreateResultForLineItemResponse$.inboundSchema = exports.CreateResultForLineItemResponse$inboundSchema;
    /** @deprecated use `CreateResultForLineItemResponse$outboundSchema` instead. */
    CreateResultForLineItemResponse$.outboundSchema = exports.CreateResultForLineItemResponse$outboundSchema;
})(CreateResultForLineItemResponse$ || (exports.CreateResultForLineItemResponse$ = CreateResultForLineItemResponse$ = {}));
function createResultForLineItemResponseToJSON(createResultForLineItemResponse) {
    return JSON.stringify(exports.CreateResultForLineItemResponse$outboundSchema.parse(createResultForLineItemResponse));
}
function createResultForLineItemResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateResultForLineItemResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateResultForLineItemResponse' from JSON`);
}
//# sourceMappingURL=createresultforlineitem.js.map