@censys/platform-sdk 0.9.0 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -6
- package/docs/sdks/accountmanagement/README.md +100 -6
- package/docs/sdks/collections/README.md +6 -6
- package/docs/sdks/threathunting/README.md +1 -1
- package/examples/package-lock.json +1 -1
- package/funcs/accountManagementGetMemberCreditUsage.d.ts +2 -2
- package/funcs/accountManagementGetMemberCreditUsage.js +5 -2
- package/funcs/accountManagementGetMemberCreditUsage.js.map +1 -1
- package/funcs/accountManagementGetOrganizationCreditUsage.d.ts +1 -1
- package/funcs/accountManagementGetOrganizationCreditUsage.js +5 -1
- package/funcs/accountManagementGetOrganizationCreditUsage.js.map +1 -1
- package/funcs/accountManagementGetOrganizationCredits.d.ts +1 -1
- package/funcs/accountManagementGetOrganizationCredits.js +1 -1
- package/funcs/accountManagementGetUserCredits.d.ts +2 -2
- package/funcs/accountManagementGetUserCredits.js +2 -2
- package/funcs/accountManagementGetUserCreditsUsage.d.ts +18 -0
- package/funcs/accountManagementGetUserCreditsUsage.d.ts.map +1 -0
- package/funcs/accountManagementGetUserCreditsUsage.js +129 -0
- package/funcs/accountManagementGetUserCreditsUsage.js.map +1 -0
- package/funcs/collectionsCreate.d.ts +1 -1
- package/funcs/collectionsCreate.js +1 -1
- package/funcs/collectionsDelete.d.ts +1 -1
- package/funcs/collectionsDelete.js +1 -1
- package/funcs/collectionsGet.d.ts +1 -1
- package/funcs/collectionsGet.js +1 -1
- package/funcs/collectionsList.d.ts +1 -1
- package/funcs/collectionsList.js +1 -1
- package/funcs/collectionsListEvents.d.ts +1 -1
- package/funcs/collectionsListEvents.js +1 -1
- package/funcs/collectionsUpdate.d.ts +1 -1
- package/funcs/collectionsUpdate.js +1 -1
- package/funcs/threatHuntingListThreats.d.ts +1 -1
- package/funcs/threatHuntingListThreats.js +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +4 -4
- package/lib/config.js +4 -4
- package/lib/sdks.js +2 -2
- package/lib/sdks.js.map +1 -1
- package/models/components/alternativequery.d.ts +3 -3
- package/models/components/alternativequery.d.ts.map +1 -1
- package/models/components/alternativequery.js +2 -2
- package/models/components/alternativequery.js.map +1 -1
- package/models/components/attribute.d.ts +4 -3
- package/models/components/attribute.d.ts.map +1 -1
- package/models/components/attribute.js +3 -2
- package/models/components/attribute.js.map +1 -1
- package/models/components/certificate.d.ts +5 -5
- package/models/components/certificate.d.ts.map +1 -1
- package/models/components/certificate.js +3 -3
- package/models/components/certificate.js.map +1 -1
- package/models/components/certificaterevocationrevocationinfo.d.ts +3 -3
- package/models/components/certificaterevocationrevocationinfo.d.ts.map +1 -1
- package/models/components/certificaterevocationrevocationinfo.js +2 -2
- package/models/components/certificaterevocationrevocationinfo.js.map +1 -1
- package/models/components/collection.d.ts +9 -5
- package/models/components/collection.d.ts.map +1 -1
- package/models/components/collection.js +5 -2
- package/models/components/collection.js.map +1 -1
- package/models/components/creditexpiration.d.ts +4 -0
- package/models/components/creditexpiration.d.ts.map +1 -1
- package/models/components/creditexpiration.js +2 -0
- package/models/components/creditexpiration.js.map +1 -1
- package/models/components/creditusagereport.d.ts +44 -5
- package/models/components/creditusagereport.d.ts.map +1 -1
- package/models/components/creditusagereport.js +28 -7
- package/models/components/creditusagereport.js.map +1 -1
- package/models/components/creditusagereportperiod.d.ts +33 -0
- package/models/components/creditusagereportperiod.d.ts.map +1 -0
- package/models/components/creditusagereportperiod.js +65 -0
- package/models/components/creditusagereportperiod.js.map +1 -0
- package/models/components/cvsscomponents.d.ts +17 -17
- package/models/components/cvsscomponents.d.ts.map +1 -1
- package/models/components/cvsscomponents.js +9 -9
- package/models/components/cvsscomponents.js.map +1 -1
- package/models/components/cvssv4components.d.ts +29 -29
- package/models/components/cvssv4components.d.ts.map +1 -1
- package/models/components/cvssv4components.js +15 -17
- package/models/components/cvssv4components.js.map +1 -1
- package/models/components/dns.d.ts +5 -5
- package/models/components/dns.d.ts.map +1 -1
- package/models/components/dns.js +3 -3
- package/models/components/dns.js.map +1 -1
- package/models/components/dnsresourcerecord.d.ts +3 -3
- package/models/components/dnsresourcerecord.d.ts.map +1 -1
- package/models/components/dnsresourcerecord.js +2 -1
- package/models/components/dnsresourcerecord.js.map +1 -1
- package/models/components/endpointscan.d.ts +3 -3
- package/models/components/endpointscan.d.ts.map +1 -1
- package/models/components/endpointscan.js +2 -1
- package/models/components/endpointscan.js.map +1 -1
- package/models/components/endpointscanstate.d.ts +5 -3
- package/models/components/endpointscanstate.d.ts.map +1 -1
- package/models/components/endpointscanstate.js +4 -1
- package/models/components/endpointscanstate.js.map +1 -1
- package/models/components/eventassetchange.d.ts +3 -3
- package/models/components/eventassetchange.d.ts.map +1 -1
- package/models/components/eventassetchange.js +2 -2
- package/models/components/eventassetchange.js.map +1 -1
- package/models/components/eventstatuschange.d.ts +5 -5
- package/models/components/eventstatuschange.d.ts.map +1 -1
- package/models/components/eventstatuschange.js +3 -4
- package/models/components/eventstatuschange.js.map +1 -1
- package/models/components/extractedendpointdata.d.ts +17 -0
- package/models/components/extractedendpointdata.d.ts.map +1 -0
- package/models/components/extractedendpointdata.js +65 -0
- package/models/components/extractedendpointdata.js.map +1 -0
- package/models/components/extractedendpointdataanalyticsservice.d.ts +11 -0
- package/models/components/extractedendpointdataanalyticsservice.d.ts.map +1 -0
- package/models/components/extractedendpointdataanalyticsservice.js +51 -0
- package/models/components/extractedendpointdataanalyticsservice.js.map +1 -0
- package/models/components/extractedendpointdatacopyright.d.ts +13 -0
- package/models/components/extractedendpointdatacopyright.d.ts.map +1 -0
- package/models/components/extractedendpointdatacopyright.js +59 -0
- package/models/components/extractedendpointdatacopyright.js.map +1 -0
- package/models/components/hajime.d.ts +10 -0
- package/models/components/hajime.d.ts.map +1 -0
- package/models/components/hajime.js +56 -0
- package/models/components/hajime.js.map +1 -0
- package/models/components/hostdnsforwardresolution.d.ts +3 -3
- package/models/components/hostdnsforwardresolution.d.ts.map +1 -1
- package/models/components/hostdnsforwardresolution.js +2 -2
- package/models/components/hostdnsforwardresolution.js.map +1 -1
- package/models/components/http.d.ts +7 -0
- package/models/components/http.d.ts.map +1 -1
- package/models/components/http.js +7 -0
- package/models/components/http.js.map +1 -1
- package/models/components/httpredirectchainlink.d.ts +25 -0
- package/models/components/httpredirectchainlink.d.ts.map +1 -0
- package/models/components/httpredirectchainlink.js +70 -0
- package/models/components/httpredirectchainlink.js.map +1 -0
- package/models/components/index.d.ts +8 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +8 -0
- package/models/components/index.js.map +1 -1
- package/models/components/jarmscan.d.ts +3 -3
- package/models/components/jarmscan.d.ts.map +1 -1
- package/models/components/jarmscan.js +2 -1
- package/models/components/jarmscan.js.map +1 -1
- package/models/components/kev.d.ts +3 -3
- package/models/components/kev.d.ts.map +1 -1
- package/models/components/kev.js +2 -2
- package/models/components/kev.js.map +1 -1
- package/models/components/label.d.ts +4 -3
- package/models/components/label.d.ts.map +1 -1
- package/models/components/label.js +3 -2
- package/models/components/label.js.map +1 -1
- package/models/components/matchedservice.d.ts +3 -3
- package/models/components/matchedservice.d.ts.map +1 -1
- package/models/components/matchedservice.js +2 -1
- package/models/components/matchedservice.js.map +1 -1
- package/models/components/networklog.d.ts +18 -0
- package/models/components/networklog.d.ts.map +1 -0
- package/models/components/networklog.js +58 -0
- package/models/components/networklog.js.map +1 -0
- package/models/components/networklogresourceinfo.d.ts +49 -0
- package/models/components/networklogresourceinfo.d.ts.map +1 -0
- package/models/components/networklogresourceinfo.js +64 -0
- package/models/components/networklogresourceinfo.js.map +1 -0
- package/models/components/paginationinfo.d.ts +1 -1
- package/models/components/reject.d.ts +3 -3
- package/models/components/reject.d.ts.map +1 -1
- package/models/components/reject.js +2 -2
- package/models/components/reject.js.map +1 -1
- package/models/components/representativeinfo.d.ts +3 -3
- package/models/components/representativeinfo.d.ts.map +1 -1
- package/models/components/representativeinfo.js +2 -1
- package/models/components/representativeinfo.js.map +1 -1
- package/models/components/risk.d.ts +8 -7
- package/models/components/risk.d.ts.map +1 -1
- package/models/components/risk.js +5 -6
- package/models/components/risk.js.map +1 -1
- package/models/components/rootstore.d.ts +3 -3
- package/models/components/rootstore.d.ts.map +1 -1
- package/models/components/rootstore.js +2 -1
- package/models/components/rootstore.js.map +1 -1
- package/models/components/searchconvertqueryresponse.d.ts +3 -3
- package/models/components/searchconvertqueryresponse.d.ts.map +1 -1
- package/models/components/searchconvertqueryresponse.js +2 -1
- package/models/components/searchconvertqueryresponse.js.map +1 -1
- package/models/components/service.d.ts +5 -3
- package/models/components/service.d.ts.map +1 -1
- package/models/components/service.js +4 -1
- package/models/components/service.js.map +1 -1
- package/models/components/serviceid.d.ts +3 -3
- package/models/components/serviceid.d.ts.map +1 -1
- package/models/components/serviceid.js +2 -1
- package/models/components/serviceid.js.map +1 -1
- package/models/components/servicescan.d.ts +5 -3
- package/models/components/servicescan.d.ts.map +1 -1
- package/models/components/servicescan.js +4 -1
- package/models/components/servicescan.js.map +1 -1
- package/models/components/sourceusagebreakdown.d.ts +9 -1
- package/models/components/sourceusagebreakdown.d.ts.map +1 -1
- package/models/components/sourceusagebreakdown.js +7 -0
- package/models/components/sourceusagebreakdown.js.map +1 -1
- package/models/components/threat.d.ts +4 -3
- package/models/components/threat.d.ts.map +1 -1
- package/models/components/threat.js +3 -1
- package/models/components/threat.js.map +1 -1
- package/models/components/tls.d.ts +3 -3
- package/models/components/tls.d.ts.map +1 -1
- package/models/components/tls.js +2 -1
- package/models/components/tls.js.map +1 -1
- package/models/components/tlsversiondata.d.ts +3 -3
- package/models/components/tlsversiondata.d.ts.map +1 -1
- package/models/components/tlsversiondata.js +2 -2
- package/models/components/tlsversiondata.js.map +1 -1
- package/models/components/trackedscantask.d.ts +3 -3
- package/models/components/trackedscantask.d.ts.map +1 -1
- package/models/components/trackedscantask.js +2 -1
- package/models/components/trackedscantask.js.map +1 -1
- package/models/components/vuln.d.ts +8 -7
- package/models/components/vuln.d.ts.map +1 -1
- package/models/components/vuln.js +5 -4
- package/models/components/vuln.js.map +1 -1
- package/models/operations/index.d.ts +1 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +1 -0
- package/models/operations/index.js.map +1 -1
- package/models/operations/v3accountmanagementmembercreditsusage.d.ts +33 -3
- package/models/operations/v3accountmanagementmembercreditsusage.d.ts.map +1 -1
- package/models/operations/v3accountmanagementmembercreditsusage.js +17 -2
- package/models/operations/v3accountmanagementmembercreditsusage.js.map +1 -1
- package/models/operations/v3accountmanagementorgcreditsusage.d.ts +38 -3
- package/models/operations/v3accountmanagementorgcreditsusage.d.ts.map +1 -1
- package/models/operations/v3accountmanagementorgcreditsusage.js +20 -2
- package/models/operations/v3accountmanagementorgcreditsusage.js.map +1 -1
- package/models/operations/v3accountmanagementusercreditsusage.d.ts +57 -0
- package/models/operations/v3accountmanagementusercreditsusage.d.ts.map +1 -0
- package/models/operations/v3accountmanagementusercreditsusage.js +85 -0
- package/models/operations/v3accountmanagementusercreditsusage.js.map +1 -0
- package/package.json +1 -1
- package/sdk/accountmanagement.d.ts +13 -6
- package/sdk/accountmanagement.d.ts.map +1 -1
- package/sdk/accountmanagement.js +16 -6
- package/sdk/accountmanagement.js.map +1 -1
- package/sdk/collections.d.ts +6 -6
- package/sdk/collections.js +6 -6
- package/sdk/threathunting.d.ts +1 -1
- package/sdk/threathunting.js +1 -1
- package/src/funcs/accountManagementGetMemberCreditUsage.ts +5 -2
- package/src/funcs/accountManagementGetOrganizationCreditUsage.ts +5 -1
- package/src/funcs/accountManagementGetOrganizationCredits.ts +1 -1
- package/src/funcs/accountManagementGetUserCredits.ts +2 -2
- package/src/funcs/accountManagementGetUserCreditsUsage.ts +190 -0
- package/src/funcs/collectionsCreate.ts +1 -1
- package/src/funcs/collectionsDelete.ts +1 -1
- package/src/funcs/collectionsGet.ts +1 -1
- package/src/funcs/collectionsList.ts +1 -1
- package/src/funcs/collectionsListEvents.ts +1 -1
- package/src/funcs/collectionsUpdate.ts +1 -1
- package/src/funcs/threatHuntingListThreats.ts +1 -1
- package/src/lib/config.ts +4 -4
- package/src/lib/sdks.ts +2 -2
- package/src/models/components/alternativequery.ts +5 -4
- package/src/models/components/attribute.ts +6 -4
- package/src/models/components/certificate.ts +14 -8
- package/src/models/components/certificaterevocationrevocationinfo.ts +5 -4
- package/src/models/components/collection.ts +20 -8
- package/src/models/components/creditexpiration.ts +6 -0
- package/src/models/components/creditusagereport.ts +70 -11
- package/src/models/components/creditusagereportperiod.ts +69 -0
- package/src/models/components/cvsscomponents.ts +47 -30
- package/src/models/components/cvssv4components.ts +83 -53
- package/src/models/components/dns.ts +11 -8
- package/src/models/components/dnsresourcerecord.ts +8 -5
- package/src/models/components/endpointscan.ts +8 -5
- package/src/models/components/endpointscanstate.ts +14 -5
- package/src/models/components/eventassetchange.ts +8 -4
- package/src/models/components/eventstatuschange.ts +14 -7
- package/src/models/components/extractedendpointdata.ts +62 -0
- package/src/models/components/extractedendpointdataanalyticsservice.ts +34 -0
- package/src/models/components/extractedendpointdatacopyright.ts +43 -0
- package/src/models/components/hajime.ts +33 -0
- package/src/models/components/hostdnsforwardresolution.ts +8 -4
- package/src/models/components/http.ts +15 -0
- package/src/models/components/httpredirectchainlink.ts +65 -0
- package/src/models/components/index.ts +8 -0
- package/src/models/components/jarmscan.ts +8 -5
- package/src/models/components/kev.ts +8 -4
- package/src/models/components/label.ts +9 -4
- package/src/models/components/matchedservice.ts +8 -5
- package/src/models/components/networklog.ts +49 -0
- package/src/models/components/networklogresourceinfo.ts +84 -0
- package/src/models/components/paginationinfo.ts +1 -1
- package/src/models/components/reject.ts +8 -4
- package/src/models/components/representativeinfo.ts +8 -5
- package/src/models/components/risk.ts +21 -10
- package/src/models/components/rootstore.ts +5 -5
- package/src/models/components/searchconvertqueryresponse.ts +8 -5
- package/src/models/components/service.ts +11 -5
- package/src/models/components/serviceid.ts +8 -5
- package/src/models/components/servicescan.ts +11 -5
- package/src/models/components/sourceusagebreakdown.ts +16 -1
- package/src/models/components/threat.ts +9 -4
- package/src/models/components/tls.ts +8 -5
- package/src/models/components/tlsversiondata.ts +5 -4
- package/src/models/components/trackedscantask.ts +8 -5
- package/src/models/components/vuln.ts +21 -11
- package/src/models/operations/index.ts +1 -0
- package/src/models/operations/v3accountmanagementmembercreditsusage.ts +43 -4
- package/src/models/operations/v3accountmanagementorgcreditsusage.ts +49 -4
- package/src/models/operations/v3accountmanagementusercreditsusage.ts +128 -0
- package/src/sdk/accountmanagement.ts +24 -6
- package/src/sdk/collections.ts +6 -6
- package/src/sdk/threathunting.ts +1 -1
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import * as z from "zod/v3";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import
|
|
8
|
+
import * as openEnums from "../../types/enums.js";
|
|
9
|
+
import { OpenEnum } from "../../types/enums.js";
|
|
9
10
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
11
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
12
|
|
|
@@ -20,7 +21,7 @@ export const CVSSv4ComponentsAttackComplexity = {
|
|
|
20
21
|
/**
|
|
21
22
|
* Indicates conditions beyond the attacker’s control that must exist in order to exploit the vulnerability. The Attack Complexity metric is scored as either Low or High. There are two possible values: Low (L) – There are no specific pre-conditions required for exploitation, High (H) – The attacker must complete some number of preparatory steps in order to get access.
|
|
22
23
|
*/
|
|
23
|
-
export type CVSSv4ComponentsAttackComplexity =
|
|
24
|
+
export type CVSSv4ComponentsAttackComplexity = OpenEnum<
|
|
24
25
|
typeof CVSSv4ComponentsAttackComplexity
|
|
25
26
|
>;
|
|
26
27
|
|
|
@@ -29,7 +30,7 @@ export const AttackRequirements = {
|
|
|
29
30
|
None: "none",
|
|
30
31
|
Present: "present",
|
|
31
32
|
} as const;
|
|
32
|
-
export type AttackRequirements =
|
|
33
|
+
export type AttackRequirements = OpenEnum<typeof AttackRequirements>;
|
|
33
34
|
|
|
34
35
|
/**
|
|
35
36
|
* Indicates the level of access required for an attacker to exploit the vulnerability. The Attack Vector metric is scored in one of four levels: Network (N) – Vulnerabilities with this rating are remotely exploitable, from one or more hops away, up to, and including, remote exploitation over the Internet, Adjacent (A) – A vulnerability with this rating requires network adjacency for exploitation. The attack must be launched from the same physical or logical network, Local (L) – Vulnerabilities with this rating are not exploitable over a network, Physical (P) – An attacker must physically interact with the target system.
|
|
@@ -44,7 +45,7 @@ export const CVSSv4ComponentsAttackVector = {
|
|
|
44
45
|
/**
|
|
45
46
|
* Indicates the level of access required for an attacker to exploit the vulnerability. The Attack Vector metric is scored in one of four levels: Network (N) – Vulnerabilities with this rating are remotely exploitable, from one or more hops away, up to, and including, remote exploitation over the Internet, Adjacent (A) – A vulnerability with this rating requires network adjacency for exploitation. The attack must be launched from the same physical or logical network, Local (L) – Vulnerabilities with this rating are not exploitable over a network, Physical (P) – An attacker must physically interact with the target system.
|
|
46
47
|
*/
|
|
47
|
-
export type CVSSv4ComponentsAttackVector =
|
|
48
|
+
export type CVSSv4ComponentsAttackVector = OpenEnum<
|
|
48
49
|
typeof CVSSv4ComponentsAttackVector
|
|
49
50
|
>;
|
|
50
51
|
|
|
@@ -53,7 +54,7 @@ export const Automatable = {
|
|
|
53
54
|
No: "no",
|
|
54
55
|
Yes: "yes",
|
|
55
56
|
} as const;
|
|
56
|
-
export type Automatable =
|
|
57
|
+
export type Automatable = OpenEnum<typeof Automatable>;
|
|
57
58
|
|
|
58
59
|
/**
|
|
59
60
|
* If an attack renders information unavailable, such as when a system crashes or through a DDoS attack, availability is negatively impacted. Availability has three possible values: None (N) – There is no loss of availability, Low (L) – Availability might be intermittently limited, or performance might be negatively impacted, as a result of a successful attack, High (H) – There is a complete loss of availability of the impacted system or information.
|
|
@@ -67,7 +68,7 @@ export const CVSSv4ComponentsAvailability = {
|
|
|
67
68
|
/**
|
|
68
69
|
* If an attack renders information unavailable, such as when a system crashes or through a DDoS attack, availability is negatively impacted. Availability has three possible values: None (N) – There is no loss of availability, Low (L) – Availability might be intermittently limited, or performance might be negatively impacted, as a result of a successful attack, High (H) – There is a complete loss of availability of the impacted system or information.
|
|
69
70
|
*/
|
|
70
|
-
export type CVSSv4ComponentsAvailability =
|
|
71
|
+
export type CVSSv4ComponentsAvailability = OpenEnum<
|
|
71
72
|
typeof CVSSv4ComponentsAvailability
|
|
72
73
|
>;
|
|
73
74
|
|
|
@@ -83,7 +84,7 @@ export const CVSSv4ComponentsConfidentiality = {
|
|
|
83
84
|
/**
|
|
84
85
|
* Refers to the disclosure of sensitive information to authorized and unauthorized users, with the goal being that only authorized users are able to access the target data. Confidentiality has three potential values: High (H) – The attacker has full access to all resources in the impacted system, including highly sensitive information such as encryption keys, Low (L) – The attacker has partial access to information, with no control over what, specifically, they are able to access, None (N) – No data is accessible to unauthorized users as a result of the exploit.
|
|
85
86
|
*/
|
|
86
|
-
export type CVSSv4ComponentsConfidentiality =
|
|
87
|
+
export type CVSSv4ComponentsConfidentiality = OpenEnum<
|
|
87
88
|
typeof CVSSv4ComponentsConfidentiality
|
|
88
89
|
>;
|
|
89
90
|
|
|
@@ -99,7 +100,7 @@ export const CVSSv4ComponentsIntegrity = {
|
|
|
99
100
|
/**
|
|
100
101
|
* Refers to whether the protected information has been tampered with or changed in any way. If there is no way for an attacker to alter the accuracy or completeness of the information, integrity has been maintained. Integrity has three values: None (N) – There is no loss of the integrity of any information, Low (L) – A limited amount of information might be tampered with or modified, but there is no serious impact on the protected system, High (H) – The attacker can modify any/all information on the target system, resulting in a complete loss of integrity.
|
|
101
102
|
*/
|
|
102
|
-
export type CVSSv4ComponentsIntegrity =
|
|
103
|
+
export type CVSSv4ComponentsIntegrity = OpenEnum<
|
|
103
104
|
typeof CVSSv4ComponentsIntegrity
|
|
104
105
|
>;
|
|
105
106
|
|
|
@@ -115,7 +116,7 @@ export const CVSSv4ComponentsPrivilegesRequired = {
|
|
|
115
116
|
/**
|
|
116
117
|
* Describes the level of privileges or access an attacker must have before successful exploitation. There are three possible values: None (N) – There is no privilege or special access required to conduct the attack, Low (L) – The attacker requires basic, “user” level privileges to leverage the exploit, High (H) – Administrative or similar access privileges are required for successful attack.
|
|
117
118
|
*/
|
|
118
|
-
export type CVSSv4ComponentsPrivilegesRequired =
|
|
119
|
+
export type CVSSv4ComponentsPrivilegesRequired = OpenEnum<
|
|
119
120
|
typeof CVSSv4ComponentsPrivilegesRequired
|
|
120
121
|
>;
|
|
121
122
|
|
|
@@ -126,7 +127,7 @@ export const ProviderUrgency = {
|
|
|
126
127
|
Amber: "amber",
|
|
127
128
|
Red: "red",
|
|
128
129
|
} as const;
|
|
129
|
-
export type ProviderUrgency =
|
|
130
|
+
export type ProviderUrgency = OpenEnum<typeof ProviderUrgency>;
|
|
130
131
|
|
|
131
132
|
export const Recovery = {
|
|
132
133
|
Unknown: "",
|
|
@@ -134,14 +135,14 @@ export const Recovery = {
|
|
|
134
135
|
User: "user",
|
|
135
136
|
Irrecoverable: "irrecoverable",
|
|
136
137
|
} as const;
|
|
137
|
-
export type Recovery =
|
|
138
|
+
export type Recovery = OpenEnum<typeof Recovery>;
|
|
138
139
|
|
|
139
140
|
export const Safety = {
|
|
140
141
|
Unknown: "",
|
|
141
142
|
Negligible: "negligible",
|
|
142
143
|
Present: "present",
|
|
143
144
|
} as const;
|
|
144
|
-
export type Safety =
|
|
145
|
+
export type Safety = OpenEnum<typeof Safety>;
|
|
145
146
|
|
|
146
147
|
/**
|
|
147
148
|
* Describes whether a user, other than the attacker, is required to do anything or participate in exploitation of the vulnerability. User interaction has two possible values: None (N) – No user interaction is required, Required (R) – A user must complete some steps for the exploit to succeed. For example, a user might be required to install some software.
|
|
@@ -154,7 +155,7 @@ export const CVSSv4ComponentsUserInteraction = {
|
|
|
154
155
|
/**
|
|
155
156
|
* Describes whether a user, other than the attacker, is required to do anything or participate in exploitation of the vulnerability. User interaction has two possible values: None (N) – No user interaction is required, Required (R) – A user must complete some steps for the exploit to succeed. For example, a user might be required to install some software.
|
|
156
157
|
*/
|
|
157
|
-
export type CVSSv4ComponentsUserInteraction =
|
|
158
|
+
export type CVSSv4ComponentsUserInteraction = OpenEnum<
|
|
158
159
|
typeof CVSSv4ComponentsUserInteraction
|
|
159
160
|
>;
|
|
160
161
|
|
|
@@ -163,7 +164,7 @@ export const ValueDensity = {
|
|
|
163
164
|
Diffuse: "diffuse",
|
|
164
165
|
Concentrated: "concentrated",
|
|
165
166
|
} as const;
|
|
166
|
-
export type ValueDensity =
|
|
167
|
+
export type ValueDensity = OpenEnum<typeof ValueDensity>;
|
|
167
168
|
|
|
168
169
|
export const VulnerabilityResponseEffort = {
|
|
169
170
|
Unknown: "",
|
|
@@ -171,7 +172,7 @@ export const VulnerabilityResponseEffort = {
|
|
|
171
172
|
Moderate: "moderate",
|
|
172
173
|
High: "high",
|
|
173
174
|
} as const;
|
|
174
|
-
export type VulnerabilityResponseEffort =
|
|
175
|
+
export type VulnerabilityResponseEffort = OpenEnum<
|
|
175
176
|
typeof VulnerabilityResponseEffort
|
|
176
177
|
>;
|
|
177
178
|
|
|
@@ -214,70 +215,99 @@ export type CVSSv4Components = {
|
|
|
214
215
|
};
|
|
215
216
|
|
|
216
217
|
/** @internal */
|
|
217
|
-
export const CVSSv4ComponentsAttackComplexity$inboundSchema: z.
|
|
218
|
-
|
|
219
|
-
|
|
218
|
+
export const CVSSv4ComponentsAttackComplexity$inboundSchema: z.ZodType<
|
|
219
|
+
CVSSv4ComponentsAttackComplexity,
|
|
220
|
+
z.ZodTypeDef,
|
|
221
|
+
unknown
|
|
222
|
+
> = openEnums.inboundSchema(CVSSv4ComponentsAttackComplexity);
|
|
220
223
|
|
|
221
224
|
/** @internal */
|
|
222
|
-
export const AttackRequirements$inboundSchema: z.
|
|
223
|
-
|
|
224
|
-
|
|
225
|
+
export const AttackRequirements$inboundSchema: z.ZodType<
|
|
226
|
+
AttackRequirements,
|
|
227
|
+
z.ZodTypeDef,
|
|
228
|
+
unknown
|
|
229
|
+
> = openEnums.inboundSchema(AttackRequirements);
|
|
225
230
|
|
|
226
231
|
/** @internal */
|
|
227
|
-
export const CVSSv4ComponentsAttackVector$inboundSchema: z.
|
|
228
|
-
|
|
229
|
-
|
|
232
|
+
export const CVSSv4ComponentsAttackVector$inboundSchema: z.ZodType<
|
|
233
|
+
CVSSv4ComponentsAttackVector,
|
|
234
|
+
z.ZodTypeDef,
|
|
235
|
+
unknown
|
|
236
|
+
> = openEnums.inboundSchema(CVSSv4ComponentsAttackVector);
|
|
230
237
|
|
|
231
238
|
/** @internal */
|
|
232
|
-
export const Automatable$inboundSchema: z.
|
|
233
|
-
|
|
239
|
+
export const Automatable$inboundSchema: z.ZodType<
|
|
240
|
+
Automatable,
|
|
241
|
+
z.ZodTypeDef,
|
|
242
|
+
unknown
|
|
243
|
+
> = openEnums.inboundSchema(Automatable);
|
|
234
244
|
|
|
235
245
|
/** @internal */
|
|
236
|
-
export const CVSSv4ComponentsAvailability$inboundSchema: z.
|
|
237
|
-
|
|
238
|
-
|
|
246
|
+
export const CVSSv4ComponentsAvailability$inboundSchema: z.ZodType<
|
|
247
|
+
CVSSv4ComponentsAvailability,
|
|
248
|
+
z.ZodTypeDef,
|
|
249
|
+
unknown
|
|
250
|
+
> = openEnums.inboundSchema(CVSSv4ComponentsAvailability);
|
|
239
251
|
|
|
240
252
|
/** @internal */
|
|
241
|
-
export const CVSSv4ComponentsConfidentiality$inboundSchema: z.
|
|
242
|
-
|
|
243
|
-
|
|
253
|
+
export const CVSSv4ComponentsConfidentiality$inboundSchema: z.ZodType<
|
|
254
|
+
CVSSv4ComponentsConfidentiality,
|
|
255
|
+
z.ZodTypeDef,
|
|
256
|
+
unknown
|
|
257
|
+
> = openEnums.inboundSchema(CVSSv4ComponentsConfidentiality);
|
|
244
258
|
|
|
245
259
|
/** @internal */
|
|
246
|
-
export const CVSSv4ComponentsIntegrity$inboundSchema: z.
|
|
247
|
-
|
|
248
|
-
|
|
260
|
+
export const CVSSv4ComponentsIntegrity$inboundSchema: z.ZodType<
|
|
261
|
+
CVSSv4ComponentsIntegrity,
|
|
262
|
+
z.ZodTypeDef,
|
|
263
|
+
unknown
|
|
264
|
+
> = openEnums.inboundSchema(CVSSv4ComponentsIntegrity);
|
|
249
265
|
|
|
250
266
|
/** @internal */
|
|
251
|
-
export const CVSSv4ComponentsPrivilegesRequired$inboundSchema: z.
|
|
252
|
-
|
|
253
|
-
|
|
267
|
+
export const CVSSv4ComponentsPrivilegesRequired$inboundSchema: z.ZodType<
|
|
268
|
+
CVSSv4ComponentsPrivilegesRequired,
|
|
269
|
+
z.ZodTypeDef,
|
|
270
|
+
unknown
|
|
271
|
+
> = openEnums.inboundSchema(CVSSv4ComponentsPrivilegesRequired);
|
|
254
272
|
|
|
255
273
|
/** @internal */
|
|
256
|
-
export const ProviderUrgency$inboundSchema: z.
|
|
257
|
-
|
|
258
|
-
|
|
274
|
+
export const ProviderUrgency$inboundSchema: z.ZodType<
|
|
275
|
+
ProviderUrgency,
|
|
276
|
+
z.ZodTypeDef,
|
|
277
|
+
unknown
|
|
278
|
+
> = openEnums.inboundSchema(ProviderUrgency);
|
|
259
279
|
|
|
260
280
|
/** @internal */
|
|
261
|
-
export const Recovery$inboundSchema: z.
|
|
262
|
-
|
|
281
|
+
export const Recovery$inboundSchema: z.ZodType<
|
|
282
|
+
Recovery,
|
|
283
|
+
z.ZodTypeDef,
|
|
284
|
+
unknown
|
|
285
|
+
> = openEnums.inboundSchema(Recovery);
|
|
263
286
|
|
|
264
287
|
/** @internal */
|
|
265
|
-
export const Safety$inboundSchema: z.
|
|
266
|
-
.
|
|
288
|
+
export const Safety$inboundSchema: z.ZodType<Safety, z.ZodTypeDef, unknown> =
|
|
289
|
+
openEnums.inboundSchema(Safety);
|
|
267
290
|
|
|
268
291
|
/** @internal */
|
|
269
|
-
export const CVSSv4ComponentsUserInteraction$inboundSchema: z.
|
|
270
|
-
|
|
271
|
-
|
|
292
|
+
export const CVSSv4ComponentsUserInteraction$inboundSchema: z.ZodType<
|
|
293
|
+
CVSSv4ComponentsUserInteraction,
|
|
294
|
+
z.ZodTypeDef,
|
|
295
|
+
unknown
|
|
296
|
+
> = openEnums.inboundSchema(CVSSv4ComponentsUserInteraction);
|
|
272
297
|
|
|
273
298
|
/** @internal */
|
|
274
|
-
export const ValueDensity$inboundSchema: z.
|
|
275
|
-
|
|
299
|
+
export const ValueDensity$inboundSchema: z.ZodType<
|
|
300
|
+
ValueDensity,
|
|
301
|
+
z.ZodTypeDef,
|
|
302
|
+
unknown
|
|
303
|
+
> = openEnums.inboundSchema(ValueDensity);
|
|
276
304
|
|
|
277
305
|
/** @internal */
|
|
278
|
-
export const VulnerabilityResponseEffort$inboundSchema: z.
|
|
279
|
-
|
|
280
|
-
|
|
306
|
+
export const VulnerabilityResponseEffort$inboundSchema: z.ZodType<
|
|
307
|
+
VulnerabilityResponseEffort,
|
|
308
|
+
z.ZodTypeDef,
|
|
309
|
+
unknown
|
|
310
|
+
> = openEnums.inboundSchema(VulnerabilityResponseEffort);
|
|
281
311
|
|
|
282
312
|
/** @internal */
|
|
283
313
|
export const CVSSv4Components$inboundSchema: z.ZodType<
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import * as z from "zod/v3";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import
|
|
8
|
+
import * as openEnums from "../../types/enums.js";
|
|
9
|
+
import { OpenEnum } from "../../types/enums.js";
|
|
9
10
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
11
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
12
|
import { DnsEDns, DnsEDns$inboundSchema } from "./dnsedns.js";
|
|
@@ -42,7 +43,7 @@ export const RCode = {
|
|
|
42
43
|
/**
|
|
43
44
|
* A enumerated field indicating the result of the request. The most common values are defined in RFC 1035.
|
|
44
45
|
*/
|
|
45
|
-
export type RCode =
|
|
46
|
+
export type RCode = OpenEnum<typeof RCode>;
|
|
46
47
|
|
|
47
48
|
/**
|
|
48
49
|
* An enumerated value indicating the behavior of the server. An AUTHORITATIVE server fulfills requests for domain names it controls, which are not listed by the server. FORWARDING and RECURSIVE_RESOLVER servers fulfill requests indirectly for domain names they do not control. A RECURSIVE_RESOLVER will query ip.parrotdns.com itself, resulting in its own IP address being present in the dns.answers.response field.
|
|
@@ -57,7 +58,7 @@ export const ServerType = {
|
|
|
57
58
|
/**
|
|
58
59
|
* An enumerated value indicating the behavior of the server. An AUTHORITATIVE server fulfills requests for domain names it controls, which are not listed by the server. FORWARDING and RECURSIVE_RESOLVER servers fulfill requests indirectly for domain names they do not control. A RECURSIVE_RESOLVER will query ip.parrotdns.com itself, resulting in its own IP address being present in the dns.answers.response field.
|
|
59
60
|
*/
|
|
60
|
-
export type ServerType =
|
|
61
|
+
export type ServerType = OpenEnum<typeof ServerType>;
|
|
61
62
|
|
|
62
63
|
export type Dns = {
|
|
63
64
|
/**
|
|
@@ -93,13 +94,15 @@ export type Dns = {
|
|
|
93
94
|
};
|
|
94
95
|
|
|
95
96
|
/** @internal */
|
|
96
|
-
export const RCode$inboundSchema: z.
|
|
97
|
-
RCode
|
|
98
|
-
);
|
|
97
|
+
export const RCode$inboundSchema: z.ZodType<RCode, z.ZodTypeDef, unknown> =
|
|
98
|
+
openEnums.inboundSchema(RCode);
|
|
99
99
|
|
|
100
100
|
/** @internal */
|
|
101
|
-
export const ServerType$inboundSchema: z.
|
|
102
|
-
|
|
101
|
+
export const ServerType$inboundSchema: z.ZodType<
|
|
102
|
+
ServerType,
|
|
103
|
+
z.ZodTypeDef,
|
|
104
|
+
unknown
|
|
105
|
+
> = openEnums.inboundSchema(ServerType);
|
|
103
106
|
|
|
104
107
|
/** @internal */
|
|
105
108
|
export const Dns$inboundSchema: z.ZodType<Dns, z.ZodTypeDef, unknown> = z
|
|
@@ -4,7 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
import * as z from "zod/v3";
|
|
6
6
|
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
-
import
|
|
7
|
+
import * as openEnums from "../../types/enums.js";
|
|
8
|
+
import { OpenEnum } from "../../types/enums.js";
|
|
8
9
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
10
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
11
|
|
|
@@ -20,7 +21,7 @@ export const DnsResourceRecordType = {
|
|
|
20
21
|
/**
|
|
21
22
|
* An enumerated field indicating what type of data is in the "services.dns.additionals.response" field. For example, "A" signifies that the value in "services.dns.additionals.response" is an IPv4 address for the FQDN in "services.dns.additionals.name".
|
|
22
23
|
*/
|
|
23
|
-
export type DnsResourceRecordType =
|
|
24
|
+
export type DnsResourceRecordType = OpenEnum<typeof DnsResourceRecordType>;
|
|
24
25
|
|
|
25
26
|
export type DnsResourceRecord = {
|
|
26
27
|
/**
|
|
@@ -38,9 +39,11 @@ export type DnsResourceRecord = {
|
|
|
38
39
|
};
|
|
39
40
|
|
|
40
41
|
/** @internal */
|
|
41
|
-
export const DnsResourceRecordType$inboundSchema: z.
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
export const DnsResourceRecordType$inboundSchema: z.ZodType<
|
|
43
|
+
DnsResourceRecordType,
|
|
44
|
+
z.ZodTypeDef,
|
|
45
|
+
unknown
|
|
46
|
+
> = openEnums.inboundSchema(DnsResourceRecordType);
|
|
44
47
|
|
|
45
48
|
/** @internal */
|
|
46
49
|
export const DnsResourceRecord$inboundSchema: z.ZodType<
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import * as z from "zod/v3";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import
|
|
8
|
+
import * as openEnums from "../../types/enums.js";
|
|
9
|
+
import { OpenEnum } from "../../types/enums.js";
|
|
9
10
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
11
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
12
|
import {
|
|
@@ -47,7 +48,7 @@ export const EndpointScanTransportProtocol = {
|
|
|
47
48
|
Icmp: "icmp",
|
|
48
49
|
Quic: "quic",
|
|
49
50
|
} as const;
|
|
50
|
-
export type EndpointScanTransportProtocol =
|
|
51
|
+
export type EndpointScanTransportProtocol = OpenEnum<
|
|
51
52
|
typeof EndpointScanTransportProtocol
|
|
52
53
|
>;
|
|
53
54
|
|
|
@@ -84,9 +85,11 @@ export type EndpointScan = {
|
|
|
84
85
|
};
|
|
85
86
|
|
|
86
87
|
/** @internal */
|
|
87
|
-
export const EndpointScanTransportProtocol$inboundSchema: z.
|
|
88
|
-
|
|
89
|
-
|
|
88
|
+
export const EndpointScanTransportProtocol$inboundSchema: z.ZodType<
|
|
89
|
+
EndpointScanTransportProtocol,
|
|
90
|
+
z.ZodTypeDef,
|
|
91
|
+
unknown
|
|
92
|
+
> = openEnums.inboundSchema(EndpointScanTransportProtocol);
|
|
90
93
|
|
|
91
94
|
/** @internal */
|
|
92
95
|
export const EndpointScan$inboundSchema: z.ZodType<
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import * as z from "zod/v3";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import
|
|
8
|
+
import * as openEnums from "../../types/enums.js";
|
|
9
|
+
import { OpenEnum } from "../../types/enums.js";
|
|
9
10
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
11
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
12
|
import {
|
|
@@ -14,6 +15,10 @@ import {
|
|
|
14
15
|
} from "./chromedevtools.js";
|
|
15
16
|
import { CobaltStrike, CobaltStrike$inboundSchema } from "./cobaltstrike.js";
|
|
16
17
|
import { ElasticSearch, ElasticSearch$inboundSchema } from "./elasticsearch.js";
|
|
18
|
+
import {
|
|
19
|
+
ExtractedEndpointData,
|
|
20
|
+
ExtractedEndpointData$inboundSchema,
|
|
21
|
+
} from "./extractedendpointdata.js";
|
|
17
22
|
import { Fortigate, Fortigate$inboundSchema } from "./fortigate.js";
|
|
18
23
|
import { Graphql, Graphql$inboundSchema } from "./graphql.js";
|
|
19
24
|
import { Http, Http$inboundSchema } from "./http.js";
|
|
@@ -46,7 +51,7 @@ export const EndpointScanStateTransportProtocol = {
|
|
|
46
51
|
Icmp: "icmp",
|
|
47
52
|
Quic: "quic",
|
|
48
53
|
} as const;
|
|
49
|
-
export type EndpointScanStateTransportProtocol =
|
|
54
|
+
export type EndpointScanStateTransportProtocol = OpenEnum<
|
|
50
55
|
typeof EndpointScanStateTransportProtocol
|
|
51
56
|
>;
|
|
52
57
|
|
|
@@ -57,6 +62,7 @@ export type EndpointScanState = {
|
|
|
57
62
|
cobaltStrike?: CobaltStrike | undefined;
|
|
58
63
|
elasticsearch?: ElasticSearch | undefined;
|
|
59
64
|
endpointType?: string | undefined;
|
|
65
|
+
extracted?: ExtractedEndpointData | undefined;
|
|
60
66
|
fortigate?: Fortigate | undefined;
|
|
61
67
|
graphql?: Graphql | undefined;
|
|
62
68
|
hostname?: string | undefined;
|
|
@@ -81,9 +87,11 @@ export type EndpointScanState = {
|
|
|
81
87
|
};
|
|
82
88
|
|
|
83
89
|
/** @internal */
|
|
84
|
-
export const EndpointScanStateTransportProtocol$inboundSchema: z.
|
|
85
|
-
|
|
86
|
-
|
|
90
|
+
export const EndpointScanStateTransportProtocol$inboundSchema: z.ZodType<
|
|
91
|
+
EndpointScanStateTransportProtocol,
|
|
92
|
+
z.ZodTypeDef,
|
|
93
|
+
unknown
|
|
94
|
+
> = openEnums.inboundSchema(EndpointScanStateTransportProtocol);
|
|
87
95
|
|
|
88
96
|
/** @internal */
|
|
89
97
|
export const EndpointScanState$inboundSchema: z.ZodType<
|
|
@@ -97,6 +105,7 @@ export const EndpointScanState$inboundSchema: z.ZodType<
|
|
|
97
105
|
cobalt_strike: CobaltStrike$inboundSchema.optional(),
|
|
98
106
|
elasticsearch: ElasticSearch$inboundSchema.optional(),
|
|
99
107
|
endpoint_type: z.string().optional(),
|
|
108
|
+
extracted: ExtractedEndpointData$inboundSchema.optional(),
|
|
100
109
|
fortigate: Fortigate$inboundSchema.optional(),
|
|
101
110
|
graphql: Graphql$inboundSchema.optional(),
|
|
102
111
|
hostname: z.string().optional(),
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import * as z from "zod/v3";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import
|
|
8
|
+
import * as openEnums from "../../types/enums.js";
|
|
9
|
+
import { OpenEnum } from "../../types/enums.js";
|
|
9
10
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
11
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
12
|
|
|
@@ -13,7 +14,7 @@ export const ChangeType = {
|
|
|
13
14
|
Added: "added",
|
|
14
15
|
Removed: "removed",
|
|
15
16
|
} as const;
|
|
16
|
-
export type ChangeType =
|
|
17
|
+
export type ChangeType = OpenEnum<typeof ChangeType>;
|
|
17
18
|
|
|
18
19
|
export type EventAssetChange = {
|
|
19
20
|
changeType: ChangeType;
|
|
@@ -22,8 +23,11 @@ export type EventAssetChange = {
|
|
|
22
23
|
};
|
|
23
24
|
|
|
24
25
|
/** @internal */
|
|
25
|
-
export const ChangeType$inboundSchema: z.
|
|
26
|
-
|
|
26
|
+
export const ChangeType$inboundSchema: z.ZodType<
|
|
27
|
+
ChangeType,
|
|
28
|
+
z.ZodTypeDef,
|
|
29
|
+
unknown
|
|
30
|
+
> = openEnums.inboundSchema(ChangeType);
|
|
27
31
|
|
|
28
32
|
/** @internal */
|
|
29
33
|
export const EventAssetChange$inboundSchema: z.ZodType<
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
import * as z from "zod/v3";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import
|
|
8
|
+
import * as openEnums from "../../types/enums.js";
|
|
9
|
+
import { OpenEnum } from "../../types/enums.js";
|
|
9
10
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
11
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
12
|
|
|
@@ -15,7 +16,7 @@ export const NewStatus = {
|
|
|
15
16
|
Paused: "paused",
|
|
16
17
|
Archived: "archived",
|
|
17
18
|
} as const;
|
|
18
|
-
export type NewStatus =
|
|
19
|
+
export type NewStatus = OpenEnum<typeof NewStatus>;
|
|
19
20
|
|
|
20
21
|
export const OldStatus = {
|
|
21
22
|
Active: "active",
|
|
@@ -23,7 +24,7 @@ export const OldStatus = {
|
|
|
23
24
|
Paused: "paused",
|
|
24
25
|
Archived: "archived",
|
|
25
26
|
} as const;
|
|
26
|
-
export type OldStatus =
|
|
27
|
+
export type OldStatus = OpenEnum<typeof OldStatus>;
|
|
27
28
|
|
|
28
29
|
export type EventStatusChange = {
|
|
29
30
|
eventTime: Date;
|
|
@@ -33,12 +34,18 @@ export type EventStatusChange = {
|
|
|
33
34
|
};
|
|
34
35
|
|
|
35
36
|
/** @internal */
|
|
36
|
-
export const NewStatus$inboundSchema: z.
|
|
37
|
-
|
|
37
|
+
export const NewStatus$inboundSchema: z.ZodType<
|
|
38
|
+
NewStatus,
|
|
39
|
+
z.ZodTypeDef,
|
|
40
|
+
unknown
|
|
41
|
+
> = openEnums.inboundSchema(NewStatus);
|
|
38
42
|
|
|
39
43
|
/** @internal */
|
|
40
|
-
export const OldStatus$inboundSchema: z.
|
|
41
|
-
|
|
44
|
+
export const OldStatus$inboundSchema: z.ZodType<
|
|
45
|
+
OldStatus,
|
|
46
|
+
z.ZodTypeDef,
|
|
47
|
+
unknown
|
|
48
|
+
> = openEnums.inboundSchema(OldStatus);
|
|
42
49
|
|
|
43
50
|
/** @internal */
|
|
44
51
|
export const EventStatusChange$inboundSchema: z.ZodType<
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import {
|
|
11
|
+
ExtractedEndpointDataAnalyticsService,
|
|
12
|
+
ExtractedEndpointDataAnalyticsService$inboundSchema,
|
|
13
|
+
} from "./extractedendpointdataanalyticsservice.js";
|
|
14
|
+
import {
|
|
15
|
+
ExtractedEndpointDataCopyright,
|
|
16
|
+
ExtractedEndpointDataCopyright$inboundSchema,
|
|
17
|
+
} from "./extractedendpointdatacopyright.js";
|
|
18
|
+
|
|
19
|
+
export type ExtractedEndpointData = {
|
|
20
|
+
analyticsServices?:
|
|
21
|
+
| Array<ExtractedEndpointDataAnalyticsService>
|
|
22
|
+
| null
|
|
23
|
+
| undefined;
|
|
24
|
+
copyrights?: Array<ExtractedEndpointDataCopyright> | null | undefined;
|
|
25
|
+
ipAddresses?: Array<string> | null | undefined;
|
|
26
|
+
languages?: Array<string> | null | undefined;
|
|
27
|
+
links?: Array<string> | null | undefined;
|
|
28
|
+
macAddresses?: Array<string> | null | undefined;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
/** @internal */
|
|
32
|
+
export const ExtractedEndpointData$inboundSchema: z.ZodType<
|
|
33
|
+
ExtractedEndpointData,
|
|
34
|
+
z.ZodTypeDef,
|
|
35
|
+
unknown
|
|
36
|
+
> = z.object({
|
|
37
|
+
analytics_services: z.nullable(
|
|
38
|
+
z.array(ExtractedEndpointDataAnalyticsService$inboundSchema),
|
|
39
|
+
).optional(),
|
|
40
|
+
copyrights: z.nullable(z.array(ExtractedEndpointDataCopyright$inboundSchema))
|
|
41
|
+
.optional(),
|
|
42
|
+
ip_addresses: z.nullable(z.array(z.string())).optional(),
|
|
43
|
+
languages: z.nullable(z.array(z.string())).optional(),
|
|
44
|
+
links: z.nullable(z.array(z.string())).optional(),
|
|
45
|
+
mac_addresses: z.nullable(z.array(z.string())).optional(),
|
|
46
|
+
}).transform((v) => {
|
|
47
|
+
return remap$(v, {
|
|
48
|
+
"analytics_services": "analyticsServices",
|
|
49
|
+
"ip_addresses": "ipAddresses",
|
|
50
|
+
"mac_addresses": "macAddresses",
|
|
51
|
+
});
|
|
52
|
+
});
|
|
53
|
+
|
|
54
|
+
export function extractedEndpointDataFromJSON(
|
|
55
|
+
jsonString: string,
|
|
56
|
+
): SafeParseResult<ExtractedEndpointData, SDKValidationError> {
|
|
57
|
+
return safeParse(
|
|
58
|
+
jsonString,
|
|
59
|
+
(x) => ExtractedEndpointData$inboundSchema.parse(JSON.parse(x)),
|
|
60
|
+
`Failed to parse 'ExtractedEndpointData' from JSON`,
|
|
61
|
+
);
|
|
62
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
|
|
10
|
+
export type ExtractedEndpointDataAnalyticsService = {
|
|
11
|
+
ids?: Array<string> | null | undefined;
|
|
12
|
+
provider?: string | undefined;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
/** @internal */
|
|
16
|
+
export const ExtractedEndpointDataAnalyticsService$inboundSchema: z.ZodType<
|
|
17
|
+
ExtractedEndpointDataAnalyticsService,
|
|
18
|
+
z.ZodTypeDef,
|
|
19
|
+
unknown
|
|
20
|
+
> = z.object({
|
|
21
|
+
ids: z.nullable(z.array(z.string())).optional(),
|
|
22
|
+
provider: z.string().optional(),
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
export function extractedEndpointDataAnalyticsServiceFromJSON(
|
|
26
|
+
jsonString: string,
|
|
27
|
+
): SafeParseResult<ExtractedEndpointDataAnalyticsService, SDKValidationError> {
|
|
28
|
+
return safeParse(
|
|
29
|
+
jsonString,
|
|
30
|
+
(x) =>
|
|
31
|
+
ExtractedEndpointDataAnalyticsService$inboundSchema.parse(JSON.parse(x)),
|
|
32
|
+
`Failed to parse 'ExtractedEndpointDataAnalyticsService' from JSON`,
|
|
33
|
+
);
|
|
34
|
+
}
|