/**
 * Cloudflare TOKEN-VALIDATION API
 *
 * Generated from Cloudflare TypeScript SDK.
 * DO NOT EDIT - regenerate with: bun scripts/generate.ts --service token-validation
 */
import * as Schema from "effect/Schema";
import type * as HttpClient from "effect/unstable/http/HttpClient";
import * as API from "../client/api.ts";
import type { Credentials } from "../credentials.ts";
import { type DefaultErrors } from "../errors.ts";
export interface GetConfigurationRequest {
    configId: string;
    /** Identifier. */
    zoneId: string;
}
export declare const GetConfigurationRequest: Schema.Schema<GetConfigurationRequest>;
export interface GetConfigurationResponse {
    /** UUID. */
    id: string;
    createdAt: string;
    credentials: {
        keys: ({
            alg: "RS256" | "RS384" | "RS512" | "PS256" | "PS384" | "PS512";
            e: string;
            kid: string;
            kty: "RSA";
            n: string;
        } | {
            alg: "ES256";
            crv: "P-256";
            kid: string;
            kty: "EC";
            x: string;
            y: string;
        } | {
            alg: "ES384";
            crv: "P-384";
            kid: string;
            kty: "EC";
            x: string;
            y: string;
        })[];
    };
    description: string;
    lastUpdated: string;
    title: string;
    tokenSources: string[];
    tokenType: "JWT";
}
export declare const GetConfigurationResponse: Schema.Schema<GetConfigurationResponse>;
export type GetConfigurationError = DefaultErrors;
export declare const getConfiguration: API.OperationMethod<GetConfigurationRequest, GetConfigurationResponse, GetConfigurationError, Credentials | HttpClient.HttpClient>;
export interface ListConfigurationsRequest {
    /** Path param: Identifier. */
    zoneId: string;
    page?: number;
    perPage?: number;
}
export declare const ListConfigurationsRequest: Schema.Schema<ListConfigurationsRequest>;
export interface ListConfigurationsResponse {
    result: {
        id: string;
        createdAt: string;
        credentials: {
            keys: ({
                alg: "RS256" | "RS384" | "RS512" | "PS256" | "PS384" | "PS512";
                e: string;
                kid: string;
                kty: "RSA";
                n: string;
            } | {
                alg: "ES256";
                crv: "P-256";
                kid: string;
                kty: "EC";
                x: string;
                y: string;
            } | {
                alg: "ES384";
                crv: "P-384";
                kid: string;
                kty: "EC";
                x: string;
                y: string;
            })[];
        };
        description: string;
        lastUpdated: string;
        title: string;
        tokenSources: string[];
        tokenType: "JWT";
    }[];
    resultInfo?: {
        count?: number | null;
        page?: number | null;
        perPage?: number | null;
        totalCount?: number | null;
    } | null;
}
export declare const ListConfigurationsResponse: Schema.Schema<ListConfigurationsResponse>;
export type ListConfigurationsError = DefaultErrors;
export declare const listConfigurations: API.PaginatedOperationMethod<ListConfigurationsRequest, ListConfigurationsResponse, ListConfigurationsError, Credentials | HttpClient.HttpClient>;
export interface CreateConfigurationRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: */
    credentials: {
        keys: ({
            alg: "RS256" | "RS384" | "RS512" | "PS256" | "PS384" | "PS512";
            e: string;
            kid: string;
            kty: "RSA";
            n: string;
        } | {
            alg: "ES256";
            crv: "P-256";
            kid: string;
            kty: "EC";
            x: string;
            y: string;
        } | {
            alg: "ES384";
            crv: "P-384";
            kid: string;
            kty: "EC";
            x: string;
            y: string;
        })[];
    };
    /** Body param: */
    description: string;
    /** Body param: */
    title: string;
    /** Body param: */
    tokenSources: string[];
    /** Body param: */
    tokenType: "JWT";
}
export declare const CreateConfigurationRequest: Schema.Schema<CreateConfigurationRequest>;
export interface CreateConfigurationResponse {
    /** UUID. */
    id: string;
    createdAt: string;
    credentials: {
        keys: ({
            alg: "RS256" | "RS384" | "RS512" | "PS256" | "PS384" | "PS512";
            e: string;
            kid: string;
            kty: "RSA";
            n: string;
        } | {
            alg: "ES256";
            crv: "P-256";
            kid: string;
            kty: "EC";
            x: string;
            y: string;
        } | {
            alg: "ES384";
            crv: "P-384";
            kid: string;
            kty: "EC";
            x: string;
            y: string;
        })[];
    };
    description: string;
    lastUpdated: string;
    title: string;
    tokenSources: string[];
    tokenType: "JWT";
}
export declare const CreateConfigurationResponse: Schema.Schema<CreateConfigurationResponse>;
export type CreateConfigurationError = DefaultErrors;
export declare const createConfiguration: API.OperationMethod<CreateConfigurationRequest, CreateConfigurationResponse, CreateConfigurationError, Credentials | HttpClient.HttpClient>;
export interface PatchConfigurationRequest {
    configId: string;
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: */
    description?: string;
    /** Body param: */
    title?: string;
    /** Body param: */
    tokenSources?: string[];
}
export declare const PatchConfigurationRequest: Schema.Schema<PatchConfigurationRequest>;
export interface PatchConfigurationResponse {
    description?: string | null;
    title?: string | null;
    tokenSources?: string[] | null;
}
export declare const PatchConfigurationResponse: Schema.Schema<PatchConfigurationResponse>;
export type PatchConfigurationError = DefaultErrors;
export declare const patchConfiguration: API.OperationMethod<PatchConfigurationRequest, PatchConfigurationResponse, PatchConfigurationError, Credentials | HttpClient.HttpClient>;
export interface DeleteConfigurationRequest {
    configId: string;
    /** Identifier. */
    zoneId: string;
}
export declare const DeleteConfigurationRequest: Schema.Schema<DeleteConfigurationRequest>;
export interface DeleteConfigurationResponse {
    /** UUID. */
    id?: string | null;
}
export declare const DeleteConfigurationResponse: Schema.Schema<DeleteConfigurationResponse>;
export type DeleteConfigurationError = DefaultErrors;
export declare const deleteConfiguration: API.OperationMethod<DeleteConfigurationRequest, DeleteConfigurationResponse, DeleteConfigurationError, Credentials | HttpClient.HttpClient>;
export interface PutConfigurationCredentialRequest {
    configId: string;
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: */
    keys: ({
        alg: "RS256" | "RS384" | "RS512" | "PS256" | "PS384" | "PS512";
        e: string;
        kid: string;
        kty: "RSA";
        n: string;
    } | {
        alg: "ES256";
        crv: "P-256";
        kid: string;
        kty: "EC";
        x: string;
        y: string;
    } | {
        alg: "ES384";
        crv: "P-384";
        kid: string;
        kty: "EC";
        x: string;
        y: string;
    })[];
}
export declare const PutConfigurationCredentialRequest: Schema.Schema<PutConfigurationCredentialRequest>;
export interface PutConfigurationCredentialResponse {
    errors: {
        code: number;
        message: string;
        documentationUrl?: string | null;
        source?: {
            pointer?: string | null;
        } | null;
    }[];
    keys: ({
        alg: "RS256" | "RS384" | "RS512" | "PS256" | "PS384" | "PS512";
        e: string;
        kid: string;
        kty: "RSA";
        n: string;
    } | {
        alg: "ES256";
        crv: "P-256";
        kid: string;
        kty: "EC";
        x: string;
        y: string;
    } | {
        alg: "ES384";
        crv: "P-384";
        kid: string;
        kty: "EC";
        x: string;
        y: string;
    })[];
    messages: {
        code: number;
        message: string;
        documentationUrl?: string | null;
        source?: {
            pointer?: string | null;
        } | null;
    }[];
    /** Whether the API call was successful. */
    success: true;
}
export declare const PutConfigurationCredentialResponse: Schema.Schema<PutConfigurationCredentialResponse>;
export type PutConfigurationCredentialError = DefaultErrors;
export declare const putConfigurationCredential: API.OperationMethod<PutConfigurationCredentialRequest, PutConfigurationCredentialResponse, PutConfigurationCredentialError, Credentials | HttpClient.HttpClient>;
export interface GetRuleRequest {
    ruleId: string;
    /** Identifier. */
    zoneId: string;
}
export declare const GetRuleRequest: Schema.Schema<GetRuleRequest>;
export interface GetRuleResponse {
    /** Action to take on requests that match operations included in `selector` and fail `expression`. */
    action: "log" | "block";
    /** A human-readable description that gives more details than `title`. */
    description: string;
    /** Toggle rule on or off. */
    enabled: boolean;
    /** Rule expression. Requests that fail to match this expression will be subject to `action`.  For details on expressions, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/j */
    expression: string;
    /** Select operations covered by this rule.  For details on selectors, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/jwt-validation/). */
    selector: {
        exclude?: {
            operationIds?: string[] | null;
        }[] | null;
        include?: {
            host?: string[] | null;
        }[] | null;
    };
    /** A human-readable name for the rule. */
    title: string;
    /** UUID. */
    id?: string | null;
    createdAt?: string | null;
    lastUpdated?: string | null;
}
export declare const GetRuleResponse: Schema.Schema<GetRuleResponse>;
export type GetRuleError = DefaultErrors;
export declare const getRule: API.OperationMethod<GetRuleRequest, GetRuleResponse, GetRuleError, Credentials | HttpClient.HttpClient>;
export interface ListRulesRequest {
    /** Path param: Identifier. */
    zoneId: string;
    page?: number;
    perPage?: number;
    /** Query param: Select rules with these IDs. */
    id?: string;
    /** Query param: Action to take on requests that match operations included in `selector` and fail `expression`. */
    action?: "log" | "block";
    /** Query param: Toggle rule on or off. */
    enabled?: boolean;
    /** Query param: Select rules with this host in `include`. */
    host?: string;
    /** Query param: Select rules with this host in `include`. */
    hostname?: string;
    /** Query param: Select rules with these IDs. */
    ruleId?: string;
    /** Query param: Select rules using any of these token configurations. */
    tokenConfiguration?: string[];
}
export declare const ListRulesRequest: Schema.Schema<ListRulesRequest>;
export interface ListRulesResponse {
    result: {
        action: "log" | "block";
        description: string;
        enabled: boolean;
        expression: string;
        selector: {
            exclude?: {
                operationIds?: string[] | null;
            }[] | null;
            include?: {
                host?: string[] | null;
            }[] | null;
        };
        title: string;
        id?: string | null;
        createdAt?: string | null;
        lastUpdated?: string | null;
    }[];
    resultInfo?: {
        count?: number | null;
        page?: number | null;
        perPage?: number | null;
        totalCount?: number | null;
    } | null;
}
export declare const ListRulesResponse: Schema.Schema<ListRulesResponse>;
export type ListRulesError = DefaultErrors;
export declare const listRules: API.PaginatedOperationMethod<ListRulesRequest, ListRulesResponse, ListRulesError, Credentials | HttpClient.HttpClient>;
export interface CreateRuleRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: Action to take on requests that match operations included in `selector` and fail `expression`. */
    action: "log" | "block";
    /** Body param: A human-readable description that gives more details than `title`. */
    description: string;
    /** Body param: Toggle rule on or off. */
    enabled: boolean;
    /** Body param: Rule expression. Requests that fail to match this expression will be subject to `action`.  For details on expressions, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shiel */
    expression: string;
    /** Body param: Select operations covered by this rule.  For details on selectors, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/jwt-validation/). */
    selector: {
        exclude?: {
            operationIds?: string[];
        }[] | null;
        include?: {
            host?: string[];
        }[] | null;
    };
    /** Body param: A human-readable name for the rule. */
    title: string;
}
export declare const CreateRuleRequest: Schema.Schema<CreateRuleRequest>;
export interface CreateRuleResponse {
    /** Action to take on requests that match operations included in `selector` and fail `expression`. */
    action: "log" | "block";
    /** A human-readable description that gives more details than `title`. */
    description: string;
    /** Toggle rule on or off. */
    enabled: boolean;
    /** Rule expression. Requests that fail to match this expression will be subject to `action`.  For details on expressions, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/j */
    expression: string;
    /** Select operations covered by this rule.  For details on selectors, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/jwt-validation/). */
    selector: {
        exclude?: {
            operationIds?: string[] | null;
        }[] | null;
        include?: {
            host?: string[] | null;
        }[] | null;
    };
    /** A human-readable name for the rule. */
    title: string;
    /** UUID. */
    id?: string | null;
    createdAt?: string | null;
    lastUpdated?: string | null;
}
export declare const CreateRuleResponse: Schema.Schema<CreateRuleResponse>;
export type CreateRuleError = DefaultErrors;
export declare const createRule: API.OperationMethod<CreateRuleRequest, CreateRuleResponse, CreateRuleError, Credentials | HttpClient.HttpClient>;
export interface PatchRuleRequest {
    ruleId: string;
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: Action to take on requests that match operations included in `selector` and fail `expression`. */
    action?: "log" | "block";
    /** Body param: A human-readable description that gives more details than `title`. */
    description?: string;
    /** Body param: Toggle rule on or off. */
    enabled?: boolean;
    /** Body param: Rule expression. Requests that fail to match this expression will be subject to `action`.  For details on expressions, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shiel */
    expression?: string;
    /** Body param: Update rule order among zone rules. */
    position?: {
        index: number;
    } | {
        before?: string;
    } | {
        after?: string;
    };
    /** Body param: Select operations covered by this rule.  For details on selectors, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/jwt-validation/). */
    selector?: {
        exclude?: {
            operationIds?: string[];
        }[] | null;
        include?: {
            host?: string[];
        }[] | null;
    };
    /** Body param: A human-readable name for the rule. */
    title?: string;
}
export declare const PatchRuleRequest: Schema.Schema<PatchRuleRequest>;
export interface PatchRuleResponse {
    /** Action to take on requests that match operations included in `selector` and fail `expression`. */
    action: "log" | "block";
    /** A human-readable description that gives more details than `title`. */
    description: string;
    /** Toggle rule on or off. */
    enabled: boolean;
    /** Rule expression. Requests that fail to match this expression will be subject to `action`.  For details on expressions, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/j */
    expression: string;
    /** Select operations covered by this rule.  For details on selectors, see the [Cloudflare Docs](https://developers.cloudflare.com/api-shield/security/jwt-validation/). */
    selector: {
        exclude?: {
            operationIds?: string[] | null;
        }[] | null;
        include?: {
            host?: string[] | null;
        }[] | null;
    };
    /** A human-readable name for the rule. */
    title: string;
    /** UUID. */
    id?: string | null;
    createdAt?: string | null;
    lastUpdated?: string | null;
}
export declare const PatchRuleResponse: Schema.Schema<PatchRuleResponse>;
export type PatchRuleError = DefaultErrors;
export declare const patchRule: API.OperationMethod<PatchRuleRequest, PatchRuleResponse, PatchRuleError, Credentials | HttpClient.HttpClient>;
export interface DeleteRuleRequest {
    ruleId: string;
    /** Identifier. */
    zoneId: string;
}
export declare const DeleteRuleRequest: Schema.Schema<DeleteRuleRequest>;
export type DeleteRuleResponse = unknown;
export declare const DeleteRuleResponse: Schema.Schema<DeleteRuleResponse>;
export type DeleteRuleError = DefaultErrors;
export declare const deleteRule: API.OperationMethod<DeleteRuleRequest, DeleteRuleResponse, DeleteRuleError, Credentials | HttpClient.HttpClient>;
export interface BulkCreateRulesRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: */
    body: {
        action: "log" | "block";
        description: string;
        enabled: boolean;
        expression: string;
        selector: {
            exclude?: {
                operationIds?: string[];
            }[] | null;
            include?: {
                host?: string[];
            }[] | null;
        };
        title: string;
    }[];
}
export declare const BulkCreateRulesRequest: Schema.Schema<BulkCreateRulesRequest>;
export interface BulkCreateRulesResponse {
    result: {
        action: "log" | "block";
        description: string;
        enabled: boolean;
        expression: string;
        selector: {
            exclude?: {
                operationIds?: string[] | null;
            }[] | null;
            include?: {
                host?: string[] | null;
            }[] | null;
        };
        title: string;
        id?: string | null;
        createdAt?: string | null;
        lastUpdated?: string | null;
    }[];
}
export declare const BulkCreateRulesResponse: Schema.Schema<BulkCreateRulesResponse>;
export type BulkCreateRulesError = DefaultErrors;
export declare const bulkCreateRules: API.PaginatedOperationMethod<BulkCreateRulesRequest, BulkCreateRulesResponse, BulkCreateRulesError, Credentials | HttpClient.HttpClient>;
export interface BulkPatchRulesRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: */
    body: {
        id: string;
        action?: "log" | "block";
        description?: string;
        enabled?: boolean;
        expression?: string;
        position?: {
            index: number;
        } | {
            before?: string;
        } | {
            after?: string;
        };
        selector?: {
            exclude?: {
                operationIds?: string[];
            }[] | null;
            include?: {
                host?: string[];
            }[] | null;
        };
        title?: string;
    }[];
}
export declare const BulkPatchRulesRequest: Schema.Schema<BulkPatchRulesRequest>;
export interface BulkPatchRulesResponse {
    result: {
        action: "log" | "block";
        description: string;
        enabled: boolean;
        expression: string;
        selector: {
            exclude?: {
                operationIds?: string[] | null;
            }[] | null;
            include?: {
                host?: string[] | null;
            }[] | null;
        };
        title: string;
        id?: string | null;
        createdAt?: string | null;
        lastUpdated?: string | null;
    }[];
}
export declare const BulkPatchRulesResponse: Schema.Schema<BulkPatchRulesResponse>;
export type BulkPatchRulesError = DefaultErrors;
export declare const bulkPatchRules: API.PaginatedOperationMethod<BulkPatchRulesRequest, BulkPatchRulesResponse, BulkPatchRulesError, Credentials | HttpClient.HttpClient>;
//# sourceMappingURL=token-validation.d.ts.map