@chainpatrol/sdk 1.10.0 → 1.12.0
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/CHANGELOG.md +34 -0
- package/dist/api/index.d.mts +89 -2
- package/dist/api/index.d.ts +89 -2
- package/dist/api/index.js +18 -0
- package/dist/api/index.js.map +1 -1
- package/dist/api/index.mjs +18 -0
- package/dist/api/index.mjs.map +1 -1
- package/dist/index.js +1626 -1104
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1627 -1105
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1274,17 +1274,17 @@ var PolyDateFormatter = class {
|
|
|
1274
1274
|
constructor(dt, intl, opts) {
|
|
1275
1275
|
this.opts = opts;
|
|
1276
1276
|
this.originalZone = void 0;
|
|
1277
|
-
let
|
|
1277
|
+
let z68 = void 0;
|
|
1278
1278
|
if (this.opts.timeZone) {
|
|
1279
1279
|
this.dt = dt;
|
|
1280
1280
|
} else if (dt.zone.type === "fixed") {
|
|
1281
1281
|
const gmtOffset = -1 * (dt.offset / 60);
|
|
1282
1282
|
const offsetZ = gmtOffset >= 0 ? `Etc/GMT+${gmtOffset}` : `Etc/GMT${gmtOffset}`;
|
|
1283
1283
|
if (dt.offset !== 0 && IANAZone.create(offsetZ).valid) {
|
|
1284
|
-
|
|
1284
|
+
z68 = offsetZ;
|
|
1285
1285
|
this.dt = dt;
|
|
1286
1286
|
} else {
|
|
1287
|
-
|
|
1287
|
+
z68 = "UTC";
|
|
1288
1288
|
this.dt = dt.offset === 0 ? dt : dt.setZone("UTC").plus({ minutes: dt.offset });
|
|
1289
1289
|
this.originalZone = dt.zone;
|
|
1290
1290
|
}
|
|
@@ -1292,14 +1292,14 @@ var PolyDateFormatter = class {
|
|
|
1292
1292
|
this.dt = dt;
|
|
1293
1293
|
} else if (dt.zone.type === "iana") {
|
|
1294
1294
|
this.dt = dt;
|
|
1295
|
-
|
|
1295
|
+
z68 = dt.zone.name;
|
|
1296
1296
|
} else {
|
|
1297
|
-
|
|
1297
|
+
z68 = "UTC";
|
|
1298
1298
|
this.dt = dt.setZone("UTC").plus({ minutes: dt.offset });
|
|
1299
1299
|
this.originalZone = dt.zone;
|
|
1300
1300
|
}
|
|
1301
1301
|
const intlOpts = __spreadValues({}, this.opts);
|
|
1302
|
-
intlOpts.timeZone = intlOpts.timeZone ||
|
|
1302
|
+
intlOpts.timeZone = intlOpts.timeZone || z68;
|
|
1303
1303
|
this.dtf = getCachedDTF(intl, intlOpts);
|
|
1304
1304
|
}
|
|
1305
1305
|
format() {
|
|
@@ -7033,6 +7033,30 @@ zod.z.object({
|
|
|
7033
7033
|
zod.z.object({
|
|
7034
7034
|
noteId: zod.z.number().int().positive()
|
|
7035
7035
|
});
|
|
7036
|
+
var getAssetSubscriptionSchema = zod.z.object({
|
|
7037
|
+
slug: zod.z.string().min(1),
|
|
7038
|
+
assetId: zod.z.number().int().positive()
|
|
7039
|
+
});
|
|
7040
|
+
getAssetSubscriptionSchema.extend({
|
|
7041
|
+
/** True to follow this asset, false to stop following it. */
|
|
7042
|
+
subscribed: zod.z.boolean()
|
|
7043
|
+
});
|
|
7044
|
+
var ASSET_TAGS = {
|
|
7045
|
+
ENFORCEMENT_EXHAUSTED: {
|
|
7046
|
+
label: "Enforcement Exhausted",
|
|
7047
|
+
description: "All available enforcement options have been pursued with the relevant providers. The asset remains active due to provider inaction.",
|
|
7048
|
+
colorScheme: "orange"
|
|
7049
|
+
}
|
|
7050
|
+
};
|
|
7051
|
+
var ASSET_TAG_KEYS = Object.keys(ASSET_TAGS);
|
|
7052
|
+
var assetTagKeySchema = zod.z.enum(ASSET_TAG_KEYS);
|
|
7053
|
+
zod.z.object({
|
|
7054
|
+
assetId: zod.z.number().int().positive()
|
|
7055
|
+
});
|
|
7056
|
+
zod.z.object({
|
|
7057
|
+
assetId: zod.z.number().int().positive(),
|
|
7058
|
+
tag: assetTagKeySchema
|
|
7059
|
+
});
|
|
7036
7060
|
zod.z.object({
|
|
7037
7061
|
slug: zod.z.string(),
|
|
7038
7062
|
assetId: zod.z.number(),
|
|
@@ -7046,6 +7070,9 @@ zod.z.object({
|
|
|
7046
7070
|
email: zod.z.string().email(),
|
|
7047
7071
|
description: zod.z.string().optional().default("")
|
|
7048
7072
|
});
|
|
7073
|
+
zod.z.object({
|
|
7074
|
+
slug: zod.z.string().min(1)
|
|
7075
|
+
});
|
|
7049
7076
|
zod.z.object({
|
|
7050
7077
|
/** Canonicalization algorithm version the client computed its prefixes with. */
|
|
7051
7078
|
algoVersion: zod.z.number().int().positive(),
|
|
@@ -7192,7 +7219,10 @@ var AssetType = {
|
|
|
7192
7219
|
FIVE_HUNDRED_PX: "FIVE_HUNDRED_PX",
|
|
7193
7220
|
LUMA: "LUMA",
|
|
7194
7221
|
SMARTMONEYMATCH: "SMARTMONEYMATCH",
|
|
7195
|
-
APK_GOLD: "APK_GOLD"
|
|
7222
|
+
APK_GOLD: "APK_GOLD",
|
|
7223
|
+
GLASSDOOR: "GLASSDOOR",
|
|
7224
|
+
PUMP_FUN: "PUMP_FUN",
|
|
7225
|
+
TUMBLR: "TUMBLR"
|
|
7196
7226
|
};
|
|
7197
7227
|
var LivenessStatus = {
|
|
7198
7228
|
UNKNOWN: "UNKNOWN",
|
|
@@ -7353,8 +7383,23 @@ zod.z.object({
|
|
|
7353
7383
|
watchStatus: zod.z.nativeEnum(WatchStatus).optional().describe("The watch status of the asset.")
|
|
7354
7384
|
}).describe("Check asset response body");
|
|
7355
7385
|
var assetListInputSchema = zod.z.object({
|
|
7356
|
-
/**
|
|
7357
|
-
|
|
7386
|
+
/**
|
|
7387
|
+
* The type of asset to retrieve. Omitting the key means every asset type,
|
|
7388
|
+
* which lets a bulk consumer sweep the whole blocklist with one cursor
|
|
7389
|
+
* instead of looping all 94 members of `AssetType`.
|
|
7390
|
+
*
|
|
7391
|
+
* An explicit `null` is rejected with a 400 rather than treated as "all
|
|
7392
|
+
* types". Only omission opts into the full sweep, so a client that sends
|
|
7393
|
+
* `type: null` from an uninitialised variable gets a clear error instead of
|
|
7394
|
+
* silently pulling every blocked asset.
|
|
7395
|
+
*
|
|
7396
|
+
* Not `.nullable()`: besides accepting that null, it renders in the
|
|
7397
|
+
* generated MCP tool manifest as a nested `anyOf` containing `{"not": {}}`,
|
|
7398
|
+
* which buries the enum hint telling a model which values are legal.
|
|
7399
|
+
*/
|
|
7400
|
+
type: zod.z.nativeEnum(AssetType).optional().describe(
|
|
7401
|
+
"Asset type to retrieve. Omit the field entirely to retrieve assets of every type in a single paginated sweep; an explicit null is rejected."
|
|
7402
|
+
),
|
|
7358
7403
|
/** Optional status filter for the assets; defaults to `BLOCKED`. */
|
|
7359
7404
|
status: zod.z.nativeEnum(AssetStatus).optional().default(AssetStatus.BLOCKED).describe("Status of the assets to retrieve"),
|
|
7360
7405
|
/**
|
|
@@ -7382,7 +7427,8 @@ var assetListInputSchema = zod.z.object({
|
|
|
7382
7427
|
}).describe(
|
|
7383
7428
|
`List asset request body
|
|
7384
7429
|
|
|
7385
|
-
|
|
7430
|
+
With no \`startDate\`, this returns every matching asset regardless of age \u2014 there
|
|
7431
|
+
is no implicit one-day window. Pass \`startDate\` to get a delta instead.
|
|
7386
7432
|
|
|
7387
7433
|
You can also choose a \`startDate\` and \`endDate\` for the range of asset updates, most
|
|
7388
7434
|
timestamp formats should work, we use [Luxon](https://moment.github.io/luxon/#/parsing)
|
|
@@ -7491,6 +7537,8 @@ var ThreatDetectionSourceKey = /* @__PURE__ */ ((ThreatDetectionSourceKey2) => {
|
|
|
7491
7537
|
ThreatDetectionSourceKey2["TELEGRAM_CHANNELS_SEARCH_VETRIC"] = "telegram_channels_search_vetric";
|
|
7492
7538
|
ThreatDetectionSourceKey2["TELEGRAM_USER_SEARCH_VETRIC"] = "telegram_user_search_vetric";
|
|
7493
7539
|
ThreatDetectionSourceKey2["FACEBOOK_PAGE_SEARCH_VETRIC"] = "facebook_page_search_vetric";
|
|
7540
|
+
ThreatDetectionSourceKey2["FACEBOOK_USER_SEARCH_VETRIC"] = "facebook_user_search_vetric";
|
|
7541
|
+
ThreatDetectionSourceKey2["FACEBOOK_POST_SEARCH_VETRIC"] = "facebook_post_search_vetric";
|
|
7494
7542
|
ThreatDetectionSourceKey2["INSTAGRAM_ACCOUNT_SEARCH_VETRIC"] = "instagram_account_search_vetric";
|
|
7495
7543
|
ThreatDetectionSourceKey2["TWITTER_SEARCH_VETRIC"] = "twitter_search_vetric";
|
|
7496
7544
|
ThreatDetectionSourceKey2["LINKEDIN_PEOPLE_SEARCH_VETRIC"] = "linkedin_people_search_vetric";
|
|
@@ -7503,6 +7551,7 @@ var ThreatDetectionSourceKey = /* @__PURE__ */ ((ThreatDetectionSourceKey2) => {
|
|
|
7503
7551
|
ThreatDetectionSourceKey2["BLOCKLIST"] = "blocklist";
|
|
7504
7552
|
ThreatDetectionSourceKey2["APPLE_APP_STORE"] = "apple_app_store";
|
|
7505
7553
|
ThreatDetectionSourceKey2["GOOGLE_ADS_SEARCH"] = "google_ads_search";
|
|
7554
|
+
ThreatDetectionSourceKey2["GOOGLE_ADS_TRANSPARENCY_SEARCH"] = "google_ads_transparency_search";
|
|
7506
7555
|
ThreatDetectionSourceKey2["MOZILLA_ADDON_SEARCH"] = "mozilla_addon_search";
|
|
7507
7556
|
ThreatDetectionSourceKey2["REDDIT_SUBREDDIT_SEARCH"] = "reddit_subreddit_search";
|
|
7508
7557
|
ThreatDetectionSourceKey2["ASSET_CHECK"] = "asset_check";
|
|
@@ -7530,14 +7579,17 @@ var ThreatDetectionSourceKey = /* @__PURE__ */ ((ThreatDetectionSourceKey2) => {
|
|
|
7530
7579
|
ThreatDetectionSourceKey2["GROK_USER_SEARCH"] = "grok_user_search";
|
|
7531
7580
|
ThreatDetectionSourceKey2["GOOGLE_LENS_IMAGE_SEARCH"] = "google_lens_image_search";
|
|
7532
7581
|
ThreatDetectionSourceKey2["YANDEX_SEARCH"] = "yandex_search";
|
|
7582
|
+
ThreatDetectionSourceKey2["YANDEX_IMAGE_SEARCH"] = "yandex_image_search";
|
|
7533
7583
|
ThreatDetectionSourceKey2["LINKEDIN_EMPLOYEE_DETECTION"] = "linkedin_employee_detection";
|
|
7534
7584
|
ThreatDetectionSourceKey2["LINKEDIN_POST_SEARCH"] = "linkedin_post_search";
|
|
7535
7585
|
ThreatDetectionSourceKey2["LINKEDIN_COMPANY_SEARCH"] = "linkedin_company_search";
|
|
7536
7586
|
ThreatDetectionSourceKey2["BING_ADS_SEARCH"] = "bing_ads_search";
|
|
7537
7587
|
ThreatDetectionSourceKey2["TIK_TOK_ADS_SEARCH"] = "tik_tok_ads_search";
|
|
7588
|
+
ThreatDetectionSourceKey2["ADLIBRARY_ADS_SEARCH"] = "adlibrary_ads_search";
|
|
7538
7589
|
ThreatDetectionSourceKey2["DNSDB"] = "dnsdb";
|
|
7539
7590
|
ThreatDetectionSourceKey2["DAILY_MOTION_SEARCH"] = "daily_motion_search";
|
|
7540
7591
|
ThreatDetectionSourceKey2["WATCHLIST"] = "watchlist";
|
|
7592
|
+
ThreatDetectionSourceKey2["GITHUB_SEARCH"] = "github_search";
|
|
7541
7593
|
return ThreatDetectionSourceKey2;
|
|
7542
7594
|
})(ThreatDetectionSourceKey || {});
|
|
7543
7595
|
var ThreatDetectionScope = /* @__PURE__ */ ((ThreatDetectionScope2) => {
|
|
@@ -7546,568 +7598,47 @@ var ThreatDetectionScope = /* @__PURE__ */ ((ThreatDetectionScope2) => {
|
|
|
7546
7598
|
return ThreatDetectionScope2;
|
|
7547
7599
|
})(ThreatDetectionScope || {});
|
|
7548
7600
|
|
|
7549
|
-
// ../../internal/utils/src/
|
|
7550
|
-
var
|
|
7551
|
-
__export(
|
|
7552
|
-
|
|
7553
|
-
|
|
7554
|
-
|
|
7555
|
-
|
|
7556
|
-
|
|
7601
|
+
// ../../internal/utils/src/url.ts
|
|
7602
|
+
var url_exports = {};
|
|
7603
|
+
__export(url_exports, {
|
|
7604
|
+
URL_REGEX: () => URL_REGEX,
|
|
7605
|
+
containsPunycode: () => containsPunycode,
|
|
7606
|
+
convertHttpsToHttp: () => convertHttpsToHttp,
|
|
7607
|
+
ensureHttpsPrefix: () => ensureHttpsPrefix,
|
|
7608
|
+
generateCanonicalIPFSUrl: () => generateCanonicalIPFSUrl,
|
|
7609
|
+
getDefangedUrl: () => getDefangedUrl,
|
|
7610
|
+
getDomain: () => tldts.getDomain,
|
|
7611
|
+
getFaviconUrl: () => getFaviconUrl,
|
|
7612
|
+
getHostname: () => getHostname,
|
|
7613
|
+
getNormalizedUrl: () => getNormalizedUrl,
|
|
7614
|
+
getParentDomains: () => getParentDomains,
|
|
7615
|
+
getPublicHostname: () => getPublicHostname,
|
|
7616
|
+
getRefangedUrl: () => getRefangedUrl,
|
|
7617
|
+
isEmail: () => isEmail,
|
|
7618
|
+
isUrl: () => isUrl,
|
|
7619
|
+
isWalrusSite: () => isWalrusSite,
|
|
7620
|
+
removeHttpProtocol: () => removeHttpProtocol,
|
|
7621
|
+
sanitizeHttpUrl: () => sanitizeHttpUrl,
|
|
7622
|
+
slugify: () => slugify,
|
|
7623
|
+
stripDomainWildcardPrefix: () => stripDomainWildcardPrefix,
|
|
7624
|
+
toUnicode: () => toUnicode2,
|
|
7625
|
+
trimDomainToLevels: () => trimDomainToLevels
|
|
7557
7626
|
});
|
|
7558
|
-
var AssetScanEnrichmentType = /* @__PURE__ */ ((AssetScanEnrichmentType2) => {
|
|
7559
|
-
AssetScanEnrichmentType2["CONTENT_AND_METADATA"] = "content_and_metadata";
|
|
7560
|
-
AssetScanEnrichmentType2["BROWSER_CAPTURE"] = "browser_capture";
|
|
7561
|
-
AssetScanEnrichmentType2["OWNERSHIP_AND_REGISTRATION"] = "ownership_and_registration";
|
|
7562
|
-
AssetScanEnrichmentType2["GEOLOCATION_AND_IP"] = "geolocation_and_ip";
|
|
7563
|
-
AssetScanEnrichmentType2["DNS"] = "dns";
|
|
7564
|
-
AssetScanEnrichmentType2["TLS"] = "tls";
|
|
7565
|
-
AssetScanEnrichmentType2["TCP"] = "tcp";
|
|
7566
|
-
AssetScanEnrichmentType2["TWITTER_POST"] = "post";
|
|
7567
|
-
AssetScanEnrichmentType2["TWITTER_PROFILE"] = "profile";
|
|
7568
|
-
AssetScanEnrichmentType2["TWITTER_FOLLOWERS"] = "twitter_followers";
|
|
7569
|
-
AssetScanEnrichmentType2["FARCASTER_CAST"] = "cast";
|
|
7570
|
-
AssetScanEnrichmentType2["FARCASTER_PROFILE"] = "farcaster_profile";
|
|
7571
|
-
AssetScanEnrichmentType2["FARCASTER_CHANNEL"] = "channel";
|
|
7572
|
-
AssetScanEnrichmentType2["FARCASTER_MINIAPP"] = "miniapp";
|
|
7573
|
-
AssetScanEnrichmentType2["TELEGRAM_PROFILE"] = "telegram_profile";
|
|
7574
|
-
AssetScanEnrichmentType2["INSTAGRAM_PROFILE"] = "instagram_profile";
|
|
7575
|
-
AssetScanEnrichmentType2["FACEBOOK_PROFILE"] = "facebook_profile";
|
|
7576
|
-
AssetScanEnrichmentType2["YOUTUBE_VIDEO"] = "youtube_video";
|
|
7577
|
-
AssetScanEnrichmentType2["YOUTUBE_CHANNEL"] = "youtube_channel";
|
|
7578
|
-
AssetScanEnrichmentType2["APPLE_APP_STORE_LISTING"] = "apple_app_store_listing";
|
|
7579
|
-
AssetScanEnrichmentType2["GOOGLE_PLAY_STORE_LISTING"] = "google_play_store_listing";
|
|
7580
|
-
AssetScanEnrichmentType2["MOZILLA_ADDON"] = "mozilla_addon";
|
|
7581
|
-
AssetScanEnrichmentType2["REDDIT_SUBREDDIT"] = "reddit_subreddit";
|
|
7582
|
-
AssetScanEnrichmentType2["EMAIL_VALIDATION"] = "email_validation";
|
|
7583
|
-
AssetScanEnrichmentType2["PHONE_LOOKUP"] = "phone_lookup";
|
|
7584
|
-
AssetScanEnrichmentType2["BILIBILI_VIDEO"] = "bilibili_video";
|
|
7585
|
-
AssetScanEnrichmentType2["BILIBILI_PROFILE"] = "bilibili_profile";
|
|
7586
|
-
AssetScanEnrichmentType2["DAILYMOTION_VIDEO"] = "dailymotion_video";
|
|
7587
|
-
AssetScanEnrichmentType2["VIMEO_VIDEO"] = "vimeo_video";
|
|
7588
|
-
AssetScanEnrichmentType2["VIMEO_PROFILE"] = "vimeo_profile";
|
|
7589
|
-
AssetScanEnrichmentType2["STACKBLITZ_PAGE"] = "stackblitz_page";
|
|
7590
|
-
AssetScanEnrichmentType2["LEETCODE_PAGE"] = "leetcode_page";
|
|
7591
|
-
AssetScanEnrichmentType2["NPM_PACKAGE"] = "npm_package";
|
|
7592
|
-
AssetScanEnrichmentType2["PYPI_PACKAGE"] = "pypi_package";
|
|
7593
|
-
AssetScanEnrichmentType2["RUST_PACKAGE"] = "rust_package";
|
|
7594
|
-
AssetScanEnrichmentType2["LINKEDIN_PROFILE"] = "linkedin_profile";
|
|
7595
|
-
AssetScanEnrichmentType2["META_AD"] = "meta_ad";
|
|
7596
|
-
AssetScanEnrichmentType2["GOOGLE_AD"] = "google_ad";
|
|
7597
|
-
AssetScanEnrichmentType2["CONTRACT_DEPLOYER"] = "contract_deployer";
|
|
7598
|
-
return AssetScanEnrichmentType2;
|
|
7599
|
-
})(AssetScanEnrichmentType || {});
|
|
7600
|
-
var AssetScanEnrichmentSource = /* @__PURE__ */ ((AssetScanEnrichmentSource2) => {
|
|
7601
|
-
AssetScanEnrichmentSource2["URLSCAN"] = "urlscan";
|
|
7602
|
-
AssetScanEnrichmentSource2["WHOIS"] = "whois";
|
|
7603
|
-
AssetScanEnrichmentSource2["RDAP"] = "rdap";
|
|
7604
|
-
AssetScanEnrichmentSource2["HTTP_CONTENT"] = "http_content";
|
|
7605
|
-
AssetScanEnrichmentSource2["NETWORK"] = "node_js_network";
|
|
7606
|
-
AssetScanEnrichmentSource2["EXTENSION"] = "extension";
|
|
7607
|
-
AssetScanEnrichmentSource2["PLAYWRIGHT"] = "playwright";
|
|
7608
|
-
AssetScanEnrichmentSource2["X_API"] = "x_api";
|
|
7609
|
-
AssetScanEnrichmentSource2["SOCIALDATA_API"] = "socialdata_api";
|
|
7610
|
-
AssetScanEnrichmentSource2["NEYNAR_API"] = "neynar_api";
|
|
7611
|
-
AssetScanEnrichmentSource2["TELEGRAM_API"] = "telegram_api";
|
|
7612
|
-
AssetScanEnrichmentSource2["INSTAGRAM_API"] = "instagram_api";
|
|
7613
|
-
AssetScanEnrichmentSource2["FACEBOOK_API"] = "facebook_api";
|
|
7614
|
-
AssetScanEnrichmentSource2["YOUTUBE_API"] = "youtube_api";
|
|
7615
|
-
AssetScanEnrichmentSource2["APPLE_APP_STORE_API"] = "apple_app_store_api";
|
|
7616
|
-
AssetScanEnrichmentSource2["GOOGLE_PLAY_STORE_API"] = "google_play_store_api";
|
|
7617
|
-
AssetScanEnrichmentSource2["MOZILLA_ADDONS_API"] = "mozilla_addons_api";
|
|
7618
|
-
AssetScanEnrichmentSource2["REDDIT_API"] = "reddit_api";
|
|
7619
|
-
AssetScanEnrichmentSource2["MAILS_API"] = "mails_api";
|
|
7620
|
-
AssetScanEnrichmentSource2["TELNYX_LOOKUP"] = "telnyx_lookup";
|
|
7621
|
-
AssetScanEnrichmentSource2["TWILIO_LOOKUP"] = "twilio_lookup";
|
|
7622
|
-
AssetScanEnrichmentSource2["DAILYMOTION_API"] = "dailymotion_api";
|
|
7623
|
-
AssetScanEnrichmentSource2["VIMEO_API"] = "vimeo_api";
|
|
7624
|
-
AssetScanEnrichmentSource2["STACKBLITZ_API"] = "stackblitz_api";
|
|
7625
|
-
AssetScanEnrichmentSource2["LEETCODE_API"] = "leetcode_api";
|
|
7626
|
-
AssetScanEnrichmentSource2["NPM_REGISTRY_API"] = "npm_registry_api";
|
|
7627
|
-
AssetScanEnrichmentSource2["PYPI_REGISTRY_API"] = "pypi_registry_api";
|
|
7628
|
-
AssetScanEnrichmentSource2["CRATES_IO_API"] = "crates_io_api";
|
|
7629
|
-
AssetScanEnrichmentSource2["APIFY_LINKEDIN_API"] = "apify_linkedin_api";
|
|
7630
|
-
AssetScanEnrichmentSource2["META_ADS_LIBRARY"] = "meta_ads_library";
|
|
7631
|
-
AssetScanEnrichmentSource2["GOOGLE_ADS_TRANSPARENCY_CENTER"] = "google_ads_transparency_center";
|
|
7632
|
-
AssetScanEnrichmentSource2["ETHERSCAN_API"] = "etherscan_api";
|
|
7633
|
-
return AssetScanEnrichmentSource2;
|
|
7634
|
-
})(AssetScanEnrichmentSource || {});
|
|
7635
|
-
var ASSET_SCAN_ENRICHMENT_TYPE_LABELS = {
|
|
7636
|
-
["content_and_metadata" /* CONTENT_AND_METADATA */]: "Content and Metadata",
|
|
7637
|
-
["post" /* TWITTER_POST */]: "Post",
|
|
7638
|
-
["profile" /* TWITTER_PROFILE */]: "Profile",
|
|
7639
|
-
["twitter_followers" /* TWITTER_FOLLOWERS */]: "Twitter Followers",
|
|
7640
|
-
["browser_capture" /* BROWSER_CAPTURE */]: "Browser Capture",
|
|
7641
|
-
["geolocation_and_ip" /* GEOLOCATION_AND_IP */]: "Geolocation and IP",
|
|
7642
|
-
["ownership_and_registration" /* OWNERSHIP_AND_REGISTRATION */]: "Ownership and Registration",
|
|
7643
|
-
["dns" /* DNS */]: "DNS Lookup",
|
|
7644
|
-
["tls" /* TLS */]: "TLS Connection Info",
|
|
7645
|
-
["tcp" /* TCP */]: "TCP Connection Info",
|
|
7646
|
-
// Farcaster
|
|
7647
|
-
["cast" /* FARCASTER_CAST */]: "Farcaster Cast",
|
|
7648
|
-
["farcaster_profile" /* FARCASTER_PROFILE */]: "Farcaster Profile",
|
|
7649
|
-
["channel" /* FARCASTER_CHANNEL */]: "Farcaster Channel",
|
|
7650
|
-
["miniapp" /* FARCASTER_MINIAPP */]: "Farcaster MiniApp",
|
|
7651
|
-
// Telegram
|
|
7652
|
-
["telegram_profile" /* TELEGRAM_PROFILE */]: "Telegram Profile",
|
|
7653
|
-
// Instagram
|
|
7654
|
-
["instagram_profile" /* INSTAGRAM_PROFILE */]: "Instagram Profile",
|
|
7655
|
-
// Facebook
|
|
7656
|
-
["facebook_profile" /* FACEBOOK_PROFILE */]: "Facebook Profile",
|
|
7657
|
-
// YouTube
|
|
7658
|
-
["youtube_video" /* YOUTUBE_VIDEO */]: "YouTube Video",
|
|
7659
|
-
["youtube_channel" /* YOUTUBE_CHANNEL */]: "YouTube Channel",
|
|
7660
|
-
// Apple App Store
|
|
7661
|
-
["apple_app_store_listing" /* APPLE_APP_STORE_LISTING */]: "Apple App Store Listing",
|
|
7662
|
-
// Google Play Store
|
|
7663
|
-
["google_play_store_listing" /* GOOGLE_PLAY_STORE_LISTING */]: "Google Play Store Listing",
|
|
7664
|
-
// Mozilla
|
|
7665
|
-
["mozilla_addon" /* MOZILLA_ADDON */]: "Mozilla Add-on",
|
|
7666
|
-
// Reddit
|
|
7667
|
-
["reddit_subreddit" /* REDDIT_SUBREDDIT */]: "Reddit Subreddit",
|
|
7668
|
-
// Email
|
|
7669
|
-
["email_validation" /* EMAIL_VALIDATION */]: "Email Validation",
|
|
7670
|
-
// Phone Number
|
|
7671
|
-
["phone_lookup" /* PHONE_LOOKUP */]: "Phone Lookup",
|
|
7672
|
-
// Bilibili
|
|
7673
|
-
["bilibili_video" /* BILIBILI_VIDEO */]: "Bilibili Video",
|
|
7674
|
-
["bilibili_profile" /* BILIBILI_PROFILE */]: "Bilibili Profile",
|
|
7675
|
-
// DailyMotion
|
|
7676
|
-
["dailymotion_video" /* DAILYMOTION_VIDEO */]: "DailyMotion Video",
|
|
7677
|
-
// Vimeo
|
|
7678
|
-
["vimeo_video" /* VIMEO_VIDEO */]: "Vimeo Video",
|
|
7679
|
-
["vimeo_profile" /* VIMEO_PROFILE */]: "Vimeo Profile",
|
|
7680
|
-
// Stackblitz
|
|
7681
|
-
["stackblitz_page" /* STACKBLITZ_PAGE */]: "Stackblitz Page",
|
|
7682
|
-
// Leetcode
|
|
7683
|
-
["leetcode_page" /* LEETCODE_PAGE */]: "Leetcode Page",
|
|
7684
|
-
// NPM
|
|
7685
|
-
["npm_package" /* NPM_PACKAGE */]: "NPM Package",
|
|
7686
|
-
// PyPI
|
|
7687
|
-
["pypi_package" /* PYPI_PACKAGE */]: "PyPI Package",
|
|
7688
|
-
// Rust Package
|
|
7689
|
-
["rust_package" /* RUST_PACKAGE */]: "Rust Package",
|
|
7690
|
-
// LinkedIn
|
|
7691
|
-
["linkedin_profile" /* LINKEDIN_PROFILE */]: "LinkedIn Profile",
|
|
7692
|
-
// Meta Ads
|
|
7693
|
-
["meta_ad" /* META_AD */]: "Meta Ad",
|
|
7694
|
-
// Google Ads
|
|
7695
|
-
["google_ad" /* GOOGLE_AD */]: "Google Ad",
|
|
7696
|
-
// Crypto / Onchain
|
|
7697
|
-
["contract_deployer" /* CONTRACT_DEPLOYER */]: "Contract Deployer"
|
|
7698
|
-
};
|
|
7699
|
-
var ASSET_SCAN_ENRICHMENT_SOURCE_LABELS = {
|
|
7700
|
-
// URL
|
|
7701
|
-
["urlscan" /* URLSCAN */]: "URLScan",
|
|
7702
|
-
["whois" /* WHOIS */]: "Whois",
|
|
7703
|
-
["rdap" /* RDAP */]: "RDAP",
|
|
7704
|
-
["http_content" /* HTTP_CONTENT */]: "HTTP Content",
|
|
7705
|
-
["node_js_network" /* NETWORK */]: "Network",
|
|
7706
|
-
["extension" /* EXTENSION */]: "Browser Extension",
|
|
7707
|
-
["playwright" /* PLAYWRIGHT */]: "Playwright",
|
|
7708
|
-
// Twitter
|
|
7709
|
-
["x_api" /* X_API */]: "X API",
|
|
7710
|
-
["socialdata_api" /* SOCIALDATA_API */]: "SocialData API",
|
|
7711
|
-
// Farcaster
|
|
7712
|
-
["neynar_api" /* NEYNAR_API */]: "Neynar API",
|
|
7713
|
-
// Telegram
|
|
7714
|
-
["telegram_api" /* TELEGRAM_API */]: "Telegram API",
|
|
7715
|
-
// Instagram
|
|
7716
|
-
["instagram_api" /* INSTAGRAM_API */]: "Instagram API",
|
|
7717
|
-
// Facebook
|
|
7718
|
-
["facebook_api" /* FACEBOOK_API */]: "Facebook API",
|
|
7719
|
-
// YouTube
|
|
7720
|
-
["youtube_api" /* YOUTUBE_API */]: "YouTube API",
|
|
7721
|
-
// Apple App Store
|
|
7722
|
-
["apple_app_store_api" /* APPLE_APP_STORE_API */]: "Apple App Store API",
|
|
7723
|
-
// Google Play Store
|
|
7724
|
-
["google_play_store_api" /* GOOGLE_PLAY_STORE_API */]: "Google Play Store API",
|
|
7725
|
-
// Mozilla
|
|
7726
|
-
["mozilla_addons_api" /* MOZILLA_ADDONS_API */]: "Mozilla Add-ons API",
|
|
7727
|
-
// Reddit
|
|
7728
|
-
["reddit_api" /* REDDIT_API */]: "Reddit API",
|
|
7729
|
-
// Email
|
|
7730
|
-
["mails_api" /* MAILS_API */]: "Mails.so API",
|
|
7731
|
-
// Phone Number
|
|
7732
|
-
["telnyx_lookup" /* TELNYX_LOOKUP */]: "Telnyx Lookup",
|
|
7733
|
-
["twilio_lookup" /* TWILIO_LOOKUP */]: "Twilio Lookup",
|
|
7734
|
-
// DailyMotion
|
|
7735
|
-
["dailymotion_api" /* DAILYMOTION_API */]: "DailyMotion API",
|
|
7736
|
-
// Vimeo
|
|
7737
|
-
["vimeo_api" /* VIMEO_API */]: "Vimeo API",
|
|
7738
|
-
// Stackblitz
|
|
7739
|
-
["stackblitz_api" /* STACKBLITZ_API */]: "Stackblitz API",
|
|
7740
|
-
// Leetcode
|
|
7741
|
-
["leetcode_api" /* LEETCODE_API */]: "Leetcode API",
|
|
7742
|
-
// NPM
|
|
7743
|
-
["npm_registry_api" /* NPM_REGISTRY_API */]: "NPM Registry API",
|
|
7744
|
-
// PyPI
|
|
7745
|
-
["pypi_registry_api" /* PYPI_REGISTRY_API */]: "PyPI Registry API",
|
|
7746
|
-
// Rust Package
|
|
7747
|
-
["crates_io_api" /* CRATES_IO_API */]: "Crates.io API",
|
|
7748
|
-
// LinkedIn
|
|
7749
|
-
["apify_linkedin_api" /* APIFY_LINKEDIN_API */]: "Apify LinkedIn API",
|
|
7750
|
-
// Meta Ads
|
|
7751
|
-
["meta_ads_library" /* META_ADS_LIBRARY */]: "Meta Ads Library",
|
|
7752
|
-
// Google Ads
|
|
7753
|
-
["google_ads_transparency_center" /* GOOGLE_ADS_TRANSPARENCY_CENTER */]: "Google Ads Transparency Center",
|
|
7754
|
-
// Crypto / Onchain
|
|
7755
|
-
["etherscan_api" /* ETHERSCAN_API */]: "Etherscan"
|
|
7756
|
-
};
|
|
7757
|
-
var ASSET_SCAN_ENRICHMENT_SOURCE_TO_TYPES = {
|
|
7758
|
-
// URL-related sources
|
|
7759
|
-
["urlscan" /* URLSCAN */]: [
|
|
7760
|
-
"browser_capture" /* BROWSER_CAPTURE */,
|
|
7761
|
-
"geolocation_and_ip" /* GEOLOCATION_AND_IP */
|
|
7762
|
-
],
|
|
7763
|
-
["whois" /* WHOIS */]: ["ownership_and_registration" /* OWNERSHIP_AND_REGISTRATION */],
|
|
7764
|
-
["rdap" /* RDAP */]: ["ownership_and_registration" /* OWNERSHIP_AND_REGISTRATION */],
|
|
7765
|
-
["http_content" /* HTTP_CONTENT */]: [
|
|
7766
|
-
"content_and_metadata" /* CONTENT_AND_METADATA */
|
|
7767
|
-
],
|
|
7768
|
-
["node_js_network" /* NETWORK */]: [
|
|
7769
|
-
"dns" /* DNS */,
|
|
7770
|
-
"tls" /* TLS */,
|
|
7771
|
-
"tcp" /* TCP */
|
|
7772
|
-
],
|
|
7773
|
-
["extension" /* EXTENSION */]: [
|
|
7774
|
-
"browser_capture" /* BROWSER_CAPTURE */,
|
|
7775
|
-
"telegram_profile" /* TELEGRAM_PROFILE */,
|
|
7776
|
-
"linkedin_profile" /* LINKEDIN_PROFILE */,
|
|
7777
|
-
"instagram_profile" /* INSTAGRAM_PROFILE */,
|
|
7778
|
-
"meta_ad" /* META_AD */
|
|
7779
|
-
],
|
|
7780
|
-
["playwright" /* PLAYWRIGHT */]: [
|
|
7781
|
-
"browser_capture" /* BROWSER_CAPTURE */,
|
|
7782
|
-
"bilibili_video" /* BILIBILI_VIDEO */,
|
|
7783
|
-
"bilibili_profile" /* BILIBILI_PROFILE */,
|
|
7784
|
-
"telegram_profile" /* TELEGRAM_PROFILE */
|
|
7785
|
-
],
|
|
7786
|
-
// Twitter-related sources
|
|
7787
|
-
["x_api" /* X_API */]: [
|
|
7788
|
-
"post" /* TWITTER_POST */,
|
|
7789
|
-
"profile" /* TWITTER_PROFILE */,
|
|
7790
|
-
"twitter_followers" /* TWITTER_FOLLOWERS */
|
|
7791
|
-
],
|
|
7792
|
-
["socialdata_api" /* SOCIALDATA_API */]: [
|
|
7793
|
-
"post" /* TWITTER_POST */,
|
|
7794
|
-
"profile" /* TWITTER_PROFILE */,
|
|
7795
|
-
"twitter_followers" /* TWITTER_FOLLOWERS */
|
|
7796
|
-
],
|
|
7797
|
-
// Farcaster-related sources
|
|
7798
|
-
["neynar_api" /* NEYNAR_API */]: [
|
|
7799
|
-
"cast" /* FARCASTER_CAST */,
|
|
7800
|
-
"farcaster_profile" /* FARCASTER_PROFILE */,
|
|
7801
|
-
"channel" /* FARCASTER_CHANNEL */,
|
|
7802
|
-
"miniapp" /* FARCASTER_MINIAPP */
|
|
7803
|
-
],
|
|
7804
|
-
// Telegram-related sources
|
|
7805
|
-
["telegram_api" /* TELEGRAM_API */]: ["telegram_profile" /* TELEGRAM_PROFILE */],
|
|
7806
|
-
// Instagram-related sources
|
|
7807
|
-
["instagram_api" /* INSTAGRAM_API */]: ["instagram_profile" /* INSTAGRAM_PROFILE */],
|
|
7808
|
-
// Facebook-related sources
|
|
7809
|
-
["facebook_api" /* FACEBOOK_API */]: ["facebook_profile" /* FACEBOOK_PROFILE */],
|
|
7810
|
-
// YouTube-related sources
|
|
7811
|
-
["youtube_api" /* YOUTUBE_API */]: [
|
|
7812
|
-
"youtube_video" /* YOUTUBE_VIDEO */,
|
|
7813
|
-
"youtube_channel" /* YOUTUBE_CHANNEL */
|
|
7814
|
-
],
|
|
7815
|
-
// Apple App Store-related sources
|
|
7816
|
-
["apple_app_store_api" /* APPLE_APP_STORE_API */]: [
|
|
7817
|
-
"apple_app_store_listing" /* APPLE_APP_STORE_LISTING */
|
|
7818
|
-
],
|
|
7819
|
-
// Google Play Store-related sources
|
|
7820
|
-
["google_play_store_api" /* GOOGLE_PLAY_STORE_API */]: [
|
|
7821
|
-
"google_play_store_listing" /* GOOGLE_PLAY_STORE_LISTING */
|
|
7822
|
-
],
|
|
7823
|
-
// Mozilla-related sources
|
|
7824
|
-
["mozilla_addons_api" /* MOZILLA_ADDONS_API */]: ["mozilla_addon" /* MOZILLA_ADDON */],
|
|
7825
|
-
// Reddit-related sources
|
|
7826
|
-
["reddit_api" /* REDDIT_API */]: ["reddit_subreddit" /* REDDIT_SUBREDDIT */],
|
|
7827
|
-
// Email-related sources
|
|
7828
|
-
["mails_api" /* MAILS_API */]: ["email_validation" /* EMAIL_VALIDATION */],
|
|
7829
|
-
// Phone Number-related sources
|
|
7830
|
-
["telnyx_lookup" /* TELNYX_LOOKUP */]: ["phone_lookup" /* PHONE_LOOKUP */],
|
|
7831
|
-
["twilio_lookup" /* TWILIO_LOOKUP */]: ["phone_lookup" /* PHONE_LOOKUP */],
|
|
7832
|
-
// DailyMotion-related sources
|
|
7833
|
-
["dailymotion_api" /* DAILYMOTION_API */]: [
|
|
7834
|
-
"dailymotion_video" /* DAILYMOTION_VIDEO */
|
|
7835
|
-
],
|
|
7836
|
-
// Vimeo-related sources
|
|
7837
|
-
["vimeo_api" /* VIMEO_API */]: [
|
|
7838
|
-
"vimeo_video" /* VIMEO_VIDEO */,
|
|
7839
|
-
"vimeo_profile" /* VIMEO_PROFILE */
|
|
7840
|
-
],
|
|
7841
|
-
// Stackblitz-related sources
|
|
7842
|
-
["stackblitz_api" /* STACKBLITZ_API */]: ["stackblitz_page" /* STACKBLITZ_PAGE */],
|
|
7843
|
-
// Leetcode-related sources
|
|
7844
|
-
["leetcode_api" /* LEETCODE_API */]: ["leetcode_page" /* LEETCODE_PAGE */],
|
|
7845
|
-
// NPM-related sources
|
|
7846
|
-
["npm_registry_api" /* NPM_REGISTRY_API */]: ["npm_package" /* NPM_PACKAGE */],
|
|
7847
|
-
// PyPI-related sources
|
|
7848
|
-
["pypi_registry_api" /* PYPI_REGISTRY_API */]: ["pypi_package" /* PYPI_PACKAGE */],
|
|
7849
|
-
// Rust Package-related sources
|
|
7850
|
-
["crates_io_api" /* CRATES_IO_API */]: ["rust_package" /* RUST_PACKAGE */],
|
|
7851
|
-
// LinkedIn-related sources
|
|
7852
|
-
["apify_linkedin_api" /* APIFY_LINKEDIN_API */]: [
|
|
7853
|
-
"linkedin_profile" /* LINKEDIN_PROFILE */
|
|
7854
|
-
],
|
|
7855
|
-
// Meta Ads-related sources
|
|
7856
|
-
["meta_ads_library" /* META_ADS_LIBRARY */]: ["meta_ad" /* META_AD */],
|
|
7857
|
-
// Google Ads-related sources
|
|
7858
|
-
["google_ads_transparency_center" /* GOOGLE_ADS_TRANSPARENCY_CENTER */]: [
|
|
7859
|
-
"google_ad" /* GOOGLE_AD */
|
|
7860
|
-
],
|
|
7861
|
-
// Crypto / Onchain sources
|
|
7862
|
-
["etherscan_api" /* ETHERSCAN_API */]: ["contract_deployer" /* CONTRACT_DEPLOYER */]
|
|
7863
|
-
};
|
|
7864
7627
|
|
|
7865
|
-
// ../../
|
|
7866
|
-
|
|
7867
|
-
|
|
7868
|
-
|
|
7869
|
-
chunkArray: () => chunkArray,
|
|
7870
|
-
combineAndRemoveDuplicatesByKey: () => combineAndRemoveDuplicatesByKey,
|
|
7871
|
-
isArray: () => isArray,
|
|
7872
|
-
isEmptyArray: () => isEmptyArray,
|
|
7873
|
-
isNonEmptyArray: () => isNonEmptyArray,
|
|
7874
|
-
randomElement: () => randomElement,
|
|
7875
|
-
randomIndex: () => randomIndex,
|
|
7876
|
-
removeDuplicates: () => removeDuplicates,
|
|
7877
|
-
shuffleInPlace: () => shuffleInPlace,
|
|
7878
|
-
shuffled: () => shuffled
|
|
7879
|
-
});
|
|
7880
|
-
function isArray(value) {
|
|
7881
|
-
return Array.isArray(value);
|
|
7882
|
-
}
|
|
7883
|
-
function isEmptyArray(value) {
|
|
7884
|
-
return value.length === 0;
|
|
7885
|
-
}
|
|
7886
|
-
function isNonEmptyArray(value) {
|
|
7887
|
-
return value.length > 0;
|
|
7888
|
-
}
|
|
7889
|
-
function randomIndex(array) {
|
|
7890
|
-
return Math.floor(Math.random() * array.length);
|
|
7891
|
-
}
|
|
7892
|
-
function randomElement(array) {
|
|
7893
|
-
return array[randomIndex(array)];
|
|
7894
|
-
}
|
|
7895
|
-
function removeDuplicates(array) {
|
|
7896
|
-
return Array.from(new Set(array));
|
|
7897
|
-
}
|
|
7898
|
-
function combineAndRemoveDuplicatesByKey(arr1, arr2, uniqueKey) {
|
|
7899
|
-
const combinedArray = [...arr1, ...arr2];
|
|
7900
|
-
const uniqueObjects = new Map(
|
|
7901
|
-
combinedArray.map((item) => [item[uniqueKey], item])
|
|
7902
|
-
);
|
|
7903
|
-
return Array.from(uniqueObjects.values());
|
|
7904
|
-
}
|
|
7905
|
-
function chunkArray(array, chunkSize) {
|
|
7906
|
-
const chunks = [];
|
|
7907
|
-
for (let i = 0; i < array.length; i += chunkSize) {
|
|
7908
|
-
chunks.push(array.slice(i, i + chunkSize));
|
|
7909
|
-
}
|
|
7910
|
-
return chunks;
|
|
7911
|
-
}
|
|
7912
|
-
function shuffleInPlace(array) {
|
|
7913
|
-
for (let i = array.length - 1; i > 0; i--) {
|
|
7914
|
-
const j = Math.floor(Math.random() * (i + 1));
|
|
7915
|
-
[array[i], array[j]] = [array[j], array[i]];
|
|
7628
|
+
// ../../node_modules/@sindresorhus/slugify/node_modules/escape-string-regexp/index.js
|
|
7629
|
+
function escapeStringRegexp(string) {
|
|
7630
|
+
if (typeof string !== "string") {
|
|
7631
|
+
throw new TypeError("Expected a string");
|
|
7916
7632
|
}
|
|
7917
|
-
}
|
|
7918
|
-
function shuffled(array) {
|
|
7919
|
-
const newArray = array.slice();
|
|
7920
|
-
shuffleInPlace(newArray);
|
|
7921
|
-
return newArray;
|
|
7922
|
-
}
|
|
7923
|
-
function arraysEqual(a, b) {
|
|
7924
|
-
if (a.length !== b.length) return false;
|
|
7925
|
-
const sortedA = [...a].sort();
|
|
7926
|
-
const sortedB = [...b].sort();
|
|
7927
|
-
return sortedA.every((val, idx) => val === sortedB[idx]);
|
|
7633
|
+
return string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
7928
7634
|
}
|
|
7929
7635
|
|
|
7930
|
-
// ../../
|
|
7931
|
-
|
|
7932
|
-
|
|
7933
|
-
|
|
7934
|
-
isValidCronExpression: () => isValidCronExpression
|
|
7935
|
-
});
|
|
7936
|
-
var WEEKDAYS = [
|
|
7937
|
-
"Sunday",
|
|
7938
|
-
"Monday",
|
|
7939
|
-
"Tuesday",
|
|
7940
|
-
"Wednesday",
|
|
7941
|
-
"Thursday",
|
|
7942
|
-
"Friday",
|
|
7943
|
-
"Saturday"
|
|
7944
|
-
];
|
|
7945
|
-
var MONTHS = [
|
|
7946
|
-
"January",
|
|
7947
|
-
"February",
|
|
7948
|
-
"March",
|
|
7949
|
-
"April",
|
|
7950
|
-
"May",
|
|
7951
|
-
"June",
|
|
7952
|
-
"July",
|
|
7953
|
-
"August",
|
|
7954
|
-
"September",
|
|
7955
|
-
"October",
|
|
7956
|
-
"November",
|
|
7957
|
-
"December"
|
|
7958
|
-
];
|
|
7959
|
-
function cronToHumanReadable(cronExpression) {
|
|
7960
|
-
const [minute, hour, dayOfMonth, month, dayOfWeek2] = cronExpression.split(" ");
|
|
7961
|
-
let result = "Runs ";
|
|
7962
|
-
if (minute === "*") {
|
|
7963
|
-
result += "every minute ";
|
|
7964
|
-
} else if (minute.includes("/")) {
|
|
7965
|
-
const [, interval] = minute.split("/");
|
|
7966
|
-
result += `every ${interval} minutes `;
|
|
7967
|
-
} else {
|
|
7968
|
-
result += `at minute ${minute} `;
|
|
7969
|
-
}
|
|
7970
|
-
if (hour !== "*") {
|
|
7971
|
-
result += `past hour ${hour} `;
|
|
7972
|
-
}
|
|
7973
|
-
if (dayOfMonth !== "*") {
|
|
7974
|
-
result += `on the ${dayOfMonth}${getDaySuffix(
|
|
7975
|
-
parseInt(dayOfMonth)
|
|
7976
|
-
)} day of the month `;
|
|
7977
|
-
}
|
|
7978
|
-
if (month !== "*") {
|
|
7979
|
-
const monthNames = month.split(",").map((m) => MONTHS[parseInt(m) - 1]);
|
|
7980
|
-
result += `in ${monthNames.join(", ")} `;
|
|
7981
|
-
}
|
|
7982
|
-
if (dayOfWeek2 !== "*") {
|
|
7983
|
-
const dayNames = dayOfWeek2.split(",").map((d) => WEEKDAYS[parseInt(d)]);
|
|
7984
|
-
result += `on ${dayNames.join(", ")}`;
|
|
7985
|
-
}
|
|
7986
|
-
return result.trim();
|
|
7987
|
-
}
|
|
7988
|
-
function getDaySuffix(day) {
|
|
7989
|
-
if (day >= 11 && day <= 13) {
|
|
7990
|
-
return "th";
|
|
7991
|
-
}
|
|
7992
|
-
switch (day % 10) {
|
|
7993
|
-
case 1:
|
|
7994
|
-
return "st";
|
|
7995
|
-
case 2:
|
|
7996
|
-
return "nd";
|
|
7997
|
-
case 3:
|
|
7998
|
-
return "rd";
|
|
7999
|
-
default:
|
|
8000
|
-
return "th";
|
|
8001
|
-
}
|
|
8002
|
-
}
|
|
8003
|
-
function isValidCronExpression(cronExpression) {
|
|
8004
|
-
if (!cronExpression || typeof cronExpression !== "string") {
|
|
8005
|
-
return false;
|
|
8006
|
-
}
|
|
8007
|
-
const parts = cronExpression.trim().split(/\s+/);
|
|
8008
|
-
if (parts.length !== 5) {
|
|
8009
|
-
return false;
|
|
7636
|
+
// ../../node_modules/@sindresorhus/transliterate/node_modules/escape-string-regexp/index.js
|
|
7637
|
+
function escapeStringRegexp2(string) {
|
|
7638
|
+
if (typeof string !== "string") {
|
|
7639
|
+
throw new TypeError("Expected a string");
|
|
8010
7640
|
}
|
|
8011
|
-
|
|
8012
|
-
return isValidCronField(minute, 0, 59) && isValidCronField(hour, 0, 23) && isValidCronField(dayOfMonth, 1, 31) && isValidCronField(month, 1, 12) && isValidCronField(dayOfWeek2, 0, 7);
|
|
8013
|
-
}
|
|
8014
|
-
function isValidCronField(field, min, max) {
|
|
8015
|
-
if (!field) return false;
|
|
8016
|
-
if (field === "*") return true;
|
|
8017
|
-
if (field.includes("/")) {
|
|
8018
|
-
const [range, step] = field.split("/");
|
|
8019
|
-
const stepNum = parseInt(step);
|
|
8020
|
-
if (isNaN(stepNum) || stepNum <= 0) return false;
|
|
8021
|
-
if (range === "*") return true;
|
|
8022
|
-
return isValidCronField(range, min, max);
|
|
8023
|
-
}
|
|
8024
|
-
if (field.includes("-")) {
|
|
8025
|
-
const [start, end] = field.split("-");
|
|
8026
|
-
const startNum = parseInt(start);
|
|
8027
|
-
const endNum = parseInt(end);
|
|
8028
|
-
if (isNaN(startNum) || isNaN(endNum)) return false;
|
|
8029
|
-
return startNum >= min && startNum <= max && endNum >= min && endNum <= max && startNum <= endNum;
|
|
8030
|
-
}
|
|
8031
|
-
if (field.includes(",")) {
|
|
8032
|
-
const values = field.split(",");
|
|
8033
|
-
return values.every((value) => isValidCronField(value.trim(), min, max));
|
|
8034
|
-
}
|
|
8035
|
-
const num3 = parseInt(field);
|
|
8036
|
-
if (isNaN(num3)) return false;
|
|
8037
|
-
if (max === 7 && num3 === 7) return true;
|
|
8038
|
-
return num3 >= min && num3 <= max;
|
|
8039
|
-
}
|
|
8040
|
-
|
|
8041
|
-
// ../../internal/utils/src/object.ts
|
|
8042
|
-
var object_exports = {};
|
|
8043
|
-
__export(object_exports, {
|
|
8044
|
-
isDefined: () => isDefined,
|
|
8045
|
-
isDefinedAndNotNull: () => isDefinedAndNotNull,
|
|
8046
|
-
isNotNull: () => isNotNull
|
|
8047
|
-
});
|
|
8048
|
-
function isDefined(value) {
|
|
8049
|
-
return value !== void 0;
|
|
8050
|
-
}
|
|
8051
|
-
function isNotNull(value) {
|
|
8052
|
-
return value !== null;
|
|
8053
|
-
}
|
|
8054
|
-
function isDefinedAndNotNull(value) {
|
|
8055
|
-
return value !== null && value !== void 0;
|
|
8056
|
-
}
|
|
8057
|
-
|
|
8058
|
-
// ../../internal/utils/src/promise.ts
|
|
8059
|
-
var promise_exports = {};
|
|
8060
|
-
__export(promise_exports, {
|
|
8061
|
-
isPromiseSettledResultFulfilled: () => isPromiseSettledResultFulfilled,
|
|
8062
|
-
isPromiseSettledResultRejected: () => isPromiseSettledResultRejected
|
|
8063
|
-
});
|
|
8064
|
-
function isPromiseSettledResultFulfilled(result) {
|
|
8065
|
-
return result.status === "fulfilled";
|
|
8066
|
-
}
|
|
8067
|
-
function isPromiseSettledResultRejected(result) {
|
|
8068
|
-
return result.status === "rejected";
|
|
8069
|
-
}
|
|
8070
|
-
|
|
8071
|
-
// ../../internal/utils/src/url.ts
|
|
8072
|
-
var url_exports = {};
|
|
8073
|
-
__export(url_exports, {
|
|
8074
|
-
URL_REGEX: () => URL_REGEX,
|
|
8075
|
-
containsPunycode: () => containsPunycode,
|
|
8076
|
-
convertHttpsToHttp: () => convertHttpsToHttp,
|
|
8077
|
-
ensureHttpsPrefix: () => ensureHttpsPrefix,
|
|
8078
|
-
generateCanonicalIPFSUrl: () => generateCanonicalIPFSUrl,
|
|
8079
|
-
getDefangedUrl: () => getDefangedUrl,
|
|
8080
|
-
getDomain: () => tldts.getDomain,
|
|
8081
|
-
getFaviconUrl: () => getFaviconUrl,
|
|
8082
|
-
getHostname: () => getHostname,
|
|
8083
|
-
getNormalizedUrl: () => getNormalizedUrl,
|
|
8084
|
-
getParentDomains: () => getParentDomains,
|
|
8085
|
-
getRefangedUrl: () => getRefangedUrl,
|
|
8086
|
-
isEmail: () => isEmail,
|
|
8087
|
-
isUrl: () => isUrl,
|
|
8088
|
-
isWalrusSite: () => isWalrusSite,
|
|
8089
|
-
removeHttpProtocol: () => removeHttpProtocol,
|
|
8090
|
-
sanitizeHttpUrl: () => sanitizeHttpUrl,
|
|
8091
|
-
slugify: () => slugify,
|
|
8092
|
-
stripDomainWildcardPrefix: () => stripDomainWildcardPrefix,
|
|
8093
|
-
toUnicode: () => toUnicode2,
|
|
8094
|
-
trimDomainToLevels: () => trimDomainToLevels
|
|
8095
|
-
});
|
|
8096
|
-
|
|
8097
|
-
// ../../node_modules/@sindresorhus/slugify/node_modules/escape-string-regexp/index.js
|
|
8098
|
-
function escapeStringRegexp(string) {
|
|
8099
|
-
if (typeof string !== "string") {
|
|
8100
|
-
throw new TypeError("Expected a string");
|
|
8101
|
-
}
|
|
8102
|
-
return string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
8103
|
-
}
|
|
8104
|
-
|
|
8105
|
-
// ../../node_modules/@sindresorhus/transliterate/node_modules/escape-string-regexp/index.js
|
|
8106
|
-
function escapeStringRegexp2(string) {
|
|
8107
|
-
if (typeof string !== "string") {
|
|
8108
|
-
throw new TypeError("Expected a string");
|
|
8109
|
-
}
|
|
8110
|
-
return string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
7641
|
+
return string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
8111
7642
|
}
|
|
8112
7643
|
|
|
8113
7644
|
// ../../node_modules/@sindresorhus/transliterate/replacements.js
|
|
@@ -10186,472 +9717,1140 @@ var buildPatternSlug = (options) => {
|
|
|
10186
9717
|
}
|
|
10187
9718
|
return new RegExp(`[^${negationSetPattern}]+`, "g");
|
|
10188
9719
|
};
|
|
10189
|
-
function slugify(string, options) {
|
|
10190
|
-
if (typeof string !== "string") {
|
|
10191
|
-
throw new TypeError(`Expected a string, got \`${typeof string}\``);
|
|
10192
|
-
}
|
|
10193
|
-
options = __spreadValues({
|
|
10194
|
-
separator: "-",
|
|
10195
|
-
lowercase: true,
|
|
10196
|
-
decamelize: true,
|
|
10197
|
-
customReplacements: [],
|
|
10198
|
-
preserveLeadingUnderscore: false,
|
|
10199
|
-
preserveTrailingDash: false,
|
|
10200
|
-
preserveCharacters: []
|
|
10201
|
-
}, options);
|
|
10202
|
-
const shouldPrependUnderscore = options.preserveLeadingUnderscore && string.startsWith("_");
|
|
10203
|
-
const shouldAppendDash = options.preserveTrailingDash && string.endsWith("-");
|
|
10204
|
-
const customReplacements = new Map([
|
|
10205
|
-
...overridable_replacements_default,
|
|
10206
|
-
...options.customReplacements
|
|
10207
|
-
]);
|
|
10208
|
-
string = transliterate(string, { customReplacements });
|
|
10209
|
-
if (options.decamelize) {
|
|
10210
|
-
string = decamelize(string);
|
|
10211
|
-
}
|
|
10212
|
-
const patternSlug = buildPatternSlug(options);
|
|
10213
|
-
if (options.lowercase) {
|
|
10214
|
-
string = string.toLowerCase();
|
|
10215
|
-
}
|
|
10216
|
-
string = string.replace(/([a-zA-Z\d]+)'([ts])(\s|$)/g, "$1$2$3");
|
|
10217
|
-
string = string.replace(patternSlug, options.separator);
|
|
10218
|
-
string = string.replace(/\\/g, "");
|
|
10219
|
-
if (options.separator) {
|
|
10220
|
-
string = removeMootSeparators(string, options.separator);
|
|
10221
|
-
}
|
|
10222
|
-
if (shouldPrependUnderscore) {
|
|
10223
|
-
string = `_${string}`;
|
|
10224
|
-
}
|
|
10225
|
-
if (shouldAppendDash) {
|
|
10226
|
-
string = `${string}-`;
|
|
10227
|
-
}
|
|
10228
|
-
return string;
|
|
10229
|
-
}
|
|
9720
|
+
function slugify(string, options) {
|
|
9721
|
+
if (typeof string !== "string") {
|
|
9722
|
+
throw new TypeError(`Expected a string, got \`${typeof string}\``);
|
|
9723
|
+
}
|
|
9724
|
+
options = __spreadValues({
|
|
9725
|
+
separator: "-",
|
|
9726
|
+
lowercase: true,
|
|
9727
|
+
decamelize: true,
|
|
9728
|
+
customReplacements: [],
|
|
9729
|
+
preserveLeadingUnderscore: false,
|
|
9730
|
+
preserveTrailingDash: false,
|
|
9731
|
+
preserveCharacters: []
|
|
9732
|
+
}, options);
|
|
9733
|
+
const shouldPrependUnderscore = options.preserveLeadingUnderscore && string.startsWith("_");
|
|
9734
|
+
const shouldAppendDash = options.preserveTrailingDash && string.endsWith("-");
|
|
9735
|
+
const customReplacements = new Map([
|
|
9736
|
+
...overridable_replacements_default,
|
|
9737
|
+
...options.customReplacements
|
|
9738
|
+
]);
|
|
9739
|
+
string = transliterate(string, { customReplacements });
|
|
9740
|
+
if (options.decamelize) {
|
|
9741
|
+
string = decamelize(string);
|
|
9742
|
+
}
|
|
9743
|
+
const patternSlug = buildPatternSlug(options);
|
|
9744
|
+
if (options.lowercase) {
|
|
9745
|
+
string = string.toLowerCase();
|
|
9746
|
+
}
|
|
9747
|
+
string = string.replace(/([a-zA-Z\d]+)'([ts])(\s|$)/g, "$1$2$3");
|
|
9748
|
+
string = string.replace(patternSlug, options.separator);
|
|
9749
|
+
string = string.replace(/\\/g, "");
|
|
9750
|
+
if (options.separator) {
|
|
9751
|
+
string = removeMootSeparators(string, options.separator);
|
|
9752
|
+
}
|
|
9753
|
+
if (shouldPrependUnderscore) {
|
|
9754
|
+
string = `_${string}`;
|
|
9755
|
+
}
|
|
9756
|
+
if (shouldAppendDash) {
|
|
9757
|
+
string = `${string}-`;
|
|
9758
|
+
}
|
|
9759
|
+
return string;
|
|
9760
|
+
}
|
|
9761
|
+
|
|
9762
|
+
// ../asset-parse/src/model.ts
|
|
9763
|
+
var AssetModel = /* @__PURE__ */ ((AssetModel2) => {
|
|
9764
|
+
AssetModel2["Addon"] = "addon";
|
|
9765
|
+
AssetModel2["App"] = "app";
|
|
9766
|
+
AssetModel2["Bot"] = "bot";
|
|
9767
|
+
AssetModel2["BusinessProfile"] = "business-profile";
|
|
9768
|
+
AssetModel2["Catalog"] = "catalog";
|
|
9769
|
+
AssetModel2["Collection"] = "collection";
|
|
9770
|
+
AssetModel2["Channel"] = "channel";
|
|
9771
|
+
AssetModel2["Group"] = "group";
|
|
9772
|
+
AssetModel2["Post"] = "post";
|
|
9773
|
+
AssetModel2["Profile"] = "profile";
|
|
9774
|
+
AssetModel2["Short"] = "short";
|
|
9775
|
+
AssetModel2["Video"] = "video";
|
|
9776
|
+
AssetModel2["Space"] = "space";
|
|
9777
|
+
AssetModel2["Issue"] = "issue";
|
|
9778
|
+
AssetModel2["PullRequest"] = "pull-request";
|
|
9779
|
+
AssetModel2["Discussion"] = "discussion";
|
|
9780
|
+
AssetModel2["Repository"] = "repository";
|
|
9781
|
+
AssetModel2["Article"] = "Article";
|
|
9782
|
+
AssetModel2["Comment"] = "comment";
|
|
9783
|
+
AssetModel2["List"] = "list";
|
|
9784
|
+
AssetModel2["Subreddit"] = "subreddit";
|
|
9785
|
+
AssetModel2["Community"] = "community";
|
|
9786
|
+
AssetModel2["MiniApp"] = "mini-app";
|
|
9787
|
+
AssetModel2["Developer"] = "developer";
|
|
9788
|
+
return AssetModel2;
|
|
9789
|
+
})(AssetModel || {});
|
|
9790
|
+
function isUrl(input) {
|
|
9791
|
+
if (input.trim() === "") {
|
|
9792
|
+
return false;
|
|
9793
|
+
}
|
|
9794
|
+
if (input.startsWith("/") || input.startsWith("#") || input.startsWith("?") || input.startsWith(".") || !input.includes(".")) {
|
|
9795
|
+
return false;
|
|
9796
|
+
}
|
|
9797
|
+
return URL.canParse(input) || URL.canParse(`https://${input}`);
|
|
9798
|
+
}
|
|
9799
|
+
function getNormalizedUrl(input) {
|
|
9800
|
+
if (!isUrl(input)) {
|
|
9801
|
+
throw new Error(`Invalid URL: ${input}`);
|
|
9802
|
+
}
|
|
9803
|
+
let url;
|
|
9804
|
+
try {
|
|
9805
|
+
url = new URL(input);
|
|
9806
|
+
} catch (e4) {
|
|
9807
|
+
try {
|
|
9808
|
+
url = new URL(`https://${input}`);
|
|
9809
|
+
} catch (e5) {
|
|
9810
|
+
throw new Error(`Invalid URL: ${input}`);
|
|
9811
|
+
}
|
|
9812
|
+
}
|
|
9813
|
+
const normalizedUrl = normalizeUrl(url.toString(), {
|
|
9814
|
+
defaultProtocol: "https"
|
|
9815
|
+
});
|
|
9816
|
+
try {
|
|
9817
|
+
return new URL(normalizedUrl);
|
|
9818
|
+
} catch (e4) {
|
|
9819
|
+
throw new Error(`Invalid URL: ${input}`);
|
|
9820
|
+
}
|
|
9821
|
+
}
|
|
9822
|
+
var ensureHttpsPrefix = (url) => {
|
|
9823
|
+
if (!url.startsWith("http")) {
|
|
9824
|
+
return `https://${url}`;
|
|
9825
|
+
}
|
|
9826
|
+
return url.replace(/^https?:\/{1,2}/, "https://");
|
|
9827
|
+
};
|
|
9828
|
+
function getHostname(input) {
|
|
9829
|
+
try {
|
|
9830
|
+
return getNormalizedUrl(input).hostname;
|
|
9831
|
+
} catch (e4) {
|
|
9832
|
+
return null;
|
|
9833
|
+
}
|
|
9834
|
+
}
|
|
9835
|
+
function getParentDomains(input) {
|
|
9836
|
+
const domain = getHostname(input);
|
|
9837
|
+
if (!domain) {
|
|
9838
|
+
return [];
|
|
9839
|
+
}
|
|
9840
|
+
const subdomain = tldts.getSubdomain(domain, { mixedInputs: false });
|
|
9841
|
+
if (!subdomain) {
|
|
9842
|
+
return [domain];
|
|
9843
|
+
}
|
|
9844
|
+
const domainWithSuffix = tldts.getDomain(domain, { mixedInputs: false });
|
|
9845
|
+
if (!domainWithSuffix) {
|
|
9846
|
+
return [];
|
|
9847
|
+
}
|
|
9848
|
+
const parentDomains = [domainWithSuffix];
|
|
9849
|
+
const parentDomainParts = subdomain.split(".");
|
|
9850
|
+
for (let i = parentDomainParts.length - 1; i >= 0; i--) {
|
|
9851
|
+
const parentDomainPart = parentDomainParts.slice(i).join(".");
|
|
9852
|
+
parentDomains.push(`${parentDomainPart}.${domainWithSuffix}`);
|
|
9853
|
+
}
|
|
9854
|
+
return parentDomains.reverse();
|
|
9855
|
+
}
|
|
9856
|
+
function trimDomainToLevels(domain, options = { levels: 4 }) {
|
|
9857
|
+
var _a;
|
|
9858
|
+
const parsed = tldts.parse(domain);
|
|
9859
|
+
const eTLDPlusOne = (_a = parsed.domain) != null ? _a : "";
|
|
9860
|
+
const subdomains = domain.replace(/https?:\/\/(www\.)?/, "").split(".");
|
|
9861
|
+
const eTLDPlusOneIndex = subdomains.findIndex(
|
|
9862
|
+
(_, i) => subdomains.slice(i).join(".") === eTLDPlusOne
|
|
9863
|
+
);
|
|
9864
|
+
const trimmedSubdomains = subdomains.slice(Math.max(eTLDPlusOneIndex - (options.levels - 1), 0)).join(".");
|
|
9865
|
+
return trimmedSubdomains;
|
|
9866
|
+
}
|
|
9867
|
+
|
|
9868
|
+
// ../asset-parse/src/phone.ts
|
|
9869
|
+
var phone_exports = {};
|
|
9870
|
+
__export(phone_exports, {
|
|
9871
|
+
PHONE_NUMBER_REGEX: () => PHONE_NUMBER_REGEX,
|
|
9872
|
+
isPhoneNumber: () => isPhoneNumber,
|
|
9873
|
+
normalizePhoneNumber: () => normalizePhoneNumber
|
|
9874
|
+
});
|
|
9875
|
+
var PHONE_NUMBER_REGEX = /(?:\+?\d{1,4}[\s.-]?)?(?:\(\d{1,4}\)|\d{1,4})[\s.-]?\d{1,4}[\s.-]?\d{1,4}[\s.-]?\d{0,4}(?:\s*(?:ext|x|extension)[\s.]*\d{1,6})?/gi;
|
|
9876
|
+
function preparePhoneInput(input) {
|
|
9877
|
+
let s2 = input.trim();
|
|
9878
|
+
s2 = s2.replace(/^\s*tel:\s*(?:\/\/)?\s*/i, "");
|
|
9879
|
+
s2 = s2.trim();
|
|
9880
|
+
s2 = s2.replace(/[\u00A0\u2000-\u200A\u202F\u205F\u3000]/g, " ");
|
|
9881
|
+
s2 = s2.replace(/[\u2010\u2011\u2012\u2013\u2014\u2015\u2212\uFE58\uFE63\uFF0D]/g, "-");
|
|
9882
|
+
s2 = s2.replace(/\uFF0B/g, "+");
|
|
9883
|
+
s2 = s2.replace(/\uFF08/g, "(");
|
|
9884
|
+
s2 = s2.replace(/\uFF09/g, ")");
|
|
9885
|
+
return s2.trim();
|
|
9886
|
+
}
|
|
9887
|
+
function isAllSameDigit(digits2) {
|
|
9888
|
+
return /^(\d)\1+$/.test(digits2);
|
|
9889
|
+
}
|
|
9890
|
+
function isStrictlyMonotonicStep1(digits2) {
|
|
9891
|
+
if (digits2.length < 8) {
|
|
9892
|
+
return false;
|
|
9893
|
+
}
|
|
9894
|
+
let increasing = true;
|
|
9895
|
+
let decreasing = true;
|
|
9896
|
+
for (let i = 1; i < digits2.length; i++) {
|
|
9897
|
+
const curr = digits2.charCodeAt(i) - 48;
|
|
9898
|
+
const prev = digits2.charCodeAt(i - 1) - 48;
|
|
9899
|
+
if (curr !== prev + 1) {
|
|
9900
|
+
increasing = false;
|
|
9901
|
+
}
|
|
9902
|
+
if (curr !== prev - 1) {
|
|
9903
|
+
decreasing = false;
|
|
9904
|
+
}
|
|
9905
|
+
}
|
|
9906
|
+
return increasing || decreasing;
|
|
9907
|
+
}
|
|
9908
|
+
function isValidNanpNational10(d10) {
|
|
9909
|
+
if (d10.length !== 10) {
|
|
9910
|
+
return false;
|
|
9911
|
+
}
|
|
9912
|
+
const npaFirst = d10.charCodeAt(0) - 48;
|
|
9913
|
+
const nxxFirst = d10.charCodeAt(3) - 48;
|
|
9914
|
+
if (npaFirst < 2 || npaFirst > 9) {
|
|
9915
|
+
return false;
|
|
9916
|
+
}
|
|
9917
|
+
if (nxxFirst < 2 || nxxFirst > 9) {
|
|
9918
|
+
return false;
|
|
9919
|
+
}
|
|
9920
|
+
return true;
|
|
9921
|
+
}
|
|
9922
|
+
function isPlausiblePhoneDigits(withoutExt) {
|
|
9923
|
+
const hasPlus = withoutExt.startsWith("+");
|
|
9924
|
+
const d = withoutExt.replace(/\D/g, "");
|
|
9925
|
+
if (d.length < 8 || d.length > 15) {
|
|
9926
|
+
return false;
|
|
9927
|
+
}
|
|
9928
|
+
if (isAllSameDigit(d) || isStrictlyMonotonicStep1(d)) {
|
|
9929
|
+
return false;
|
|
9930
|
+
}
|
|
9931
|
+
const onlyDigits = /^\d+$/.test(withoutExt);
|
|
9932
|
+
if (hasPlus) {
|
|
9933
|
+
if (d.length === 11 && d.startsWith("1")) {
|
|
9934
|
+
return isValidNanpNational10(d.slice(1));
|
|
9935
|
+
}
|
|
9936
|
+
return true;
|
|
9937
|
+
}
|
|
9938
|
+
if (onlyDigits) {
|
|
9939
|
+
if (d.length === 10) {
|
|
9940
|
+
return isValidNanpNational10(d);
|
|
9941
|
+
}
|
|
9942
|
+
if (d.length === 11 && d.startsWith("1")) {
|
|
9943
|
+
return isValidNanpNational10(d.slice(1));
|
|
9944
|
+
}
|
|
9945
|
+
if (d.length === 11 && d.startsWith("0")) {
|
|
9946
|
+
return true;
|
|
9947
|
+
}
|
|
9948
|
+
return false;
|
|
9949
|
+
}
|
|
9950
|
+
if (d.length === 10) {
|
|
9951
|
+
return isValidNanpNational10(d);
|
|
9952
|
+
}
|
|
9953
|
+
if (d.length === 11 && d.startsWith("1")) {
|
|
9954
|
+
return isValidNanpNational10(d.slice(1));
|
|
9955
|
+
}
|
|
9956
|
+
if (d.length === 11 && d.startsWith("0")) {
|
|
9957
|
+
return true;
|
|
9958
|
+
}
|
|
9959
|
+
if (d.length >= 12 && d.length <= 15) {
|
|
9960
|
+
return true;
|
|
9961
|
+
}
|
|
9962
|
+
return false;
|
|
9963
|
+
}
|
|
9964
|
+
function isPhoneNumber(input) {
|
|
9965
|
+
const trimmed = preparePhoneInput(input);
|
|
9966
|
+
if (trimmed === "") {
|
|
9967
|
+
return false;
|
|
9968
|
+
}
|
|
9969
|
+
if (!/^[+\d(]/.test(trimmed)) {
|
|
9970
|
+
return false;
|
|
9971
|
+
}
|
|
9972
|
+
const withoutExt = trimmed.replace(/\s*(ext|extension|x)\s*\d+$/i, "");
|
|
9973
|
+
if (/[a-zA-Z]/.test(withoutExt)) {
|
|
9974
|
+
return false;
|
|
9975
|
+
}
|
|
9976
|
+
const hasPhoneMarker = /[+()\s-]/.test(trimmed);
|
|
9977
|
+
const isPureDotSeparated = /^\d+(\.\d+)+$/.test(trimmed);
|
|
9978
|
+
if (isPureDotSeparated && !hasPhoneMarker) {
|
|
9979
|
+
return false;
|
|
9980
|
+
}
|
|
9981
|
+
const phoneRegex = /^(?:\+?\d{1,4}[\s.-]?)?(?:\(\d{1,4}\)|\d{1,4})[\s.-]?\d{1,4}[\s.-]?\d{1,4}[\s.-]?\d{0,4}(?:\s*(?:ext|x|extension)[\s.]*\d{1,6})?$/i;
|
|
9982
|
+
if (!phoneRegex.test(trimmed)) {
|
|
9983
|
+
return false;
|
|
9984
|
+
}
|
|
9985
|
+
return isPlausiblePhoneDigits(withoutExt);
|
|
9986
|
+
}
|
|
9987
|
+
function normalizePhoneNumber(phone) {
|
|
9988
|
+
const trimmed = preparePhoneInput(phone);
|
|
9989
|
+
const withoutExt = trimmed.replace(/\s*(ext|extension|x)\s*\d+$/i, "");
|
|
9990
|
+
const hasPlus = withoutExt.startsWith("+");
|
|
9991
|
+
const digitsOnly = withoutExt.replace(/\D/g, "");
|
|
9992
|
+
return hasPlus ? `+${digitsOnly}` : digitsOnly;
|
|
9993
|
+
}
|
|
9994
|
+
|
|
9995
|
+
// ../../internal/utils/src/punycode.ts
|
|
9996
|
+
var maxInt = 2147483647;
|
|
9997
|
+
var base = 36;
|
|
9998
|
+
var tMin = 1;
|
|
9999
|
+
var tMax = 26;
|
|
10000
|
+
var skew = 38;
|
|
10001
|
+
var damp = 700;
|
|
10002
|
+
var initialBias = 72;
|
|
10003
|
+
var initialN = 128;
|
|
10004
|
+
var delimiter = "-";
|
|
10005
|
+
var regexPunycode = /^xn--/;
|
|
10006
|
+
var regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g;
|
|
10007
|
+
var errors = {
|
|
10008
|
+
overflow: "Overflow: input needs wider integers to process",
|
|
10009
|
+
"not-basic": "Illegal input >= 0x80 (not a basic code point)",
|
|
10010
|
+
"invalid-input": "Invalid input"
|
|
10011
|
+
};
|
|
10012
|
+
var baseMinusTMin = base - tMin;
|
|
10013
|
+
var floor = Math.floor;
|
|
10014
|
+
function error(type) {
|
|
10015
|
+
throw new RangeError(errors[type]);
|
|
10016
|
+
}
|
|
10017
|
+
function mapDomain(domain, callback) {
|
|
10018
|
+
const parts = domain.split("@");
|
|
10019
|
+
let result = "";
|
|
10020
|
+
if (parts.length > 1) {
|
|
10021
|
+
result = parts[0] + "@";
|
|
10022
|
+
domain = parts[1];
|
|
10023
|
+
}
|
|
10024
|
+
domain = domain.replace(regexSeparators, ".");
|
|
10025
|
+
const labels = domain.split(".");
|
|
10026
|
+
const encoded = labels.map(callback).join(".");
|
|
10027
|
+
return result + encoded;
|
|
10028
|
+
}
|
|
10029
|
+
function basicToDigit(codePoint) {
|
|
10030
|
+
if (codePoint >= 48 && codePoint < 58) {
|
|
10031
|
+
return 26 + (codePoint - 48);
|
|
10032
|
+
}
|
|
10033
|
+
if (codePoint >= 65 && codePoint < 91) {
|
|
10034
|
+
return codePoint - 65;
|
|
10035
|
+
}
|
|
10036
|
+
if (codePoint >= 97 && codePoint < 123) {
|
|
10037
|
+
return codePoint - 97;
|
|
10038
|
+
}
|
|
10039
|
+
return base;
|
|
10040
|
+
}
|
|
10041
|
+
function adapt(delta, numPoints, firstTime) {
|
|
10042
|
+
let k4 = 0;
|
|
10043
|
+
delta = firstTime ? floor(delta / damp) : delta >> 1;
|
|
10044
|
+
delta += floor(delta / numPoints);
|
|
10045
|
+
for (
|
|
10046
|
+
;
|
|
10047
|
+
/* no initialization */
|
|
10048
|
+
delta > baseMinusTMin * tMax >> 1;
|
|
10049
|
+
k4 += base
|
|
10050
|
+
) {
|
|
10051
|
+
delta = floor(delta / baseMinusTMin);
|
|
10052
|
+
}
|
|
10053
|
+
return floor(k4 + (baseMinusTMin + 1) * delta / (delta + skew));
|
|
10054
|
+
}
|
|
10055
|
+
function decode(input) {
|
|
10056
|
+
const output = [];
|
|
10057
|
+
const inputLength = input.length;
|
|
10058
|
+
let i = 0;
|
|
10059
|
+
let n2 = initialN;
|
|
10060
|
+
let bias2 = initialBias;
|
|
10061
|
+
let basic = input.lastIndexOf(delimiter);
|
|
10062
|
+
if (basic < 0) {
|
|
10063
|
+
basic = 0;
|
|
10064
|
+
}
|
|
10065
|
+
for (let j = 0; j < basic; ++j) {
|
|
10066
|
+
if (input.charCodeAt(j) >= 128) {
|
|
10067
|
+
error("not-basic");
|
|
10068
|
+
}
|
|
10069
|
+
output.push(input.charCodeAt(j));
|
|
10070
|
+
}
|
|
10071
|
+
for (let index = basic > 0 ? basic + 1 : 0; index < inputLength; ) {
|
|
10072
|
+
const oldi = i;
|
|
10073
|
+
for (let w = 1, k4 = base; ; k4 += base) {
|
|
10074
|
+
if (index >= inputLength) {
|
|
10075
|
+
error("invalid-input");
|
|
10076
|
+
}
|
|
10077
|
+
const digit = basicToDigit(input.charCodeAt(index++));
|
|
10078
|
+
if (digit >= base) {
|
|
10079
|
+
error("invalid-input");
|
|
10080
|
+
}
|
|
10081
|
+
if (digit > floor((maxInt - i) / w)) {
|
|
10082
|
+
error("overflow");
|
|
10083
|
+
}
|
|
10084
|
+
i += digit * w;
|
|
10085
|
+
const t = k4 <= bias2 ? tMin : k4 >= bias2 + tMax ? tMax : k4 - bias2;
|
|
10086
|
+
if (digit < t) {
|
|
10087
|
+
break;
|
|
10088
|
+
}
|
|
10089
|
+
const baseMinusT = base - t;
|
|
10090
|
+
if (w > floor(maxInt / baseMinusT)) {
|
|
10091
|
+
error("overflow");
|
|
10092
|
+
}
|
|
10093
|
+
w *= baseMinusT;
|
|
10094
|
+
}
|
|
10095
|
+
const out = output.length + 1;
|
|
10096
|
+
bias2 = adapt(i - oldi, out, oldi == 0);
|
|
10097
|
+
if (floor(i / out) > maxInt - n2) {
|
|
10098
|
+
error("overflow");
|
|
10099
|
+
}
|
|
10100
|
+
n2 += floor(i / out);
|
|
10101
|
+
i %= out;
|
|
10102
|
+
output.splice(i++, 0, n2);
|
|
10103
|
+
}
|
|
10104
|
+
return String.fromCodePoint(...output);
|
|
10105
|
+
}
|
|
10106
|
+
function toUnicode(input) {
|
|
10107
|
+
return mapDomain(input, function(string) {
|
|
10108
|
+
return regexPunycode.test(string) ? decode(string.slice(4).toLowerCase()) : string;
|
|
10109
|
+
});
|
|
10110
|
+
}
|
|
10111
|
+
|
|
10112
|
+
// ../../internal/utils/src/url.ts
|
|
10113
|
+
function isEmail(input) {
|
|
10114
|
+
if (input.trim() === "") {
|
|
10115
|
+
return false;
|
|
10116
|
+
}
|
|
10117
|
+
const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
|
|
10118
|
+
return emailRegex.test(input);
|
|
10119
|
+
}
|
|
10120
|
+
function removeHttpProtocol(input) {
|
|
10121
|
+
return input.replace(/^https?:\/\//, "");
|
|
10122
|
+
}
|
|
10123
|
+
function stripDomainWildcardPrefix(domain) {
|
|
10124
|
+
const trimmedDomain = domain.trim();
|
|
10125
|
+
const strippedDomain = trimmedDomain.startsWith("*.") ? trimmedDomain.slice(2) : trimmedDomain;
|
|
10126
|
+
return strippedDomain.length > 0 ? strippedDomain : null;
|
|
10127
|
+
}
|
|
10128
|
+
function getDefangedUrl(input) {
|
|
10129
|
+
if (!isUrl(input)) {
|
|
10130
|
+
console.warn(`[getDefangedUrl] Invalid URL: ${input}, returning input as-is`);
|
|
10131
|
+
return input;
|
|
10132
|
+
}
|
|
10133
|
+
return input.replace(/\./g, "[.]").replace(/(https:\/\/)/g, "hxxps://").replace(/(http:\/\/)/g, "hxxp://").replace(/:\/\//g, "[://]");
|
|
10134
|
+
}
|
|
10135
|
+
function getRefangedUrl(input) {
|
|
10136
|
+
return input.replace(/hxxps/gi, "https").replace(/hxxp/gi, "http").replace(/\[:\/{2}\]/g, "://").replace(/\[\.\]/g, ".");
|
|
10137
|
+
}
|
|
10138
|
+
function containsPunycode(url) {
|
|
10139
|
+
return url.indexOf("xn--") !== -1;
|
|
10140
|
+
}
|
|
10141
|
+
function toUnicode2(url) {
|
|
10142
|
+
return toUnicode(url);
|
|
10143
|
+
}
|
|
10144
|
+
function convertHttpsToHttp(url) {
|
|
10145
|
+
if (url.startsWith("https://")) {
|
|
10146
|
+
const httpUrl = new URL(url);
|
|
10147
|
+
httpUrl.protocol = "http:";
|
|
10148
|
+
return httpUrl.toString();
|
|
10149
|
+
}
|
|
10150
|
+
throw new Error(`URL is not HTTPS: ${url}`);
|
|
10151
|
+
}
|
|
10152
|
+
function generateCanonicalIPFSUrl(content) {
|
|
10153
|
+
if (!content) {
|
|
10154
|
+
return content;
|
|
10155
|
+
}
|
|
10156
|
+
if (content.includes("ipfs.io")) {
|
|
10157
|
+
return content;
|
|
10158
|
+
}
|
|
10159
|
+
if (content.startsWith("Qm") || content.startsWith("bafy")) {
|
|
10160
|
+
return `ipfs.io/ipfs/${content}`;
|
|
10161
|
+
}
|
|
10162
|
+
return content;
|
|
10163
|
+
}
|
|
10164
|
+
function isWalrusSite(content) {
|
|
10165
|
+
return content.includes(".walrus.site") || content.includes(".walrus.host") || content.includes(".wal.app") || content.includes(".wal.site");
|
|
10166
|
+
}
|
|
10167
|
+
function getFaviconUrl(content) {
|
|
10168
|
+
const normalizedUrl = getNormalizedUrl(content);
|
|
10169
|
+
return `https://icons.duckduckgo.com/ip3/${normalizedUrl.hostname}.ico`;
|
|
10170
|
+
}
|
|
10171
|
+
function sanitizeHttpUrl(value) {
|
|
10172
|
+
if (typeof value !== "string" || value.length === 0) {
|
|
10173
|
+
return null;
|
|
10174
|
+
}
|
|
10175
|
+
try {
|
|
10176
|
+
const parsed = new URL(value);
|
|
10177
|
+
if (parsed.protocol !== "http:" && parsed.protocol !== "https:") {
|
|
10178
|
+
return null;
|
|
10179
|
+
}
|
|
10180
|
+
return parsed.toString();
|
|
10181
|
+
} catch (e4) {
|
|
10182
|
+
return null;
|
|
10183
|
+
}
|
|
10184
|
+
}
|
|
10185
|
+
var SCHEME_PREFIX_REGEX = /^[a-z][a-z0-9+.-]*:\/\//i;
|
|
10186
|
+
function getPublicHostname(input) {
|
|
10187
|
+
try {
|
|
10188
|
+
const trimmed = input.trim();
|
|
10189
|
+
const hasHttpScheme = /^https?:\/\//i.test(trimmed);
|
|
10190
|
+
if (!hasHttpScheme && SCHEME_PREFIX_REGEX.test(trimmed)) {
|
|
10191
|
+
return null;
|
|
10192
|
+
}
|
|
10193
|
+
const withScheme = hasHttpScheme ? trimmed : `https://${trimmed}`;
|
|
10194
|
+
const afterScheme = withScheme.replace(SCHEME_PREFIX_REGEX, "");
|
|
10195
|
+
const authority = afterScheme.split(/[/?#\\]/)[0];
|
|
10196
|
+
const remainder = afterScheme.slice(authority.length);
|
|
10197
|
+
if (remainder !== "" && remainder !== "/") {
|
|
10198
|
+
return null;
|
|
10199
|
+
}
|
|
10200
|
+
if (!/^[\p{L}\p{N}.-]+$/u.test(authority)) {
|
|
10201
|
+
return null;
|
|
10202
|
+
}
|
|
10203
|
+
const url = new URL(withScheme);
|
|
10204
|
+
const host = url.hostname.toLowerCase().replace(/\.$/, "");
|
|
10205
|
+
if (host.split(".").includes("")) {
|
|
10206
|
+
return null;
|
|
10207
|
+
}
|
|
10208
|
+
const parsed = tldts.parse(host);
|
|
10209
|
+
if (parsed.isIp || !parsed.isIcann || !parsed.domain) {
|
|
10210
|
+
return null;
|
|
10211
|
+
}
|
|
10212
|
+
return host;
|
|
10213
|
+
} catch (e4) {
|
|
10214
|
+
return null;
|
|
10215
|
+
}
|
|
10216
|
+
}
|
|
10217
|
+
var URL_REGEX = /https?:\/\/[^\s"'<>\])]*/g;
|
|
10218
|
+
|
|
10219
|
+
// ../../internal/utils/src/enrichments.ts
|
|
10220
|
+
var enrichments_exports = {};
|
|
10221
|
+
__export(enrichments_exports, {
|
|
10222
|
+
ASSET_SCAN_ENRICHMENT_SOURCE_LABELS: () => ASSET_SCAN_ENRICHMENT_SOURCE_LABELS,
|
|
10223
|
+
ASSET_SCAN_ENRICHMENT_SOURCE_TO_TYPES: () => ASSET_SCAN_ENRICHMENT_SOURCE_TO_TYPES,
|
|
10224
|
+
ASSET_SCAN_ENRICHMENT_TYPE_LABELS: () => ASSET_SCAN_ENRICHMENT_TYPE_LABELS,
|
|
10225
|
+
AssetScanEnrichmentSource: () => AssetScanEnrichmentSource,
|
|
10226
|
+
AssetScanEnrichmentType: () => AssetScanEnrichmentType
|
|
10227
|
+
});
|
|
10228
|
+
var AssetScanEnrichmentType = /* @__PURE__ */ ((AssetScanEnrichmentType2) => {
|
|
10229
|
+
AssetScanEnrichmentType2["CONTENT_AND_METADATA"] = "content_and_metadata";
|
|
10230
|
+
AssetScanEnrichmentType2["BROWSER_CAPTURE"] = "browser_capture";
|
|
10231
|
+
AssetScanEnrichmentType2["OWNERSHIP_AND_REGISTRATION"] = "ownership_and_registration";
|
|
10232
|
+
AssetScanEnrichmentType2["GEOLOCATION_AND_IP"] = "geolocation_and_ip";
|
|
10233
|
+
AssetScanEnrichmentType2["DNS"] = "dns";
|
|
10234
|
+
AssetScanEnrichmentType2["TLS"] = "tls";
|
|
10235
|
+
AssetScanEnrichmentType2["TCP"] = "tcp";
|
|
10236
|
+
AssetScanEnrichmentType2["HOSTNAME_FIRST_SEEN"] = "hostname_first_seen";
|
|
10237
|
+
AssetScanEnrichmentType2["TWITTER_POST"] = "post";
|
|
10238
|
+
AssetScanEnrichmentType2["TWITTER_PROFILE"] = "profile";
|
|
10239
|
+
AssetScanEnrichmentType2["TWITTER_FOLLOWERS"] = "twitter_followers";
|
|
10240
|
+
AssetScanEnrichmentType2["FARCASTER_CAST"] = "cast";
|
|
10241
|
+
AssetScanEnrichmentType2["FARCASTER_PROFILE"] = "farcaster_profile";
|
|
10242
|
+
AssetScanEnrichmentType2["FARCASTER_CHANNEL"] = "channel";
|
|
10243
|
+
AssetScanEnrichmentType2["FARCASTER_MINIAPP"] = "miniapp";
|
|
10244
|
+
AssetScanEnrichmentType2["TELEGRAM_PROFILE"] = "telegram_profile";
|
|
10245
|
+
AssetScanEnrichmentType2["INSTAGRAM_PROFILE"] = "instagram_profile";
|
|
10246
|
+
AssetScanEnrichmentType2["FACEBOOK_PROFILE"] = "facebook_profile";
|
|
10247
|
+
AssetScanEnrichmentType2["YOUTUBE_VIDEO"] = "youtube_video";
|
|
10248
|
+
AssetScanEnrichmentType2["YOUTUBE_CHANNEL"] = "youtube_channel";
|
|
10249
|
+
AssetScanEnrichmentType2["APPLE_APP_STORE_LISTING"] = "apple_app_store_listing";
|
|
10250
|
+
AssetScanEnrichmentType2["GOOGLE_PLAY_STORE_LISTING"] = "google_play_store_listing";
|
|
10251
|
+
AssetScanEnrichmentType2["MOZILLA_ADDON"] = "mozilla_addon";
|
|
10252
|
+
AssetScanEnrichmentType2["GITHUB_COMMENT"] = "github_comment";
|
|
10253
|
+
AssetScanEnrichmentType2["REDDIT_SUBREDDIT"] = "reddit_subreddit";
|
|
10254
|
+
AssetScanEnrichmentType2["EMAIL_VALIDATION"] = "email_validation";
|
|
10255
|
+
AssetScanEnrichmentType2["PHONE_LOOKUP"] = "phone_lookup";
|
|
10256
|
+
AssetScanEnrichmentType2["BILIBILI_VIDEO"] = "bilibili_video";
|
|
10257
|
+
AssetScanEnrichmentType2["BILIBILI_PROFILE"] = "bilibili_profile";
|
|
10258
|
+
AssetScanEnrichmentType2["DAILYMOTION_VIDEO"] = "dailymotion_video";
|
|
10259
|
+
AssetScanEnrichmentType2["VIMEO_VIDEO"] = "vimeo_video";
|
|
10260
|
+
AssetScanEnrichmentType2["VIMEO_PROFILE"] = "vimeo_profile";
|
|
10261
|
+
AssetScanEnrichmentType2["STACKBLITZ_PAGE"] = "stackblitz_page";
|
|
10262
|
+
AssetScanEnrichmentType2["LEETCODE_PAGE"] = "leetcode_page";
|
|
10263
|
+
AssetScanEnrichmentType2["TUMBLR_BLOG"] = "tumblr_blog";
|
|
10264
|
+
AssetScanEnrichmentType2["TUMBLR_POST"] = "tumblr_post";
|
|
10265
|
+
AssetScanEnrichmentType2["TUMBLR_COMMUNITY"] = "tumblr_community";
|
|
10266
|
+
AssetScanEnrichmentType2["NPM_PACKAGE"] = "npm_package";
|
|
10267
|
+
AssetScanEnrichmentType2["PYPI_PACKAGE"] = "pypi_package";
|
|
10268
|
+
AssetScanEnrichmentType2["RUST_PACKAGE"] = "rust_package";
|
|
10269
|
+
AssetScanEnrichmentType2["LINKEDIN_PROFILE"] = "linkedin_profile";
|
|
10270
|
+
AssetScanEnrichmentType2["PUMP_FUN_TOKEN"] = "pump_fun_token";
|
|
10271
|
+
AssetScanEnrichmentType2["META_AD"] = "meta_ad";
|
|
10272
|
+
AssetScanEnrichmentType2["GOOGLE_AD"] = "google_ad";
|
|
10273
|
+
AssetScanEnrichmentType2["ADLIBRARY_AD"] = "adlibrary_ad";
|
|
10274
|
+
AssetScanEnrichmentType2["CONTRACT_DEPLOYER"] = "contract_deployer";
|
|
10275
|
+
AssetScanEnrichmentType2["THREAT_INTEL"] = "threat_intel";
|
|
10276
|
+
AssetScanEnrichmentType2["LIST_MEMBERSHIP"] = "list_membership";
|
|
10277
|
+
AssetScanEnrichmentType2["THREAT_SCORE"] = "threat_score";
|
|
10278
|
+
return AssetScanEnrichmentType2;
|
|
10279
|
+
})(AssetScanEnrichmentType || {});
|
|
10280
|
+
var AssetScanEnrichmentSource = /* @__PURE__ */ ((AssetScanEnrichmentSource2) => {
|
|
10281
|
+
AssetScanEnrichmentSource2["URLSCAN"] = "urlscan";
|
|
10282
|
+
AssetScanEnrichmentSource2["WHOIS"] = "whois";
|
|
10283
|
+
AssetScanEnrichmentSource2["RDAP"] = "rdap";
|
|
10284
|
+
AssetScanEnrichmentSource2["HTTP_CONTENT"] = "http_content";
|
|
10285
|
+
AssetScanEnrichmentSource2["NETWORK"] = "node_js_network";
|
|
10286
|
+
AssetScanEnrichmentSource2["EXTENSION"] = "extension";
|
|
10287
|
+
AssetScanEnrichmentSource2["PLAYWRIGHT"] = "playwright";
|
|
10288
|
+
AssetScanEnrichmentSource2["CHAINPATROL_BROWSER"] = "chainpatrol_browser";
|
|
10289
|
+
AssetScanEnrichmentSource2["STEEL_BROWSER"] = "steel_browser";
|
|
10290
|
+
AssetScanEnrichmentSource2["X_API"] = "x_api";
|
|
10291
|
+
AssetScanEnrichmentSource2["SOCIALDATA_API"] = "socialdata_api";
|
|
10292
|
+
AssetScanEnrichmentSource2["NEYNAR_API"] = "neynar_api";
|
|
10293
|
+
AssetScanEnrichmentSource2["TELEGRAM_API"] = "telegram_api";
|
|
10294
|
+
AssetScanEnrichmentSource2["INSTAGRAM_API"] = "instagram_api";
|
|
10295
|
+
AssetScanEnrichmentSource2["FACEBOOK_API"] = "facebook_api";
|
|
10296
|
+
AssetScanEnrichmentSource2["YOUTUBE_API"] = "youtube_api";
|
|
10297
|
+
AssetScanEnrichmentSource2["APPLE_APP_STORE_API"] = "apple_app_store_api";
|
|
10298
|
+
AssetScanEnrichmentSource2["GOOGLE_PLAY_STORE_API"] = "google_play_store_api";
|
|
10299
|
+
AssetScanEnrichmentSource2["MOZILLA_ADDONS_API"] = "mozilla_addons_api";
|
|
10300
|
+
AssetScanEnrichmentSource2["GITHUB_API"] = "github_api";
|
|
10301
|
+
AssetScanEnrichmentSource2["REDDIT_API"] = "reddit_api";
|
|
10302
|
+
AssetScanEnrichmentSource2["MAILS_API"] = "mails_api";
|
|
10303
|
+
AssetScanEnrichmentSource2["TELNYX_LOOKUP"] = "telnyx_lookup";
|
|
10304
|
+
AssetScanEnrichmentSource2["TWILIO_LOOKUP"] = "twilio_lookup";
|
|
10305
|
+
AssetScanEnrichmentSource2["DAILYMOTION_API"] = "dailymotion_api";
|
|
10306
|
+
AssetScanEnrichmentSource2["VIMEO_API"] = "vimeo_api";
|
|
10307
|
+
AssetScanEnrichmentSource2["STACKBLITZ_API"] = "stackblitz_api";
|
|
10308
|
+
AssetScanEnrichmentSource2["LEETCODE_API"] = "leetcode_api";
|
|
10309
|
+
AssetScanEnrichmentSource2["TUMBLR_API"] = "tumblr_api";
|
|
10310
|
+
AssetScanEnrichmentSource2["NPM_REGISTRY_API"] = "npm_registry_api";
|
|
10311
|
+
AssetScanEnrichmentSource2["PYPI_REGISTRY_API"] = "pypi_registry_api";
|
|
10312
|
+
AssetScanEnrichmentSource2["CRATES_IO_API"] = "crates_io_api";
|
|
10313
|
+
AssetScanEnrichmentSource2["APIFY_LINKEDIN_API"] = "apify_linkedin_api";
|
|
10314
|
+
AssetScanEnrichmentSource2["PUMP_FUN_API"] = "pump_fun_api";
|
|
10315
|
+
AssetScanEnrichmentSource2["META_ADS_LIBRARY"] = "meta_ads_library";
|
|
10316
|
+
AssetScanEnrichmentSource2["STEEL_META_ADS_LIBRARY"] = "steel_meta_ads_library";
|
|
10317
|
+
AssetScanEnrichmentSource2["GOOGLE_ADS_TRANSPARENCY_CENTER"] = "google_ads_transparency_center";
|
|
10318
|
+
AssetScanEnrichmentSource2["ADLIBRARY"] = "adlibrary";
|
|
10319
|
+
AssetScanEnrichmentSource2["ETHERSCAN_API"] = "etherscan_api";
|
|
10320
|
+
AssetScanEnrichmentSource2["GOOGLE_WEB_RISK"] = "google_web_risk";
|
|
10321
|
+
AssetScanEnrichmentSource2["SEAL_ISAC"] = "seal_isac";
|
|
10322
|
+
AssetScanEnrichmentSource2["ETH_PHISHING_DETECT"] = "eth_phishing_detect";
|
|
10323
|
+
AssetScanEnrichmentSource2["POLKADOT_PHISHING"] = "polkadot_phishing";
|
|
10324
|
+
AssetScanEnrichmentSource2["TRANCO"] = "tranco";
|
|
10325
|
+
AssetScanEnrichmentSource2["UMBRELLA"] = "umbrella";
|
|
10326
|
+
AssetScanEnrichmentSource2["OPEN_PAGE_RANK"] = "open_page_rank";
|
|
10327
|
+
AssetScanEnrichmentSource2["DEFILLAMA"] = "defillama";
|
|
10328
|
+
AssetScanEnrichmentSource2["VERCEL_DOMAINS"] = "vercel_domains";
|
|
10329
|
+
return AssetScanEnrichmentSource2;
|
|
10330
|
+
})(AssetScanEnrichmentSource || {});
|
|
10331
|
+
var ASSET_SCAN_ENRICHMENT_TYPE_LABELS = {
|
|
10332
|
+
["content_and_metadata" /* CONTENT_AND_METADATA */]: "Content and Metadata",
|
|
10333
|
+
["post" /* TWITTER_POST */]: "Post",
|
|
10334
|
+
["profile" /* TWITTER_PROFILE */]: "Profile",
|
|
10335
|
+
["twitter_followers" /* TWITTER_FOLLOWERS */]: "Twitter Followers",
|
|
10336
|
+
["browser_capture" /* BROWSER_CAPTURE */]: "Browser Capture",
|
|
10337
|
+
["geolocation_and_ip" /* GEOLOCATION_AND_IP */]: "Geolocation and IP",
|
|
10338
|
+
["ownership_and_registration" /* OWNERSHIP_AND_REGISTRATION */]: "Ownership and Registration",
|
|
10339
|
+
["dns" /* DNS */]: "DNS Lookup",
|
|
10340
|
+
["tls" /* TLS */]: "TLS Connection Info",
|
|
10341
|
+
["tcp" /* TCP */]: "TCP Connection Info",
|
|
10342
|
+
["hostname_first_seen" /* HOSTNAME_FIRST_SEEN */]: "Hostname First Seen",
|
|
10343
|
+
// Farcaster
|
|
10344
|
+
["cast" /* FARCASTER_CAST */]: "Farcaster Cast",
|
|
10345
|
+
["farcaster_profile" /* FARCASTER_PROFILE */]: "Farcaster Profile",
|
|
10346
|
+
["channel" /* FARCASTER_CHANNEL */]: "Farcaster Channel",
|
|
10347
|
+
["miniapp" /* FARCASTER_MINIAPP */]: "Farcaster MiniApp",
|
|
10348
|
+
// Telegram
|
|
10349
|
+
["telegram_profile" /* TELEGRAM_PROFILE */]: "Telegram Profile",
|
|
10350
|
+
// Instagram
|
|
10351
|
+
["instagram_profile" /* INSTAGRAM_PROFILE */]: "Instagram Profile",
|
|
10352
|
+
// Facebook
|
|
10353
|
+
["facebook_profile" /* FACEBOOK_PROFILE */]: "Facebook Profile",
|
|
10354
|
+
// YouTube
|
|
10355
|
+
["youtube_video" /* YOUTUBE_VIDEO */]: "YouTube Video",
|
|
10356
|
+
["youtube_channel" /* YOUTUBE_CHANNEL */]: "YouTube Channel",
|
|
10357
|
+
// Apple App Store
|
|
10358
|
+
["apple_app_store_listing" /* APPLE_APP_STORE_LISTING */]: "Apple App Store Listing",
|
|
10359
|
+
// Google Play Store
|
|
10360
|
+
["google_play_store_listing" /* GOOGLE_PLAY_STORE_LISTING */]: "Google Play Store Listing",
|
|
10361
|
+
// Mozilla
|
|
10362
|
+
["mozilla_addon" /* MOZILLA_ADDON */]: "Mozilla Add-on",
|
|
10363
|
+
// GitHub
|
|
10364
|
+
["github_comment" /* GITHUB_COMMENT */]: "GitHub Comment",
|
|
10365
|
+
// Reddit
|
|
10366
|
+
["reddit_subreddit" /* REDDIT_SUBREDDIT */]: "Reddit Subreddit",
|
|
10367
|
+
// Email
|
|
10368
|
+
["email_validation" /* EMAIL_VALIDATION */]: "Email Validation",
|
|
10369
|
+
// Phone Number
|
|
10370
|
+
["phone_lookup" /* PHONE_LOOKUP */]: "Phone Lookup",
|
|
10371
|
+
// Bilibili
|
|
10372
|
+
["bilibili_video" /* BILIBILI_VIDEO */]: "Bilibili Video",
|
|
10373
|
+
["bilibili_profile" /* BILIBILI_PROFILE */]: "Bilibili Profile",
|
|
10374
|
+
// DailyMotion
|
|
10375
|
+
["dailymotion_video" /* DAILYMOTION_VIDEO */]: "DailyMotion Video",
|
|
10376
|
+
// Vimeo
|
|
10377
|
+
["vimeo_video" /* VIMEO_VIDEO */]: "Vimeo Video",
|
|
10378
|
+
["vimeo_profile" /* VIMEO_PROFILE */]: "Vimeo Profile",
|
|
10379
|
+
// Stackblitz
|
|
10380
|
+
["stackblitz_page" /* STACKBLITZ_PAGE */]: "Stackblitz Page",
|
|
10381
|
+
// Leetcode
|
|
10382
|
+
["leetcode_page" /* LEETCODE_PAGE */]: "Leetcode Page",
|
|
10383
|
+
// Tumblr
|
|
10384
|
+
["tumblr_blog" /* TUMBLR_BLOG */]: "Tumblr Blog",
|
|
10385
|
+
["tumblr_post" /* TUMBLR_POST */]: "Tumblr Post",
|
|
10386
|
+
["tumblr_community" /* TUMBLR_COMMUNITY */]: "Tumblr Community",
|
|
10387
|
+
// NPM
|
|
10388
|
+
["npm_package" /* NPM_PACKAGE */]: "NPM Package",
|
|
10389
|
+
// PyPI
|
|
10390
|
+
["pypi_package" /* PYPI_PACKAGE */]: "PyPI Package",
|
|
10391
|
+
// Rust Package
|
|
10392
|
+
["rust_package" /* RUST_PACKAGE */]: "Rust Package",
|
|
10393
|
+
// LinkedIn
|
|
10394
|
+
["linkedin_profile" /* LINKEDIN_PROFILE */]: "LinkedIn Profile",
|
|
10395
|
+
// Pump.fun
|
|
10396
|
+
["pump_fun_token" /* PUMP_FUN_TOKEN */]: "Pump.fun Token",
|
|
10397
|
+
// Meta Ads
|
|
10398
|
+
["meta_ad" /* META_AD */]: "Meta Ad",
|
|
10399
|
+
// Google Ads
|
|
10400
|
+
["google_ad" /* GOOGLE_AD */]: "Google Ad",
|
|
10401
|
+
// Cross-platform ad intelligence
|
|
10402
|
+
["adlibrary_ad" /* ADLIBRARY_AD */]: "AdLibrary Ad",
|
|
10403
|
+
// Crypto / Onchain
|
|
10404
|
+
["contract_deployer" /* CONTRACT_DEPLOYER */]: "Contract Deployer",
|
|
10405
|
+
// URL reputation
|
|
10406
|
+
["threat_intel" /* THREAT_INTEL */]: "Threat Intelligence",
|
|
10407
|
+
["list_membership" /* LIST_MEMBERSHIP */]: "List Membership",
|
|
10408
|
+
["threat_score" /* THREAT_SCORE */]: "Threat Score"
|
|
10409
|
+
};
|
|
10410
|
+
var ASSET_SCAN_ENRICHMENT_SOURCE_LABELS = {
|
|
10411
|
+
// URL
|
|
10412
|
+
["urlscan" /* URLSCAN */]: "URLScan",
|
|
10413
|
+
["whois" /* WHOIS */]: "Whois",
|
|
10414
|
+
["rdap" /* RDAP */]: "RDAP",
|
|
10415
|
+
["http_content" /* HTTP_CONTENT */]: "HTTP Content",
|
|
10416
|
+
["node_js_network" /* NETWORK */]: "Network",
|
|
10417
|
+
["extension" /* EXTENSION */]: "Browser Extension",
|
|
10418
|
+
["playwright" /* PLAYWRIGHT */]: "Playwright",
|
|
10419
|
+
["chainpatrol_browser" /* CHAINPATROL_BROWSER */]: "ChainPatrol Browser",
|
|
10420
|
+
["steel_browser" /* STEEL_BROWSER */]: "Steel Browser",
|
|
10421
|
+
// Twitter
|
|
10422
|
+
["x_api" /* X_API */]: "X API",
|
|
10423
|
+
["socialdata_api" /* SOCIALDATA_API */]: "SocialData API",
|
|
10424
|
+
// Farcaster
|
|
10425
|
+
["neynar_api" /* NEYNAR_API */]: "Neynar API",
|
|
10426
|
+
// Telegram
|
|
10427
|
+
["telegram_api" /* TELEGRAM_API */]: "Telegram API",
|
|
10428
|
+
// Instagram
|
|
10429
|
+
["instagram_api" /* INSTAGRAM_API */]: "Instagram API",
|
|
10430
|
+
// Facebook
|
|
10431
|
+
["facebook_api" /* FACEBOOK_API */]: "Facebook API",
|
|
10432
|
+
// YouTube
|
|
10433
|
+
["youtube_api" /* YOUTUBE_API */]: "YouTube API",
|
|
10434
|
+
// Apple App Store
|
|
10435
|
+
["apple_app_store_api" /* APPLE_APP_STORE_API */]: "Apple App Store API",
|
|
10436
|
+
// Google Play Store
|
|
10437
|
+
["google_play_store_api" /* GOOGLE_PLAY_STORE_API */]: "Google Play Store API",
|
|
10438
|
+
// Mozilla
|
|
10439
|
+
["mozilla_addons_api" /* MOZILLA_ADDONS_API */]: "Mozilla Add-ons API",
|
|
10440
|
+
// GitHub
|
|
10441
|
+
["github_api" /* GITHUB_API */]: "GitHub API",
|
|
10442
|
+
// Reddit
|
|
10443
|
+
["reddit_api" /* REDDIT_API */]: "Reddit API",
|
|
10444
|
+
// Email
|
|
10445
|
+
["mails_api" /* MAILS_API */]: "Mails.so API",
|
|
10446
|
+
// Phone Number
|
|
10447
|
+
["telnyx_lookup" /* TELNYX_LOOKUP */]: "Telnyx Lookup",
|
|
10448
|
+
["twilio_lookup" /* TWILIO_LOOKUP */]: "Twilio Lookup",
|
|
10449
|
+
// DailyMotion
|
|
10450
|
+
["dailymotion_api" /* DAILYMOTION_API */]: "DailyMotion API",
|
|
10451
|
+
// Vimeo
|
|
10452
|
+
["vimeo_api" /* VIMEO_API */]: "Vimeo API",
|
|
10453
|
+
// Stackblitz
|
|
10454
|
+
["stackblitz_api" /* STACKBLITZ_API */]: "Stackblitz API",
|
|
10455
|
+
// Leetcode
|
|
10456
|
+
["leetcode_api" /* LEETCODE_API */]: "Leetcode API",
|
|
10457
|
+
// Tumblr
|
|
10458
|
+
["tumblr_api" /* TUMBLR_API */]: "Tumblr API",
|
|
10459
|
+
// NPM
|
|
10460
|
+
["npm_registry_api" /* NPM_REGISTRY_API */]: "NPM Registry API",
|
|
10461
|
+
// PyPI
|
|
10462
|
+
["pypi_registry_api" /* PYPI_REGISTRY_API */]: "PyPI Registry API",
|
|
10463
|
+
// Rust Package
|
|
10464
|
+
["crates_io_api" /* CRATES_IO_API */]: "Crates.io API",
|
|
10465
|
+
// LinkedIn
|
|
10466
|
+
["apify_linkedin_api" /* APIFY_LINKEDIN_API */]: "Apify LinkedIn API",
|
|
10467
|
+
// Pump.fun
|
|
10468
|
+
["pump_fun_api" /* PUMP_FUN_API */]: "Pump.fun API",
|
|
10469
|
+
// Meta Ads
|
|
10470
|
+
["meta_ads_library" /* META_ADS_LIBRARY */]: "Meta Ads Library",
|
|
10471
|
+
["steel_meta_ads_library" /* STEEL_META_ADS_LIBRARY */]: "Steel Meta Ads Library",
|
|
10472
|
+
// Google Ads
|
|
10473
|
+
["google_ads_transparency_center" /* GOOGLE_ADS_TRANSPARENCY_CENTER */]: "Google Ads Transparency Center",
|
|
10474
|
+
// Cross-platform ad intelligence
|
|
10475
|
+
["adlibrary" /* ADLIBRARY */]: "AdLibrary",
|
|
10476
|
+
// Crypto / Onchain
|
|
10477
|
+
["etherscan_api" /* ETHERSCAN_API */]: "Etherscan",
|
|
10478
|
+
// URL reputation
|
|
10479
|
+
["google_web_risk" /* GOOGLE_WEB_RISK */]: "Google Web Risk",
|
|
10480
|
+
["seal_isac" /* SEAL_ISAC */]: "SEAL-ISAC",
|
|
10481
|
+
["eth_phishing_detect" /* ETH_PHISHING_DETECT */]: "eth-phishing-detect",
|
|
10482
|
+
["polkadot_phishing" /* POLKADOT_PHISHING */]: "Polkadot Phishing",
|
|
10483
|
+
["tranco" /* TRANCO */]: "Tranco",
|
|
10484
|
+
["umbrella" /* UMBRELLA */]: "Cisco Umbrella",
|
|
10485
|
+
["open_page_rank" /* OPEN_PAGE_RANK */]: "Open Page Rank",
|
|
10486
|
+
["defillama" /* DEFILLAMA */]: "DefiLlama",
|
|
10487
|
+
["vercel_domains" /* VERCEL_DOMAINS */]: "Vercel Domains"
|
|
10488
|
+
};
|
|
10489
|
+
var ASSET_SCAN_ENRICHMENT_SOURCE_TO_TYPES = {
|
|
10490
|
+
// URL-related sources
|
|
10491
|
+
["urlscan" /* URLSCAN */]: [
|
|
10492
|
+
"browser_capture" /* BROWSER_CAPTURE */,
|
|
10493
|
+
"geolocation_and_ip" /* GEOLOCATION_AND_IP */,
|
|
10494
|
+
"hostname_first_seen" /* HOSTNAME_FIRST_SEEN */
|
|
10495
|
+
],
|
|
10496
|
+
["whois" /* WHOIS */]: ["ownership_and_registration" /* OWNERSHIP_AND_REGISTRATION */],
|
|
10497
|
+
["rdap" /* RDAP */]: ["ownership_and_registration" /* OWNERSHIP_AND_REGISTRATION */],
|
|
10498
|
+
["http_content" /* HTTP_CONTENT */]: [
|
|
10499
|
+
"content_and_metadata" /* CONTENT_AND_METADATA */
|
|
10500
|
+
],
|
|
10501
|
+
["node_js_network" /* NETWORK */]: [
|
|
10502
|
+
"dns" /* DNS */,
|
|
10503
|
+
"tls" /* TLS */,
|
|
10504
|
+
"tcp" /* TCP */
|
|
10505
|
+
],
|
|
10506
|
+
["extension" /* EXTENSION */]: [
|
|
10507
|
+
"browser_capture" /* BROWSER_CAPTURE */,
|
|
10508
|
+
"telegram_profile" /* TELEGRAM_PROFILE */,
|
|
10509
|
+
"linkedin_profile" /* LINKEDIN_PROFILE */,
|
|
10510
|
+
"instagram_profile" /* INSTAGRAM_PROFILE */,
|
|
10511
|
+
"meta_ad" /* META_AD */
|
|
10512
|
+
],
|
|
10513
|
+
["playwright" /* PLAYWRIGHT */]: [
|
|
10514
|
+
"browser_capture" /* BROWSER_CAPTURE */,
|
|
10515
|
+
"bilibili_video" /* BILIBILI_VIDEO */,
|
|
10516
|
+
"bilibili_profile" /* BILIBILI_PROFILE */,
|
|
10517
|
+
"telegram_profile" /* TELEGRAM_PROFILE */
|
|
10518
|
+
],
|
|
10519
|
+
// Only the generic page capture: the in-house browser does not (yet) run the
|
|
10520
|
+
// platform-specific scrapes PLAYWRIGHT does above.
|
|
10521
|
+
["chainpatrol_browser" /* CHAINPATROL_BROWSER */]: [
|
|
10522
|
+
"browser_capture" /* BROWSER_CAPTURE */
|
|
10523
|
+
],
|
|
10524
|
+
["steel_browser" /* STEEL_BROWSER */]: ["browser_capture" /* BROWSER_CAPTURE */],
|
|
10525
|
+
// Twitter-related sources
|
|
10526
|
+
["x_api" /* X_API */]: [
|
|
10527
|
+
"post" /* TWITTER_POST */,
|
|
10528
|
+
"profile" /* TWITTER_PROFILE */,
|
|
10529
|
+
"twitter_followers" /* TWITTER_FOLLOWERS */
|
|
10530
|
+
],
|
|
10531
|
+
["socialdata_api" /* SOCIALDATA_API */]: [
|
|
10532
|
+
"post" /* TWITTER_POST */,
|
|
10533
|
+
"profile" /* TWITTER_PROFILE */,
|
|
10534
|
+
"twitter_followers" /* TWITTER_FOLLOWERS */
|
|
10535
|
+
],
|
|
10536
|
+
// Farcaster-related sources
|
|
10537
|
+
["neynar_api" /* NEYNAR_API */]: [
|
|
10538
|
+
"cast" /* FARCASTER_CAST */,
|
|
10539
|
+
"farcaster_profile" /* FARCASTER_PROFILE */,
|
|
10540
|
+
"channel" /* FARCASTER_CHANNEL */,
|
|
10541
|
+
"miniapp" /* FARCASTER_MINIAPP */
|
|
10542
|
+
],
|
|
10543
|
+
// Telegram-related sources
|
|
10544
|
+
["telegram_api" /* TELEGRAM_API */]: ["telegram_profile" /* TELEGRAM_PROFILE */],
|
|
10545
|
+
// Instagram-related sources
|
|
10546
|
+
["instagram_api" /* INSTAGRAM_API */]: ["instagram_profile" /* INSTAGRAM_PROFILE */],
|
|
10547
|
+
// Facebook-related sources
|
|
10548
|
+
["facebook_api" /* FACEBOOK_API */]: ["facebook_profile" /* FACEBOOK_PROFILE */],
|
|
10549
|
+
// YouTube-related sources
|
|
10550
|
+
["youtube_api" /* YOUTUBE_API */]: [
|
|
10551
|
+
"youtube_video" /* YOUTUBE_VIDEO */,
|
|
10552
|
+
"youtube_channel" /* YOUTUBE_CHANNEL */
|
|
10553
|
+
],
|
|
10554
|
+
// Apple App Store-related sources
|
|
10555
|
+
["apple_app_store_api" /* APPLE_APP_STORE_API */]: [
|
|
10556
|
+
"apple_app_store_listing" /* APPLE_APP_STORE_LISTING */
|
|
10557
|
+
],
|
|
10558
|
+
// Google Play Store-related sources
|
|
10559
|
+
["google_play_store_api" /* GOOGLE_PLAY_STORE_API */]: [
|
|
10560
|
+
"google_play_store_listing" /* GOOGLE_PLAY_STORE_LISTING */
|
|
10561
|
+
],
|
|
10562
|
+
// Mozilla-related sources
|
|
10563
|
+
["mozilla_addons_api" /* MOZILLA_ADDONS_API */]: ["mozilla_addon" /* MOZILLA_ADDON */],
|
|
10564
|
+
// GitHub-related sources
|
|
10565
|
+
["github_api" /* GITHUB_API */]: ["github_comment" /* GITHUB_COMMENT */],
|
|
10566
|
+
// Reddit-related sources
|
|
10567
|
+
["reddit_api" /* REDDIT_API */]: ["reddit_subreddit" /* REDDIT_SUBREDDIT */],
|
|
10568
|
+
// Email-related sources
|
|
10569
|
+
["mails_api" /* MAILS_API */]: ["email_validation" /* EMAIL_VALIDATION */],
|
|
10570
|
+
// Phone Number-related sources
|
|
10571
|
+
["telnyx_lookup" /* TELNYX_LOOKUP */]: ["phone_lookup" /* PHONE_LOOKUP */],
|
|
10572
|
+
["twilio_lookup" /* TWILIO_LOOKUP */]: ["phone_lookup" /* PHONE_LOOKUP */],
|
|
10573
|
+
// DailyMotion-related sources
|
|
10574
|
+
["dailymotion_api" /* DAILYMOTION_API */]: [
|
|
10575
|
+
"dailymotion_video" /* DAILYMOTION_VIDEO */
|
|
10576
|
+
],
|
|
10577
|
+
// Vimeo-related sources
|
|
10578
|
+
["vimeo_api" /* VIMEO_API */]: [
|
|
10579
|
+
"vimeo_video" /* VIMEO_VIDEO */,
|
|
10580
|
+
"vimeo_profile" /* VIMEO_PROFILE */
|
|
10581
|
+
],
|
|
10582
|
+
// Stackblitz-related sources
|
|
10583
|
+
["stackblitz_api" /* STACKBLITZ_API */]: ["stackblitz_page" /* STACKBLITZ_PAGE */],
|
|
10584
|
+
// Leetcode-related sources
|
|
10585
|
+
["leetcode_api" /* LEETCODE_API */]: ["leetcode_page" /* LEETCODE_PAGE */],
|
|
10586
|
+
// Tumblr-related sources
|
|
10587
|
+
["tumblr_api" /* TUMBLR_API */]: [
|
|
10588
|
+
"tumblr_blog" /* TUMBLR_BLOG */,
|
|
10589
|
+
"tumblr_post" /* TUMBLR_POST */,
|
|
10590
|
+
"tumblr_community" /* TUMBLR_COMMUNITY */
|
|
10591
|
+
],
|
|
10592
|
+
// NPM-related sources
|
|
10593
|
+
["npm_registry_api" /* NPM_REGISTRY_API */]: ["npm_package" /* NPM_PACKAGE */],
|
|
10594
|
+
// PyPI-related sources
|
|
10595
|
+
["pypi_registry_api" /* PYPI_REGISTRY_API */]: ["pypi_package" /* PYPI_PACKAGE */],
|
|
10596
|
+
// Rust Package-related sources
|
|
10597
|
+
["crates_io_api" /* CRATES_IO_API */]: ["rust_package" /* RUST_PACKAGE */],
|
|
10598
|
+
// LinkedIn-related sources
|
|
10599
|
+
["apify_linkedin_api" /* APIFY_LINKEDIN_API */]: [
|
|
10600
|
+
"linkedin_profile" /* LINKEDIN_PROFILE */
|
|
10601
|
+
],
|
|
10602
|
+
// Pump.fun
|
|
10603
|
+
["pump_fun_api" /* PUMP_FUN_API */]: ["pump_fun_token" /* PUMP_FUN_TOKEN */],
|
|
10604
|
+
// Meta Ads-related sources
|
|
10605
|
+
["meta_ads_library" /* META_ADS_LIBRARY */]: ["meta_ad" /* META_AD */],
|
|
10606
|
+
["steel_meta_ads_library" /* STEEL_META_ADS_LIBRARY */]: ["meta_ad" /* META_AD */],
|
|
10607
|
+
// Google Ads-related sources
|
|
10608
|
+
["google_ads_transparency_center" /* GOOGLE_ADS_TRANSPARENCY_CENTER */]: [
|
|
10609
|
+
"google_ad" /* GOOGLE_AD */
|
|
10610
|
+
],
|
|
10611
|
+
// Cross-platform ad intelligence sources
|
|
10612
|
+
["adlibrary" /* ADLIBRARY */]: ["adlibrary_ad" /* ADLIBRARY_AD */],
|
|
10613
|
+
// Crypto / Onchain sources
|
|
10614
|
+
["etherscan_api" /* ETHERSCAN_API */]: ["contract_deployer" /* CONTRACT_DEPLOYER */],
|
|
10615
|
+
// URL reputation
|
|
10616
|
+
["google_web_risk" /* GOOGLE_WEB_RISK */]: ["threat_score" /* THREAT_SCORE */],
|
|
10617
|
+
["seal_isac" /* SEAL_ISAC */]: ["threat_intel" /* THREAT_INTEL */],
|
|
10618
|
+
["eth_phishing_detect" /* ETH_PHISHING_DETECT */]: ["threat_intel" /* THREAT_INTEL */],
|
|
10619
|
+
["polkadot_phishing" /* POLKADOT_PHISHING */]: ["threat_intel" /* THREAT_INTEL */],
|
|
10620
|
+
["tranco" /* TRANCO */]: ["list_membership" /* LIST_MEMBERSHIP */],
|
|
10621
|
+
["umbrella" /* UMBRELLA */]: ["list_membership" /* LIST_MEMBERSHIP */],
|
|
10622
|
+
["open_page_rank" /* OPEN_PAGE_RANK */]: ["list_membership" /* LIST_MEMBERSHIP */],
|
|
10623
|
+
["defillama" /* DEFILLAMA */]: ["list_membership" /* LIST_MEMBERSHIP */],
|
|
10624
|
+
["vercel_domains" /* VERCEL_DOMAINS */]: ["list_membership" /* LIST_MEMBERSHIP */]
|
|
10625
|
+
};
|
|
10230
10626
|
|
|
10231
|
-
//
|
|
10232
|
-
var
|
|
10233
|
-
|
|
10234
|
-
|
|
10235
|
-
|
|
10236
|
-
|
|
10237
|
-
|
|
10238
|
-
|
|
10239
|
-
|
|
10240
|
-
|
|
10241
|
-
|
|
10242
|
-
|
|
10243
|
-
|
|
10244
|
-
|
|
10245
|
-
|
|
10246
|
-
|
|
10247
|
-
|
|
10248
|
-
AssetModel2["Discussion"] = "discussion";
|
|
10249
|
-
AssetModel2["Repository"] = "repository";
|
|
10250
|
-
AssetModel2["Article"] = "Article";
|
|
10251
|
-
AssetModel2["Comment"] = "comment";
|
|
10252
|
-
AssetModel2["List"] = "list";
|
|
10253
|
-
AssetModel2["Subreddit"] = "subreddit";
|
|
10254
|
-
AssetModel2["Community"] = "community";
|
|
10255
|
-
AssetModel2["MiniApp"] = "mini-app";
|
|
10256
|
-
AssetModel2["Developer"] = "developer";
|
|
10257
|
-
return AssetModel2;
|
|
10258
|
-
})(AssetModel || {});
|
|
10259
|
-
function isUrl(input) {
|
|
10260
|
-
if (input.trim() === "") {
|
|
10261
|
-
return false;
|
|
10262
|
-
}
|
|
10263
|
-
if (input.startsWith("/") || input.startsWith("#") || input.startsWith("?") || input.startsWith(".") || !input.includes(".")) {
|
|
10264
|
-
return false;
|
|
10265
|
-
}
|
|
10266
|
-
return URL.canParse(input) || URL.canParse(`https://${input}`);
|
|
10267
|
-
}
|
|
10268
|
-
function getNormalizedUrl(input) {
|
|
10269
|
-
if (!isUrl(input)) {
|
|
10270
|
-
throw new Error(`Invalid URL: ${input}`);
|
|
10271
|
-
}
|
|
10272
|
-
let url;
|
|
10273
|
-
try {
|
|
10274
|
-
url = new URL(input);
|
|
10275
|
-
} catch (e4) {
|
|
10276
|
-
try {
|
|
10277
|
-
url = new URL(`https://${input}`);
|
|
10278
|
-
} catch (e5) {
|
|
10279
|
-
throw new Error(`Invalid URL: ${input}`);
|
|
10280
|
-
}
|
|
10281
|
-
}
|
|
10282
|
-
const normalizedUrl = normalizeUrl(url.toString(), {
|
|
10283
|
-
defaultProtocol: "https"
|
|
10284
|
-
});
|
|
10285
|
-
try {
|
|
10286
|
-
return new URL(normalizedUrl);
|
|
10287
|
-
} catch (e4) {
|
|
10288
|
-
throw new Error(`Invalid URL: ${input}`);
|
|
10289
|
-
}
|
|
10290
|
-
}
|
|
10291
|
-
var ensureHttpsPrefix = (url) => {
|
|
10292
|
-
if (!url.startsWith("http")) {
|
|
10293
|
-
return `https://${url}`;
|
|
10294
|
-
}
|
|
10295
|
-
return url.replace(/^https?:\/{1,2}/, "https://");
|
|
10296
|
-
};
|
|
10297
|
-
function getHostname(input) {
|
|
10298
|
-
try {
|
|
10299
|
-
return getNormalizedUrl(input).hostname;
|
|
10300
|
-
} catch (e4) {
|
|
10301
|
-
return null;
|
|
10302
|
-
}
|
|
10303
|
-
}
|
|
10304
|
-
function getParentDomains(input) {
|
|
10305
|
-
const domain = getHostname(input);
|
|
10306
|
-
if (!domain) {
|
|
10307
|
-
return [];
|
|
10308
|
-
}
|
|
10309
|
-
const subdomain = tldts.getSubdomain(domain, { mixedInputs: false });
|
|
10310
|
-
if (!subdomain) {
|
|
10311
|
-
return [domain];
|
|
10312
|
-
}
|
|
10313
|
-
const domainWithSuffix = tldts.getDomain(domain, { mixedInputs: false });
|
|
10314
|
-
if (!domainWithSuffix) {
|
|
10315
|
-
return [];
|
|
10316
|
-
}
|
|
10317
|
-
const parentDomains = [domainWithSuffix];
|
|
10318
|
-
const parentDomainParts = subdomain.split(".");
|
|
10319
|
-
for (let i = parentDomainParts.length - 1; i >= 0; i--) {
|
|
10320
|
-
const parentDomainPart = parentDomainParts.slice(i).join(".");
|
|
10321
|
-
parentDomains.push(`${parentDomainPart}.${domainWithSuffix}`);
|
|
10322
|
-
}
|
|
10323
|
-
return parentDomains.reverse();
|
|
10627
|
+
// ../../internal/utils/src/array.ts
|
|
10628
|
+
var array_exports = {};
|
|
10629
|
+
__export(array_exports, {
|
|
10630
|
+
arraysEqual: () => arraysEqual,
|
|
10631
|
+
chunkArray: () => chunkArray,
|
|
10632
|
+
combineAndRemoveDuplicatesByKey: () => combineAndRemoveDuplicatesByKey,
|
|
10633
|
+
isArray: () => isArray,
|
|
10634
|
+
isEmptyArray: () => isEmptyArray,
|
|
10635
|
+
isNonEmptyArray: () => isNonEmptyArray,
|
|
10636
|
+
randomElement: () => randomElement,
|
|
10637
|
+
randomIndex: () => randomIndex,
|
|
10638
|
+
removeDuplicates: () => removeDuplicates,
|
|
10639
|
+
shuffleInPlace: () => shuffleInPlace,
|
|
10640
|
+
shuffled: () => shuffled
|
|
10641
|
+
});
|
|
10642
|
+
function isArray(value) {
|
|
10643
|
+
return Array.isArray(value);
|
|
10324
10644
|
}
|
|
10325
|
-
function
|
|
10326
|
-
|
|
10327
|
-
const parsed = tldts.parse(domain);
|
|
10328
|
-
const eTLDPlusOne = (_a = parsed.domain) != null ? _a : "";
|
|
10329
|
-
const subdomains = domain.replace(/https?:\/\/(www\.)?/, "").split(".");
|
|
10330
|
-
const eTLDPlusOneIndex = subdomains.findIndex(
|
|
10331
|
-
(_, i) => subdomains.slice(i).join(".") === eTLDPlusOne
|
|
10332
|
-
);
|
|
10333
|
-
const trimmedSubdomains = subdomains.slice(Math.max(eTLDPlusOneIndex - (options.levels - 1), 0)).join(".");
|
|
10334
|
-
return trimmedSubdomains;
|
|
10645
|
+
function isEmptyArray(value) {
|
|
10646
|
+
return value.length === 0;
|
|
10335
10647
|
}
|
|
10336
|
-
|
|
10337
|
-
|
|
10338
|
-
var phone_exports = {};
|
|
10339
|
-
__export(phone_exports, {
|
|
10340
|
-
PHONE_NUMBER_REGEX: () => PHONE_NUMBER_REGEX,
|
|
10341
|
-
isPhoneNumber: () => isPhoneNumber,
|
|
10342
|
-
normalizePhoneNumber: () => normalizePhoneNumber
|
|
10343
|
-
});
|
|
10344
|
-
var PHONE_NUMBER_REGEX = /(?:\+?\d{1,4}[\s.-]?)?(?:\(\d{1,4}\)|\d{1,4})[\s.-]?\d{1,4}[\s.-]?\d{1,4}[\s.-]?\d{0,4}(?:\s*(?:ext|x|extension)[\s.]*\d{1,6})?/gi;
|
|
10345
|
-
function preparePhoneInput(input) {
|
|
10346
|
-
let s2 = input.trim();
|
|
10347
|
-
s2 = s2.replace(/^\s*tel:\s*(?:\/\/)?\s*/i, "");
|
|
10348
|
-
s2 = s2.trim();
|
|
10349
|
-
s2 = s2.replace(/[\u00A0\u2000-\u200A\u202F\u205F\u3000]/g, " ");
|
|
10350
|
-
s2 = s2.replace(/[\u2010\u2011\u2012\u2013\u2014\u2015\u2212\uFE58\uFE63\uFF0D]/g, "-");
|
|
10351
|
-
s2 = s2.replace(/\uFF0B/g, "+");
|
|
10352
|
-
s2 = s2.replace(/\uFF08/g, "(");
|
|
10353
|
-
s2 = s2.replace(/\uFF09/g, ")");
|
|
10354
|
-
return s2.trim();
|
|
10648
|
+
function isNonEmptyArray(value) {
|
|
10649
|
+
return value.length > 0;
|
|
10355
10650
|
}
|
|
10356
|
-
function
|
|
10357
|
-
return
|
|
10651
|
+
function randomIndex(array) {
|
|
10652
|
+
return Math.floor(Math.random() * array.length);
|
|
10358
10653
|
}
|
|
10359
|
-
function
|
|
10360
|
-
|
|
10361
|
-
return false;
|
|
10362
|
-
}
|
|
10363
|
-
let increasing = true;
|
|
10364
|
-
let decreasing = true;
|
|
10365
|
-
for (let i = 1; i < digits2.length; i++) {
|
|
10366
|
-
const curr = digits2.charCodeAt(i) - 48;
|
|
10367
|
-
const prev = digits2.charCodeAt(i - 1) - 48;
|
|
10368
|
-
if (curr !== prev + 1) {
|
|
10369
|
-
increasing = false;
|
|
10370
|
-
}
|
|
10371
|
-
if (curr !== prev - 1) {
|
|
10372
|
-
decreasing = false;
|
|
10373
|
-
}
|
|
10374
|
-
}
|
|
10375
|
-
return increasing || decreasing;
|
|
10654
|
+
function randomElement(array) {
|
|
10655
|
+
return array[randomIndex(array)];
|
|
10376
10656
|
}
|
|
10377
|
-
function
|
|
10378
|
-
|
|
10379
|
-
return false;
|
|
10380
|
-
}
|
|
10381
|
-
const npaFirst = d10.charCodeAt(0) - 48;
|
|
10382
|
-
const nxxFirst = d10.charCodeAt(3) - 48;
|
|
10383
|
-
if (npaFirst < 2 || npaFirst > 9) {
|
|
10384
|
-
return false;
|
|
10385
|
-
}
|
|
10386
|
-
if (nxxFirst < 2 || nxxFirst > 9) {
|
|
10387
|
-
return false;
|
|
10388
|
-
}
|
|
10389
|
-
return true;
|
|
10657
|
+
function removeDuplicates(array) {
|
|
10658
|
+
return Array.from(new Set(array));
|
|
10390
10659
|
}
|
|
10391
|
-
function
|
|
10392
|
-
const
|
|
10393
|
-
const
|
|
10394
|
-
|
|
10395
|
-
|
|
10396
|
-
|
|
10397
|
-
if (isAllSameDigit(d) || isStrictlyMonotonicStep1(d)) {
|
|
10398
|
-
return false;
|
|
10399
|
-
}
|
|
10400
|
-
const onlyDigits = /^\d+$/.test(withoutExt);
|
|
10401
|
-
if (hasPlus) {
|
|
10402
|
-
if (d.length === 11 && d.startsWith("1")) {
|
|
10403
|
-
return isValidNanpNational10(d.slice(1));
|
|
10404
|
-
}
|
|
10405
|
-
return true;
|
|
10406
|
-
}
|
|
10407
|
-
if (onlyDigits) {
|
|
10408
|
-
if (d.length === 10) {
|
|
10409
|
-
return isValidNanpNational10(d);
|
|
10410
|
-
}
|
|
10411
|
-
if (d.length === 11 && d.startsWith("1")) {
|
|
10412
|
-
return isValidNanpNational10(d.slice(1));
|
|
10413
|
-
}
|
|
10414
|
-
if (d.length === 11 && d.startsWith("0")) {
|
|
10415
|
-
return true;
|
|
10416
|
-
}
|
|
10417
|
-
return false;
|
|
10418
|
-
}
|
|
10419
|
-
if (d.length === 10) {
|
|
10420
|
-
return isValidNanpNational10(d);
|
|
10421
|
-
}
|
|
10422
|
-
if (d.length === 11 && d.startsWith("1")) {
|
|
10423
|
-
return isValidNanpNational10(d.slice(1));
|
|
10424
|
-
}
|
|
10425
|
-
if (d.length === 11 && d.startsWith("0")) {
|
|
10426
|
-
return true;
|
|
10427
|
-
}
|
|
10428
|
-
if (d.length >= 12 && d.length <= 15) {
|
|
10429
|
-
return true;
|
|
10430
|
-
}
|
|
10431
|
-
return false;
|
|
10660
|
+
function combineAndRemoveDuplicatesByKey(arr1, arr2, uniqueKey) {
|
|
10661
|
+
const combinedArray = [...arr1, ...arr2];
|
|
10662
|
+
const uniqueObjects = new Map(
|
|
10663
|
+
combinedArray.map((item) => [item[uniqueKey], item])
|
|
10664
|
+
);
|
|
10665
|
+
return Array.from(uniqueObjects.values());
|
|
10432
10666
|
}
|
|
10433
|
-
function
|
|
10434
|
-
const
|
|
10435
|
-
|
|
10436
|
-
|
|
10437
|
-
}
|
|
10438
|
-
if (!/^[+\d(]/.test(trimmed)) {
|
|
10439
|
-
return false;
|
|
10440
|
-
}
|
|
10441
|
-
const withoutExt = trimmed.replace(/\s*(ext|extension|x)\s*\d+$/i, "");
|
|
10442
|
-
if (/[a-zA-Z]/.test(withoutExt)) {
|
|
10443
|
-
return false;
|
|
10444
|
-
}
|
|
10445
|
-
const hasPhoneMarker = /[+()\s-]/.test(trimmed);
|
|
10446
|
-
const isPureDotSeparated = /^\d+(\.\d+)+$/.test(trimmed);
|
|
10447
|
-
if (isPureDotSeparated && !hasPhoneMarker) {
|
|
10448
|
-
return false;
|
|
10667
|
+
function chunkArray(array, chunkSize) {
|
|
10668
|
+
const chunks = [];
|
|
10669
|
+
for (let i = 0; i < array.length; i += chunkSize) {
|
|
10670
|
+
chunks.push(array.slice(i, i + chunkSize));
|
|
10449
10671
|
}
|
|
10450
|
-
|
|
10451
|
-
|
|
10452
|
-
|
|
10672
|
+
return chunks;
|
|
10673
|
+
}
|
|
10674
|
+
function shuffleInPlace(array) {
|
|
10675
|
+
for (let i = array.length - 1; i > 0; i--) {
|
|
10676
|
+
const j = Math.floor(Math.random() * (i + 1));
|
|
10677
|
+
[array[i], array[j]] = [array[j], array[i]];
|
|
10453
10678
|
}
|
|
10454
|
-
return isPlausiblePhoneDigits(withoutExt);
|
|
10455
10679
|
}
|
|
10456
|
-
function
|
|
10457
|
-
const
|
|
10458
|
-
|
|
10459
|
-
|
|
10460
|
-
const digitsOnly = withoutExt.replace(/\D/g, "");
|
|
10461
|
-
return hasPlus ? `+${digitsOnly}` : digitsOnly;
|
|
10680
|
+
function shuffled(array) {
|
|
10681
|
+
const newArray = array.slice();
|
|
10682
|
+
shuffleInPlace(newArray);
|
|
10683
|
+
return newArray;
|
|
10462
10684
|
}
|
|
10463
|
-
|
|
10464
|
-
|
|
10465
|
-
|
|
10466
|
-
|
|
10467
|
-
|
|
10468
|
-
var tMax = 26;
|
|
10469
|
-
var skew = 38;
|
|
10470
|
-
var damp = 700;
|
|
10471
|
-
var initialBias = 72;
|
|
10472
|
-
var initialN = 128;
|
|
10473
|
-
var delimiter = "-";
|
|
10474
|
-
var regexPunycode = /^xn--/;
|
|
10475
|
-
var regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g;
|
|
10476
|
-
var errors = {
|
|
10477
|
-
overflow: "Overflow: input needs wider integers to process",
|
|
10478
|
-
"not-basic": "Illegal input >= 0x80 (not a basic code point)",
|
|
10479
|
-
"invalid-input": "Invalid input"
|
|
10480
|
-
};
|
|
10481
|
-
var baseMinusTMin = base - tMin;
|
|
10482
|
-
var floor = Math.floor;
|
|
10483
|
-
function error(type) {
|
|
10484
|
-
throw new RangeError(errors[type]);
|
|
10685
|
+
function arraysEqual(a, b) {
|
|
10686
|
+
if (a.length !== b.length) return false;
|
|
10687
|
+
const sortedA = [...a].sort();
|
|
10688
|
+
const sortedB = [...b].sort();
|
|
10689
|
+
return sortedA.every((val, idx) => val === sortedB[idx]);
|
|
10485
10690
|
}
|
|
10486
|
-
|
|
10487
|
-
|
|
10488
|
-
|
|
10489
|
-
|
|
10490
|
-
|
|
10491
|
-
|
|
10691
|
+
|
|
10692
|
+
// ../../internal/utils/src/cron.ts
|
|
10693
|
+
var cron_exports = {};
|
|
10694
|
+
__export(cron_exports, {
|
|
10695
|
+
cronToHumanReadable: () => cronToHumanReadable,
|
|
10696
|
+
isValidCronExpression: () => isValidCronExpression
|
|
10697
|
+
});
|
|
10698
|
+
var WEEKDAYS = [
|
|
10699
|
+
"Sunday",
|
|
10700
|
+
"Monday",
|
|
10701
|
+
"Tuesday",
|
|
10702
|
+
"Wednesday",
|
|
10703
|
+
"Thursday",
|
|
10704
|
+
"Friday",
|
|
10705
|
+
"Saturday"
|
|
10706
|
+
];
|
|
10707
|
+
var MONTHS = [
|
|
10708
|
+
"January",
|
|
10709
|
+
"February",
|
|
10710
|
+
"March",
|
|
10711
|
+
"April",
|
|
10712
|
+
"May",
|
|
10713
|
+
"June",
|
|
10714
|
+
"July",
|
|
10715
|
+
"August",
|
|
10716
|
+
"September",
|
|
10717
|
+
"October",
|
|
10718
|
+
"November",
|
|
10719
|
+
"December"
|
|
10720
|
+
];
|
|
10721
|
+
function cronToHumanReadable(cronExpression) {
|
|
10722
|
+
const [minute, hour, dayOfMonth, month, dayOfWeek2] = cronExpression.split(" ");
|
|
10723
|
+
let result = "Runs ";
|
|
10724
|
+
if (minute === "*") {
|
|
10725
|
+
result += "every minute ";
|
|
10726
|
+
} else if (minute.includes("/")) {
|
|
10727
|
+
const [, interval] = minute.split("/");
|
|
10728
|
+
result += `every ${interval} minutes `;
|
|
10729
|
+
} else {
|
|
10730
|
+
result += `at minute ${minute} `;
|
|
10492
10731
|
}
|
|
10493
|
-
|
|
10494
|
-
|
|
10495
|
-
const encoded = labels.map(callback).join(".");
|
|
10496
|
-
return result + encoded;
|
|
10497
|
-
}
|
|
10498
|
-
function basicToDigit(codePoint) {
|
|
10499
|
-
if (codePoint >= 48 && codePoint < 58) {
|
|
10500
|
-
return 26 + (codePoint - 48);
|
|
10732
|
+
if (hour !== "*") {
|
|
10733
|
+
result += `past hour ${hour} `;
|
|
10501
10734
|
}
|
|
10502
|
-
if (
|
|
10503
|
-
|
|
10735
|
+
if (dayOfMonth !== "*") {
|
|
10736
|
+
result += `on the ${dayOfMonth}${getDaySuffix(
|
|
10737
|
+
parseInt(dayOfMonth)
|
|
10738
|
+
)} day of the month `;
|
|
10504
10739
|
}
|
|
10505
|
-
if (
|
|
10506
|
-
|
|
10740
|
+
if (month !== "*") {
|
|
10741
|
+
const monthNames = month.split(",").map((m) => MONTHS[parseInt(m) - 1]);
|
|
10742
|
+
result += `in ${monthNames.join(", ")} `;
|
|
10507
10743
|
}
|
|
10508
|
-
|
|
10509
|
-
|
|
10510
|
-
|
|
10511
|
-
let k4 = 0;
|
|
10512
|
-
delta = firstTime ? floor(delta / damp) : delta >> 1;
|
|
10513
|
-
delta += floor(delta / numPoints);
|
|
10514
|
-
for (
|
|
10515
|
-
;
|
|
10516
|
-
/* no initialization */
|
|
10517
|
-
delta > baseMinusTMin * tMax >> 1;
|
|
10518
|
-
k4 += base
|
|
10519
|
-
) {
|
|
10520
|
-
delta = floor(delta / baseMinusTMin);
|
|
10744
|
+
if (dayOfWeek2 !== "*") {
|
|
10745
|
+
const dayNames = dayOfWeek2.split(",").map((d) => WEEKDAYS[parseInt(d)]);
|
|
10746
|
+
result += `on ${dayNames.join(", ")}`;
|
|
10521
10747
|
}
|
|
10522
|
-
return
|
|
10748
|
+
return result.trim();
|
|
10523
10749
|
}
|
|
10524
|
-
function
|
|
10525
|
-
|
|
10526
|
-
|
|
10527
|
-
let i = 0;
|
|
10528
|
-
let n2 = initialN;
|
|
10529
|
-
let bias2 = initialBias;
|
|
10530
|
-
let basic = input.lastIndexOf(delimiter);
|
|
10531
|
-
if (basic < 0) {
|
|
10532
|
-
basic = 0;
|
|
10533
|
-
}
|
|
10534
|
-
for (let j = 0; j < basic; ++j) {
|
|
10535
|
-
if (input.charCodeAt(j) >= 128) {
|
|
10536
|
-
error("not-basic");
|
|
10537
|
-
}
|
|
10538
|
-
output.push(input.charCodeAt(j));
|
|
10750
|
+
function getDaySuffix(day) {
|
|
10751
|
+
if (day >= 11 && day <= 13) {
|
|
10752
|
+
return "th";
|
|
10539
10753
|
}
|
|
10540
|
-
|
|
10541
|
-
|
|
10542
|
-
|
|
10543
|
-
|
|
10544
|
-
|
|
10545
|
-
|
|
10546
|
-
|
|
10547
|
-
|
|
10548
|
-
|
|
10549
|
-
}
|
|
10550
|
-
if (digit > floor((maxInt - i) / w)) {
|
|
10551
|
-
error("overflow");
|
|
10552
|
-
}
|
|
10553
|
-
i += digit * w;
|
|
10554
|
-
const t = k4 <= bias2 ? tMin : k4 >= bias2 + tMax ? tMax : k4 - bias2;
|
|
10555
|
-
if (digit < t) {
|
|
10556
|
-
break;
|
|
10557
|
-
}
|
|
10558
|
-
const baseMinusT = base - t;
|
|
10559
|
-
if (w > floor(maxInt / baseMinusT)) {
|
|
10560
|
-
error("overflow");
|
|
10561
|
-
}
|
|
10562
|
-
w *= baseMinusT;
|
|
10563
|
-
}
|
|
10564
|
-
const out = output.length + 1;
|
|
10565
|
-
bias2 = adapt(i - oldi, out, oldi == 0);
|
|
10566
|
-
if (floor(i / out) > maxInt - n2) {
|
|
10567
|
-
error("overflow");
|
|
10568
|
-
}
|
|
10569
|
-
n2 += floor(i / out);
|
|
10570
|
-
i %= out;
|
|
10571
|
-
output.splice(i++, 0, n2);
|
|
10754
|
+
switch (day % 10) {
|
|
10755
|
+
case 1:
|
|
10756
|
+
return "st";
|
|
10757
|
+
case 2:
|
|
10758
|
+
return "nd";
|
|
10759
|
+
case 3:
|
|
10760
|
+
return "rd";
|
|
10761
|
+
default:
|
|
10762
|
+
return "th";
|
|
10572
10763
|
}
|
|
10573
|
-
return String.fromCodePoint(...output);
|
|
10574
|
-
}
|
|
10575
|
-
function toUnicode(input) {
|
|
10576
|
-
return mapDomain(input, function(string) {
|
|
10577
|
-
return regexPunycode.test(string) ? decode(string.slice(4).toLowerCase()) : string;
|
|
10578
|
-
});
|
|
10579
10764
|
}
|
|
10580
|
-
|
|
10581
|
-
|
|
10582
|
-
function isEmail(input) {
|
|
10583
|
-
if (input.trim() === "") {
|
|
10765
|
+
function isValidCronExpression(cronExpression) {
|
|
10766
|
+
if (!cronExpression || typeof cronExpression !== "string") {
|
|
10584
10767
|
return false;
|
|
10585
10768
|
}
|
|
10586
|
-
const
|
|
10587
|
-
|
|
10588
|
-
|
|
10589
|
-
function removeHttpProtocol(input) {
|
|
10590
|
-
return input.replace(/^https?:\/\//, "");
|
|
10591
|
-
}
|
|
10592
|
-
function stripDomainWildcardPrefix(domain) {
|
|
10593
|
-
const trimmedDomain = domain.trim();
|
|
10594
|
-
const strippedDomain = trimmedDomain.startsWith("*.") ? trimmedDomain.slice(2) : trimmedDomain;
|
|
10595
|
-
return strippedDomain.length > 0 ? strippedDomain : null;
|
|
10596
|
-
}
|
|
10597
|
-
function getDefangedUrl(input) {
|
|
10598
|
-
if (!isUrl(input)) {
|
|
10599
|
-
console.warn(`[getDefangedUrl] Invalid URL: ${input}, returning input as-is`);
|
|
10600
|
-
return input;
|
|
10601
|
-
}
|
|
10602
|
-
return input.replace(/\./g, "[.]").replace(/(https:\/\/)/g, "hxxps://").replace(/(http:\/\/)/g, "hxxp://").replace(/:\/\//g, "[://]");
|
|
10603
|
-
}
|
|
10604
|
-
function getRefangedUrl(input) {
|
|
10605
|
-
return input.replace(/hxxps/gi, "https").replace(/hxxp/gi, "http").replace(/\[:\/{2}\]/g, "://").replace(/\[\.\]/g, ".");
|
|
10606
|
-
}
|
|
10607
|
-
function containsPunycode(url) {
|
|
10608
|
-
return url.indexOf("xn--") !== -1;
|
|
10609
|
-
}
|
|
10610
|
-
function toUnicode2(url) {
|
|
10611
|
-
return toUnicode(url);
|
|
10612
|
-
}
|
|
10613
|
-
function convertHttpsToHttp(url) {
|
|
10614
|
-
if (url.startsWith("https://")) {
|
|
10615
|
-
const httpUrl = new URL(url);
|
|
10616
|
-
httpUrl.protocol = "http:";
|
|
10617
|
-
return httpUrl.toString();
|
|
10769
|
+
const parts = cronExpression.trim().split(/\s+/);
|
|
10770
|
+
if (parts.length !== 5) {
|
|
10771
|
+
return false;
|
|
10618
10772
|
}
|
|
10619
|
-
|
|
10773
|
+
const [minute, hour, dayOfMonth, month, dayOfWeek2] = parts;
|
|
10774
|
+
return isValidCronField(minute, 0, 59) && isValidCronField(hour, 0, 23) && isValidCronField(dayOfMonth, 1, 31) && isValidCronField(month, 1, 12) && isValidCronField(dayOfWeek2, 0, 7);
|
|
10620
10775
|
}
|
|
10621
|
-
function
|
|
10622
|
-
if (!
|
|
10623
|
-
|
|
10776
|
+
function isValidCronField(field, min, max) {
|
|
10777
|
+
if (!field) return false;
|
|
10778
|
+
if (field === "*") return true;
|
|
10779
|
+
if (field.includes("/")) {
|
|
10780
|
+
const [range, step] = field.split("/");
|
|
10781
|
+
const stepNum = parseInt(step);
|
|
10782
|
+
if (isNaN(stepNum) || stepNum <= 0) return false;
|
|
10783
|
+
if (range === "*") return true;
|
|
10784
|
+
return isValidCronField(range, min, max);
|
|
10624
10785
|
}
|
|
10625
|
-
if (
|
|
10626
|
-
|
|
10786
|
+
if (field.includes("-")) {
|
|
10787
|
+
const [start, end] = field.split("-");
|
|
10788
|
+
const startNum = parseInt(start);
|
|
10789
|
+
const endNum = parseInt(end);
|
|
10790
|
+
if (isNaN(startNum) || isNaN(endNum)) return false;
|
|
10791
|
+
return startNum >= min && startNum <= max && endNum >= min && endNum <= max && startNum <= endNum;
|
|
10627
10792
|
}
|
|
10628
|
-
if (
|
|
10629
|
-
|
|
10793
|
+
if (field.includes(",")) {
|
|
10794
|
+
const values = field.split(",");
|
|
10795
|
+
return values.every((value) => isValidCronField(value.trim(), min, max));
|
|
10630
10796
|
}
|
|
10631
|
-
|
|
10797
|
+
const num3 = parseInt(field);
|
|
10798
|
+
if (isNaN(num3)) return false;
|
|
10799
|
+
if (max === 7 && num3 === 7) return true;
|
|
10800
|
+
return num3 >= min && num3 <= max;
|
|
10632
10801
|
}
|
|
10633
|
-
|
|
10634
|
-
|
|
10802
|
+
|
|
10803
|
+
// ../../internal/utils/src/object.ts
|
|
10804
|
+
var object_exports = {};
|
|
10805
|
+
__export(object_exports, {
|
|
10806
|
+
isDefined: () => isDefined,
|
|
10807
|
+
isDefinedAndNotNull: () => isDefinedAndNotNull,
|
|
10808
|
+
isNotNull: () => isNotNull
|
|
10809
|
+
});
|
|
10810
|
+
function isDefined(value) {
|
|
10811
|
+
return value !== void 0;
|
|
10635
10812
|
}
|
|
10636
|
-
function
|
|
10637
|
-
|
|
10638
|
-
return `https://icons.duckduckgo.com/ip3/${normalizedUrl.hostname}.ico`;
|
|
10813
|
+
function isNotNull(value) {
|
|
10814
|
+
return value !== null;
|
|
10639
10815
|
}
|
|
10640
|
-
function
|
|
10641
|
-
|
|
10642
|
-
|
|
10643
|
-
|
|
10644
|
-
|
|
10645
|
-
|
|
10646
|
-
|
|
10647
|
-
|
|
10648
|
-
|
|
10649
|
-
|
|
10650
|
-
|
|
10651
|
-
|
|
10652
|
-
|
|
10816
|
+
function isDefinedAndNotNull(value) {
|
|
10817
|
+
return value !== null && value !== void 0;
|
|
10818
|
+
}
|
|
10819
|
+
|
|
10820
|
+
// ../../internal/utils/src/promise.ts
|
|
10821
|
+
var promise_exports = {};
|
|
10822
|
+
__export(promise_exports, {
|
|
10823
|
+
allSettledWithConcurrency: () => allSettledWithConcurrency,
|
|
10824
|
+
isPromiseSettledResultFulfilled: () => isPromiseSettledResultFulfilled,
|
|
10825
|
+
isPromiseSettledResultRejected: () => isPromiseSettledResultRejected
|
|
10826
|
+
});
|
|
10827
|
+
function isPromiseSettledResultFulfilled(result) {
|
|
10828
|
+
return result.status === "fulfilled";
|
|
10829
|
+
}
|
|
10830
|
+
function isPromiseSettledResultRejected(result) {
|
|
10831
|
+
return result.status === "rejected";
|
|
10832
|
+
}
|
|
10833
|
+
function allSettledWithConcurrency(items, limit, fn5) {
|
|
10834
|
+
return __async(this, null, function* () {
|
|
10835
|
+
const results = new Array(items.length);
|
|
10836
|
+
let next = 0;
|
|
10837
|
+
const worker = () => __async(null, null, function* () {
|
|
10838
|
+
for (; ; ) {
|
|
10839
|
+
const index = next;
|
|
10840
|
+
next += 1;
|
|
10841
|
+
if (index >= items.length) return;
|
|
10842
|
+
try {
|
|
10843
|
+
results[index] = { status: "fulfilled", value: yield fn5(items[index], index) };
|
|
10844
|
+
} catch (reason) {
|
|
10845
|
+
results[index] = { status: "rejected", reason };
|
|
10846
|
+
}
|
|
10847
|
+
}
|
|
10848
|
+
});
|
|
10849
|
+
const workers = Math.max(1, Math.min(Math.floor(limit) || 1, items.length));
|
|
10850
|
+
yield Promise.all(Array.from({ length: workers }, worker));
|
|
10851
|
+
return results;
|
|
10852
|
+
});
|
|
10653
10853
|
}
|
|
10654
|
-
var URL_REGEX = /https?:\/\/[^\s"'<>\])]*/g;
|
|
10655
10854
|
|
|
10656
10855
|
// ../../internal/utils/src/email.ts
|
|
10657
10856
|
var email_exports = {};
|
|
@@ -10821,6 +11020,7 @@ function buildSafePreviewUrl({
|
|
|
10821
11020
|
var parse_exports = {};
|
|
10822
11021
|
__export(parse_exports, {
|
|
10823
11022
|
parseTerms: () => parseTerms,
|
|
11023
|
+
repairTermsString: () => repairTermsString,
|
|
10824
11024
|
stringifyTerms: () => stringifyTerms
|
|
10825
11025
|
});
|
|
10826
11026
|
function parseTerms(terms, {
|
|
@@ -10847,6 +11047,31 @@ function parseTerms(terms, {
|
|
|
10847
11047
|
function stringifyTerms(parsedTerms) {
|
|
10848
11048
|
return parsedTerms.map((term) => term.type === "exact" ? `*${term.value}*` : term.value).join(", ");
|
|
10849
11049
|
}
|
|
11050
|
+
function repairTermsString(terms) {
|
|
11051
|
+
if (!terms) return terms;
|
|
11052
|
+
const entries = terms.split(",").map((entry) => entry.trim()).filter((entry) => entry.length > 0);
|
|
11053
|
+
if (entries.length === 0) return terms;
|
|
11054
|
+
const first = entries[0];
|
|
11055
|
+
const last = entries[entries.length - 1];
|
|
11056
|
+
const isWholeListWrap = entries.length > 1 && first.startsWith("*") && !first.endsWith("*") && last.endsWith("*") && !last.startsWith("*");
|
|
11057
|
+
const hasOneSidedAsterisk = entries.some(
|
|
11058
|
+
(entry) => entry.startsWith("*") !== entry.endsWith("*")
|
|
11059
|
+
);
|
|
11060
|
+
if (!isWholeListWrap && !hasOneSidedAsterisk) return terms;
|
|
11061
|
+
const seen = /* @__PURE__ */ new Set();
|
|
11062
|
+
const repaired = [];
|
|
11063
|
+
for (const entry of entries) {
|
|
11064
|
+
const inner = entry.replace(/^\*+|\*+$/g, "").trim();
|
|
11065
|
+
if (inner.length === 0) continue;
|
|
11066
|
+
const isExact = isWholeListWrap || entry.startsWith("*") && entry.endsWith("*") && entry.length > 2;
|
|
11067
|
+
const formatted = isExact ? `*${inner}*` : inner;
|
|
11068
|
+
const key = formatted.toLowerCase();
|
|
11069
|
+
if (seen.has(key)) continue;
|
|
11070
|
+
seen.add(key);
|
|
11071
|
+
repaired.push(formatted);
|
|
11072
|
+
}
|
|
11073
|
+
return repaired.join(", ");
|
|
11074
|
+
}
|
|
10850
11075
|
|
|
10851
11076
|
// ../../internal/utils/src/brand-pattern.ts
|
|
10852
11077
|
var brand_pattern_exports = {};
|
|
@@ -11108,6 +11333,65 @@ function parseLinkedInProfileUrl(url) {
|
|
|
11108
11333
|
return { pathSegment, handle, name, profileUrl };
|
|
11109
11334
|
}
|
|
11110
11335
|
|
|
11336
|
+
// ../../internal/utils/src/detection-sources.ts
|
|
11337
|
+
var UNKNOWN_DETECTION_SOURCE = "unknown";
|
|
11338
|
+
var WORD_OVERRIDES = {
|
|
11339
|
+
ads: "Ads",
|
|
11340
|
+
dns: "DNS",
|
|
11341
|
+
dnsdb: "DNSDB",
|
|
11342
|
+
duck: "Duck",
|
|
11343
|
+
go: "Go",
|
|
11344
|
+
ip: "IP",
|
|
11345
|
+
linkedin: "LinkedIn",
|
|
11346
|
+
rss: "RSS",
|
|
11347
|
+
serp: "SERP",
|
|
11348
|
+
tik: "Tik",
|
|
11349
|
+
tok: "Tok",
|
|
11350
|
+
urlscan: "URLScan",
|
|
11351
|
+
youtube: "YouTube"
|
|
11352
|
+
};
|
|
11353
|
+
var KEY_OVERRIDES = {
|
|
11354
|
+
["duck_duck_go_search" /* DUCK_DUCK_GO_SEARCH */]: "DuckDuckGo Search",
|
|
11355
|
+
["tik_tok_ads_search" /* TIK_TOK_ADS_SEARCH */]: "TikTok Ads Search",
|
|
11356
|
+
["tik_tok_user_search" /* TIK_TOK_USER_SEARCH */]: "TikTok User Search",
|
|
11357
|
+
["tik_tok_video_search" /* TIK_TOK_VIDEO_SEARCH */]: "TikTok Video Search",
|
|
11358
|
+
["dns_twist" /* DNS_TWIST */]: "DNSTwist",
|
|
11359
|
+
// Keys carry the vendor for internal traceability; customers see neither.
|
|
11360
|
+
["telegram_user_search_vetric" /* TELEGRAM_USER_SEARCH_VETRIC */]: "Telegram User Discovery",
|
|
11361
|
+
["telegram_channels_search_vetric" /* TELEGRAM_CHANNELS_SEARCH_VETRIC */]: "Telegram Channel Discovery",
|
|
11362
|
+
["facebook_page_search_vetric" /* FACEBOOK_PAGE_SEARCH_VETRIC */]: "Facebook Page Discovery",
|
|
11363
|
+
["facebook_user_search_vetric" /* FACEBOOK_USER_SEARCH_VETRIC */]: "Facebook User Discovery",
|
|
11364
|
+
["facebook_post_search_vetric" /* FACEBOOK_POST_SEARCH_VETRIC */]: "Facebook Post Discovery",
|
|
11365
|
+
["instagram_account_search_vetric" /* INSTAGRAM_ACCOUNT_SEARCH_VETRIC */]: "Instagram Account Discovery",
|
|
11366
|
+
["twitter_search_vetric" /* TWITTER_SEARCH_VETRIC */]: "Twitter People Discovery",
|
|
11367
|
+
["linkedin_people_search_vetric" /* LINKEDIN_PEOPLE_SEARCH_VETRIC */]: "LinkedIn People Discovery",
|
|
11368
|
+
["linkedin_company_search_vetric" /* LINKEDIN_COMPANY_SEARCH_VETRIC */]: "LinkedIn Company Discovery",
|
|
11369
|
+
["meta_ads_search_vetric" /* META_ADS_SEARCH_VETRIC */]: "Meta Ads Discovery",
|
|
11370
|
+
["tik_tok_user_search_vetric" /* TIK_TOK_USER_SEARCH_VETRIC */]: "TikTok User Discovery",
|
|
11371
|
+
["tik_tok_video_search_vetric" /* TIK_TOK_VIDEO_SEARCH_VETRIC */]: "TikTok Post Discovery",
|
|
11372
|
+
[UNKNOWN_DETECTION_SOURCE]: "Unknown (no source recorded)"
|
|
11373
|
+
};
|
|
11374
|
+
function detectionSourceLabel(key) {
|
|
11375
|
+
const override = KEY_OVERRIDES[key];
|
|
11376
|
+
if (override) return override;
|
|
11377
|
+
return key.split("_").map((word2) => {
|
|
11378
|
+
var _a;
|
|
11379
|
+
return (_a = WORD_OVERRIDES[word2]) != null ? _a : word2.charAt(0).toUpperCase() + word2.slice(1);
|
|
11380
|
+
}).join(" ");
|
|
11381
|
+
}
|
|
11382
|
+
[
|
|
11383
|
+
...Object.values(ThreatDetectionSourceKey).map((key) => ({
|
|
11384
|
+
value: key,
|
|
11385
|
+
label: detectionSourceLabel(key),
|
|
11386
|
+
searchText: `${key} ${detectionSourceLabel(key)}`
|
|
11387
|
+
})),
|
|
11388
|
+
{
|
|
11389
|
+
value: UNKNOWN_DETECTION_SOURCE,
|
|
11390
|
+
label: detectionSourceLabel(UNKNOWN_DETECTION_SOURCE),
|
|
11391
|
+
searchText: UNKNOWN_DETECTION_SOURCE
|
|
11392
|
+
}
|
|
11393
|
+
].sort((a, b) => a.label.localeCompare(b.label));
|
|
11394
|
+
|
|
11111
11395
|
// ../../internal/validation/src/public/detection/configs-create.ts
|
|
11112
11396
|
zod.z.object({
|
|
11113
11397
|
slug: zod.z.string().min(1).optional().describe(
|
|
@@ -11492,6 +11776,44 @@ zod.z.object({
|
|
|
11492
11776
|
})
|
|
11493
11777
|
)
|
|
11494
11778
|
});
|
|
11779
|
+
var DATE_ONLY_PATTERN = /^\d{4}-\d{2}-\d{2}$/;
|
|
11780
|
+
var utcDateSchema = (endOfDay) => zod.z.preprocess((value) => {
|
|
11781
|
+
if (typeof value !== "string") {
|
|
11782
|
+
return value;
|
|
11783
|
+
}
|
|
11784
|
+
const parsed = DateTime.fromISO(value, { zone: "utc" });
|
|
11785
|
+
if (!parsed.isValid) {
|
|
11786
|
+
return new Date(Number.NaN);
|
|
11787
|
+
}
|
|
11788
|
+
return endOfDay && DATE_ONLY_PATTERN.test(value) ? parsed.endOf("day").toJSDate() : parsed.toJSDate();
|
|
11789
|
+
}, zod.z.coerce.date());
|
|
11790
|
+
|
|
11791
|
+
// ../../internal/validation/src/public/metrics/false-positive-rate.ts
|
|
11792
|
+
zod.z.object({
|
|
11793
|
+
slug: zod.z.string().min(1).describe("Organization slug"),
|
|
11794
|
+
startDate: utcDateSchema(false).optional().describe(
|
|
11795
|
+
"Only include assets blocked on or after this date. A date-only value (YYYY-MM-DD) starts at midnight UTC"
|
|
11796
|
+
),
|
|
11797
|
+
endDate: utcDateSchema(true).optional().describe(
|
|
11798
|
+
"Only include assets blocked on or before this date. A date-only value (YYYY-MM-DD) covers the whole day in UTC; pass a full timestamp for a precise cut-off"
|
|
11799
|
+
),
|
|
11800
|
+
brandIds: zod.z.array(zod.z.number().int().positive()).optional().describe("Only include assets belonging to these brands"),
|
|
11801
|
+
countryCodes: zod.z.array(zod.z.string().length(2)).optional().describe("Only include assets scanned from these ISO 3166-1 alpha-2 countries")
|
|
11802
|
+
});
|
|
11803
|
+
zod.z.object({
|
|
11804
|
+
byAssetType: zod.z.array(
|
|
11805
|
+
zod.z.object({
|
|
11806
|
+
assetType: zod.z.nativeEnum(AssetType).describe("Asset type that was blocked"),
|
|
11807
|
+
blocked: zod.z.number().describe("Assets of this type blocked within the date range"),
|
|
11808
|
+
falsePositives: zod.z.number().describe("Of those, how many are no longer blocked today"),
|
|
11809
|
+
falsePositiveRate: zod.z.number().nullable().describe(
|
|
11810
|
+
"falsePositives / blocked, 0-1. Null only when nothing was blocked, which cannot happen for a returned row"
|
|
11811
|
+
)
|
|
11812
|
+
})
|
|
11813
|
+
).describe(
|
|
11814
|
+
"False positive rate, one entry per asset type blocked in the range, descending by number blocked. Asset types with no false positives are included with a rate of 0; asset types with no blocks at all in the range are omitted, since they have no rate to report. The denominator counts block events, not distinct assets, so an asset blocked twice in the range counts twice. Whether a block still stands is read as of now while the range bounds the block itself, so a recent range reads low. An asset's blocked status is global, so a block another organization's report caused to be reversed is counted here too"
|
|
11815
|
+
)
|
|
11816
|
+
});
|
|
11495
11817
|
zod.z.object({
|
|
11496
11818
|
slug: zod.z.string().min(1),
|
|
11497
11819
|
startDate: zod.z.date(),
|
|
@@ -11506,8 +11828,8 @@ zod.z.object({
|
|
|
11506
11828
|
endDate: zod.z.date()
|
|
11507
11829
|
})
|
|
11508
11830
|
});
|
|
11509
|
-
var
|
|
11510
|
-
var
|
|
11831
|
+
var DATE_ONLY_PATTERN2 = /^\d{4}-\d{2}-\d{2}$/;
|
|
11832
|
+
var utcDateSchema2 = (endOfDay) => zod.z.preprocess((value) => {
|
|
11511
11833
|
if (typeof value !== "string") {
|
|
11512
11834
|
return value;
|
|
11513
11835
|
}
|
|
@@ -11515,7 +11837,7 @@ var utcDateSchema = (endOfDay) => zod.z.preprocess((value) => {
|
|
|
11515
11837
|
if (!parsed.isValid) {
|
|
11516
11838
|
return new Date(Number.NaN);
|
|
11517
11839
|
}
|
|
11518
|
-
return endOfDay &&
|
|
11840
|
+
return endOfDay && DATE_ONLY_PATTERN2.test(value) ? parsed.endOf("day").toJSDate() : parsed.toJSDate();
|
|
11519
11841
|
}, zod.z.coerce.date());
|
|
11520
11842
|
var funnelCountsSchema = zod.z.object({
|
|
11521
11843
|
blocked: zod.z.number().int().nonnegative().describe(
|
|
@@ -11524,10 +11846,10 @@ var funnelCountsSchema = zod.z.object({
|
|
|
11524
11846
|
});
|
|
11525
11847
|
zod.z.object({
|
|
11526
11848
|
slug: zod.z.string().min(1).describe("Organization slug"),
|
|
11527
|
-
startDate:
|
|
11849
|
+
startDate: utcDateSchema2(false).describe(
|
|
11528
11850
|
"Only include assets whose earliest report was created on or after this date. A date-only value (YYYY-MM-DD) starts at midnight UTC"
|
|
11529
11851
|
),
|
|
11530
|
-
endDate:
|
|
11852
|
+
endDate: utcDateSchema2(true).describe(
|
|
11531
11853
|
"Only include assets whose earliest report was created on or before this date. A date-only value (YYYY-MM-DD) covers the whole day in UTC; pass a full timestamp for a precise cut-off"
|
|
11532
11854
|
),
|
|
11533
11855
|
brandIds: zod.z.array(zod.z.number().int().positive()).optional().describe("Only include assets belonging to these brands")
|
|
@@ -11581,25 +11903,12 @@ zod.z.object({
|
|
|
11581
11903
|
})
|
|
11582
11904
|
)
|
|
11583
11905
|
});
|
|
11584
|
-
var DATE_ONLY_PATTERN2 = /^\d{4}-\d{2}-\d{2}$/;
|
|
11585
|
-
var utcDateSchema2 = (endOfDay) => zod.z.preprocess((value) => {
|
|
11586
|
-
if (typeof value !== "string") {
|
|
11587
|
-
return value;
|
|
11588
|
-
}
|
|
11589
|
-
const parsed = DateTime.fromISO(value, { zone: "utc" });
|
|
11590
|
-
if (!parsed.isValid) {
|
|
11591
|
-
return new Date(Number.NaN);
|
|
11592
|
-
}
|
|
11593
|
-
return endOfDay && DATE_ONLY_PATTERN2.test(value) ? parsed.endOf("day").toJSDate() : parsed.toJSDate();
|
|
11594
|
-
}, zod.z.coerce.date());
|
|
11595
|
-
|
|
11596
|
-
// ../../internal/validation/src/public/metrics/takedown-success-rate.ts
|
|
11597
11906
|
zod.z.object({
|
|
11598
11907
|
slug: zod.z.string().min(1).describe("Organization slug"),
|
|
11599
|
-
startDate:
|
|
11908
|
+
startDate: utcDateSchema(false).optional().describe(
|
|
11600
11909
|
"Only include takedowns first submitted to a provider on or after this date. A date-only value (YYYY-MM-DD) starts at midnight UTC"
|
|
11601
11910
|
),
|
|
11602
|
-
endDate:
|
|
11911
|
+
endDate: utcDateSchema(true).optional().describe(
|
|
11603
11912
|
"Only include takedowns first submitted to a provider on or before this date. A date-only value (YYYY-MM-DD) covers the whole day in UTC; pass a full timestamp for a precise cut-off"
|
|
11604
11913
|
),
|
|
11605
11914
|
blockLabel: zod.z.string().optional().describe(
|
|
@@ -11627,10 +11936,10 @@ zod.z.object({
|
|
|
11627
11936
|
});
|
|
11628
11937
|
zod.z.object({
|
|
11629
11938
|
slug: zod.z.string().min(1).describe("Organization slug"),
|
|
11630
|
-
startDate:
|
|
11939
|
+
startDate: utcDateSchema(false).optional().describe(
|
|
11631
11940
|
"Only include takedowns completed on or after this date. A date-only value (YYYY-MM-DD) starts at midnight UTC"
|
|
11632
11941
|
),
|
|
11633
|
-
endDate:
|
|
11942
|
+
endDate: utcDateSchema(true).optional().describe(
|
|
11634
11943
|
"Only include takedowns completed on or before this date. A date-only value (YYYY-MM-DD) covers the whole day in UTC; pass a full timestamp for a precise cut-off"
|
|
11635
11944
|
),
|
|
11636
11945
|
blockLabel: zod.z.string().optional().describe(
|
|
@@ -11660,10 +11969,10 @@ var TakedownProviderRoleSchema = zod.z.enum([
|
|
|
11660
11969
|
]);
|
|
11661
11970
|
zod.z.object({
|
|
11662
11971
|
slug: zod.z.string().min(1).describe("Organization slug"),
|
|
11663
|
-
startDate:
|
|
11972
|
+
startDate: utcDateSchema(false).optional().describe(
|
|
11664
11973
|
"Only include takedowns completed on or after this date. A date-only value (YYYY-MM-DD) starts at midnight UTC"
|
|
11665
11974
|
),
|
|
11666
|
-
endDate:
|
|
11975
|
+
endDate: utcDateSchema(true).optional().describe(
|
|
11667
11976
|
"Only include takedowns completed on or before this date. A date-only value (YYYY-MM-DD) covers the whole day in UTC; pass a full timestamp for a precise cut-off"
|
|
11668
11977
|
),
|
|
11669
11978
|
roles: zod.z.array(TakedownProviderRoleSchema).optional().describe(
|
|
@@ -11742,6 +12051,35 @@ zod.z.object({
|
|
|
11742
12051
|
"One series per requested asset type, in the order requested, or a single pooled series when no asset types were given"
|
|
11743
12052
|
)
|
|
11744
12053
|
});
|
|
12054
|
+
zod.z.object({
|
|
12055
|
+
slug: zod.z.string().min(1).describe("Organization slug"),
|
|
12056
|
+
startDate: utcDateSchema(false).optional().describe(
|
|
12057
|
+
"Only include assets blocked on or after this date. A date-only value (YYYY-MM-DD) starts at midnight UTC"
|
|
12058
|
+
),
|
|
12059
|
+
endDate: utcDateSchema(true).optional().describe(
|
|
12060
|
+
"Only include assets blocked on or before this date. A date-only value (YYYY-MM-DD) covers the whole day in UTC; pass a full timestamp for a precise cut-off"
|
|
12061
|
+
),
|
|
12062
|
+
brandIds: zod.z.array(zod.z.number().int().positive()).optional().describe("Only include assets belonging to these brands"),
|
|
12063
|
+
countryCodes: zod.z.array(zod.z.string().length(2)).optional().describe("Only include assets scanned from these ISO 3166-1 alpha-2 countries")
|
|
12064
|
+
});
|
|
12065
|
+
zod.z.object({
|
|
12066
|
+
byAssetType: zod.z.array(
|
|
12067
|
+
zod.z.object({
|
|
12068
|
+
assetType: zod.z.nativeEnum(AssetType).describe("Asset type that was blocked"),
|
|
12069
|
+
blocked: zod.z.number().describe(
|
|
12070
|
+
"Distinct assets of this type the organization blocked within the date range that are still blocked today"
|
|
12071
|
+
),
|
|
12072
|
+
withEvidence: zod.z.number().describe(
|
|
12073
|
+
"Of those, how many enter the median: an accepted live date and an automated detection after it. A live date with no detection result does not count, and a human report is not a detection"
|
|
12074
|
+
),
|
|
12075
|
+
medianDaysAtLeast: zod.z.number().nullable().describe(
|
|
12076
|
+
"Median days the asset was already live before the earliest automated detection of that asset, for any organization. Always a minimum, because the live date is the first time anyone saw the asset. Null when withEvidence is 0"
|
|
12077
|
+
)
|
|
12078
|
+
})
|
|
12079
|
+
).describe(
|
|
12080
|
+
"Time to Detection, one entry per asset type this organization blocked in the range, descending by number blocked. The clock stops at the earliest automated detection of the asset for any organization, not at this organization's report. Assets that do not enter withEvidence are left out of the median. For URL and page assets only an observed-serving date counts, so a domain registration date never enters the number"
|
|
12081
|
+
)
|
|
12082
|
+
});
|
|
11745
12083
|
zod.z.object({
|
|
11746
12084
|
slug: zod.z.string().optional().describe(
|
|
11747
12085
|
"Organization slug. Optional for organization-scoped API keys, which resolve the organization from the key itself. Required when your credentials can reach more than one organization."
|
|
@@ -11947,6 +12285,79 @@ var brandItemSchema = zod.z.object({
|
|
|
11947
12285
|
zod.z.object({
|
|
11948
12286
|
brands: zod.z.array(brandItemSchema).describe("List of brands")
|
|
11949
12287
|
}).describe("Successful operation");
|
|
12288
|
+
var threatLifecycleStateSchema = zod.z.enum(["investigating", "escalated", "blocked", "allowed", "closed"]).describe(
|
|
12289
|
+
"Lifecycle stage: `investigating` (a report is open and under review), `escalated` (an open report has been passed to the organization for a decision), `blocked` (confirmed malicious), `allowed` (confirmed benign / false positive), `closed` (every report reviewed, asset neither blocked nor allowed). `escalated` reflects an escalation that is still open, not one that was decided and followed by a new report."
|
|
12290
|
+
);
|
|
12291
|
+
zod.z.object({
|
|
12292
|
+
slug: zod.z.string().optional().describe(
|
|
12293
|
+
"Organization slug. Optional for organization-scoped API keys, which resolve the organization from the key itself. Required when your credentials can reach more than one organization."
|
|
12294
|
+
),
|
|
12295
|
+
/**
|
|
12296
|
+
* A poll watermark rather than a true event cursor: there is no single
|
|
12297
|
+
* change log behind these threats, so the filter is an OR across the
|
|
12298
|
+
* `updatedAt` of every table the projection reads. Set it a few minutes
|
|
12299
|
+
* behind the last successful sync so in-flight writes are not skipped.
|
|
12300
|
+
*/
|
|
12301
|
+
updatedSince: zod.z.string().refine((value) => DateTime.fromISO(value, { zone: "utc" }).isValid, {
|
|
12302
|
+
message: "updatedSince must be a valid ISO 8601 timestamp"
|
|
12303
|
+
}).transform((value) => DateTime.fromISO(value, { zone: "utc" }).toJSDate()).optional().describe(
|
|
12304
|
+
"Only return threats touched at or after this ISO 8601 timestamp. Compared against the most recent change to the asset, its reports, and its takedown \u2014 whichever is latest. Omit for a full backfill. Overlap your windows by a few minutes: writes that land mid-request can otherwise fall between two polls."
|
|
12305
|
+
),
|
|
12306
|
+
assetType: zod.z.nativeEnum(AssetType).optional().describe("Filter by asset type. Omit to return every type."),
|
|
12307
|
+
per_page: zod.z.number().int().min(1).max(1e3).optional().default(100).describe("The number of threats to return per page (max 1000)"),
|
|
12308
|
+
next_page: zod.z.string().optional().nullable().describe("Cursor for fetching the next page of results")
|
|
12309
|
+
}).describe(
|
|
12310
|
+
`List organization threats request body
|
|
12311
|
+
|
|
12312
|
+
Returns every asset this organization has filed a report against, together with
|
|
12313
|
+
the lifecycle state of that investigation \u2014 report opened, escalated, blocked,
|
|
12314
|
+
takedown submitted, takedown completed.
|
|
12315
|
+
|
|
12316
|
+
This is a projection of current state, not an event stream: each threat is
|
|
12317
|
+
returned with the facts as they stand right now, so a consumer that upserts on
|
|
12318
|
+
\`id\` converges regardless of which intermediate transitions it saw. Results are
|
|
12319
|
+
ordered by asset ID ascending and paginated with \`next_page\`.`
|
|
12320
|
+
);
|
|
12321
|
+
var organizationThreatBrandSchema = zod.z.object({
|
|
12322
|
+
slug: zod.z.string().describe("Brand slug"),
|
|
12323
|
+
name: zod.z.string().describe("Brand name")
|
|
12324
|
+
});
|
|
12325
|
+
var organizationThreatTakedownSchema = zod.z.object({
|
|
12326
|
+
status: zod.z.nativeEnum(TakedownStatus).describe("Current takedown status"),
|
|
12327
|
+
submittedAt: zod.z.date().nullable().describe(
|
|
12328
|
+
"When the first takedown request was submitted to a provider, or null if nothing has been submitted yet"
|
|
12329
|
+
),
|
|
12330
|
+
completedAt: zod.z.date().nullable().describe("When the takedown was marked completed, or null if it has not been")
|
|
12331
|
+
});
|
|
12332
|
+
var organizationThreatSchema = zod.z.object({
|
|
12333
|
+
id: zod.z.number().describe("Asset ID"),
|
|
12334
|
+
content: zod.z.string().describe("Asset content (URL, handle, email, etc.)"),
|
|
12335
|
+
type: zod.z.nativeEnum(AssetType).describe("Asset type"),
|
|
12336
|
+
status: zod.z.nativeEnum(AssetStatus).describe("Raw asset status"),
|
|
12337
|
+
state: threatLifecycleStateSchema,
|
|
12338
|
+
livenessStatus: zod.z.nativeEnum(LivenessStatus).describe(
|
|
12339
|
+
"Whether the threat is currently reachable (`ALIVE`), gone (`DEAD`), or unchecked (`UNKNOWN`)"
|
|
12340
|
+
),
|
|
12341
|
+
brands: zod.z.array(organizationThreatBrandSchema).describe(
|
|
12342
|
+
"The brands of yours this threat was reported against. Empty when no report named one."
|
|
12343
|
+
),
|
|
12344
|
+
firstReportedAt: zod.z.date().describe("When this organization first filed a report against the asset"),
|
|
12345
|
+
escalatedAt: zod.z.date().nullable().describe(
|
|
12346
|
+
"When the asset was *first* escalated to this organization for a decision, or null if it never was. This is escalation history, not current state: an asset escalated once and later reported again reports `escalated_at` alongside a `state` of `investigating`. Read `state` to know whether anything is waiting on you right now."
|
|
12347
|
+
),
|
|
12348
|
+
blockedAt: zod.z.date().nullable().describe("When the asset was blocklisted, or null if it has not been"),
|
|
12349
|
+
takedown: organizationThreatTakedownSchema.nullable().describe("Takedown progress, or null if no takedown was opened"),
|
|
12350
|
+
detailsUrl: zod.z.string().describe("Deep link to the asset's reports and takedowns in the ChainPatrol app"),
|
|
12351
|
+
updatedAt: zod.z.date().describe(
|
|
12352
|
+
"The most recent change to anything in this record \u2014 the asset, its reports, its takedown or that takedown's tasks. Matches what `updatedSince` filters on. To derive your next watermark, drain every page until `next_page` is null and take the highest value across the whole sweep: results are ordered by asset ID, not by this field, so a later page can carry an earlier timestamp and a per-page watermark would skip it."
|
|
12353
|
+
)
|
|
12354
|
+
});
|
|
12355
|
+
zod.z.object({
|
|
12356
|
+
threats: zod.z.array(organizationThreatSchema),
|
|
12357
|
+
next_page: zod.z.string().nullable().optional().describe(
|
|
12358
|
+
"Cursor for fetching the next page of results, or null on the last page. Drain it to null before advancing your `updatedSince` watermark \u2014 see `updatedAt`."
|
|
12359
|
+
)
|
|
12360
|
+
}).describe("Successful operation");
|
|
11950
12361
|
var FILTERABLE_SUBSCRIPTION_STATUSES = [
|
|
11951
12362
|
SubscriptionStatus.PROSPECT,
|
|
11952
12363
|
SubscriptionStatus.POC,
|
|
@@ -12299,8 +12710,10 @@ var reportCreateInputSchema = zod.z.object({
|
|
|
12299
12710
|
).optional().refine((value) => !value || !isPhoneNumberMissingCountryCode(value), {
|
|
12300
12711
|
message: PHONE_COUNTRY_CODE_ERROR_MESSAGE
|
|
12301
12712
|
}),
|
|
12302
|
-
/** Optional list of URLs for
|
|
12303
|
-
attachmentUrls: zod.z.array(zod.z.string().url()).optional().describe(
|
|
12713
|
+
/** Optional list of URLs for files to be attached to the report as evidence. */
|
|
12714
|
+
attachmentUrls: zod.z.array(zod.z.string().url()).optional().describe(
|
|
12715
|
+
"URLs of files to attach to the report as evidence. Any file type, not only images: .eml/.msg messages, PDFs, and documents are all supported. Upload a file to POST /attachment/upload to get a URL, or pass a publicly reachable URL you host yourself."
|
|
12716
|
+
),
|
|
12304
12717
|
/** Optional link to the external submission (e.g. Telegram message link) */
|
|
12305
12718
|
externalSubmissionLink: zod.z.string().url().optional().describe("Link to the external submission (e.g. Telegram message link)"),
|
|
12306
12719
|
/** Optional user agent string from the reporter's browser */
|
|
@@ -12468,6 +12881,38 @@ for parsing the dates.`
|
|
|
12468
12881
|
path: ["startDate"]
|
|
12469
12882
|
}
|
|
12470
12883
|
);
|
|
12884
|
+
var TakedownProofType = {
|
|
12885
|
+
ProviderEmail: "provider-email"
|
|
12886
|
+
};
|
|
12887
|
+
var takedownProofEmailSchema = zod.z.object({
|
|
12888
|
+
text: zod.z.string().describe(
|
|
12889
|
+
"The provider's reply, verbatim. Plain-text body where the provider sent one, otherwise the raw HTML body \u2014 treat it as untrusted content and escape it before rendering."
|
|
12890
|
+
),
|
|
12891
|
+
subject: zod.z.string().nullable().describe("Subject line of the provider's reply.")
|
|
12892
|
+
}).nullable().describe(
|
|
12893
|
+
"Present when `type` is `provider-email`, `null` for every other proof type."
|
|
12894
|
+
);
|
|
12895
|
+
var takedownProofSchema = zod.z.object({
|
|
12896
|
+
type: zod.z.nativeEnum(TakedownProofType).describe(
|
|
12897
|
+
"Which kind of evidence this is. Currently only `provider-email`. New types may be added over time \u2014 read `type` before reading any of the type-specific objects below, and treat an unrecognised value as an opaque proof rather than an error."
|
|
12898
|
+
),
|
|
12899
|
+
source: zod.z.string().nullable().describe(
|
|
12900
|
+
"Who confirmed the takedown, in whatever form that provider identifies itself \u2014 an address such as `abuse@example.com` for `provider-email`."
|
|
12901
|
+
),
|
|
12902
|
+
confirmedAt: zod.z.date().describe("When the provider confirmed the takedown."),
|
|
12903
|
+
email: takedownProofEmailSchema
|
|
12904
|
+
});
|
|
12905
|
+
var takedownProofsSchema = zod.z.array(takedownProofSchema).describe(
|
|
12906
|
+
`Evidence that this takedown is ours: providers confirming they removed the asset, newest first.
|
|
12907
|
+
|
|
12908
|
+
A takedown filed at several providers can be confirmed by more than one of them, so this is a list. At most 5 are returned per takedown.
|
|
12909
|
+
|
|
12910
|
+
\`type\`, \`source\` and \`confirmedAt\` are present on every entry, so a caller that only needs to show "confirmed by X on date Y" never has to branch on the type. The type-specific object (\`email\`, and others as they are added) carries the underlying evidence.
|
|
12911
|
+
|
|
12912
|
+
Empty unless the takedown is COMPLETED and we hold a confirmation \u2014 which is the common case, because most providers either never reply or reply without confirming they acted. An empty list is not evidence that the asset is still up.
|
|
12913
|
+
|
|
12914
|
+
Requires the \`takedown-proof-api\` feature flag; without it this is always empty.`
|
|
12915
|
+
);
|
|
12471
12916
|
var takedownItemSchema = zod.z.object({
|
|
12472
12917
|
id: zod.z.number().describe("Takedown ID"),
|
|
12473
12918
|
status: zod.z.nativeEnum(TakedownStatus).describe("Takedown status"),
|
|
@@ -12517,7 +12962,8 @@ var takedownItemSchema = zod.z.object({
|
|
|
12517
12962
|
name: zod.z.string().describe("TLD registrar name (e.g. `Verisign`, `Public Interest Registry`)")
|
|
12518
12963
|
}).nullable().describe(
|
|
12519
12964
|
"Top-level-domain registrar assigned to this takedown. `null` when unresolved."
|
|
12520
|
-
)
|
|
12965
|
+
),
|
|
12966
|
+
proofs: takedownProofsSchema
|
|
12521
12967
|
});
|
|
12522
12968
|
zod.z.object({
|
|
12523
12969
|
takedowns: zod.z.array(takedownItemSchema).describe("List of takedowns"),
|
|
@@ -12833,12 +13279,17 @@ var ONE_PAGER_BUDGETS = {
|
|
|
12833
13279
|
headline: 60,
|
|
12834
13280
|
badge: 28,
|
|
12835
13281
|
frontLabel: 44,
|
|
12836
|
-
paragraph: 480,
|
|
12837
13282
|
paragraphsMax: 2,
|
|
12838
13283
|
heroPhrase: 80,
|
|
12839
|
-
|
|
12840
|
-
|
|
12841
|
-
|
|
13284
|
+
landscapeCaption: 180,
|
|
13285
|
+
xp01Line: 220,
|
|
13286
|
+
screenshotCaption: 48,
|
|
13287
|
+
divergenceLine: 220
|
|
13288
|
+
};
|
|
13289
|
+
var ONE_PAGER_STORED_MAX = {
|
|
13290
|
+
paragraph: 480,
|
|
13291
|
+
paragraph2Lead: 60,
|
|
13292
|
+
heroNarrative: 300
|
|
12842
13293
|
};
|
|
12843
13294
|
var onePagerFactPayloadSchema = zod.z.object({
|
|
12844
13295
|
/** Raw (not defanged) asset contents the prose may reference. */
|
|
@@ -12850,24 +13301,56 @@ var onePagerFactPayloadSchema = zod.z.object({
|
|
|
12850
13301
|
platforms: zod.z.array(zod.z.string()),
|
|
12851
13302
|
groupSize: zod.z.number(),
|
|
12852
13303
|
takedownCompletedAt: zod.z.string().nullable(),
|
|
12853
|
-
activeSince: zod.z.string().nullable()
|
|
13304
|
+
activeSince: zod.z.string().nullable(),
|
|
13305
|
+
// ---- v2 enrichment ----------------------------------------------------
|
|
13306
|
+
// Optional rather than defaulted so rows stored by v1 keep parsing AND the
|
|
13307
|
+
// inferred type stays assignable from a v1-shaped literal.
|
|
13308
|
+
/** How the attacker paid for the surface ("free_subdomain" | ...). */
|
|
13309
|
+
hostingPattern: zod.z.string().nullable().optional(),
|
|
13310
|
+
/** Who surfaced it first ("client_reported" | "proactive"). */
|
|
13311
|
+
sourceKind: zod.z.string().nullable().optional(),
|
|
13312
|
+
/** Prior blocked assets in the same relaunch family. */
|
|
13313
|
+
relaunchCount: zod.z.number().nullable().optional(),
|
|
13314
|
+
/** Earliest sighting, ISO. */
|
|
13315
|
+
firstSeenAt: zod.z.string().nullable().optional(),
|
|
13316
|
+
/**
|
|
13317
|
+
* Pre-computed hours from first sighting to confirmed removal, as a string
|
|
13318
|
+
* so it lands in the same allowlist as `numbers`. The model is forbidden
|
|
13319
|
+
* from doing arithmetic, so every duration it may cite is computed here.
|
|
13320
|
+
*/
|
|
13321
|
+
timeToRemovalHrs: zod.z.string().nullable().optional()
|
|
12854
13322
|
});
|
|
12855
13323
|
var onePagerStorySchema = zod.z.object({
|
|
12856
13324
|
archetypeId: zod.z.string(),
|
|
12857
13325
|
archetypeCategory: zod.z.string(),
|
|
12858
13326
|
/** 1-5 = placed on the page; null = alternate available for swap. */
|
|
12859
13327
|
slot: zod.z.number().int().min(1).max(5).nullable(),
|
|
13328
|
+
/** Column layout the story occupies; slot 1 is full-width by convention. */
|
|
13329
|
+
layout: zod.z.enum(["full", "half"]).default("half"),
|
|
12860
13330
|
frontLabel: zod.z.string().max(ONE_PAGER_BUDGETS.frontLabel),
|
|
12861
13331
|
headline: zod.z.string().max(ONE_PAGER_BUDGETS.headline),
|
|
13332
|
+
/** Compound "10 of 10 removed · 3 hrs". */
|
|
12862
13333
|
badge: zod.z.string().max(ONE_PAGER_BUDGETS.badge),
|
|
12863
|
-
paragraphs: zod.z.array(zod.z.string().max(
|
|
13334
|
+
paragraphs: zod.z.array(zod.z.string().max(ONE_PAGER_STORED_MAX.paragraph)).min(1).max(ONE_PAGER_BUDGETS.paragraphsMax),
|
|
13335
|
+
/** Bold lead-in shown ahead of the second paragraph. */
|
|
13336
|
+
paragraph2Lead: zod.z.string().max(ONE_PAGER_STORED_MAX.paragraph2Lead).nullable().default(null),
|
|
12864
13337
|
/** Defanged, display-ready asset identifiers. */
|
|
12865
|
-
assetList: zod.z.array(zod.z.string()).max(
|
|
13338
|
+
assetList: zod.z.array(zod.z.string()).max(12),
|
|
13339
|
+
/** Story-bank identity for the referenced assets. */
|
|
13340
|
+
assetIds: zod.z.array(zod.z.number()).default([]),
|
|
12866
13341
|
screenshotUrls: zod.z.array(zod.z.string()),
|
|
12867
13342
|
selectedScreenshotUrls: zod.z.array(zod.z.string()).max(2),
|
|
13343
|
+
/** Parallel to selectedScreenshotUrls. */
|
|
13344
|
+
screenshotCaptions: zod.z.array(zod.z.string().max(ONE_PAGER_BUDGETS.screenshotCaption)).max(2).default([]),
|
|
13345
|
+
/** Manual redact toggle, parallel to selectedScreenshotUrls. */
|
|
13346
|
+
screenshotBlur: zod.z.array(zod.z.boolean()).max(2).default([]),
|
|
12868
13347
|
xp01Line: zod.z.string().max(ONE_PAGER_BUDGETS.xp01Line).nullable(),
|
|
12869
13348
|
factPayload: onePagerFactPayloadSchema,
|
|
12870
|
-
proseSource: zod.z.enum(["llm", "template"])
|
|
13349
|
+
proseSource: zod.z.enum(["llm", "template"]),
|
|
13350
|
+
/** Cross-period continuation framing. */
|
|
13351
|
+
continuation: zod.z.boolean().default(false),
|
|
13352
|
+
/** Shown in the editor when this story overlaps with a prior period. */
|
|
13353
|
+
priorHeadline: zod.z.string().nullable().default(null)
|
|
12871
13354
|
});
|
|
12872
13355
|
var onePagerLandscapeRowSchema = zod.z.object({
|
|
12873
13356
|
platform: zod.z.string(),
|
|
@@ -12878,25 +13361,55 @@ var onePagerFormDataObjectSchema = zod.z.object({
|
|
|
12878
13361
|
orgName: zod.z.string(),
|
|
12879
13362
|
orgSlug: zod.z.string(),
|
|
12880
13363
|
periodLabel: zod.z.string(),
|
|
13364
|
+
partnershipLabel: zod.z.string().max(40).default("AN ONGOING PARTNERSHIP"),
|
|
13365
|
+
coverageWindow: zod.z.object({ start: zod.z.string(), end: zod.z.string(), label: zod.z.string(), short: zod.z.boolean() }).nullable().default(null),
|
|
12881
13366
|
heroStat: zod.z.object({
|
|
12882
13367
|
value: zod.z.string(),
|
|
12883
13368
|
phrase: zod.z.string().max(ONE_PAGER_BUDGETS.heroPhrase)
|
|
12884
13369
|
}),
|
|
12885
|
-
heroNarrative: zod.z.string().max(
|
|
12886
|
-
|
|
13370
|
+
heroNarrative: zod.z.string().max(ONE_PAGER_STORED_MAX.heroNarrative),
|
|
13371
|
+
/**
|
|
13372
|
+
* Up to 4 rows, but the metric library legitimately returns fewer on a thin
|
|
13373
|
+
* month (a zero-valued metric is excluded outright rather than rendered as
|
|
13374
|
+
* a "0" row), so this is a range, not a fixed length. Below 2 the block
|
|
13375
|
+
* reads as broken rather than short.
|
|
13376
|
+
*/
|
|
13377
|
+
metricsRows: zod.z.array(
|
|
13378
|
+
zod.z.object({
|
|
13379
|
+
key: zod.z.string().default("legacy"),
|
|
13380
|
+
label: zod.z.string(),
|
|
13381
|
+
value: zod.z.string()
|
|
13382
|
+
})
|
|
13383
|
+
).min(2).max(4),
|
|
12887
13384
|
landscape: zod.z.object({
|
|
12888
13385
|
rows: zod.z.array(onePagerLandscapeRowSchema).max(8),
|
|
12889
13386
|
otherCount: zod.z.number().nullable(),
|
|
12890
13387
|
otherPlatformsLabel: zod.z.string().nullable(),
|
|
12891
|
-
|
|
13388
|
+
/** Kept for legacy row parse; caption is preferred going forward. */
|
|
13389
|
+
divergenceLine: zod.z.string().max(ONE_PAGER_BUDGETS.divergenceLine).nullable(),
|
|
13390
|
+
caption: zod.z.string().max(ONE_PAGER_BUDGETS.landscapeCaption).nullable().default(null)
|
|
12892
13391
|
}),
|
|
12893
13392
|
stories: zod.z.array(onePagerStorySchema).min(1).max(6),
|
|
12894
|
-
footer: zod.z.object({
|
|
13393
|
+
footer: zod.z.object({
|
|
13394
|
+
contactName: zod.z.string(),
|
|
13395
|
+
contactLine: zod.z.string(),
|
|
13396
|
+
contactEmail: zod.z.string().default(""),
|
|
13397
|
+
bookingLink: zod.z.string().default(""),
|
|
13398
|
+
ctaLine: zod.z.string().default("Anything your community has flagged, send it over.")
|
|
13399
|
+
}),
|
|
13400
|
+
/** Engine v2 writes 2; absent/older rows default to 1. */
|
|
13401
|
+
schemaVersion: zod.z.number().default(1)
|
|
12895
13402
|
});
|
|
12896
13403
|
onePagerFormDataObjectSchema.refine(
|
|
12897
13404
|
(data) => data.stories.some((s2) => s2.slot !== null),
|
|
12898
13405
|
{ message: "at least one story must be placed", path: ["stories"] }
|
|
12899
13406
|
);
|
|
13407
|
+
var INTERNAL_ORG_SLUGS = [
|
|
13408
|
+
"chainpatrol",
|
|
13409
|
+
"chainpatrol-automation",
|
|
13410
|
+
"mountaintop"
|
|
13411
|
+
];
|
|
13412
|
+
new Set(INTERNAL_ORG_SLUGS);
|
|
12900
13413
|
zod.z.object({
|
|
12901
13414
|
x: zod.z.number().min(0).max(1),
|
|
12902
13415
|
y: zod.z.number().min(0).max(1),
|
|
@@ -13517,7 +14030,7 @@ function parseModernSyntax(tokens, includeHue) {
|
|
|
13517
14030
|
coords.unshift(token.value);
|
|
13518
14031
|
return coords;
|
|
13519
14032
|
}
|
|
13520
|
-
var
|
|
14033
|
+
var parse4 = (color) => {
|
|
13521
14034
|
if (typeof color !== "string") {
|
|
13522
14035
|
return void 0;
|
|
13523
14036
|
}
|
|
@@ -13533,7 +14046,7 @@ var parse3 = (color) => {
|
|
|
13533
14046
|
}
|
|
13534
14047
|
return tokens ? parseColorSyntax(tokens) : void 0;
|
|
13535
14048
|
};
|
|
13536
|
-
var parse_default =
|
|
14049
|
+
var parse_default = parse4;
|
|
13537
14050
|
|
|
13538
14051
|
// ../../node_modules/culori/src/rgb/parseRgb.js
|
|
13539
14052
|
function parseRgb(color, parsed) {
|
|
@@ -13662,20 +14175,20 @@ var convertA98ToXyz65_default = convertA98ToXyz65;
|
|
|
13662
14175
|
|
|
13663
14176
|
// ../../node_modules/culori/src/a98/convertXyz65ToA98.js
|
|
13664
14177
|
var gamma = (v) => Math.pow(Math.abs(v), 256 / 563) * Math.sign(v);
|
|
13665
|
-
var convertXyz65ToA98 = ({ x, y, z:
|
|
14178
|
+
var convertXyz65ToA98 = ({ x, y, z: z68, alpha }) => {
|
|
13666
14179
|
if (x === void 0) x = 0;
|
|
13667
14180
|
if (y === void 0) y = 0;
|
|
13668
|
-
if (
|
|
14181
|
+
if (z68 === void 0) z68 = 0;
|
|
13669
14182
|
let res = {
|
|
13670
14183
|
mode: "a98",
|
|
13671
14184
|
r: gamma(
|
|
13672
|
-
x * 2.0415879038107465 - y * 0.5650069742788597 - 0.3447313507783297 *
|
|
14185
|
+
x * 2.0415879038107465 - y * 0.5650069742788597 - 0.3447313507783297 * z68
|
|
13673
14186
|
),
|
|
13674
14187
|
g: gamma(
|
|
13675
|
-
x * -0.9692436362808798 + y * 1.8759675015077206 + 0.0415550574071756 *
|
|
14188
|
+
x * -0.9692436362808798 + y * 1.8759675015077206 + 0.0415550574071756 * z68
|
|
13676
14189
|
),
|
|
13677
14190
|
b: gamma(
|
|
13678
|
-
x * 0.0134442806320312 - y * 0.1183623922310184 + 1.0151749943912058 *
|
|
14191
|
+
x * 0.0134442806320312 - y * 0.1183623922310184 + 1.0151749943912058 * z68
|
|
13679
14192
|
)
|
|
13680
14193
|
};
|
|
13681
14194
|
if (alpha !== void 0) {
|
|
@@ -13742,14 +14255,14 @@ var convertLrgbToRgb = ({ r, g, b, alpha }, mode = "rgb") => {
|
|
|
13742
14255
|
var convertLrgbToRgb_default = convertLrgbToRgb;
|
|
13743
14256
|
|
|
13744
14257
|
// ../../node_modules/culori/src/xyz65/convertXyz65ToRgb.js
|
|
13745
|
-
var convertXyz65ToRgb = ({ x, y, z:
|
|
14258
|
+
var convertXyz65ToRgb = ({ x, y, z: z68, alpha }) => {
|
|
13746
14259
|
if (x === void 0) x = 0;
|
|
13747
14260
|
if (y === void 0) y = 0;
|
|
13748
|
-
if (
|
|
14261
|
+
if (z68 === void 0) z68 = 0;
|
|
13749
14262
|
let res = convertLrgbToRgb_default({
|
|
13750
|
-
r: x * 3.2409699419045226 - y * 1.537383177570094 - 0.4986107602930034 *
|
|
13751
|
-
g: x * -0.9692436362808796 + y * 1.8759675015077204 + 0.0415550574071756 *
|
|
13752
|
-
b: x * 0.0556300796969936 - y * 0.2039769588889765 + 1.0569715142428784 *
|
|
14263
|
+
r: x * 3.2409699419045226 - y * 1.537383177570094 - 0.4986107602930034 * z68,
|
|
14264
|
+
g: x * -0.9692436362808796 + y * 1.8759675015077204 + 0.0415550574071756 * z68,
|
|
14265
|
+
b: x * 0.0556300796969936 - y * 0.2039769588889765 + 1.0569715142428784 * z68
|
|
13753
14266
|
});
|
|
13754
14267
|
if (alpha !== void 0) {
|
|
13755
14268
|
res.alpha = alpha;
|
|
@@ -13999,13 +14512,13 @@ var convertLab65ToRgb_default = convertLab65ToRgb;
|
|
|
13999
14512
|
|
|
14000
14513
|
// ../../node_modules/culori/src/lab65/convertXyz65ToLab65.js
|
|
14001
14514
|
var f = (value) => value > e ? Math.cbrt(value) : (k * value + 16) / 116;
|
|
14002
|
-
var convertXyz65ToLab65 = ({ x, y, z:
|
|
14515
|
+
var convertXyz65ToLab65 = ({ x, y, z: z68, alpha }) => {
|
|
14003
14516
|
if (x === void 0) x = 0;
|
|
14004
14517
|
if (y === void 0) y = 0;
|
|
14005
|
-
if (
|
|
14518
|
+
if (z68 === void 0) z68 = 0;
|
|
14006
14519
|
let f0 = f(x / D65.X);
|
|
14007
14520
|
let f1 = f(y / D65.Y);
|
|
14008
|
-
let f22 = f(
|
|
14521
|
+
let f22 = f(z68 / D65.Z);
|
|
14009
14522
|
let res = {
|
|
14010
14523
|
mode: "lab65",
|
|
14011
14524
|
l: 116 * f1 - 16,
|
|
@@ -14662,10 +15175,10 @@ var convertItpToXyz65_default = convertItpToXyz65;
|
|
|
14662
15175
|
|
|
14663
15176
|
// ../../node_modules/culori/src/itp/convertXyz65ToItp.js
|
|
14664
15177
|
var toAbs = (c2 = 0) => Math.max(c2 * YW, 0);
|
|
14665
|
-
var convertXyz65ToItp = ({ x, y, z:
|
|
15178
|
+
var convertXyz65ToItp = ({ x, y, z: z68, alpha }) => {
|
|
14666
15179
|
const absX = toAbs(x);
|
|
14667
15180
|
const absY = toAbs(y);
|
|
14668
|
-
const absZ = toAbs(
|
|
15181
|
+
const absZ = toAbs(z68);
|
|
14669
15182
|
const l2 = transferPqEncode(
|
|
14670
15183
|
0.3592832590121217 * absX + 0.6976051147779502 * absY - 0.0358915932320289 * absZ
|
|
14671
15184
|
);
|
|
@@ -14723,15 +15236,15 @@ var jabPqEncode = (v) => {
|
|
|
14723
15236
|
return Math.pow((C1 + C2 * vn3) / (1 + C3 * vn3), p);
|
|
14724
15237
|
};
|
|
14725
15238
|
var abs = (v = 0) => Math.max(v * 203, 0);
|
|
14726
|
-
var convertXyz65ToJab = ({ x, y, z:
|
|
15239
|
+
var convertXyz65ToJab = ({ x, y, z: z68, alpha }) => {
|
|
14727
15240
|
x = abs(x);
|
|
14728
15241
|
y = abs(y);
|
|
14729
|
-
|
|
14730
|
-
let xp = 1.15 * x - 0.15 *
|
|
15242
|
+
z68 = abs(z68);
|
|
15243
|
+
let xp = 1.15 * x - 0.15 * z68;
|
|
14731
15244
|
let yp = 0.66 * y + 0.34 * x;
|
|
14732
|
-
let l2 = jabPqEncode(0.41478972 * xp + 0.579999 * yp + 0.014648 *
|
|
14733
|
-
let m = jabPqEncode(-0.20151 * xp + 1.120649 * yp + 0.0531008 *
|
|
14734
|
-
let s2 = jabPqEncode(-0.0166008 * xp + 0.2648 * yp + 0.6684799 *
|
|
15245
|
+
let l2 = jabPqEncode(0.41478972 * xp + 0.579999 * yp + 0.014648 * z68);
|
|
15246
|
+
let m = jabPqEncode(-0.20151 * xp + 1.120649 * yp + 0.0531008 * z68);
|
|
15247
|
+
let s2 = jabPqEncode(-0.0166008 * xp + 0.2648 * yp + 0.6684799 * z68);
|
|
14735
15248
|
let i = (l2 + m) / 2;
|
|
14736
15249
|
let res = {
|
|
14737
15250
|
mode: "jab",
|
|
@@ -14917,14 +15430,14 @@ var convertLabToXyz50 = ({ l: l2, a, b, alpha }) => {
|
|
|
14917
15430
|
var convertLabToXyz50_default = convertLabToXyz50;
|
|
14918
15431
|
|
|
14919
15432
|
// ../../node_modules/culori/src/xyz50/convertXyz50ToRgb.js
|
|
14920
|
-
var convertXyz50ToRgb = ({ x, y, z:
|
|
15433
|
+
var convertXyz50ToRgb = ({ x, y, z: z68, alpha }) => {
|
|
14921
15434
|
if (x === void 0) x = 0;
|
|
14922
15435
|
if (y === void 0) y = 0;
|
|
14923
|
-
if (
|
|
15436
|
+
if (z68 === void 0) z68 = 0;
|
|
14924
15437
|
let res = convertLrgbToRgb_default({
|
|
14925
|
-
r: x * 3.1341359569958707 - y * 1.6173863321612538 - 0.4906619460083532 *
|
|
14926
|
-
g: x * -0.978795502912089 + y * 1.916254567259524 + 0.03344273116131949 *
|
|
14927
|
-
b: x * 0.07195537988411677 - y * 0.2289768264158322 + 1.405386058324125 *
|
|
15438
|
+
r: x * 3.1341359569958707 - y * 1.6173863321612538 - 0.4906619460083532 * z68,
|
|
15439
|
+
g: x * -0.978795502912089 + y * 1.916254567259524 + 0.03344273116131949 * z68,
|
|
15440
|
+
b: x * 0.07195537988411677 - y * 0.2289768264158322 + 1.405386058324125 * z68
|
|
14928
15441
|
});
|
|
14929
15442
|
if (alpha !== void 0) {
|
|
14930
15443
|
res.alpha = alpha;
|
|
@@ -14955,13 +15468,13 @@ var convertRgbToXyz50_default = convertRgbToXyz50;
|
|
|
14955
15468
|
|
|
14956
15469
|
// ../../node_modules/culori/src/lab/convertXyz50ToLab.js
|
|
14957
15470
|
var f2 = (value) => value > e3 ? Math.cbrt(value) : (k3 * value + 16) / 116;
|
|
14958
|
-
var convertXyz50ToLab = ({ x, y, z:
|
|
15471
|
+
var convertXyz50ToLab = ({ x, y, z: z68, alpha }) => {
|
|
14959
15472
|
if (x === void 0) x = 0;
|
|
14960
15473
|
if (y === void 0) y = 0;
|
|
14961
|
-
if (
|
|
15474
|
+
if (z68 === void 0) z68 = 0;
|
|
14962
15475
|
let f0 = f2(x / D50.X);
|
|
14963
15476
|
let f1 = f2(y / D50.Y);
|
|
14964
|
-
let f22 = f2(
|
|
15477
|
+
let f22 = f2(z68 / D50.Z);
|
|
14965
15478
|
let res = {
|
|
14966
15479
|
mode: "lab",
|
|
14967
15480
|
l: 116 * f1 - 16,
|
|
@@ -15196,18 +15709,18 @@ var convertLchuvToLuv = ({ l: l2, c: c2, h, alpha }) => {
|
|
|
15196
15709
|
var convertLchuvToLuv_default = convertLchuvToLuv;
|
|
15197
15710
|
|
|
15198
15711
|
// ../../node_modules/culori/src/luv/convertXyz50ToLuv.js
|
|
15199
|
-
var u_fn = (x, y,
|
|
15200
|
-
var v_fn = (x, y,
|
|
15712
|
+
var u_fn = (x, y, z68) => 4 * x / (x + 15 * y + 3 * z68);
|
|
15713
|
+
var v_fn = (x, y, z68) => 9 * y / (x + 15 * y + 3 * z68);
|
|
15201
15714
|
var un = u_fn(D50.X, D50.Y, D50.Z);
|
|
15202
15715
|
var vn = v_fn(D50.X, D50.Y, D50.Z);
|
|
15203
15716
|
var l_fn = (value) => value <= e3 ? k3 * value : 116 * Math.cbrt(value) - 16;
|
|
15204
|
-
var convertXyz50ToLuv = ({ x, y, z:
|
|
15717
|
+
var convertXyz50ToLuv = ({ x, y, z: z68, alpha }) => {
|
|
15205
15718
|
if (x === void 0) x = 0;
|
|
15206
15719
|
if (y === void 0) y = 0;
|
|
15207
|
-
if (
|
|
15720
|
+
if (z68 === void 0) z68 = 0;
|
|
15208
15721
|
let l2 = l_fn(y / D50.Y);
|
|
15209
|
-
let u = u_fn(x, y,
|
|
15210
|
-
let v = v_fn(x, y,
|
|
15722
|
+
let u = u_fn(x, y, z68);
|
|
15723
|
+
let v = v_fn(x, y, z68);
|
|
15211
15724
|
if (!isFinite(u) || !isFinite(v)) {
|
|
15212
15725
|
l2 = u = v = 0;
|
|
15213
15726
|
} else {
|
|
@@ -15228,8 +15741,8 @@ var convertXyz50ToLuv = ({ x, y, z: z61, alpha }) => {
|
|
|
15228
15741
|
var convertXyz50ToLuv_default = convertXyz50ToLuv;
|
|
15229
15742
|
|
|
15230
15743
|
// ../../node_modules/culori/src/luv/convertLuvToXyz50.js
|
|
15231
|
-
var u_fn2 = (x, y,
|
|
15232
|
-
var v_fn2 = (x, y,
|
|
15744
|
+
var u_fn2 = (x, y, z68) => 4 * x / (x + 15 * y + 3 * z68);
|
|
15745
|
+
var v_fn2 = (x, y, z68) => 9 * y / (x + 15 * y + 3 * z68);
|
|
15233
15746
|
var un2 = u_fn2(D50.X, D50.Y, D50.Z);
|
|
15234
15747
|
var vn2 = v_fn2(D50.X, D50.Y, D50.Z);
|
|
15235
15748
|
var convertLuvToXyz50 = ({ l: l2, u, v, alpha }) => {
|
|
@@ -15243,8 +15756,8 @@ var convertLuvToXyz50 = ({ l: l2, u, v, alpha }) => {
|
|
|
15243
15756
|
let vp = v / (13 * l2) + vn2;
|
|
15244
15757
|
let y = D50.Y * (l2 <= 8 ? l2 / k3 : Math.pow((l2 + 16) / 116, 3));
|
|
15245
15758
|
let x = y * (9 * up) / (4 * vp);
|
|
15246
|
-
let
|
|
15247
|
-
let res = { mode: "xyz50", x, y, z:
|
|
15759
|
+
let z68 = y * (12 - 3 * up - 20 * vp) / (4 * vp);
|
|
15760
|
+
let res = { mode: "xyz50", x, y, z: z68 };
|
|
15248
15761
|
if (alpha !== void 0) {
|
|
15249
15762
|
res.alpha = alpha;
|
|
15250
15763
|
}
|
|
@@ -15861,15 +16374,15 @@ var convertP3ToXyz65 = (rgb2) => {
|
|
|
15861
16374
|
var convertP3ToXyz65_default = convertP3ToXyz65;
|
|
15862
16375
|
|
|
15863
16376
|
// ../../node_modules/culori/src/p3/convertXyz65ToP3.js
|
|
15864
|
-
var convertXyz65ToP3 = ({ x, y, z:
|
|
16377
|
+
var convertXyz65ToP3 = ({ x, y, z: z68, alpha }) => {
|
|
15865
16378
|
if (x === void 0) x = 0;
|
|
15866
16379
|
if (y === void 0) y = 0;
|
|
15867
|
-
if (
|
|
16380
|
+
if (z68 === void 0) z68 = 0;
|
|
15868
16381
|
let res = convertLrgbToRgb_default(
|
|
15869
16382
|
{
|
|
15870
|
-
r: x * 2.4934969119414263 - y * 0.9313836179191242 - 0.402710784450717 *
|
|
15871
|
-
g: x * -0.8294889695615749 + y * 1.7626640603183465 + 0.0236246858419436 *
|
|
15872
|
-
b: x * 0.0358458302437845 - y * 0.0761723892680418 + 0.9568845240076871 *
|
|
16383
|
+
r: x * 2.4934969119414263 - y * 0.9313836179191242 - 0.402710784450717 * z68,
|
|
16384
|
+
g: x * -0.8294889695615749 + y * 1.7626640603183465 + 0.0236246858419436 * z68,
|
|
16385
|
+
b: x * 0.0358458302437845 - y * 0.0761723892680418 + 0.9568845240076871 * z68
|
|
15873
16386
|
},
|
|
15874
16387
|
"p3"
|
|
15875
16388
|
);
|
|
@@ -15904,19 +16417,19 @@ var gamma2 = (v) => {
|
|
|
15904
16417
|
}
|
|
15905
16418
|
return 16 * v;
|
|
15906
16419
|
};
|
|
15907
|
-
var convertXyz50ToProphoto = ({ x, y, z:
|
|
16420
|
+
var convertXyz50ToProphoto = ({ x, y, z: z68, alpha }) => {
|
|
15908
16421
|
if (x === void 0) x = 0;
|
|
15909
16422
|
if (y === void 0) y = 0;
|
|
15910
|
-
if (
|
|
16423
|
+
if (z68 === void 0) z68 = 0;
|
|
15911
16424
|
let res = {
|
|
15912
16425
|
mode: "prophoto",
|
|
15913
16426
|
r: gamma2(
|
|
15914
|
-
x * 1.3457868816471585 - y * 0.2555720873797946 - 0.0511018649755453 *
|
|
16427
|
+
x * 1.3457868816471585 - y * 0.2555720873797946 - 0.0511018649755453 * z68
|
|
15915
16428
|
),
|
|
15916
16429
|
g: gamma2(
|
|
15917
|
-
x * -0.5446307051249019 + y * 1.5082477428451466 + 0.0205274474364214 *
|
|
16430
|
+
x * -0.5446307051249019 + y * 1.5082477428451466 + 0.0205274474364214 * z68
|
|
15918
16431
|
),
|
|
15919
|
-
b: gamma2(x * 0 + y * 0 + 1.2119675456389452 *
|
|
16432
|
+
b: gamma2(x * 0 + y * 0 + 1.2119675456389452 * z68)
|
|
15920
16433
|
};
|
|
15921
16434
|
if (alpha !== void 0) {
|
|
15922
16435
|
res.alpha = alpha;
|
|
@@ -15976,20 +16489,20 @@ var gamma3 = (v) => {
|
|
|
15976
16489
|
}
|
|
15977
16490
|
return 4.5 * v;
|
|
15978
16491
|
};
|
|
15979
|
-
var convertXyz65ToRec2020 = ({ x, y, z:
|
|
16492
|
+
var convertXyz65ToRec2020 = ({ x, y, z: z68, alpha }) => {
|
|
15980
16493
|
if (x === void 0) x = 0;
|
|
15981
16494
|
if (y === void 0) y = 0;
|
|
15982
|
-
if (
|
|
16495
|
+
if (z68 === void 0) z68 = 0;
|
|
15983
16496
|
let res = {
|
|
15984
16497
|
mode: "rec2020",
|
|
15985
16498
|
r: gamma3(
|
|
15986
|
-
x * 1.7166511879712683 - y * 0.3556707837763925 - 0.2533662813736599 *
|
|
16499
|
+
x * 1.7166511879712683 - y * 0.3556707837763925 - 0.2533662813736599 * z68
|
|
15987
16500
|
),
|
|
15988
16501
|
g: gamma3(
|
|
15989
|
-
x * -0.6666843518324893 + y * 1.6164812366349395 + 0.0157685458139111 *
|
|
16502
|
+
x * -0.6666843518324893 + y * 1.6164812366349395 + 0.0157685458139111 * z68
|
|
15990
16503
|
),
|
|
15991
16504
|
b: gamma3(
|
|
15992
|
-
x * 0.0176398574453108 - y * 0.0427706132578085 + 0.9421031212354739 *
|
|
16505
|
+
x * 0.0176398574453108 - y * 0.0427706132578085 + 0.9421031212354739 * z68
|
|
15993
16506
|
)
|
|
15994
16507
|
};
|
|
15995
16508
|
if (alpha !== void 0) {
|
|
@@ -16142,15 +16655,15 @@ var definition_default26 = definition26;
|
|
|
16142
16655
|
|
|
16143
16656
|
// ../../node_modules/culori/src/xyz65/convertXyz65ToXyz50.js
|
|
16144
16657
|
var convertXyz65ToXyz50 = (xyz652) => {
|
|
16145
|
-
let { x, y, z:
|
|
16658
|
+
let { x, y, z: z68, alpha } = xyz652;
|
|
16146
16659
|
if (x === void 0) x = 0;
|
|
16147
16660
|
if (y === void 0) y = 0;
|
|
16148
|
-
if (
|
|
16661
|
+
if (z68 === void 0) z68 = 0;
|
|
16149
16662
|
let res = {
|
|
16150
16663
|
mode: "xyz50",
|
|
16151
|
-
x: 1.0479298208405488 * x + 0.0229467933410191 * y - 0.0501922295431356 *
|
|
16152
|
-
y: 0.0296278156881593 * x + 0.990434484573249 * y - 0.0170738250293851 *
|
|
16153
|
-
z: -0.0092430581525912 * x + 0.0150551448965779 * y + 0.7518742899580008 *
|
|
16664
|
+
x: 1.0479298208405488 * x + 0.0229467933410191 * y - 0.0501922295431356 * z68,
|
|
16665
|
+
y: 0.0296278156881593 * x + 0.990434484573249 * y - 0.0170738250293851 * z68,
|
|
16666
|
+
z: -0.0092430581525912 * x + 0.0150551448965779 * y + 0.7518742899580008 * z68
|
|
16154
16667
|
};
|
|
16155
16668
|
if (alpha !== void 0) {
|
|
16156
16669
|
res.alpha = alpha;
|
|
@@ -16161,15 +16674,15 @@ var convertXyz65ToXyz50_default = convertXyz65ToXyz50;
|
|
|
16161
16674
|
|
|
16162
16675
|
// ../../node_modules/culori/src/xyz65/convertXyz50ToXyz65.js
|
|
16163
16676
|
var convertXyz50ToXyz65 = (xyz502) => {
|
|
16164
|
-
let { x, y, z:
|
|
16677
|
+
let { x, y, z: z68, alpha } = xyz502;
|
|
16165
16678
|
if (x === void 0) x = 0;
|
|
16166
16679
|
if (y === void 0) y = 0;
|
|
16167
|
-
if (
|
|
16680
|
+
if (z68 === void 0) z68 = 0;
|
|
16168
16681
|
let res = {
|
|
16169
16682
|
mode: "xyz65",
|
|
16170
|
-
x: 0.9554734527042182 * x - 0.0230985368742614 * y + 0.0632593086610217 *
|
|
16171
|
-
y: -0.0283697069632081 * x + 1.0099954580058226 * y + 0.021041398966943 *
|
|
16172
|
-
z: 0.0123140016883199 * x - 0.0205076964334779 * y + 1.3303659366080753 *
|
|
16683
|
+
x: 0.9554734527042182 * x - 0.0230985368742614 * y + 0.0632593086610217 * z68,
|
|
16684
|
+
y: -0.0283697069632081 * x + 1.0099954580058226 * y + 0.021041398966943 * z68,
|
|
16685
|
+
z: 0.0123140016883199 * x - 0.0205076964334779 * y + 1.3303659366080753 * z68
|
|
16173
16686
|
};
|
|
16174
16687
|
if (alpha !== void 0) {
|
|
16175
16688
|
res.alpha = alpha;
|
|
@@ -16406,6 +16919,13 @@ function validateTermsString(termsString) {
|
|
|
16406
16919
|
};
|
|
16407
16920
|
}
|
|
16408
16921
|
} else {
|
|
16922
|
+
if (term.startsWith("*") || term.endsWith("*")) {
|
|
16923
|
+
const inner = term.replace(/^\*+|\*+$/g, "");
|
|
16924
|
+
return {
|
|
16925
|
+
valid: false,
|
|
16926
|
+
error: `Term "${term}" has an unmatched asterisk. Use *${inner}* for exact matching, or ${inner} for loose matching.`
|
|
16927
|
+
};
|
|
16928
|
+
}
|
|
16409
16929
|
normalizedTerm = term.replace(/\s+/g, "");
|
|
16410
16930
|
if (normalizedTerm.length < 6) {
|
|
16411
16931
|
return {
|
|
@@ -17003,6 +17523,8 @@ var SCAN_TEMPLATES = [
|
|
|
17003
17523
|
new Map(
|
|
17004
17524
|
SCAN_TEMPLATES.map((template) => [template.id, template])
|
|
17005
17525
|
);
|
|
17526
|
+
var DARK_WEB_ENTITY_SEARCH_KINDS = ["domain", "email", "crypto"];
|
|
17527
|
+
zod.z.enum(DARK_WEB_ENTITY_SEARCH_KINDS);
|
|
17006
17528
|
|
|
17007
17529
|
// src/client.ts
|
|
17008
17530
|
function trimTrailingSlashes(url) {
|