@vercel/sdk
Version:
<p align="center"> <a href="https://vercel.com"> <img src="https://assets.vercel.com/image/upload/v1588805858/repositories/vercel/logo.png" height="96"> <h3 align="center">Vercel</h3> </a> <p align="center">Develop. Preview. Ship.</p> </p>
4,506 lines • 149 kB
text/typescript
/*
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
*/
import * as z from "zod/v3";
import { remap as remap$ } from "../lib/primitives.js";
import { safeParse } from "../lib/schemas.js";
import { ClosedEnum } from "../types/enums.js";
import { Result as SafeParseResult } from "../types/fp.js";
import * as types from "../types/primitives.js";
import { smartUnion } from "../types/smartUnion.js";
import { SDKValidationError } from "./sdkvalidationerror.js";
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction
>;
export type GetSecurityFirewallConfigSecurityResponseSd = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction
>;
export type GetSecurityFirewallConfigSecurityResponseMa = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction
>;
export type GetSecurityFirewallConfigSecurityResponseLfi = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction;
};
export const GetSecurityFirewallConfigSecurityResponse200Action = {
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200Action = ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200Action
>;
export type GetSecurityFirewallConfigSecurityResponseRfi = {
active: boolean;
action: GetSecurityFirewallConfigSecurityResponse200Action;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction
>;
export type GetSecurityFirewallConfigSecurityResponseRce = {
active: boolean;
action: GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction
>;
export type GetSecurityFirewallConfigSecurityResponsePhp = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction
>;
export type GetSecurityFirewallConfigSecurityResponseGen = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction
>;
export type GetSecurityFirewallConfigSecurityResponseXss = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction
>;
export type GetSecurityFirewallConfigSecurityResponseSqli = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction
>;
export type GetSecurityFirewallConfigSecurityResponseSf = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction
>;
export type GetSecurityFirewallConfigSecurityResponseJava = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction;
};
export type GetSecurityFirewallConfigSecurityResponseCrs = {
sd: GetSecurityFirewallConfigSecurityResponseSd;
ma: GetSecurityFirewallConfigSecurityResponseMa;
lfi: GetSecurityFirewallConfigSecurityResponseLfi;
rfi: GetSecurityFirewallConfigSecurityResponseRfi;
rce: GetSecurityFirewallConfigSecurityResponseRce;
php: GetSecurityFirewallConfigSecurityResponsePhp;
gen: GetSecurityFirewallConfigSecurityResponseGen;
xss: GetSecurityFirewallConfigSecurityResponseXss;
sqli: GetSecurityFirewallConfigSecurityResponseSqli;
sf: GetSecurityFirewallConfigSecurityResponseSf;
java: GetSecurityFirewallConfigSecurityResponseJava;
};
export const GetSecurityFirewallConfigRulesType = {
BotCategory: "bot_category",
BotName: "bot_name",
BotProtection: "bot_protection",
BotStatus: "bot_status",
Cookie: "cookie",
DomainEnvironment: "domain_environment",
Environment: "environment",
GeoAsNumber: "geo_as_number",
GeoCity: "geo_city",
GeoContinent: "geo_continent",
GeoCountry: "geo_country",
GeoCountryRegion: "geo_country_region",
Header: "header",
Host: "host",
IpAddress: "ip_address",
Ja3Digest: "ja3_digest",
Ja4Digest: "ja4_digest",
Method: "method",
Path: "path",
Protocol: "protocol",
Query: "query",
RateLimitApiId: "rate_limit_api_id",
RawPath: "raw_path",
Region: "region",
Route: "route",
Ruleset: "ruleset",
Scheme: "scheme",
ServerAction: "server_action",
SharedCondition: "shared_condition",
TargetPath: "target_path",
TrafficSource: "traffic_source",
TrustedSource: "trusted_source",
UserAgent: "user_agent",
} as const;
export type GetSecurityFirewallConfigRulesType = ClosedEnum<
typeof GetSecurityFirewallConfigRulesType
>;
export const GetSecurityFirewallConfigRulesOp = {
Eq: "eq",
Ex: "ex",
Gt: "gt",
Gte: "gte",
Inc: "inc",
List: "list",
Lt: "lt",
Lte: "lte",
Neq: "neq",
Nex: "nex",
Ninc: "ninc",
Pre: "pre",
Re: "re",
Sub: "sub",
Suf: "suf",
} as const;
export type GetSecurityFirewallConfigRulesOp = ClosedEnum<
typeof GetSecurityFirewallConfigRulesOp
>;
export type GetSecurityFirewallConfigRulesValue =
| string
| number
| Array<string>;
export type GetSecurityFirewallConfigRulesConditions = {
type: GetSecurityFirewallConfigRulesType;
op: GetSecurityFirewallConfigRulesOp;
neg?: boolean | undefined;
key?: string | undefined;
value?: string | number | Array<string> | undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup =
{
conditions: Array<GetSecurityFirewallConfigRulesConditions>;
};
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action =
{
Allow: "allow",
Bypass: "bypass",
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
Redirect: "redirect",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action
>;
export const GetSecurityFirewallConfigRulesAlgo = {
FixedWindow: "fixed_window",
TokenBucket: "token_bucket",
} as const;
export type GetSecurityFirewallConfigRulesAlgo = ClosedEnum<
typeof GetSecurityFirewallConfigRulesAlgo
>;
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction
>;
export type GetSecurityFirewallConfigRulesRateLimit = {
algo: GetSecurityFirewallConfigRulesAlgo;
window: number;
limit: number;
keys: Array<string>;
action?:
| GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction
| null
| undefined;
};
export type GetSecurityFirewallConfigRulesRedirect = {
location: string;
permanent: boolean;
};
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22 =
{
Wildcard: "*",
} as const;
export type GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22 =
ClosedEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22
>;
export type GetSecurityFirewallConfigRulesLogHeaders =
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22;
export type GetSecurityFirewallConfigRulesMitigate = {
action:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action;
rateLimit?: GetSecurityFirewallConfigRulesRateLimit | null | undefined;
redirect?: GetSecurityFirewallConfigRulesRedirect | null | undefined;
actionDuration?: string | null | undefined;
bypassSystem?: boolean | null | undefined;
logHeaders?:
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22
| undefined;
};
export type GetSecurityFirewallConfigRulesAction = {
mitigate?: GetSecurityFirewallConfigRulesMitigate | undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponse2 = {
id: string;
name: string;
description?: string | undefined;
active: boolean;
conditionGroup: Array<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup
>;
action: GetSecurityFirewallConfigRulesAction;
valid: false;
validationErrors: Array<string>;
};
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType =
{
BotCategory: "bot_category",
BotName: "bot_name",
BotProtection: "bot_protection",
BotStatus: "bot_status",
Cookie: "cookie",
DomainEnvironment: "domain_environment",
Environment: "environment",
GeoAsNumber: "geo_as_number",
GeoCity: "geo_city",
GeoContinent: "geo_continent",
GeoCountry: "geo_country",
GeoCountryRegion: "geo_country_region",
Header: "header",
Host: "host",
IpAddress: "ip_address",
Ja3Digest: "ja3_digest",
Ja4Digest: "ja4_digest",
Method: "method",
Path: "path",
Protocol: "protocol",
Query: "query",
RateLimitApiId: "rate_limit_api_id",
RawPath: "raw_path",
Region: "region",
Route: "route",
Ruleset: "ruleset",
Scheme: "scheme",
ServerAction: "server_action",
SharedCondition: "shared_condition",
TargetPath: "target_path",
TrafficSource: "traffic_source",
TrustedSource: "trusted_source",
UserAgent: "user_agent",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType
>;
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp =
{
Eq: "eq",
Ex: "ex",
Gt: "gt",
Gte: "gte",
Inc: "inc",
List: "list",
Lt: "lt",
Lte: "lte",
Neq: "neq",
Nex: "nex",
Ninc: "ninc",
Pre: "pre",
Re: "re",
Sub: "sub",
Suf: "suf",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp
>;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyValue =
| string
| number
| Array<string>;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions =
{
type:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType;
op:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp;
neg?: boolean | undefined;
key?: string | undefined;
value?: string | number | Array<string> | undefined;
};
export type GetSecurityFirewallConfigRulesConditionGroup = {
conditions: Array<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions
>;
};
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction =
{
Allow: "allow",
Bypass: "bypass",
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
Redirect: "redirect",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction
>;
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo =
{
FixedWindow: "fixed_window",
TokenBucket: "token_bucket",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo
>;
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action
>;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit =
{
algo:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo;
window: number;
limit: number;
keys: Array<string>;
action?:
| GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action
| null
| undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect =
{
location: string;
permanent: boolean;
};
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2 =
{
Wildcard: "*",
} as const;
export type GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2 =
ClosedEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2
>;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyLogHeaders =
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate =
{
action:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction;
rateLimit?:
| GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit
| null
| undefined;
redirect?:
| GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect
| null
| undefined;
actionDuration?: string | null | undefined;
bypassSystem?: boolean | null | undefined;
logHeaders?:
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2
| undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction =
{
mitigate?:
| GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate
| undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponse1 = {
id: string;
name: string;
description?: string | undefined;
active: boolean;
conditionGroup: Array<GetSecurityFirewallConfigRulesConditionGroup>;
action:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction;
valid: true;
validationErrors?: any | null | undefined;
};
export type GetSecurityFirewallConfigRules =
| GetSecurityFirewallConfigRulesSecurityResponse1
| GetSecurityFirewallConfigRulesSecurityResponse2;
export const GetSecurityFirewallConfigAction = {
Bypass: "bypass",
Challenge: "challenge",
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigAction = ClosedEnum<
typeof GetSecurityFirewallConfigAction
>;
export type GetSecurityFirewallConfigSecurityResponseIps = {
id: string;
hostname: string;
ip: string;
notes?: string | undefined;
action: GetSecurityFirewallConfigAction;
};
export const GetSecurityFirewallConfigRulesetsAction = {
Allow: "allow",
Bypass: "bypass",
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
Redirect: "redirect",
} as const;
export type GetSecurityFirewallConfigRulesetsAction = ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsAction
>;
export const GetSecurityFirewallConfigRulesetsSecurityResponseAlgo = {
FixedWindow: "fixed_window",
TokenBucket: "token_bucket",
} as const;
export type GetSecurityFirewallConfigRulesetsSecurityResponseAlgo = ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponseAlgo
>;
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
} as const;
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction
>;
export type GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit = {
algo: GetSecurityFirewallConfigRulesetsSecurityResponseAlgo;
window: number;
limit: number;
keys: Array<string>;
action?:
| GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction
| null
| undefined;
};
export type GetSecurityFirewallConfigRulesetsSecurityResponseRedirect = {
location: string;
permanent: boolean;
};
export const GetSecurityFirewallConfigLogHeadersSecurityResponse2002 = {
Wildcard: "*",
} as const;
export type GetSecurityFirewallConfigLogHeadersSecurityResponse2002 =
ClosedEnum<typeof GetSecurityFirewallConfigLogHeadersSecurityResponse2002>;
export type GetSecurityFirewallConfigRulesetsSecurityResponseLogHeaders =
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse2002;
export type GetSecurityFirewallConfigRulesetsSecurityResponse2 = {
action: GetSecurityFirewallConfigRulesetsAction;
rateLimit?:
| GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit
| null
| undefined;
redirect?:
| GetSecurityFirewallConfigRulesetsSecurityResponseRedirect
| null
| undefined;
actionDuration?: string | null | undefined;
bypassSystem?: boolean | null | undefined;
logHeaders?:
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse2002
| undefined;
};
export const GetSecurityFirewallConfigRulesetsSecurityResponseType = {
BotCategory: "bot_category",
BotName: "bot_name",
BotProtection: "bot_protection",
BotStatus: "bot_status",
Cookie: "cookie",
DomainEnvironment: "domain_environment",
Environment: "environment",
GeoAsNumber: "geo_as_number",
GeoCity: "geo_city",
GeoContinent: "geo_continent",
GeoCountry: "geo_country",
GeoCountryRegion: "geo_country_region",
Header: "header",
Host: "host",
IpAddress: "ip_address",
Ja3Digest: "ja3_digest",
Ja4Digest: "ja4_digest",
Method: "method",
Path: "path",
Protocol: "protocol",
Query: "query",
RateLimitApiId: "rate_limit_api_id",
RawPath: "raw_path",
Region: "region",
Route: "route",
Ruleset: "ruleset",
Scheme: "scheme",
ServerAction: "server_action",
SharedCondition: "shared_condition",
TargetPath: "target_path",
TrafficSource: "traffic_source",
TrustedSource: "trusted_source",
UserAgent: "user_agent",
} as const;
export type GetSecurityFirewallConfigRulesetsSecurityResponseType = ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponseType
>;
export const GetSecurityFirewallConfigRulesetsSecurityResponseOp = {
Eq: "eq",
Ex: "ex",
Gt: "gt",
Gte: "gte",
Inc: "inc",
List: "list",
Lt: "lt",
Lte: "lte",
Neq: "neq",
Nex: "nex",
Ninc: "ninc",
Pre: "pre",
Re: "re",
Sub: "sub",
Suf: "suf",
} as const;
export type GetSecurityFirewallConfigRulesetsSecurityResponseOp = ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponseOp
>;
export type GetSecurityFirewallConfigRulesetsSecurityResponseValue =
| string
| number
| Array<string>;
export type GetSecurityFirewallConfigRulesetsSecurityResponseConditions = {
type: GetSecurityFirewallConfigRulesetsSecurityResponseType;
op: GetSecurityFirewallConfigRulesetsSecurityResponseOp;
neg?: boolean | undefined;
key?: string | undefined;
value?: string | number | Array<string> | undefined;
};
export type GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup = {
conditions: Array<
GetSecurityFirewallConfigRulesetsSecurityResponseConditions
>;
};
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action =
{
Allow: "allow",
Bypass: "bypass",
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
Redirect: "redirect",
} as const;
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action
>;
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo =
{
FixedWindow: "fixed_window",
TokenBucket: "token_bucket",
} as const;
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo
>;
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
} as const;
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction
>;
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit =
{
algo:
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo;
window: number;
limit: number;
keys: Array<string>;
action?:
| GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction
| null
| undefined;
};
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect =
{
location: string;
permanent: boolean;
};
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2 =
{
Wildcard: "*",
} as const;
export type GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2 =
ClosedEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2
>;
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyLogHeaders =
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2;
export type GetSecurityFirewallConfigRulesetsSecurityResponseMitigate = {
action:
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action;
rateLimit?:
| GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit
| null
| undefined;
redirect?:
| GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect
| null
| undefined;
actionDuration?: string | null | undefined;
bypassSystem?: boolean | null | undefined;
logHeaders?:
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2
| undefined;
};
export type GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction =
{
mitigate?:
| GetSecurityFirewallConfigRulesetsSecurityResponseMitigate
| undefined;
};
export type GetSecurityFirewallConfigRulesetsSecurityResponse1 = {
description?: string | undefined;
id: string;
name: string;
active: boolean;
conditionGroup: Array<
GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup
>;
action?:
| GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction
| undefined;
};
export type GetSecurityFirewallConfigRulesets =
| Array<GetSecurityFirewallConfigRulesetsSecurityResponse1>
| { [k: string]: GetSecurityFirewallConfigRulesetsSecurityResponse2 };
export const GetSecurityFirewallConfigType = {
BotCategory: "bot_category",
BotName: "bot_name",
BotProtection: "bot_protection",
BotStatus: "bot_status",
Cookie: "cookie",
DomainEnvironment: "domain_environment",
Environment: "environment",
GeoAsNumber: "geo_as_number",
GeoCity: "geo_city",
GeoContinent: "geo_continent",
GeoCountry: "geo_country",
GeoCountryRegion: "geo_country_region",
Header: "header",
Host: "host",
IpAddress: "ip_address",
Ja3Digest: "ja3_digest",
Ja4Digest: "ja4_digest",
Method: "method",
Path: "path",
Protocol: "protocol",
Query: "query",
RateLimitApiId: "rate_limit_api_id",
RawPath: "raw_path",
Region: "region",
Route: "route",
Ruleset: "ruleset",
Scheme: "scheme",
ServerAction: "server_action",
SharedCondition: "shared_condition",
TargetPath: "target_path",
TrafficSource: "traffic_source",
TrustedSource: "trusted_source",
UserAgent: "user_agent",
} as const;
export type GetSecurityFirewallConfigType = ClosedEnum<
typeof GetSecurityFirewallConfigType
>;
export const GetSecurityFirewallConfigOp = {
Eq: "eq",
Ex: "ex",
Gt: "gt",
Gte: "gte",
Inc: "inc",
List: "list",
Lt: "lt",
Lte: "lte",
Neq: "neq",
Nex: "nex",
Ninc: "ninc",
Pre: "pre",
Re: "re",
Sub: "sub",
Suf: "suf",
} as const;
export type GetSecurityFirewallConfigOp = ClosedEnum<
typeof GetSecurityFirewallConfigOp
>;
export type GetSecurityFirewallConfigValue = string | number | Array<string>;
export type GetSecurityFirewallConfigSecurityResponse200Conditions = {
type: GetSecurityFirewallConfigType;
op: GetSecurityFirewallConfigOp;
neg?: boolean | undefined;
key?: string | undefined;
value?: string | number | Array<string> | undefined;
};
export type GetSecurityFirewallConfigSecurityResponseConditionGroup = {
conditions: Array<GetSecurityFirewallConfigSecurityResponse200Conditions>;
};
export type GetSecurityFirewallConfigConditions = {
description?: string | undefined;
id: string;
name: string;
active: boolean;
conditionGroup: Array<
GetSecurityFirewallConfigSecurityResponseConditionGroup
>;
};
export type GetSecurityFirewallConfigSecurityResponseChanges = {};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction
>;
export type GetSecurityFirewallConfigSecurityResponseBotProtection = {
active: boolean;
action?:
| GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction
| undefined;
updatedAt?: string | undefined;
userId?: string | undefined;
username?: string | undefined;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction
>;
export type GetSecurityFirewallConfigAiBots = {
active: boolean;
action?:
| GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction
| undefined;
updatedAt?: string | undefined;
userId?: string | undefined;
username?: string | undefined;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction
>;
export type GetSecurityFirewallConfigOwasp = {
active: boolean;
action?:
| GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction
| undefined;
updatedAt?: string | undefined;
userId?: string | undefined;
username?: string | undefined;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction
>;
export type GetSecurityFirewallConfigVercelRuleset = {
active: boolean;
action?:
| GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction
| undefined;
updatedAt?: string | undefined;
userId?: string | undefined;
username?: string | undefined;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction
>;
export type GetSecurityFirewallConfigTrafficSources = {
active: boolean;
action?:
| GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction
| undefined;
updatedAt?: string | undefined;
userId?: string | undefined;
username?: string | undefined;
};
export type GetSecurityFirewallConfigManagedRules = {
botProtection?:
| GetSecurityFirewallConfigSecurityResponseBotProtection
| undefined;
aiBots?: GetSecurityFirewallConfigAiBots | undefined;
owasp?: GetSecurityFirewallConfigOwasp | undefined;
vercelRuleset?: GetSecurityFirewallConfigVercelRuleset | undefined;
trafficSources?: GetSecurityFirewallConfigTrafficSources | undefined;
};
export const GetSecurityFirewallConfigLogHeaders2 = {
Wildcard: "*",
} as const;
export type GetSecurityFirewallConfigLogHeaders2 = ClosedEnum<
typeof GetSecurityFirewallConfigLogHeaders2
>;
export type GetSecurityFirewallConfigLogHeaders =
| Array<string>
| GetSecurityFirewallConfigLogHeaders2;
export type Active = {
ownerId: string;
projectKey: string;
id: string;
version: number;
updatedAt: string;
firewallEnabled: boolean;
crs?: GetSecurityFirewallConfigSecurityResponseCrs | undefined;
rules: Array<
| GetSecurityFirewallConfigRulesSecurityResponse1
| GetSecurityFirewallConfigRulesSecurityResponse2
>;
ips: Array<GetSecurityFirewallConfigSecurityResponseIps>;
rulesets?: Array<GetSecurityFirewallConfigRulesetsSecurityResponse1> | {
[k: string]: GetSecurityFirewallConfigRulesetsSecurityResponse2;
} | undefined;
conditions?: Array<GetSecurityFirewallConfigConditions> | undefined;
changes: Array<GetSecurityFirewallConfigSecurityResponseChanges>;
managedRules?: GetSecurityFirewallConfigManagedRules | undefined;
botIdEnabled?: boolean | undefined;
logHeaders?: Array<string> | GetSecurityFirewallConfigLogHeaders2 | undefined;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction
>;
export type GetSecurityFirewallConfigSd = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction
>;
export type GetSecurityFirewallConfigMa = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction
>;
export type GetSecurityFirewallConfigLfi = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction
>;
export type GetSecurityFirewallConfigRfi = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction
>;
export type GetSecurityFirewallConfigRce = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction
>;
export type GetSecurityFirewallConfigPhp = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction
>;
export type GetSecurityFirewallConfigGen = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction
>;
export type GetSecurityFirewallConfigXss = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction
>;
export type GetSecurityFirewallConfigSqli = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction
>;
export type GetSecurityFirewallConfigSf = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction;
};
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction =
{
Deny: "deny",
Log: "log",
} as const;
export type GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction =
ClosedEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction
>;
export type GetSecurityFirewallConfigJava = {
active: boolean;
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction;
};
export type GetSecurityFirewallConfigCrs = {
sd: GetSecurityFirewallConfigSd;
ma: GetSecurityFirewallConfigMa;
lfi: GetSecurityFirewallConfigLfi;
rfi: GetSecurityFirewallConfigRfi;
rce: GetSecurityFirewallConfigRce;
php: GetSecurityFirewallConfigPhp;
gen: GetSecurityFirewallConfigGen;
xss: GetSecurityFirewallConfigXss;
sqli: GetSecurityFirewallConfigSqli;
sf: GetSecurityFirewallConfigSf;
java: GetSecurityFirewallConfigJava;
};
export const GetSecurityFirewallConfigRulesSecurityResponseType = {
BotCategory: "bot_category",
BotName: "bot_name",
BotProtection: "bot_protection",
BotStatus: "bot_status",
Cookie: "cookie",
DomainEnvironment: "domain_environment",
Environment: "environment",
GeoAsNumber: "geo_as_number",
GeoCity: "geo_city",
GeoContinent: "geo_continent",
GeoCountry: "geo_country",
GeoCountryRegion: "geo_country_region",
Header: "header",
Host: "host",
IpAddress: "ip_address",
Ja3Digest: "ja3_digest",
Ja4Digest: "ja4_digest",
Method: "method",
Path: "path",
Protocol: "protocol",
Query: "query",
RateLimitApiId: "rate_limit_api_id",
RawPath: "raw_path",
Region: "region",
Route: "route",
Ruleset: "ruleset",
Scheme: "scheme",
ServerAction: "server_action",
SharedCondition: "shared_condition",
TargetPath: "target_path",
TrafficSource: "traffic_source",
TrustedSource: "trusted_source",
UserAgent: "user_agent",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponseType = ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponseType
>;
export const GetSecurityFirewallConfigRulesSecurityResponseOp = {
Eq: "eq",
Ex: "ex",
Gt: "gt",
Gte: "gte",
Inc: "inc",
List: "list",
Lt: "lt",
Lte: "lte",
Neq: "neq",
Nex: "nex",
Ninc: "ninc",
Pre: "pre",
Re: "re",
Sub: "sub",
Suf: "suf",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponseOp = ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponseOp
>;
export type GetSecurityFirewallConfigRulesSecurityResponseValue =
| string
| number
| Array<string>;
export type GetSecurityFirewallConfigRulesSecurityResponseConditions = {
type: GetSecurityFirewallConfigRulesSecurityResponseType;
op: GetSecurityFirewallConfigRulesSecurityResponseOp;
neg?: boolean | undefined;
key?: string | undefined;
value?: string | number | Array<string> | undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponseConditionGroup = {
conditions: Array<GetSecurityFirewallConfigRulesSecurityResponseConditions>;
};
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action =
{
Allow: "allow",
Bypass: "bypass",
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
Redirect: "redirect",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action
>;
export const GetSecurityFirewallConfigRulesSecurityResponseAlgo = {
FixedWindow: "fixed_window",
TokenBucket: "token_bucket",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponseAlgo = ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponseAlgo
>;
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction
>;
export type GetSecurityFirewallConfigRulesSecurityResponseRateLimit = {
algo: GetSecurityFirewallConfigRulesSecurityResponseAlgo;
window: number;
limit: number;
keys: Array<string>;
action?:
| GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction
| null
| undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponseRedirect = {
location: string;
permanent: boolean;
};
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2 =
{
Wildcard: "*",
} as const;
export type GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2 =
ClosedEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2
>;
export type GetSecurityFirewallConfigRulesSecurityResponseLogHeaders =
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2;
export type GetSecurityFirewallConfigRulesSecurityResponseMitigate = {
action:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action;
rateLimit?:
| GetSecurityFirewallConfigRulesSecurityResponseRateLimit
| null
| undefined;
redirect?:
| GetSecurityFirewallConfigRulesSecurityResponseRedirect
| null
| undefined;
actionDuration?: string | null | undefined;
bypassSystem?: boolean | null | undefined;
logHeaders?:
| Array<string>
| GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2
| undefined;
};
export type GetSecurityFirewallConfigRulesSecurityResponseAction = {
mitigate?: GetSecurityFirewallConfigRulesSecurityResponseMitigate | undefined;
};
export type GetSecurityFirewallConfigRules2 = {
id: string;
name: string;
description?: string | undefined;
active: boolean;
conditionGroup: Array<
GetSecurityFirewallConfigRulesSecurityResponseConditionGroup
>;
action: GetSecurityFirewallConfigRulesSecurityResponseAction;
valid: false;
validationErrors: Array<string>;
};
export const GetSecurityFirewallConfigRulesSecurityType = {
BotCategory: "bot_category",
BotName: "bot_name",
BotProtection: "bot_protection",
BotStatus: "bot_status",
Cookie: "cookie",
DomainEnvironment: "domain_environment",
Environment: "environment",
GeoAsNumber: "geo_as_number",
GeoCity: "geo_city",
GeoContinent: "geo_continent",
GeoCountry: "geo_country",
GeoCountryRegion: "geo_country_region",
Header: "header",
Host: "host",
IpAddress: "ip_address",
Ja3Digest: "ja3_digest",
Ja4Digest: "ja4_digest",
Method: "method",
Path: "path",
Protocol: "protocol",
Query: "query",
RateLimitApiId: "rate_limit_api_id",
RawPath: "raw_path",
Region: "region",
Route: "route",
Ruleset: "ruleset",
Scheme: "scheme",
ServerAction: "server_action",
SharedCondition: "shared_condition",
TargetPath: "target_path",
TrafficSource: "traffic_source",
TrustedSource: "trusted_source",
UserAgent: "user_agent",
} as const;
export type GetSecurityFirewallConfigRulesSecurityType = ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityType
>;
export const GetSecurityFirewallConfigRulesSecurityOp = {
Eq: "eq",
Ex: "ex",
Gt: "gt",
Gte: "gte",
Inc: "inc",
List: "list",
Lt: "lt",
Lte: "lte",
Neq: "neq",
Nex: "nex",
Ninc: "ninc",
Pre: "pre",
Re: "re",
Sub: "sub",
Suf: "suf",
} as const;
export type GetSecurityFirewallConfigRulesSecurityOp = ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityOp
>;
export type GetSecurityFirewallConfigRulesSecurityValue =
| string
| number
| Array<string>;
export type GetSecurityFirewallConfigRulesSecurityConditions = {
type: GetSecurityFirewallConfigRulesSecurityType;
op: GetSecurityFirewallConfigRulesSecurityOp;
neg?: boolean | undefined;
key?: string | undefined;
value?: string | number | Array<string> | undefined;
};
export type GetSecurityFirewallConfigRulesSecurityConditionGroup = {
conditions: Array<GetSecurityFirewallConfigRulesSecurityConditions>;
};
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraftAction =
{
Allow: "allow",
Bypass: "bypass",
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
Redirect: "redirect",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraftAction =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraftAction
>;
export const GetSecurityFirewallConfigRulesSecurityAlgo = {
FixedWindow: "fixed_window",
TokenBucket: "token_bucket",
} as const;
export type GetSecurityFirewallConfigRulesSecurityAlgo = ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityAlgo
>;
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action =
{
Challenge: "challenge",
Deny: "deny",
Log: "log",
RateLimit: "rate_limit",
} as const;
export type GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action =
ClosedEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action
>;
export type GetSecurityFirewallConfigRulesSecurityRateLimit = {
algo: GetSecurityFirewallConfigRulesSecurityAlgo;
window: number;
limit: number;
keys: Array<string>;
action?:
| GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action
| null
| undefined;
};
export type GetSecurityFirewallConfigRulesSecurityRedirect = {
location: string;
permanent: boolean;
};
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraftRules2 =
{
Wildcard: "*",
} as const;
export type GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraftRules2 =
ClosedEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraftRules2
>;
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseSd$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseSd,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSdAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseSdFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseSd,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseSd$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseSd' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseMa$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseMa,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsMaAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseMaFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseMa,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseMa$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseMa' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseLfi$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseLfi,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsLfiAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseLfiFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseLfi,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseLfi$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseLfi' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200Action$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigSecurityResponse200Action> = z
.nativeEnum(GetSecurityFirewallConfigSecurityResponse200Action);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseRfi$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseRfi,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action: GetSecurityFirewallConfigSecurityResponse200Action$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseRfiFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseRfi,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseRfi$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseRfi' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseRce$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseRce,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseRceFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseRce,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseRce$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseRce' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponsePhp$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponsePhp,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponsePhpFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponsePhp,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponsePhp$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponsePhp' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseGen$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseGen,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseGenFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseGen,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseGen$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseGen' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseXss$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseXss,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseXssFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseXss,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseXss$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseXss' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseSqli$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseSqli,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSqliAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseSqliFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseSqli,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseSqli$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseSqli' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseSf$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseSf,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsSfAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseSfFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseSf,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseSf$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseSf' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseJava$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseJava,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveCrsJavaAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseJavaFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseJava,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseJava$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseJava' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseCrs$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseCrs,
z.ZodTypeDef,
unknown
> = z.object({
sd: z.lazy(() => GetSecurityFirewallConfigSecurityResponseSd$inboundSchema),
ma: z.lazy(() => GetSecurityFirewallConfigSecurityResponseMa$inboundSchema),
lfi: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseLfi$inboundSchema
),
rfi: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseRfi$inboundSchema
),
rce: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseRce$inboundSchema
),
php: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponsePhp$inboundSchema
),
gen: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseGen$inboundSchema
),
xss: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseXss$inboundSchema
),
sqli: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseSqli$inboundSchema
),
sf: z.lazy(() => GetSecurityFirewallConfigSecurityResponseSf$inboundSchema),
java: z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseJava$inboundSchema
),
});
export function getSecurityFirewallConfigSecurityResponseCrsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseCrs,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseCrs$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseCrs' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesType$inboundSchema: z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesType
> = z.nativeEnum(GetSecurityFirewallConfigRulesType);
/** @internal */
export const GetSecurityFirewallConfigRulesOp$inboundSchema: z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesOp
> = z.nativeEnum(GetSecurityFirewallConfigRulesOp);
/** @internal */
export const GetSecurityFirewallConfigRulesValue$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesValue,
z.ZodTypeDef,
unknown
> = smartUnion([types.string(), types.number(), z.array(types.string())]);
export function getSecurityFirewallConfigRulesValueFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRulesValue, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesValue$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesValue' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesConditions$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesConditions,
z.ZodTypeDef,
unknown
> = z.object({
type: GetSecurityFirewallConfigRulesType$inboundSchema,
op: GetSecurityFirewallConfigRulesOp$inboundSchema,
neg: types.optional(types.boolean()),
key: types.optional(types.string()),
value: types.optional(
smartUnion([types.string(), types.number(), z.array(types.string())]),
),
});
export function getSecurityFirewallConfigRulesConditionsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesConditions,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesConditions$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesConditions' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup,
z.ZodTypeDef,
unknown
> = z.object({
conditions: z.array(
z.lazy(() => GetSecurityFirewallConfigRulesConditions$inboundSchema),
),
});
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroupFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action,
);
/** @internal */
export const GetSecurityFirewallConfigRulesAlgo$inboundSchema: z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesAlgo
> = z.nativeEnum(GetSecurityFirewallConfigRulesAlgo);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction,
);
/** @internal */
export const GetSecurityFirewallConfigRulesRateLimit$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesRateLimit,
z.ZodTypeDef,
unknown
> = z.object({
algo: GetSecurityFirewallConfigRulesAlgo$inboundSchema,
window: types.number(),
limit: types.number(),
keys: z.array(types.string()),
action: z.nullable(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2ActionAction$inboundSchema,
).optional(),
});
export function getSecurityFirewallConfigRulesRateLimitFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesRateLimit,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesRateLimit$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesRateLimit' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesRedirect$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesRedirect,
z.ZodTypeDef,
unknown
> = z.object({
location: types.string(),
permanent: types.boolean(),
});
export function getSecurityFirewallConfigRulesRedirectFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRulesRedirect, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesRedirect$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesRedirect' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22
> = z.nativeEnum(
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22,
);
/** @internal */
export const GetSecurityFirewallConfigRulesLogHeaders$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesLogHeaders,
z.ZodTypeDef,
unknown
> = smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22$inboundSchema,
]);
export function getSecurityFirewallConfigRulesLogHeadersFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesLogHeaders,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesLogHeaders$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesLogHeaders' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesMitigate$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesMitigate,
z.ZodTypeDef,
unknown
> = z.object({
action:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive2Action$inboundSchema,
rateLimit: z.nullable(
z.lazy(() => GetSecurityFirewallConfigRulesRateLimit$inboundSchema),
).optional(),
redirect: z.nullable(
z.lazy(() => GetSecurityFirewallConfigRulesRedirect$inboundSchema),
).optional(),
actionDuration: z.nullable(types.string()).optional(),
bypassSystem: z.nullable(types.boolean()).optional(),
logHeaders: types.optional(
smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules22$inboundSchema,
]),
),
});
export function getSecurityFirewallConfigRulesMitigateFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRulesMitigate, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesMitigate$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesMitigate' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesAction$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesAction,
z.ZodTypeDef,
unknown
> = z.object({
mitigate: types.optional(
z.lazy(() => GetSecurityFirewallConfigRulesMitigate$inboundSchema),
),
});
export function getSecurityFirewallConfigRulesActionFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRulesAction, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesAction$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesAction' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse2$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse2,
z.ZodTypeDef,
unknown
> = z.object({
id: types.string(),
name: types.string(),
description: types.optional(types.string()),
active: types.boolean(),
conditionGroup: z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionGroup$inboundSchema
),
),
action: z.lazy(() => GetSecurityFirewallConfigRulesAction$inboundSchema),
valid: types.literal(false),
validationErrors: z.array(types.string()),
});
export function getSecurityFirewallConfigRulesSecurityResponse2FromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse2,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse2$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse2' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyValue$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyValue,
z.ZodTypeDef,
unknown
> = smartUnion([types.string(), types.number(), z.array(types.string())]);
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyValueFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyValue,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyValue$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyValue' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions,
z.ZodTypeDef,
unknown
> = z.object({
type:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyType$inboundSchema,
op:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyOp$inboundSchema,
neg: types.optional(types.boolean()),
key: types.optional(types.string()),
value: types.optional(
smartUnion([types.string(), types.number(), z.array(types.string())]),
),
});
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditionsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesConditionGroup$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesConditionGroup,
z.ZodTypeDef,
unknown
> = z.object({
conditions: z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyConditions$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesConditionGroupFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesConditionGroup,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesConditionGroup$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesConditionGroup' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit,
z.ZodTypeDef,
unknown
> = z.object({
algo:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAlgo$inboundSchema,
window: types.number(),
limit: types.number(),
keys: z.array(types.string()),
action: z.nullable(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActive1Action$inboundSchema,
).optional(),
});
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimitFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect,
z.ZodTypeDef,
unknown
> = z.object({
location: types.string(),
permanent: types.boolean(),
});
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirectFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2
> = z.nativeEnum(
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyLogHeaders$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyLogHeaders,
z.ZodTypeDef,
unknown
> = smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2$inboundSchema,
]);
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyLogHeadersFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyLogHeaders,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyLogHeaders$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyLogHeaders' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate,
z.ZodTypeDef,
unknown
> = z.object({
action:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActiveAction$inboundSchema,
rateLimit: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRateLimit$inboundSchema
),
).optional(),
redirect: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyRedirect$inboundSchema
),
).optional(),
actionDuration: z.nullable(types.string()).optional(),
bypassSystem: z.nullable(types.boolean()).optional(),
logHeaders: types.optional(
smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActiveRules2$inboundSchema,
]),
),
});
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigateFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction,
z.ZodTypeDef,
unknown
> = z.object({
mitigate: types.optional(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyMitigate$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyActionFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse1$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponse1,
z.ZodTypeDef,
unknown
> = z.object({
id: types.string(),
name: types.string(),
description: types.optional(types.string()),
active: types.boolean(),
conditionGroup: z.array(
z.lazy(() => GetSecurityFirewallConfigRulesConditionGroup$inboundSchema),
),
action: z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema
),
valid: types.literal(true),
validationErrors: z.nullable(z.any()).optional(),
});
export function getSecurityFirewallConfigRulesSecurityResponse1FromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponse1,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponse1$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponse1' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRules$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRules,
z.ZodTypeDef,
unknown
> = smartUnion([
z.lazy(() => GetSecurityFirewallConfigRulesSecurityResponse1$inboundSchema),
z.lazy(() => GetSecurityFirewallConfigRulesSecurityResponse2$inboundSchema),
]);
export function getSecurityFirewallConfigRulesFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRules, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigRules$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRules' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigAction$inboundSchema: z.ZodNativeEnum<
typeof GetSecurityFirewallConfigAction
> = z.nativeEnum(GetSecurityFirewallConfigAction);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseIps$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseIps,
z.ZodTypeDef,
unknown
> = z.object({
id: types.string(),
hostname: types.string(),
ip: types.string(),
notes: types.optional(types.string()),
action: GetSecurityFirewallConfigAction$inboundSchema,
});
export function getSecurityFirewallConfigSecurityResponseIpsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseIps,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseIps$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseIps' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsAction$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesetsAction> = z
.nativeEnum(GetSecurityFirewallConfigRulesetsAction);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseAlgo$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponseAlgo
> = z.nativeEnum(GetSecurityFirewallConfigRulesetsSecurityResponseAlgo);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction
> = z.nativeEnum(
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction,
);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit,
z.ZodTypeDef,
unknown
> = z.object({
algo: GetSecurityFirewallConfigRulesetsSecurityResponseAlgo$inboundSchema,
window: types.number(),
limit: types.number(),
keys: z.array(types.string()),
action: z.nullable(
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActiveAction$inboundSchema,
).optional(),
});
export function getSecurityFirewallConfigRulesetsSecurityResponseRateLimitFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseRedirect$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponseRedirect,
z.ZodTypeDef,
unknown
> = z.object({
location: types.string(),
permanent: types.boolean(),
});
export function getSecurityFirewallConfigRulesetsSecurityResponseRedirectFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponseRedirect,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponseRedirect$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponseRedirect' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigLogHeadersSecurityResponse2002$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse2002
> = z.nativeEnum(GetSecurityFirewallConfigLogHeadersSecurityResponse2002);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseLogHeaders$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponseLogHeaders,
z.ZodTypeDef,
unknown
> = smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse2002$inboundSchema,
]);
export function getSecurityFirewallConfigRulesetsSecurityResponseLogHeadersFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponseLogHeaders,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponseLogHeaders$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponseLogHeaders' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse2$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponse2,
z.ZodTypeDef,
unknown
> = z.object({
action: GetSecurityFirewallConfigRulesetsAction$inboundSchema,
rateLimit: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponseRateLimit$inboundSchema
),
).optional(),
redirect: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponseRedirect$inboundSchema
),
).optional(),
actionDuration: z.nullable(types.string()).optional(),
bypassSystem: z.nullable(types.boolean()).optional(),
logHeaders: types.optional(
smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse2002$inboundSchema,
]),
),
});
export function getSecurityFirewallConfigRulesetsSecurityResponse2FromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponse2,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponse2$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponse2' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseType$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponseType
> = z.nativeEnum(GetSecurityFirewallConfigRulesetsSecurityResponseType);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseOp$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesetsSecurityResponseOp> =
z.nativeEnum(GetSecurityFirewallConfigRulesetsSecurityResponseOp);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseValue$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponseValue,
z.ZodTypeDef,
unknown
> = smartUnion([types.string(), types.number(), z.array(types.string())]);
export function getSecurityFirewallConfigRulesetsSecurityResponseValueFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponseValue,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponseValue$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponseValue' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseConditions$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponseConditions,
z.ZodTypeDef,
unknown
> = z.object({
type: GetSecurityFirewallConfigRulesetsSecurityResponseType$inboundSchema,
op: GetSecurityFirewallConfigRulesetsSecurityResponseOp$inboundSchema,
neg: types.optional(types.boolean()),
key: types.optional(types.string()),
value: types.optional(
smartUnion([types.string(), types.number(), z.array(types.string())]),
),
});
export function getSecurityFirewallConfigRulesetsSecurityResponseConditionsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponseConditions,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponseConditions$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponseConditions' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup,
z.ZodTypeDef,
unknown
> = z.object({
conditions: z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponseConditions$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesetsSecurityResponseConditionGroupFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action
> = z.nativeEnum(
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action,
);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo
> = z.nativeEnum(
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo,
);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction
> = z.nativeEnum(
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction,
);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit,
z.ZodTypeDef,
unknown
> = z.object({
algo:
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAlgo$inboundSchema,
window: types.number(),
limit: types.number(),
keys: z.array(types.string()),
action: z.nullable(
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1ActionAction$inboundSchema,
).optional(),
});
export function getSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimitFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect,
z.ZodTypeDef,
unknown
> = z.object({
location: types.string(),
permanent: types.boolean(),
});
export function getSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirectFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2
> = z.nativeEnum(
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2,
);
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyLogHeaders$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyLogHeaders,
z.ZodTypeDef,
unknown
> = smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2$inboundSchema,
]);
export function getSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyLogHeadersFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyLogHeaders,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyLogHeaders$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyLogHeaders' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponseMitigate$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponseMitigate,
z.ZodTypeDef,
unknown
> = z.object({
action:
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActive1Action$inboundSchema,
rateLimit: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRateLimit$inboundSchema
),
).optional(),
redirect: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyRedirect$inboundSchema
),
).optional(),
actionDuration: z.nullable(types.string()).optional(),
bypassSystem: z.nullable(types.boolean()).optional(),
logHeaders: types.optional(
smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyActive2$inboundSchema,
]),
),
});
export function getSecurityFirewallConfigRulesetsSecurityResponseMitigateFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponseMitigate,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponseMitigate$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponseMitigate' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction,
z.ZodTypeDef,
unknown
> = z.object({
mitigate: types.optional(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponseMitigate$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyActionFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesetsSecurityResponse1$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesetsSecurityResponse1,
z.ZodTypeDef,
unknown
> = z.object({
description: types.optional(types.string()),
id: types.string(),
name: types.string(),
active: types.boolean(),
conditionGroup: z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponseConditionGroup$inboundSchema
),
),
action: types.optional(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponse200ApplicationJSONResponseBodyAction$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesetsSecurityResponse1FromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesetsSecurityResponse1,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesetsSecurityResponse1$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesetsSecurityResponse1' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesets$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRulesets,
z.ZodTypeDef,
unknown
> = smartUnion([
z.array(z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponse1$inboundSchema
)),
z.record(z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponse2$inboundSchema
)),
]);
export function getSecurityFirewallConfigRulesetsFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRulesets, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigRulesets$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesets' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigType$inboundSchema: z.ZodNativeEnum<
typeof GetSecurityFirewallConfigType
> = z.nativeEnum(GetSecurityFirewallConfigType);
/** @internal */
export const GetSecurityFirewallConfigOp$inboundSchema: z.ZodNativeEnum<
typeof GetSecurityFirewallConfigOp
> = z.nativeEnum(GetSecurityFirewallConfigOp);
/** @internal */
export const GetSecurityFirewallConfigValue$inboundSchema: z.ZodType<
GetSecurityFirewallConfigValue,
z.ZodTypeDef,
unknown
> = smartUnion([types.string(), types.number(), z.array(types.string())]);
export function getSecurityFirewallConfigValueFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigValue, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigValue$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigValue' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200Conditions$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponse200Conditions,
z.ZodTypeDef,
unknown
> = z.object({
type: GetSecurityFirewallConfigType$inboundSchema,
op: GetSecurityFirewallConfigOp$inboundSchema,
neg: types.optional(types.boolean()),
key: types.optional(types.string()),
value: types.optional(
smartUnion([types.string(), types.number(), z.array(types.string())]),
),
});
export function getSecurityFirewallConfigSecurityResponse200ConditionsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponse200Conditions,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponse200Conditions$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponse200Conditions' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseConditionGroup$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseConditionGroup,
z.ZodTypeDef,
unknown
> = z.object({
conditions: z.array(
z.lazy(() =>
GetSecurityFirewallConfigSecurityResponse200Conditions$inboundSchema
),
),
});
export function getSecurityFirewallConfigSecurityResponseConditionGroupFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseConditionGroup,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseConditionGroup$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseConditionGroup' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigConditions$inboundSchema: z.ZodType<
GetSecurityFirewallConfigConditions,
z.ZodTypeDef,
unknown
> = z.object({
description: types.optional(types.string()),
id: types.string(),
name: types.string(),
active: types.boolean(),
conditionGroup: z.array(
z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseConditionGroup$inboundSchema
),
),
});
export function getSecurityFirewallConfigConditionsFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigConditions, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigConditions$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigConditions' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseChanges$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseChanges,
z.ZodTypeDef,
unknown
> = z.object({});
export function getSecurityFirewallConfigSecurityResponseChangesFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseChanges,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseChanges$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseChanges' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction,
);
/** @internal */
export const GetSecurityFirewallConfigSecurityResponseBotProtection$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigSecurityResponseBotProtection,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action: types.optional(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAction$inboundSchema,
),
updatedAt: types.optional(types.string()),
userId: types.optional(types.string()),
username: types.optional(types.string()),
});
export function getSecurityFirewallConfigSecurityResponseBotProtectionFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigSecurityResponseBotProtection,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigSecurityResponseBotProtection$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigSecurityResponseBotProtection' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction,
);
/** @internal */
export const GetSecurityFirewallConfigAiBots$inboundSchema: z.ZodType<
GetSecurityFirewallConfigAiBots,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action: types.optional(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesAiBotsAction$inboundSchema,
),
updatedAt: types.optional(types.string()),
userId: types.optional(types.string()),
username: types.optional(types.string()),
});
export function getSecurityFirewallConfigAiBotsFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigAiBots, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigAiBots$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigAiBots' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction,
);
/** @internal */
export const GetSecurityFirewallConfigOwasp$inboundSchema: z.ZodType<
GetSecurityFirewallConfigOwasp,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action: types.optional(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesOwaspAction$inboundSchema,
),
updatedAt: types.optional(types.string()),
userId: types.optional(types.string()),
username: types.optional(types.string()),
});
export function getSecurityFirewallConfigOwaspFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigOwasp, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigOwasp$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigOwasp' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction,
);
/** @internal */
export const GetSecurityFirewallConfigVercelRuleset$inboundSchema: z.ZodType<
GetSecurityFirewallConfigVercelRuleset,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action: types.optional(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesVercelRulesetAction$inboundSchema,
),
updatedAt: types.optional(types.string()),
userId: types.optional(types.string()),
username: types.optional(types.string()),
});
export function getSecurityFirewallConfigVercelRulesetFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigVercelRuleset, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigVercelRuleset$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigVercelRuleset' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction,
);
/** @internal */
export const GetSecurityFirewallConfigTrafficSources$inboundSchema: z.ZodType<
GetSecurityFirewallConfigTrafficSources,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action: types.optional(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyActiveManagedRulesTrafficSourcesAction$inboundSchema,
),
updatedAt: types.optional(types.string()),
userId: types.optional(types.string()),
username: types.optional(types.string()),
});
export function getSecurityFirewallConfigTrafficSourcesFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigTrafficSources,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigTrafficSources$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigTrafficSources' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigManagedRules$inboundSchema: z.ZodType<
GetSecurityFirewallConfigManagedRules,
z.ZodTypeDef,
unknown
> = z.object({
bot_protection: types.optional(
z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseBotProtection$inboundSchema
),
),
ai_bots: types.optional(
z.lazy(() => GetSecurityFirewallConfigAiBots$inboundSchema),
),
owasp: types.optional(
z.lazy(() => GetSecurityFirewallConfigOwasp$inboundSchema),
),
vercel_ruleset: types.optional(
z.lazy(() => GetSecurityFirewallConfigVercelRuleset$inboundSchema),
),
traffic_sources: types.optional(
z.lazy(() => GetSecurityFirewallConfigTrafficSources$inboundSchema),
),
}).transform((v) => {
return remap$(v, {
"bot_protection": "botProtection",
"ai_bots": "aiBots",
"vercel_ruleset": "vercelRuleset",
"traffic_sources": "trafficSources",
});
});
export function getSecurityFirewallConfigManagedRulesFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigManagedRules, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigManagedRules$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigManagedRules' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigLogHeaders2$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigLogHeaders2> = z.nativeEnum(
GetSecurityFirewallConfigLogHeaders2,
);
/** @internal */
export const GetSecurityFirewallConfigLogHeaders$inboundSchema: z.ZodType<
GetSecurityFirewallConfigLogHeaders,
z.ZodTypeDef,
unknown
> = smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeaders2$inboundSchema,
]);
export function getSecurityFirewallConfigLogHeadersFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigLogHeaders, SDKValidationError> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigLogHeaders$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigLogHeaders' from JSON`,
);
}
/** @internal */
export const Active$inboundSchema: z.ZodType<Active, z.ZodTypeDef, unknown> = z
.object({
ownerId: types.string(),
projectKey: types.string(),
id: types.string(),
version: types.number(),
updatedAt: types.string(),
firewallEnabled: types.boolean(),
crs: types.optional(
z.lazy(() => GetSecurityFirewallConfigSecurityResponseCrs$inboundSchema),
),
rules: z.array(
smartUnion([
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse1$inboundSchema
),
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponse2$inboundSchema
),
]),
),
ips: z.array(
z.lazy(() => GetSecurityFirewallConfigSecurityResponseIps$inboundSchema),
),
rulesets: types.optional(
smartUnion([
z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponse1$inboundSchema
),
),
z.record(
z.lazy(() =>
GetSecurityFirewallConfigRulesetsSecurityResponse2$inboundSchema
),
),
]),
),
conditions: types.optional(
z.array(z.lazy(() => GetSecurityFirewallConfigConditions$inboundSchema)),
),
changes: z.array(
z.lazy(() =>
GetSecurityFirewallConfigSecurityResponseChanges$inboundSchema
),
),
managedRules: types.optional(
z.lazy(() => GetSecurityFirewallConfigManagedRules$inboundSchema),
),
botIdEnabled: types.optional(types.boolean()),
logHeaders: types.optional(
smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeaders2$inboundSchema,
]),
),
});
export function activeFromJSON(
jsonString: string,
): SafeParseResult<Active, SDKValidationError> {
return safeParse(
jsonString,
(x) => Active$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'Active' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction,
);
/** @internal */
export const GetSecurityFirewallConfigSd$inboundSchema: z.ZodType<
GetSecurityFirewallConfigSd,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftAction$inboundSchema,
});
export function getSecurityFirewallConfigSdFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigSd, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigSd$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigSd' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction,
);
/** @internal */
export const GetSecurityFirewallConfigMa$inboundSchema: z.ZodType<
GetSecurityFirewallConfigMa,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsAction$inboundSchema,
});
export function getSecurityFirewallConfigMaFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigMa, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigMa$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigMa' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction,
);
/** @internal */
export const GetSecurityFirewallConfigLfi$inboundSchema: z.ZodType<
GetSecurityFirewallConfigLfi,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsLfiAction$inboundSchema,
});
export function getSecurityFirewallConfigLfiFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigLfi, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigLfi$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigLfi' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction,
);
/** @internal */
export const GetSecurityFirewallConfigRfi$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRfi,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRfiAction$inboundSchema,
});
export function getSecurityFirewallConfigRfiFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRfi, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigRfi$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRfi' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction,
);
/** @internal */
export const GetSecurityFirewallConfigRce$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRce,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsRceAction$inboundSchema,
});
export function getSecurityFirewallConfigRceFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRce, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigRce$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRce' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction,
);
/** @internal */
export const GetSecurityFirewallConfigPhp$inboundSchema: z.ZodType<
GetSecurityFirewallConfigPhp,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsPhpAction$inboundSchema,
});
export function getSecurityFirewallConfigPhpFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigPhp, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigPhp$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigPhp' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction,
);
/** @internal */
export const GetSecurityFirewallConfigGen$inboundSchema: z.ZodType<
GetSecurityFirewallConfigGen,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsGenAction$inboundSchema,
});
export function getSecurityFirewallConfigGenFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigGen, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigGen$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigGen' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction,
);
/** @internal */
export const GetSecurityFirewallConfigXss$inboundSchema: z.ZodType<
GetSecurityFirewallConfigXss,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsXssAction$inboundSchema,
});
export function getSecurityFirewallConfigXssFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigXss, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigXss$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigXss' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction,
);
/** @internal */
export const GetSecurityFirewallConfigSqli$inboundSchema: z.ZodType<
GetSecurityFirewallConfigSqli,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSqliAction$inboundSchema,
});
export function getSecurityFirewallConfigSqliFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigSqli, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigSqli$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigSqli' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction,
);
/** @internal */
export const GetSecurityFirewallConfigSf$inboundSchema: z.ZodType<
GetSecurityFirewallConfigSf,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsSfAction$inboundSchema,
});
export function getSecurityFirewallConfigSfFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigSf, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigSf$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigSf' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction
> = z.nativeEnum(
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction,
);
/** @internal */
export const GetSecurityFirewallConfigJava$inboundSchema: z.ZodType<
GetSecurityFirewallConfigJava,
z.ZodTypeDef,
unknown
> = z.object({
active: types.boolean(),
action:
GetSecurityFirewallConfigSecurityResponse200ApplicationJSONResponseBodyDraftCrsJavaAction$inboundSchema,
});
export function getSecurityFirewallConfigJavaFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigJava, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigJava$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigJava' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigCrs$inboundSchema: z.ZodType<
GetSecurityFirewallConfigCrs,
z.ZodTypeDef,
unknown
> = z.object({
sd: z.lazy(() => GetSecurityFirewallConfigSd$inboundSchema),
ma: z.lazy(() => GetSecurityFirewallConfigMa$inboundSchema),
lfi: z.lazy(() => GetSecurityFirewallConfigLfi$inboundSchema),
rfi: z.lazy(() => GetSecurityFirewallConfigRfi$inboundSchema),
rce: z.lazy(() => GetSecurityFirewallConfigRce$inboundSchema),
php: z.lazy(() => GetSecurityFirewallConfigPhp$inboundSchema),
gen: z.lazy(() => GetSecurityFirewallConfigGen$inboundSchema),
xss: z.lazy(() => GetSecurityFirewallConfigXss$inboundSchema),
sqli: z.lazy(() => GetSecurityFirewallConfigSqli$inboundSchema),
sf: z.lazy(() => GetSecurityFirewallConfigSf$inboundSchema),
java: z.lazy(() => GetSecurityFirewallConfigJava$inboundSchema),
});
export function getSecurityFirewallConfigCrsFromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigCrs, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigCrs$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigCrs' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseType$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesSecurityResponseType> = z
.nativeEnum(GetSecurityFirewallConfigRulesSecurityResponseType);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseOp$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesSecurityResponseOp> = z
.nativeEnum(GetSecurityFirewallConfigRulesSecurityResponseOp);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseValue$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseValue,
z.ZodTypeDef,
unknown
> = smartUnion([types.string(), types.number(), z.array(types.string())]);
export function getSecurityFirewallConfigRulesSecurityResponseValueFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseValue,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseValue$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseValue' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseConditions$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseConditions,
z.ZodTypeDef,
unknown
> = z.object({
type: GetSecurityFirewallConfigRulesSecurityResponseType$inboundSchema,
op: GetSecurityFirewallConfigRulesSecurityResponseOp$inboundSchema,
neg: types.optional(types.boolean()),
key: types.optional(types.string()),
value: types.optional(
smartUnion([types.string(), types.number(), z.array(types.string())]),
),
});
export function getSecurityFirewallConfigRulesSecurityResponseConditionsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseConditions,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseConditions$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseConditions' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseConditionGroup$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseConditionGroup,
z.ZodTypeDef,
unknown
> = z.object({
conditions: z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponseConditions$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesSecurityResponseConditionGroupFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseConditionGroup,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseConditionGroup$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseConditionGroup' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseAlgo$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesSecurityResponseAlgo> = z
.nativeEnum(GetSecurityFirewallConfigRulesSecurityResponseAlgo);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseRateLimit$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseRateLimit,
z.ZodTypeDef,
unknown
> = z.object({
algo: GetSecurityFirewallConfigRulesSecurityResponseAlgo$inboundSchema,
window: types.number(),
limit: types.number(),
keys: z.array(types.string()),
action: z.nullable(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2ActionAction$inboundSchema,
).optional(),
});
export function getSecurityFirewallConfigRulesSecurityResponseRateLimitFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseRateLimit,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseRateLimit$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseRateLimit' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseRedirect$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseRedirect,
z.ZodTypeDef,
unknown
> = z.object({
location: types.string(),
permanent: types.boolean(),
});
export function getSecurityFirewallConfigRulesSecurityResponseRedirectFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseRedirect,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseRedirect$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseRedirect' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2
> = z.nativeEnum(
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseLogHeaders$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseLogHeaders,
z.ZodTypeDef,
unknown
> = smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2$inboundSchema,
]);
export function getSecurityFirewallConfigRulesSecurityResponseLogHeadersFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseLogHeaders,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseLogHeaders$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseLogHeaders' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseMitigate$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseMitigate,
z.ZodTypeDef,
unknown
> = z.object({
action:
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft2Action$inboundSchema,
rateLimit: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponseRateLimit$inboundSchema
),
).optional(),
redirect: z.nullable(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponseRedirect$inboundSchema
),
).optional(),
actionDuration: z.nullable(types.string()).optional(),
bypassSystem: z.nullable(types.boolean()).optional(),
logHeaders: types.optional(
smartUnion([
z.array(types.string()),
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraft2$inboundSchema,
]),
),
});
export function getSecurityFirewallConfigRulesSecurityResponseMitigateFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseMitigate,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseMitigate$inboundSchema
.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseMitigate' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponseAction$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityResponseAction,
z.ZodTypeDef,
unknown
> = z.object({
mitigate: types.optional(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponseMitigate$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesSecurityResponseActionFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityResponseAction,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityResponseAction$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityResponseAction' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRules2$inboundSchema: z.ZodType<
GetSecurityFirewallConfigRules2,
z.ZodTypeDef,
unknown
> = z.object({
id: types.string(),
name: types.string(),
description: types.optional(types.string()),
active: types.boolean(),
conditionGroup: z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponseConditionGroup$inboundSchema
),
),
action: z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityResponseAction$inboundSchema
),
valid: types.literal(false),
validationErrors: z.array(types.string()),
});
export function getSecurityFirewallConfigRules2FromJSON(
jsonString: string,
): SafeParseResult<GetSecurityFirewallConfigRules2, SDKValidationError> {
return safeParse(
jsonString,
(x) => GetSecurityFirewallConfigRules2$inboundSchema.parse(JSON.parse(x)),
`Failed to parse 'GetSecurityFirewallConfigRules2' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityType$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesSecurityType> = z
.nativeEnum(GetSecurityFirewallConfigRulesSecurityType);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityOp$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesSecurityOp> = z
.nativeEnum(GetSecurityFirewallConfigRulesSecurityOp);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityValue$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityValue,
z.ZodTypeDef,
unknown
> = smartUnion([types.string(), types.number(), z.array(types.string())]);
export function getSecurityFirewallConfigRulesSecurityValueFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityValue,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityValue$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityValue' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityConditions$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityConditions,
z.ZodTypeDef,
unknown
> = z.object({
type: GetSecurityFirewallConfigRulesSecurityType$inboundSchema,
op: GetSecurityFirewallConfigRulesSecurityOp$inboundSchema,
neg: types.optional(types.boolean()),
key: types.optional(types.string()),
value: types.optional(
smartUnion([types.string(), types.number(), z.array(types.string())]),
),
});
export function getSecurityFirewallConfigRulesSecurityConditionsFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityConditions,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityConditions$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityConditions' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityConditionGroup$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityConditionGroup,
z.ZodTypeDef,
unknown
> = z.object({
conditions: z.array(
z.lazy(() =>
GetSecurityFirewallConfigRulesSecurityConditions$inboundSchema
),
),
});
export function getSecurityFirewallConfigRulesSecurityConditionGroupFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityConditionGroup,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityConditionGroup$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityConditionGroup' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraftAction$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraftAction
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraftAction,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityAlgo$inboundSchema:
z.ZodNativeEnum<typeof GetSecurityFirewallConfigRulesSecurityAlgo> = z
.nativeEnum(GetSecurityFirewallConfigRulesSecurityAlgo);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action
> = z.nativeEnum(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action,
);
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityRateLimit$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityRateLimit,
z.ZodTypeDef,
unknown
> = z.object({
algo: GetSecurityFirewallConfigRulesSecurityAlgo$inboundSchema,
window: types.number(),
limit: types.number(),
keys: z.array(types.string()),
action: z.nullable(
GetSecurityFirewallConfigRulesSecurityResponse200ApplicationJSONResponseBodyDraft1Action$inboundSchema,
).optional(),
});
export function getSecurityFirewallConfigRulesSecurityRateLimitFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityRateLimit,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityRateLimit$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityRateLimit' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigRulesSecurityRedirect$inboundSchema:
z.ZodType<
GetSecurityFirewallConfigRulesSecurityRedirect,
z.ZodTypeDef,
unknown
> = z.object({
location: types.string(),
permanent: types.boolean(),
});
export function getSecurityFirewallConfigRulesSecurityRedirectFromJSON(
jsonString: string,
): SafeParseResult<
GetSecurityFirewallConfigRulesSecurityRedirect,
SDKValidationError
> {
return safeParse(
jsonString,
(x) =>
GetSecurityFirewallConfigRulesSecurityRedirect$inboundSchema.parse(
JSON.parse(x),
),
`Failed to parse 'GetSecurityFirewallConfigRulesSecurityRedirect' from JSON`,
);
}
/** @internal */
export const GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraftRules2$inboundSchema:
z.ZodNativeEnum<
typeof GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraftRules2
> = z.nativeEnum(
GetSecurityFirewallConfigLogHeadersSecurityResponse200ApplicationJSONResponseBodyDraftRules2,
);