/**
 * Cloudflare PAGE-SHIELD API
 *
 * Generated from Cloudflare TypeScript SDK.
 * DO NOT EDIT - regenerate with: bun scripts/generate.ts --service page-shield
 */
import * as Schema from "effect/Schema";
import * as API from "../client/api.js";
import * as T from "../traits.js";
import {} from "../errors.js";
export const GetConnectionRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    connectionId: Schema.String.pipe(T.HttpPath("connectionId")),
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
}).pipe(T.Http({
    method: "GET",
    path: "/zones/{zone_id}/page_shield/connections/{connectionId}",
}));
export const GetConnectionResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.String,
    addedAt: Schema.String,
    firstSeenAt: Schema.String,
    host: Schema.String,
    lastSeenAt: Schema.String,
    url: Schema.String,
    urlContainsCdnCgiPath: Schema.Boolean,
    domainReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
    firstPageUrl: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
    maliciousDomainCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
    maliciousUrlCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
    pageUrls: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
    urlReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
})
    .pipe(Schema.encodeKeys({
    id: "id",
    addedAt: "added_at",
    firstSeenAt: "first_seen_at",
    host: "host",
    lastSeenAt: "last_seen_at",
    url: "url",
    urlContainsCdnCgiPath: "url_contains_cdn_cgi_path",
    domainReportedMalicious: "domain_reported_malicious",
    firstPageUrl: "first_page_url",
    maliciousDomainCategories: "malicious_domain_categories",
    maliciousUrlCategories: "malicious_url_categories",
    pageUrls: "page_urls",
    urlReportedMalicious: "url_reported_malicious",
}))
    .pipe(T.ResponsePath("result"));
export const getConnection = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: GetConnectionRequest,
    output: GetConnectionResponse,
    errors: [],
}));
export const ListConnectionsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
    direction: Schema.optional(Schema.Literals(["asc", "desc"])).pipe(T.HttpQuery("direction")),
    excludeCdnCgi: Schema.optional(Schema.Boolean).pipe(T.HttpQuery("exclude_cdn_cgi")),
    excludeUrls: Schema.optional(Schema.String).pipe(T.HttpQuery("exclude_urls")),
    export: Schema.optional(Schema.Literal("csv")).pipe(T.HttpQuery("export")),
    hosts: Schema.optional(Schema.String).pipe(T.HttpQuery("hosts")),
    orderBy: Schema.optional(Schema.Literals(["first_seen_at", "last_seen_at"])).pipe(T.HttpQuery("order_by")),
    page: Schema.optional(Schema.String).pipe(T.HttpQuery("page")),
    pageUrl: Schema.optional(Schema.String).pipe(T.HttpQuery("page_url")),
    perPage: Schema.optional(Schema.Number).pipe(T.HttpQuery("per_page")),
    prioritizeMalicious: Schema.optional(Schema.Boolean).pipe(T.HttpQuery("prioritize_malicious")),
    status: Schema.optional(Schema.String).pipe(T.HttpQuery("status")),
    urls: Schema.optional(Schema.String).pipe(T.HttpQuery("urls")),
}).pipe(T.Http({ method: "GET", path: "/zones/{zone_id}/page_shield/connections" }));
export const ListConnectionsResponse = 
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    result: Schema.Array(Schema.Struct({
        id: Schema.String,
        addedAt: Schema.String,
        firstSeenAt: Schema.String,
        host: Schema.String,
        lastSeenAt: Schema.String,
        url: Schema.String,
        urlContainsCdnCgiPath: Schema.Boolean,
        domainReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
        firstPageUrl: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
        maliciousDomainCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
        maliciousUrlCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
        pageUrls: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
        urlReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
    }).pipe(Schema.encodeKeys({
        id: "id",
        addedAt: "added_at",
        firstSeenAt: "first_seen_at",
        host: "host",
        lastSeenAt: "last_seen_at",
        url: "url",
        urlContainsCdnCgiPath: "url_contains_cdn_cgi_path",
        domainReportedMalicious: "domain_reported_malicious",
        firstPageUrl: "first_page_url",
        maliciousDomainCategories: "malicious_domain_categories",
        maliciousUrlCategories: "malicious_url_categories",
        pageUrls: "page_urls",
        urlReportedMalicious: "url_reported_malicious",
    }))),
});
export const listConnections = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
    input: ListConnectionsRequest,
    output: ListConnectionsResponse,
    errors: [],
    pagination: {
        mode: "single",
        items: "result",
    },
}));
export const GetCookyRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    cookieId: Schema.String.pipe(T.HttpPath("cookieId")),
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
}).pipe(T.Http({
    method: "GET",
    path: "/zones/{zone_id}/page_shield/cookies/{cookieId}",
}));
export const GetCookyResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.String,
    firstSeenAt: Schema.String,
    host: Schema.String,
    lastSeenAt: Schema.String,
    name: Schema.String,
    type: Schema.Literals(["first_party", "unknown"]),
    domainAttribute: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
    expiresAttribute: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
    httpOnlyAttribute: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
    maxAgeAttribute: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
    pageUrls: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
    pathAttribute: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
    sameSiteAttribute: Schema.optional(Schema.Union([Schema.Literals(["lax", "strict", "none"]), Schema.Null])),
    secureAttribute: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
})
    .pipe(Schema.encodeKeys({
    id: "id",
    firstSeenAt: "first_seen_at",
    host: "host",
    lastSeenAt: "last_seen_at",
    name: "name",
    type: "type",
    domainAttribute: "domain_attribute",
    expiresAttribute: "expires_attribute",
    httpOnlyAttribute: "http_only_attribute",
    maxAgeAttribute: "max_age_attribute",
    pageUrls: "page_urls",
    pathAttribute: "path_attribute",
    sameSiteAttribute: "same_site_attribute",
    secureAttribute: "secure_attribute",
}))
    .pipe(T.ResponsePath("result"));
