/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import * as z from "zod";
import { remap as remap$ } from "../../lib/primitives.js";
import { safeParse } from "../../lib/schemas.js";
import * as components from "../components/index.js";
/** @internal */
export const ListResourcesByContextGlobals$inboundSchema = z.object({
    cloud_name: z.string().optional(),
}).transform((v) => {
    return remap$(v, {
        "cloud_name": "cloudName",
    });
});
/** @internal */
export const ListResourcesByContextGlobals$outboundSchema = z.object({
    cloudName: z.string().optional(),
}).transform((v) => {
    return remap$(v, {
        cloudName: "cloud_name",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var ListResourcesByContextGlobals$;
(function (ListResourcesByContextGlobals$) {
    /** @deprecated use `ListResourcesByContextGlobals$inboundSchema` instead. */
    ListResourcesByContextGlobals$.inboundSchema = ListResourcesByContextGlobals$inboundSchema;
    /** @deprecated use `ListResourcesByContextGlobals$outboundSchema` instead. */
    ListResourcesByContextGlobals$.outboundSchema = ListResourcesByContextGlobals$outboundSchema;
})(ListResourcesByContextGlobals$ || (ListResourcesByContextGlobals$ = {}));
export function listResourcesByContextGlobalsToJSON(listResourcesByContextGlobals) {
    return JSON.stringify(ListResourcesByContextGlobals$outboundSchema.parse(listResourcesByContextGlobals));
}
export function listResourcesByContextGlobalsFromJSON(jsonString) {
    return safeParse(jsonString, (x) => ListResourcesByContextGlobals$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ListResourcesByContextGlobals' from JSON`);
}
/** @internal */
export const ListResourcesByContextRequest$inboundSchema = z.object({
    resource_type: components.ResourceTypeParameter$inboundSchema,
    key: z.string(),
    value: z.string().optional(),
    next_cursor: z.string().optional(),
    max_results: z.number().int().optional(),
    direction: components.Direction$inboundSchema.optional(),
    fields: z.array(components.FieldsSpec$inboundSchema).optional(),
}).transform((v) => {
    return remap$(v, {
        "resource_type": "resourceType",
        "next_cursor": "nextCursor",
        "max_results": "maxResults",
    });
});
/** @internal */
export const ListResourcesByContextRequest$outboundSchema = z.object({
    resourceType: components.ResourceTypeParameter$outboundSchema,
    key: z.string(),
    value: z.string().optional(),
    nextCursor: z.string().optional(),
    maxResults: z.number().int().optional(),
    direction: components.Direction$outboundSchema.optional(),
    fields: z.array(components.FieldsSpec$outboundSchema).optional(),
}).transform((v) => {
    return remap$(v, {
        resourceType: "resource_type",
        nextCursor: "next_cursor",
        maxResults: "max_results",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var ListResourcesByContextRequest$;
(function (ListResourcesByContextRequest$) {
    /** @deprecated use `ListResourcesByContextRequest$inboundSchema` instead. */
    ListResourcesByContextRequest$.inboundSchema = ListResourcesByContextRequest$inboundSchema;
    /** @deprecated use `ListResourcesByContextRequest$outboundSchema` instead. */
    ListResourcesByContextRequest$.outboundSchema = ListResourcesByContextRequest$outboundSchema;
})(ListResourcesByContextRequest$ || (ListResourcesByContextRequest$ = {}));
export function listResourcesByContextRequestToJSON(listResourcesByContextRequest) {
    return JSON.stringify(ListResourcesByContextRequest$outboundSchema.parse(listResourcesByContextRequest));
}
export function listResourcesByContextRequestFromJSON(jsonString) {
    return safeParse(jsonString, (x) => ListResourcesByContextRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ListResourcesByContextRequest' from JSON`);
}
//# sourceMappingURL=listresourcesbycontext.js.map