@accelerated-software-development/caddy-api-client - v0.2.2
    Preparing search index...

    Variable ReverseProxyHandlerSchemaConst

    ReverseProxyHandlerSchema: ZodObject<
        {
            flush_interval: ZodOptional<ZodUnion<[ZodNumber, ZodString]>>;
            handler: ZodLiteral<"reverse_proxy">;
            headers: ZodOptional<
                ZodObject<
                    {
                        request: ZodOptional<
                            ZodObject<
                                {
                                    add: ZodOptional<ZodRecord<ZodString, ZodArray<(...), (...)>>>;
                                    delete: ZodOptional<ZodArray<ZodString, "many">>;
                                    set: ZodOptional<ZodRecord<ZodString, ZodArray<(...), (...)>>>;
                                },
                                "strip",
                                ZodTypeAny,
                                {
                                    add?: Record<string, (...)[]>;
                                    delete?: string[];
                                    set?: Record<string, (...)[]>;
                                },
                                {
                                    add?: Record<string, (...)[]>;
                                    delete?: string[];
                                    set?: Record<string, (...)[]>;
                                },
                            >,
                        >;
                        response: ZodOptional<
                            ZodObject<
                                {
                                    add: ZodOptional<ZodRecord<ZodString, ZodArray<(...), (...)>>>;
                                    delete: ZodOptional<ZodArray<ZodString, "many">>;
                                    set: ZodOptional<ZodRecord<ZodString, ZodArray<(...), (...)>>>;
                                },
                                "strip",
                                ZodTypeAny,
                                {
                                    add?: Record<string, (...)[]>;
                                    delete?: string[];
                                    set?: Record<string, (...)[]>;
                                },
                                {
                                    add?: Record<string, (...)[]>;
                                    delete?: string[];
                                    set?: Record<string, (...)[]>;
                                },
                            >,
                        >;
                    },
                    "strip",
                    ZodTypeAny,
                    {
                        request?: {
                            add?: Record<string, string[]>;
                            delete?: string[];
                            set?: Record<string, string[]>;
                        };
                        response?: {
                            add?: Record<string, string[]>;
                            delete?: string[];
                            set?: Record<string, string[]>;
                        };
                    },
                    {
                        request?: {
                            add?: Record<string, string[]>;
                            delete?: string[];
                            set?: Record<string, string[]>;
                        };
                        response?: {
                            add?: Record<string, string[]>;
                            delete?: string[];
                            set?: Record<string, string[]>;
                        };
                    },
                >,
            >;
            health_checks: ZodOptional<
                ZodObject<
                    {
                        active: ZodOptional<
                            ZodObject<
                                {
                                    expect_body: ZodOptional<ZodString>;
                                    expect_status: ZodOptional<ZodNumber>;
                                    fails: ZodOptional<ZodNumber>;
                                    follow_redirects: ZodOptional<ZodBoolean>;
                                    headers: ZodOptional<ZodRecord<ZodString, ZodArray<(...), (...)>>>;
                                    interval: ZodOptional<ZodUnion<[(...), (...)]>>;
                                    max_size: ZodOptional<ZodNumber>;
                                    passes: ZodOptional<ZodNumber>;
                                    path: ZodOptional<ZodString>;
                                    port: ZodOptional<ZodNumber>;
                                    timeout: ZodOptional<ZodUnion<[(...), (...)]>>;
                                    uri: ZodOptional<ZodString>;
                                },
                                "strip",
                                ZodTypeAny,
                                {
                                    expect_body?: string;
                                    expect_status?: number;
                                    fails?: number;
                                    follow_redirects?: boolean;
                                    headers?: Record<string, (...)[]>;
                                    interval?: string | number;
                                    max_size?: number;
                                    passes?: number;
                                    path?: string;
                                    port?: number;
                                    timeout?: string | number;
                                    uri?: string;
                                },
                                {
                                    expect_body?: string;
                                    expect_status?: number;
                                    fails?: number;
                                    follow_redirects?: boolean;
                                    headers?: Record<string, (...)[]>;
                                    interval?: string | number;
                                    max_size?: number;
                                    passes?: number;
                                    path?: string;
                                    port?: number;
                                    timeout?: string | number;
                                    uri?: string;
                                },
                            >,
                        >;
                        passive: ZodOptional<
                            ZodObject<
                                {
                                    fail_duration: ZodOptional<ZodUnion<[(...), (...)]>>;
                                    max_fails: ZodOptional<ZodNumber>;
                                    unhealthy_latency: ZodOptional<ZodUnion<[(...), (...)]>>;
                                    unhealthy_request_count: ZodOptional<ZodNumber>;
                                    unhealthy_status: ZodOptional<ZodArray<ZodNumber, "many">>;
                                },
                                "strip",
                                ZodTypeAny,
                                {
                                    fail_duration?: string
                                    | number;
                                    max_fails?: number;
                                    unhealthy_latency?: string | number;
                                    unhealthy_request_count?: number;
                                    unhealthy_status?: number[];
                                },
                                {
                                    fail_duration?: string
                                    | number;
                                    max_fails?: number;
                                    unhealthy_latency?: string | number;
                                    unhealthy_request_count?: number;
                                    unhealthy_status?: number[];
                                },
                            >,
                        >;
                    },
                    "strip",
                    ZodTypeAny,
                    {
                        active?: {
                            expect_body?: string;
                            expect_status?: number;
                            fails?: number;
                            follow_redirects?: boolean;
                            headers?: Record<string, string[]>;
                            interval?: string | number;
                            max_size?: number;
                            passes?: number;
                            path?: string;
                            port?: number;
                            timeout?: string | number;
                            uri?: string;
                        };
                        passive?: {
                            fail_duration?: string
                            | number;
                            max_fails?: number;
                            unhealthy_latency?: string | number;
                            unhealthy_request_count?: number;
                            unhealthy_status?: number[];
                        };
                    },
                    {
                        active?: {
                            expect_body?: string;
                            expect_status?: number;
                            fails?: number;
                            follow_redirects?: boolean;
                            headers?: Record<string, string[]>;
                            interval?: string | number;
                            max_size?: number;
                            passes?: number;
                            path?: string;
                            port?: number;
                            timeout?: string | number;
                            uri?: string;
                        };
                        passive?: {
                            fail_duration?: string
                            | number;
                            max_fails?: number;
                            unhealthy_latency?: string | number;
                            unhealthy_request_count?: number;
                            unhealthy_status?: number[];
                        };
                    },
                >,
            >;
            load_balancing: ZodOptional<
                ZodObject<
                    {
                        retries: ZodOptional<ZodNumber>;
                        selection_policy: ZodOptional<
                            ZodObject<
                                {
                                    policy: ZodEnum<
                                        [
                                            "first",
                                            "random",
                                            "least_conn",
                                            "round_robin",
                                            "ip_hash",
                                            "uri_hash",
                                            "header",
                                            "cookie",
                                        ],
                                    >;
                                },
                                "passthrough",
                                ZodTypeAny,
                                objectOutputType<
                                    {
                                        policy: ZodEnum<
                                            [(...), (...), (...), (...), (...), (...), (...), (...)],
                                        >;
                                    },
                                    ZodTypeAny,
                                    "passthrough",
                                >,
                                objectInputType<
                                    {
                                        policy: ZodEnum<
                                            [(...), (...), (...), (...), (...), (...), (...), (...)],
                                        >;
                                    },
                                    ZodTypeAny,
                                    "passthrough",
                                >,
                            >,
                        >;
                        try_duration: ZodOptional<ZodUnion<[ZodNumber, ZodString]>>;
                        try_interval: ZodOptional<ZodUnion<[ZodNumber, ZodString]>>;
                    },
                    "strip",
                    ZodTypeAny,
                    {
                        retries?: number;
                        selection_policy?: objectOutputType<
                            {
                                policy: ZodEnum<
                                    [
                                        "first",
                                        "random",
                                        "least_conn",
                                        "round_robin",
                                        "ip_hash",
                                        "uri_hash",
                                        "header",
                                        "cookie",
                                    ],
                                >;
                            },
                            ZodTypeAny,
                            "passthrough",
                        >;
                        try_duration?: string
                        | number;
                        try_interval?: string | number;
                    },
                    {
                        retries?: number;
                        selection_policy?: objectInputType<
                            {
                                policy: ZodEnum<
                                    [
                                        "first",
                                        "random",
                                        "least_conn",
                                        "round_robin",
                                        "ip_hash",
                                        "uri_hash",
                                        "header",
                                        "cookie",
                                    ],
                                >;
                            },
                            ZodTypeAny,
                            "passthrough",
                        >;
                        try_duration?: string
                        | number;
                        try_interval?: string | number;
                    },
                >,
            >;
            request_buffers: ZodOptional<ZodNumber>;
            response_buffers: ZodOptional<ZodNumber>;
            transport: ZodOptional<
                ZodObject<
                    { protocol: ZodString },
                    "passthrough",
                    ZodTypeAny,
                    objectOutputType<{ protocol: ZodString }, ZodTypeAny, "passthrough">,
                    objectInputType<{ protocol: ZodString }, ZodTypeAny, "passthrough">,
                >,
            >;
            upstreams: ZodOptional<
                ZodArray<
                    ZodObject<
                        { dial: ZodString; max_requests: ZodOptional<ZodNumber> },
                        "strip",
                        ZodTypeAny,
                        { dial: string; max_requests?: number },
                        { dial: string; max_requests?: number },
                    >,
                    "many",
                >,
            >;
        },
        "strip",
        ZodTypeAny,
        {
            flush_interval?: string
            | number;
            handler: "reverse_proxy";
            headers?: {
                request?: {
                    add?: Record<string, string[]>;
                    delete?: string[];
                    set?: Record<string, string[]>;
                };
                response?: {
                    add?: Record<string, string[]>;
                    delete?: string[];
                    set?: Record<string, string[]>;
                };
            };
            health_checks?: {
                active?: {
                    expect_body?: string;
                    expect_status?: number;
                    fails?: number;
                    follow_redirects?: boolean;
                    headers?: Record<string, string[]>;
                    interval?: string | number;
                    max_size?: number;
                    passes?: number;
                    path?: string;
                    port?: number;
                    timeout?: string | number;
                    uri?: string;
                };
                passive?: {
                    fail_duration?: string
                    | number;
                    max_fails?: number;
                    unhealthy_latency?: string | number;
                    unhealthy_request_count?: number;
                    unhealthy_status?: number[];
                };
            };
            load_balancing?: {
                retries?: number;
                selection_policy?: objectOutputType<
                    {
                        policy: ZodEnum<
                            [
                                "first",
                                "random",
                                "least_conn",
                                "round_robin",
                                "ip_hash",
                                "uri_hash",
                                "header",
                                "cookie",
                            ],
                        >;
                    },
                    ZodTypeAny,
                    "passthrough",
                >;
                try_duration?: string
                | number;
                try_interval?: string | number;
            };
            request_buffers?: number;
            response_buffers?: number;
            transport?: objectOutputType<
                { protocol: ZodString },
                ZodTypeAny,
                "passthrough",
            >;
            upstreams?: { dial: string; max_requests?: number }[];
        },
        {
            flush_interval?: string
            | number;
            handler: "reverse_proxy";
            headers?: {
                request?: {
                    add?: Record<string, string[]>;
                    delete?: string[];
                    set?: Record<string, string[]>;
                };
                response?: {
                    add?: Record<string, string[]>;
                    delete?: string[];
                    set?: Record<string, string[]>;
                };
            };
            health_checks?: {
                active?: {
                    expect_body?: string;
                    expect_status?: number;
                    fails?: number;
                    follow_redirects?: boolean;
                    headers?: Record<string, string[]>;
                    interval?: string | number;
                    max_size?: number;
                    passes?: number;
                    path?: string;
                    port?: number;
                    timeout?: string | number;
                    uri?: string;
                };
                passive?: {
                    fail_duration?: string
                    | number;
                    max_fails?: number;
                    unhealthy_latency?: string | number;
                    unhealthy_request_count?: number;
                    unhealthy_status?: number[];
                };
            };
            load_balancing?: {
                retries?: number;
                selection_policy?: objectInputType<
                    {
                        policy: ZodEnum<
                            [
                                "first",
                                "random",
                                "least_conn",
                                "round_robin",
                                "ip_hash",
                                "uri_hash",
                                "header",
                                "cookie",
                            ],
                        >;
                    },
                    ZodTypeAny,
                    "passthrough",
                >;
                try_duration?: string
                | number;
                try_interval?: string | number;
            };
            request_buffers?: number;
            response_buffers?: number;
            transport?: objectInputType<
                { protocol: ZodString },
                ZodTypeAny,
                "passthrough",
            >;
            upstreams?: { dial: string; max_requests?: number }[];
        },
    > = ...

    Reverse proxy handler schema with full options