export const getCooky = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: GetCookyRequest,
    output: GetCookyResponse,
    errors: [],
}));
export const ListCookiesRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
    direction: Schema.optional(Schema.Literals(["asc", "desc"])).pipe(T.HttpQuery("direction")),
    domain: Schema.optional(Schema.String).pipe(T.HttpQuery("domain")),
    export: Schema.optional(Schema.Literal("csv")).pipe(T.HttpQuery("export")),
    hosts: Schema.optional(Schema.String).pipe(T.HttpQuery("hosts")),
    httpOnly: Schema.optional(Schema.Boolean).pipe(T.HttpQuery("http_only")),
    name: Schema.optional(Schema.String).pipe(T.HttpQuery("name")),
    orderBy: Schema.optional(Schema.Literals(["first_seen_at", "last_seen_at"])).pipe(T.HttpQuery("order_by")),
    page: Schema.optional(Schema.String).pipe(T.HttpQuery("page")),
    pageUrl: Schema.optional(Schema.String).pipe(T.HttpQuery("page_url")),
    path: Schema.optional(Schema.String).pipe(T.HttpQuery("path")),
    perPage: Schema.optional(Schema.Number).pipe(T.HttpQuery("per_page")),
    sameSite: Schema.optional(Schema.Literals(["lax", "strict", "none"])).pipe(T.HttpQuery("same_site")),
    secure: Schema.optional(Schema.Boolean).pipe(T.HttpQuery("secure")),
    type: Schema.optional(Schema.Literals(["first_party", "unknown"])).pipe(T.HttpQuery("type")),
}).pipe(T.Http({ method: "GET", path: "/zones/{zone_id}/page_shield/cookies" }));
export const ListCookiesResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    result: Schema.Array(Schema.Struct({
        id: Schema.String,
        firstSeenAt: Schema.String,
        host: Schema.String,
        lastSeenAt: Schema.String,
        name: Schema.String,
        type: Schema.Literals(["first_party", "unknown"]),
        domainAttribute: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
        expiresAttribute: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
        httpOnlyAttribute: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
        maxAgeAttribute: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        pageUrls: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
        pathAttribute: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
        sameSiteAttribute: Schema.optional(Schema.Union([Schema.Literals(["lax", "strict", "none"]), Schema.Null])),
        secureAttribute: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
    }).pipe(Schema.encodeKeys({
        id: "id",
        firstSeenAt: "first_seen_at",
        host: "host",
        lastSeenAt: "last_seen_at",
        name: "name",
        type: "type",
        domainAttribute: "domain_attribute",
        expiresAttribute: "expires_attribute",
        httpOnlyAttribute: "http_only_attribute",
        maxAgeAttribute: "max_age_attribute",
        pageUrls: "page_urls",
        pathAttribute: "path_attribute",
        sameSiteAttribute: "same_site_attribute",
        secureAttribute: "secure_attribute",
    }))),
});
export const listCookies = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
    input: ListCookiesRequest,
    output: ListCookiesResponse,
    errors: [],
    pagination: {
        mode: "single",
        items: "result",
    },
}));
export const GetPageShieldRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
}).pipe(T.Http({ method: "GET", path: "/zones/{zone_id}/page_shield" }));
export const GetPageShieldResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    enabled: Schema.Boolean,
    updatedAt: Schema.String,
    useCloudflareReportingEndpoint: Schema.Boolean,
    useConnectionUrlPath: Schema.Boolean,
})
    .pipe(Schema.encodeKeys({
    enabled: "enabled",
    updatedAt: "updated_at",
    useCloudflareReportingEndpoint: "use_cloudflare_reporting_endpoint",
    useConnectionUrlPath: "use_connection_url_path",
}))
    .pipe(T.ResponsePath("result"));
