/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import * as z from "zod";
import { safeParse } from "../../lib/schemas.js";
import { BasinConfig$inboundSchema, BasinConfig$outboundSchema, } from "./basinconfig.js";
import { BasinScope$inboundSchema, BasinScope$outboundSchema, } from "./basinscope.js";
/** @internal */
export const Scope$inboundSchema = BasinScope$inboundSchema;
/** @internal */
export const Scope$outboundSchema = BasinScope$outboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var Scope$;
(function (Scope$) {
    /** @deprecated use `Scope$inboundSchema` instead. */
    Scope$.inboundSchema = Scope$inboundSchema;
    /** @deprecated use `Scope$outboundSchema` instead. */
    Scope$.outboundSchema = Scope$outboundSchema;
})(Scope$ || (Scope$ = {}));
export function scopeToJSON(scope) {
    return JSON.stringify(Scope$outboundSchema.parse(scope));
}
export function scopeFromJSON(jsonString) {
    return safeParse(jsonString, (x) => Scope$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Scope' from JSON`);
}
/** @internal */
export const CreateBasinRequest$inboundSchema = z.object({
    basin: z.string(),
    config: z.nullable(BasinConfig$inboundSchema).optional(),
    scope: BasinScope$inboundSchema.optional(),
});
/** @internal */
export const CreateBasinRequest$outboundSchema = z.object({
    basin: z.string(),
    config: z.nullable(BasinConfig$outboundSchema).optional(),
    scope: BasinScope$outboundSchema.optional(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var CreateBasinRequest$;
(function (CreateBasinRequest$) {
    /** @deprecated use `CreateBasinRequest$inboundSchema` instead. */
    CreateBasinRequest$.inboundSchema = CreateBasinRequest$inboundSchema;
    /** @deprecated use `CreateBasinRequest$outboundSchema` instead. */
    CreateBasinRequest$.outboundSchema = CreateBasinRequest$outboundSchema;
})(CreateBasinRequest$ || (CreateBasinRequest$ = {}));
export function createBasinRequestToJSON(createBasinRequest) {
    return JSON.stringify(CreateBasinRequest$outboundSchema.parse(createBasinRequest));
}
export function createBasinRequestFromJSON(jsonString) {
    return safeParse(jsonString, (x) => CreateBasinRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateBasinRequest' from JSON`);
}
//# sourceMappingURL=createbasinrequest.js.map