export const getPageShield = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: GetPageShieldRequest,
    output: GetPageShieldResponse,
    errors: [],
}));
export const PutPageShieldRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
    enabled: Schema.optional(Schema.Boolean),
    useCloudflareReportingEndpoint: Schema.optional(Schema.Boolean),
    useConnectionUrlPath: Schema.optional(Schema.Boolean),
}).pipe(Schema.encodeKeys({
    enabled: "enabled",
    useCloudflareReportingEndpoint: "use_cloudflare_reporting_endpoint",
    useConnectionUrlPath: "use_connection_url_path",
}), T.Http({ method: "PUT", path: "/zones/{zone_id}/page_shield" }));
export const PutPageShieldResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    enabled: Schema.Boolean,
    updatedAt: Schema.String,
    useCloudflareReportingEndpoint: Schema.Boolean,
    useConnectionUrlPath: Schema.Boolean,
})
    .pipe(Schema.encodeKeys({
    enabled: "enabled",
    updatedAt: "updated_at",
    useCloudflareReportingEndpoint: "use_cloudflare_reporting_endpoint",
    useConnectionUrlPath: "use_connection_url_path",
}))
    .pipe(T.ResponsePath("result"));
export const putPageShield = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: PutPageShieldRequest,
    output: PutPageShieldResponse,
    errors: [],
}));
export const GetPolicyRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    policyId: Schema.String.pipe(T.HttpPath("policyId")),
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
}).pipe(T.Http({
    method: "GET",
    path: "/zones/{zone_id}/page_shield/policies/{policyId}",
}));
export const GetPolicyResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.String,
    action: Schema.Literals(["allow", "log"]),
    description: Schema.String,
    enabled: Schema.Boolean,
    expression: Schema.String,
    value: Schema.String,
}).pipe(T.ResponsePath("result"));
export const getPolicy = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: GetPolicyRequest,
    output: GetPolicyResponse,
    errors: [],
}));
export const ListPoliciesRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
}).pipe(T.Http({ method: "GET", path: "/zones/{zone_id}/page_shield/policies" }));
export const ListPoliciesResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    result: Schema.Array(Schema.Struct({
        id: Schema.String,
        action: Schema.Literals(["allow", "log"]),
        description: Schema.String,
        enabled: Schema.Boolean,
        expression: Schema.String,
        value: Schema.String,
    })),
});
export const listPolicies = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
    input: ListPoliciesRequest,
    output: ListPoliciesResponse,
    errors: [],
    pagination: {
        mode: "single",
        items: "result",
    },
}));
export const CreatePolicyRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
    action: Schema.Literals(["allow", "log"]),
    description: Schema.String,
    enabled: Schema.Boolean,
    expression: Schema.String,
    value: Schema.String,
}).pipe(T.Http({ method: "POST", path: "/zones/{zone_id}/page_shield/policies" }));
export const CreatePolicyResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.String,
    action: Schema.Literals(["allow", "log"]),
    description: Schema.String,
    enabled: Schema.Boolean,
    expression: Schema.String,
    value: Schema.String,
}).pipe(T.ResponsePath("result"));
export const createPolicy = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: CreatePolicyRequest,
    output: CreatePolicyResponse,
    errors: [],
}));
export const UpdatePolicyRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    policyId: Schema.String.pipe(T.HttpPath("policyId")),
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
    action: Schema.optional(Schema.Literals(["allow", "log"])),
    description: Schema.optional(Schema.String),
    enabled: Schema.optional(Schema.Boolean),
    expression: Schema.optional(Schema.String),
    value: Schema.optional(Schema.String),
}).pipe(T.Http({
    method: "PUT",
    path: "/zones/{zone_id}/page_shield/policies/{policyId}",
}));
export const UpdatePolicyResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.String,
    action: Schema.Literals(["allow", "log"]),
    description: Schema.String,
    enabled: Schema.Boolean,
    expression: Schema.String,
    value: Schema.String,
}).pipe(T.ResponsePath("result"));
export const updatePolicy = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: UpdatePolicyRequest,
    output: UpdatePolicyResponse,
    errors: [],
}));
export const DeletePolicyRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    policyId: Schema.String.pipe(T.HttpPath("policyId")),
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
}).pipe(T.Http({
    method: "DELETE",
    path: "/zones/{zone_id}/page_shield/policies/{policyId}",
}));
export const DeletePolicyResponse = 
/*@__PURE__*/ /*#__PURE__*/ Schema.Unknown;
export const deletePolicy = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: DeletePolicyRequest,
    output: DeletePolicyResponse,
    errors: [],
}));
export const GetScriptRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    scriptId: Schema.String.pipe(T.HttpPath("scriptId")),
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
}).pipe(T.Http({
    method: "GET",
    path: "/zones/{zone_id}/page_shield/scripts/{scriptId}",
}));
export const GetScriptResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.String,
    addedAt: Schema.String,
    firstSeenAt: Schema.String,
    host: Schema.String,
    lastSeenAt: Schema.String,
    url: Schema.String,
    urlContainsCdnCgiPath: Schema.Boolean,
    cryptominingScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
    dataflowScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
    domainReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
    fetchedAt: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
    firstPageUrl: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
    hash: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
    jsIntegrityScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
    magecartScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
    maliciousDomainCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
    maliciousUrlCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
    malwareScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
    obfuscationScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
    pageUrls: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
    urlReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
    versions: Schema.optional(Schema.Union([
        Schema.Array(Schema.Struct({
            cryptominingScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
            dataflowScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
            fetchedAt: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
            hash: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
            jsIntegrityScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
            magecartScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
            malwareScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
            obfuscationScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        }).pipe(Schema.encodeKeys({
            cryptominingScore: "cryptomining_score",
            dataflowScore: "dataflow_score",
            fetchedAt: "fetched_at",
            hash: "hash",
            jsIntegrityScore: "js_integrity_score",
            magecartScore: "magecart_score",
            malwareScore: "malware_score",
            obfuscationScore: "obfuscation_score",
        }))),
        Schema.Null,
    ])),
})
    .pipe(Schema.encodeKeys({
    id: "id",
    addedAt: "added_at",
    firstSeenAt: "first_seen_at",
    host: "host",
    lastSeenAt: "last_seen_at",
    url: "url",
    urlContainsCdnCgiPath: "url_contains_cdn_cgi_path",
    cryptominingScore: "cryptomining_score",
    dataflowScore: "dataflow_score",
    domainReportedMalicious: "domain_reported_malicious",
    fetchedAt: "fetched_at",
    firstPageUrl: "first_page_url",
    hash: "hash",
    jsIntegrityScore: "js_integrity_score",
    magecartScore: "magecart_score",
    maliciousDomainCategories: "malicious_domain_categories",
    maliciousUrlCategories: "malicious_url_categories",
    malwareScore: "malware_score",
    obfuscationScore: "obfuscation_score",
    pageUrls: "page_urls",
    urlReportedMalicious: "url_reported_malicious",
    versions: "versions",
}))
    .pipe(T.ResponsePath("result"));
export const getScript = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    input: GetScriptRequest,
    output: GetScriptResponse,
    errors: [],
}));
export const ListScriptsRequest = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    zoneId: Schema.String.pipe(T.HttpPath("zone_id")),
    direction: Schema.optional(Schema.Literals(["asc", "desc"])).pipe(T.HttpQuery("direction")),
    excludeCdnCgi: Schema.optional(Schema.Boolean).pipe(T.HttpQuery("exclude_cdn_cgi")),
    excludeDuplicates: Schema.optional(Schema.Boolean).pipe(T.HttpQuery("exclude_duplicates")),
    excludeUrls: Schema.optional(Schema.String).pipe(T.HttpQuery("exclude_urls")),
    export: Schema.optional(Schema.Literal("csv")).pipe(T.HttpQuery("export")),
    hosts: Schema.optional(Schema.String).pipe(T.HttpQuery("hosts")),
    orderBy: Schema.optional(Schema.Literals(["first_seen_at", "last_seen_at"])).pipe(T.HttpQuery("order_by")),
    page: Schema.optional(Schema.String).pipe(T.HttpQuery("page")),
    pageUrl: Schema.optional(Schema.String).pipe(T.HttpQuery("page_url")),
    perPage: Schema.optional(Schema.Number).pipe(T.HttpQuery("per_page")),
    prioritizeMalicious: Schema.optional(Schema.Boolean).pipe(T.HttpQuery("prioritize_malicious")),
    status: Schema.optional(Schema.String).pipe(T.HttpQuery("status")),
    urls: Schema.optional(Schema.String).pipe(T.HttpQuery("urls")),
}).pipe(T.Http({ method: "GET", path: "/zones/{zone_id}/page_shield/scripts" }));
export const ListScriptsResponse = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    result: Schema.Array(Schema.Struct({
        id: Schema.String,
        addedAt: Schema.String,
        firstSeenAt: Schema.String,
        host: Schema.String,
        lastSeenAt: Schema.String,
        url: Schema.String,
        urlContainsCdnCgiPath: Schema.Boolean,
        cryptominingScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        dataflowScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        domainReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
        fetchedAt: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
        firstPageUrl: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
        hash: Schema.optional(Schema.Union([Schema.String, Schema.Null])),
        jsIntegrityScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        magecartScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        maliciousDomainCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
        maliciousUrlCategories: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
        malwareScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        obfuscationScore: Schema.optional(Schema.Union([Schema.Number, Schema.Null])),
        pageUrls: Schema.optional(Schema.Union([Schema.Array(Schema.String), Schema.Null])),
        urlReportedMalicious: Schema.optional(Schema.Union([Schema.Boolean, Schema.Null])),
    }).pipe(Schema.encodeKeys({
        id: "id",
        addedAt: "added_at",
        firstSeenAt: "first_seen_at",
        host: "host",
        lastSeenAt: "last_seen_at",
        url: "url",
        urlContainsCdnCgiPath: "url_contains_cdn_cgi_path",
        cryptominingScore: "cryptomining_score",
        dataflowScore: "dataflow_score",
        domainReportedMalicious: "domain_reported_malicious",
        fetchedAt: "fetched_at",
        firstPageUrl: "first_page_url",
        hash: "hash",
        jsIntegrityScore: "js_integrity_score",
        magecartScore: "magecart_score",
        maliciousDomainCategories: "malicious_domain_categories",
        maliciousUrlCategories: "malicious_url_categories",
        malwareScore: "malware_score",
        obfuscationScore: "obfuscation_score",
        pageUrls: "page_urls",
        urlReportedMalicious: "url_reported_malicious",
    }))),
});
export const listScripts = /*@__PURE__*/ /*#__PURE__*/ API.makePaginated(() => ({
    input: ListScriptsRequest,
    output: ListScriptsResponse,
    errors: [],
    pagination: {
        mode: "single",
        items: "result",
    },
}));
//# sourceMappingURL=page-shield.js.map