@chainpatrol/sdk 0.11.0 → 1.0.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 +26 -0
- package/dist/api/index.d.mts +48 -3
- package/dist/api/index.d.ts +48 -3
- package/dist/api/index.js.map +1 -1
- package/dist/api/index.mjs.map +1 -1
- package/dist/{chunk-UTEZF4EZ.mjs → chunk-S5BCAUOT.mjs} +4 -4
- package/dist/chunk-S5BCAUOT.mjs.map +1 -0
- package/dist/index.js +330 -1264
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +331 -1265
- package/dist/index.mjs.map +1 -1
- package/dist/skill/cli.js +2 -2
- package/dist/skill/cli.js.map +1 -1
- package/dist/skill/cli.mjs +1 -1
- package/dist/skill/index.js +2 -2
- package/dist/skill/index.js.map +1 -1
- package/dist/skill/index.mjs +1 -1
- package/package.json +1 -1
- package/dist/chunk-UTEZF4EZ.mjs.map +0 -1
package/dist/index.js
CHANGED
|
@@ -614,6 +614,32 @@ zod.z.object({
|
|
|
614
614
|
email: zod.z.string().email(),
|
|
615
615
|
description: zod.z.string().optional().default("")
|
|
616
616
|
});
|
|
617
|
+
zod.z.object({
|
|
618
|
+
/** Canonicalization algorithm version the client computed its prefixes with. */
|
|
619
|
+
algoVersion: zod.z.number().int().positive(),
|
|
620
|
+
/** 4-byte (8-hex-char) prefixes that hit the client's local index. */
|
|
621
|
+
prefixes: zod.z.array(zod.z.string().regex(/^[0-9a-f]{8}$/)).min(1).max(200)
|
|
622
|
+
}).describe("Blocklist confirm request");
|
|
623
|
+
zod.z.object({
|
|
624
|
+
/** Full 64-char SHA-256 hashes of blocked expressions, grouped by prefix. */
|
|
625
|
+
fullHashes: zod.z.record(zod.z.string(), zod.z.array(zod.z.string()))
|
|
626
|
+
}).describe("Blocklist confirm response");
|
|
627
|
+
zod.z.void().describe("Blocklist version request");
|
|
628
|
+
zod.z.object({
|
|
629
|
+
/** Canonicalization algorithm version the artifacts + confirm are built with. */
|
|
630
|
+
algoVersion: zod.z.number().int().positive(),
|
|
631
|
+
snapshot: zod.z.object({
|
|
632
|
+
token: zod.z.string(),
|
|
633
|
+
url: zod.z.string().url(),
|
|
634
|
+
prefixBytes: zod.z.number().int().positive(),
|
|
635
|
+
count: zod.z.number().int().nonnegative()
|
|
636
|
+
}),
|
|
637
|
+
recent: zod.z.object({
|
|
638
|
+
token: zod.z.string(),
|
|
639
|
+
url: zod.z.string().url(),
|
|
640
|
+
windowSeconds: zod.z.number().int().positive()
|
|
641
|
+
})
|
|
642
|
+
}).describe("Blocklist version response");
|
|
617
643
|
|
|
618
644
|
// ../../node_modules/luxon/src/errors.js
|
|
619
645
|
var LuxonError = class extends Error {
|
|
@@ -7035,7 +7061,7 @@ var BrandType = {
|
|
|
7035
7061
|
ORGANIZATION: "ORGANIZATION"
|
|
7036
7062
|
};
|
|
7037
7063
|
var SubscriptionStatus = {
|
|
7038
|
-
|
|
7064
|
+
POC: "POC",
|
|
7039
7065
|
ACTIVE: "ACTIVE",
|
|
7040
7066
|
PROSPECT: "PROSPECT",
|
|
7041
7067
|
INTEGRATION: "INTEGRATION",
|
|
@@ -7131,7 +7157,8 @@ var AssetType = {
|
|
|
7131
7157
|
BANDCAMP: "BANDCAMP",
|
|
7132
7158
|
ARCHIVE_ORG: "ARCHIVE_ORG",
|
|
7133
7159
|
FIVE_HUNDRED_PX: "FIVE_HUNDRED_PX",
|
|
7134
|
-
LUMA: "LUMA"
|
|
7160
|
+
LUMA: "LUMA",
|
|
7161
|
+
SMARTMONEYMATCH: "SMARTMONEYMATCH"
|
|
7135
7162
|
};
|
|
7136
7163
|
var LivenessStatus = {
|
|
7137
7164
|
UNKNOWN: "UNKNOWN",
|
|
@@ -7657,14 +7684,6 @@ zod.z.object({
|
|
|
7657
7684
|
warnAgeHours: zod.z.number().int().positive().default(24 * 7),
|
|
7658
7685
|
failAgeHours: zod.z.number().int().positive().default(24 * 14)
|
|
7659
7686
|
});
|
|
7660
|
-
zod.z.object({
|
|
7661
|
-
slug: zod.z.string().min(1),
|
|
7662
|
-
warnThreshold: zod.z.number().int().nonnegative().default(200)
|
|
7663
|
-
});
|
|
7664
|
-
zod.z.object({
|
|
7665
|
-
slug: zod.z.string().min(1),
|
|
7666
|
-
warnAgeHours: zod.z.number().int().nonnegative().default(24 * 30)
|
|
7667
|
-
});
|
|
7668
7687
|
zod.z.object({
|
|
7669
7688
|
slug: zod.z.string().min(1),
|
|
7670
7689
|
warnAgeHours: zod.z.number().int().nonnegative().default(24 * 30),
|
|
@@ -7900,6 +7919,26 @@ Returns all brands belonging to the organization associated with your API key,
|
|
|
7900
7919
|
including sub-brands (\`ORGANIZATION\`) and individual / employee brands
|
|
7901
7920
|
(\`INDIVIDUAL\`). Soft-deleted brands are excluded.`
|
|
7902
7921
|
);
|
|
7922
|
+
var brandLegalDocumentSchema = zod.z.object({
|
|
7923
|
+
present: zod.z.boolean().describe("Whether the brand has this document attached"),
|
|
7924
|
+
fileName: zod.z.string().nullable().describe("Original filename of the uploaded document (null when not present)"),
|
|
7925
|
+
fileUrl: zod.z.string().nullable().describe("Direct URL to view or download the document (null when not present)")
|
|
7926
|
+
});
|
|
7927
|
+
var brandTrademarkRegistrationSchema = zod.z.object({
|
|
7928
|
+
id: zod.z.number().describe("Trademark registration ID"),
|
|
7929
|
+
brandName: zod.z.string().describe("Trademarked brand name as it appears on the registration"),
|
|
7930
|
+
trademarkOffice: zod.z.string().describe("Issuing trademark office (e.g. `USPTO`, `EUIPO`)"),
|
|
7931
|
+
registrationNumber: zod.z.string().describe("Registration number assigned by the office"),
|
|
7932
|
+
goodsAndServicesClass: zod.z.string().describe("Nice Classification class(es) the registration covers"),
|
|
7933
|
+
rightsOwnerName: zod.z.string().nullable().describe("Legal entity the trademark is registered to, if recorded"),
|
|
7934
|
+
registrationPageUrl: zod.z.string().nullable().describe("Public URL on the trademark office's site, if recorded"),
|
|
7935
|
+
certificateFileName: zod.z.string().nullable().describe(
|
|
7936
|
+
"Original filename of the uploaded certificate PDF (null when no certificate is attached)"
|
|
7937
|
+
),
|
|
7938
|
+
certificateFileUrl: zod.z.string().nullable().describe(
|
|
7939
|
+
"Direct URL to view or download the certificate PDF (null when no certificate is attached)"
|
|
7940
|
+
)
|
|
7941
|
+
});
|
|
7903
7942
|
var brandItemSchema = zod.z.object({
|
|
7904
7943
|
id: zod.z.number().describe("Brand ID"),
|
|
7905
7944
|
slug: zod.z.string().describe("Brand slug (stable, URL-safe identifier)"),
|
|
@@ -7916,14 +7955,24 @@ var brandItemSchema = zod.z.object({
|
|
|
7916
7955
|
excludedTerms: zod.z.array(zod.z.string()).describe("Terms that should be excluded when matching this brand"),
|
|
7917
7956
|
tickers: zod.z.array(zod.z.string()).describe("Ticker symbols associated with the brand (e.g. `$JUP`)"),
|
|
7918
7957
|
brandGroupId: zod.z.number().nullable().describe("Group this brand belongs to (only set for `INDIVIDUAL` brands)"),
|
|
7919
|
-
createdAt: zod.z.date().describe("When the brand was created")
|
|
7958
|
+
createdAt: zod.z.date().describe("When the brand was created"),
|
|
7959
|
+
useOrganizationDocs: zod.z.boolean().describe(
|
|
7960
|
+
"When true, this brand inherits its Letter of Authorization and Power of Attorney from the organization rather than carrying its own. The `legalDocuments` block below always reflects the brand-level attachments \u2014 read `/user/orgs/{slug}` for the org-level fallbacks."
|
|
7961
|
+
),
|
|
7962
|
+
legalDocuments: zod.z.object({
|
|
7963
|
+
letterOfAuthorization: brandLegalDocumentSchema,
|
|
7964
|
+
powerOfAttorney: brandLegalDocumentSchema
|
|
7965
|
+
}).describe("Brand-level Letter of Authorization and Power of Attorney attachments"),
|
|
7966
|
+
trademarkRegistrations: zod.z.array(brandTrademarkRegistrationSchema).describe(
|
|
7967
|
+
"Trademark registrations attached to this brand. An empty array means no trademarks are on file for the brand \u2014 use this to identify brands that still need them added."
|
|
7968
|
+
)
|
|
7920
7969
|
});
|
|
7921
7970
|
zod.z.object({
|
|
7922
7971
|
brands: zod.z.array(brandItemSchema).describe("List of brands")
|
|
7923
7972
|
}).describe("Successful operation");
|
|
7924
7973
|
var FILTERABLE_SUBSCRIPTION_STATUSES = [
|
|
7925
7974
|
SubscriptionStatus.PROSPECT,
|
|
7926
|
-
SubscriptionStatus.
|
|
7975
|
+
SubscriptionStatus.POC,
|
|
7927
7976
|
SubscriptionStatus.ACTIVE,
|
|
7928
7977
|
SubscriptionStatus.INTEGRATION
|
|
7929
7978
|
];
|
|
@@ -7998,6 +8047,30 @@ var UserOrgIntegrationsSchema = zod.z.object({
|
|
|
7998
8047
|
intercom: zod.z.boolean(),
|
|
7999
8048
|
moderation: zod.z.boolean()
|
|
8000
8049
|
});
|
|
8050
|
+
var UserOrgLegalDocumentSchema = zod.z.object({
|
|
8051
|
+
present: zod.z.boolean().describe("Whether the organization has this document attached"),
|
|
8052
|
+
fileName: zod.z.string().nullable().describe("Original filename of the uploaded document (null when not present)"),
|
|
8053
|
+
fileUrl: zod.z.string().nullable().describe("Direct URL to view or download the document (null when not present)")
|
|
8054
|
+
});
|
|
8055
|
+
var UserOrgLegalDocumentsSchema = zod.z.object({
|
|
8056
|
+
letterOfAuthorization: UserOrgLegalDocumentSchema,
|
|
8057
|
+
powerOfAttorney: UserOrgLegalDocumentSchema
|
|
8058
|
+
});
|
|
8059
|
+
var UserOrgTrademarkRegistrationSchema = zod.z.object({
|
|
8060
|
+
id: zod.z.number().describe("Trademark registration ID"),
|
|
8061
|
+
brandName: zod.z.string().describe("Trademarked brand name as it appears on the registration"),
|
|
8062
|
+
trademarkOffice: zod.z.string().describe("Issuing trademark office (e.g. `USPTO`, `EUIPO`)"),
|
|
8063
|
+
registrationNumber: zod.z.string().describe("Registration number assigned by the office"),
|
|
8064
|
+
goodsAndServicesClass: zod.z.string().describe("Nice Classification class(es) the registration covers"),
|
|
8065
|
+
rightsOwnerName: zod.z.string().nullable().describe("Legal entity the trademark is registered to, if recorded"),
|
|
8066
|
+
registrationPageUrl: zod.z.string().nullable().describe("Public URL on the trademark office's site, if recorded"),
|
|
8067
|
+
certificateFileName: zod.z.string().nullable().describe(
|
|
8068
|
+
"Original filename of the uploaded certificate PDF (null when no certificate is attached)"
|
|
8069
|
+
),
|
|
8070
|
+
certificateFileUrl: zod.z.string().nullable().describe(
|
|
8071
|
+
"Direct URL to view or download the certificate PDF (null when no certificate is attached)"
|
|
8072
|
+
)
|
|
8073
|
+
});
|
|
8001
8074
|
var UserOrgSchema = zod.z.object({
|
|
8002
8075
|
id: zod.z.number(),
|
|
8003
8076
|
name: zod.z.string(),
|
|
@@ -8015,7 +8088,13 @@ var UserOrgSchema = zod.z.object({
|
|
|
8015
8088
|
}),
|
|
8016
8089
|
integrations: UserOrgIntegrationsSchema,
|
|
8017
8090
|
obligatoryAdminApproval: UserOrgObligatoryAdminApprovalSchema,
|
|
8018
|
-
pendingServiceApprovals: zod.z.array(PendingServiceApprovalSchema)
|
|
8091
|
+
pendingServiceApprovals: zod.z.array(PendingServiceApprovalSchema),
|
|
8092
|
+
legalDocuments: UserOrgLegalDocumentsSchema.describe(
|
|
8093
|
+
"Org-level Letter of Authorization and Power of Attorney attachments"
|
|
8094
|
+
),
|
|
8095
|
+
trademarkRegistrations: zod.z.array(UserOrgTrademarkRegistrationSchema).describe(
|
|
8096
|
+
"Org-level trademark registrations attached to the organization. An empty array means no trademarks are on file \u2014 use this to identify customers who still need to add them."
|
|
8097
|
+
)
|
|
8019
8098
|
});
|
|
8020
8099
|
zod.z.object({
|
|
8021
8100
|
organizations: zod.z.array(UserOrgSchema)
|
|
@@ -8060,7 +8139,7 @@ zod.z.object({
|
|
|
8060
8139
|
"Shortcut for 'every org the caller is authorized to read'. Reuses the same filter logic as `/user/orgs`: org-scoped API keys are rejected (they're pinned to one org \u2014 use the default form); user API keys / Bearer sessions resolve to the user's memberships (or every active org for staff). Combine with `subscriptionStatus` and `services` to narrow (e.g. only paying customers with takedowns enabled). The resolved org set is still capped at " + String(ORGANIZATION_METRICS_MAX_SLUGS) + " and a 413 is returned if exceeded. Mutually exclusive with `organizationSlug`, `slugs`, and `brandSlug`."
|
|
8061
8140
|
),
|
|
8062
8141
|
subscriptionStatus: zod.z.array(UserOrgsSubscriptionStatusSchema).min(1).optional().describe(
|
|
8063
|
-
"Only meaningful with `allMyOrgs: true`. Defaults to the same set `/user/orgs` uses (ACTIVE/
|
|
8142
|
+
"Only meaningful with `allMyOrgs: true`. Defaults to the same set `/user/orgs` uses (ACTIVE/POC/PROSPECT/INTEGRATION \u2014 INACTIVE is always excluded)."
|
|
8064
8143
|
),
|
|
8065
8144
|
services: organizationMetricsServicesFilterSchema.describe(
|
|
8066
8145
|
"Only meaningful with `allMyOrgs: true`. Same shape as `/user/orgs`'s `services` filter \u2014 every service accepts `{ active }`, and **only `takedowns` additionally accepts `automated`** (the one service where manual-vs-automated changes real platform behavior). E.g. `{ takedowns: { active: true, automated: false } }` for 'orgs with takedowns enabled but automation off'."
|
|
@@ -8229,6 +8308,7 @@ var AssetScanEnrichmentSource = /* @__PURE__ */ ((AssetScanEnrichmentSource2) =>
|
|
|
8229
8308
|
AssetScanEnrichmentSource2["REDDIT_API"] = "reddit_api";
|
|
8230
8309
|
AssetScanEnrichmentSource2["MAILS_API"] = "mails_api";
|
|
8231
8310
|
AssetScanEnrichmentSource2["TELNYX_LOOKUP"] = "telnyx_lookup";
|
|
8311
|
+
AssetScanEnrichmentSource2["TWILIO_LOOKUP"] = "twilio_lookup";
|
|
8232
8312
|
AssetScanEnrichmentSource2["DAILYMOTION_API"] = "dailymotion_api";
|
|
8233
8313
|
AssetScanEnrichmentSource2["VIMEO_API"] = "vimeo_api";
|
|
8234
8314
|
AssetScanEnrichmentSource2["STACKBLITZ_API"] = "stackblitz_api";
|
|
@@ -8330,6 +8410,7 @@ var ASSET_SCAN_ENRICHMENT_SOURCE_LABELS = {
|
|
|
8330
8410
|
["mails_api" /* MAILS_API */]: "Mails.so API",
|
|
8331
8411
|
// Phone Number
|
|
8332
8412
|
["telnyx_lookup" /* TELNYX_LOOKUP */]: "Telnyx Lookup",
|
|
8413
|
+
["twilio_lookup" /* TWILIO_LOOKUP */]: "Twilio Lookup",
|
|
8333
8414
|
// DailyMotion
|
|
8334
8415
|
["dailymotion_api" /* DAILYMOTION_API */]: "DailyMotion API",
|
|
8335
8416
|
// Vimeo
|
|
@@ -8421,6 +8502,7 @@ var ASSET_SCAN_ENRICHMENT_SOURCE_TO_TYPES = {
|
|
|
8421
8502
|
["mails_api" /* MAILS_API */]: ["email_validation" /* EMAIL_VALIDATION */],
|
|
8422
8503
|
// Phone Number-related sources
|
|
8423
8504
|
["telnyx_lookup" /* TELNYX_LOOKUP */]: ["phone_lookup" /* PHONE_LOOKUP */],
|
|
8505
|
+
["twilio_lookup" /* TWILIO_LOOKUP */]: ["phone_lookup" /* PHONE_LOOKUP */],
|
|
8424
8506
|
// DailyMotion-related sources
|
|
8425
8507
|
["dailymotion_api" /* DAILYMOTION_API */]: [
|
|
8426
8508
|
"dailymotion_video" /* DAILYMOTION_VIDEO */
|
|
@@ -10814,124 +10896,34 @@ function slugify(string, options) {
|
|
|
10814
10896
|
return string;
|
|
10815
10897
|
}
|
|
10816
10898
|
|
|
10817
|
-
//
|
|
10818
|
-
var
|
|
10819
|
-
|
|
10820
|
-
|
|
10821
|
-
|
|
10822
|
-
|
|
10823
|
-
|
|
10824
|
-
|
|
10825
|
-
|
|
10826
|
-
|
|
10827
|
-
|
|
10828
|
-
|
|
10829
|
-
|
|
10830
|
-
|
|
10831
|
-
"
|
|
10832
|
-
"
|
|
10833
|
-
|
|
10834
|
-
|
|
10835
|
-
|
|
10836
|
-
|
|
10837
|
-
|
|
10838
|
-
|
|
10839
|
-
|
|
10840
|
-
|
|
10841
|
-
|
|
10842
|
-
|
|
10843
|
-
|
|
10844
|
-
|
|
10845
|
-
}
|
|
10846
|
-
domain = domain.replace(regexSeparators, ".");
|
|
10847
|
-
const labels = domain.split(".");
|
|
10848
|
-
const encoded = labels.map(callback).join(".");
|
|
10849
|
-
return result + encoded;
|
|
10850
|
-
}
|
|
10851
|
-
function basicToDigit(codePoint) {
|
|
10852
|
-
if (codePoint >= 48 && codePoint < 58) {
|
|
10853
|
-
return 26 + (codePoint - 48);
|
|
10854
|
-
}
|
|
10855
|
-
if (codePoint >= 65 && codePoint < 91) {
|
|
10856
|
-
return codePoint - 65;
|
|
10857
|
-
}
|
|
10858
|
-
if (codePoint >= 97 && codePoint < 123) {
|
|
10859
|
-
return codePoint - 97;
|
|
10860
|
-
}
|
|
10861
|
-
return base;
|
|
10862
|
-
}
|
|
10863
|
-
function adapt(delta, numPoints, firstTime) {
|
|
10864
|
-
let k4 = 0;
|
|
10865
|
-
delta = firstTime ? floor(delta / damp) : delta >> 1;
|
|
10866
|
-
delta += floor(delta / numPoints);
|
|
10867
|
-
for (
|
|
10868
|
-
;
|
|
10869
|
-
/* no initialization */
|
|
10870
|
-
delta > baseMinusTMin * tMax >> 1;
|
|
10871
|
-
k4 += base
|
|
10872
|
-
) {
|
|
10873
|
-
delta = floor(delta / baseMinusTMin);
|
|
10874
|
-
}
|
|
10875
|
-
return floor(k4 + (baseMinusTMin + 1) * delta / (delta + skew));
|
|
10876
|
-
}
|
|
10877
|
-
function decode(input) {
|
|
10878
|
-
const output = [];
|
|
10879
|
-
const inputLength = input.length;
|
|
10880
|
-
let i = 0;
|
|
10881
|
-
let n2 = initialN;
|
|
10882
|
-
let bias2 = initialBias;
|
|
10883
|
-
let basic = input.lastIndexOf(delimiter);
|
|
10884
|
-
if (basic < 0) {
|
|
10885
|
-
basic = 0;
|
|
10886
|
-
}
|
|
10887
|
-
for (let j = 0; j < basic; ++j) {
|
|
10888
|
-
if (input.charCodeAt(j) >= 128) {
|
|
10889
|
-
error("not-basic");
|
|
10890
|
-
}
|
|
10891
|
-
output.push(input.charCodeAt(j));
|
|
10892
|
-
}
|
|
10893
|
-
for (let index = basic > 0 ? basic + 1 : 0; index < inputLength; ) {
|
|
10894
|
-
const oldi = i;
|
|
10895
|
-
for (let w = 1, k4 = base; ; k4 += base) {
|
|
10896
|
-
if (index >= inputLength) {
|
|
10897
|
-
error("invalid-input");
|
|
10898
|
-
}
|
|
10899
|
-
const digit = basicToDigit(input.charCodeAt(index++));
|
|
10900
|
-
if (digit >= base) {
|
|
10901
|
-
error("invalid-input");
|
|
10902
|
-
}
|
|
10903
|
-
if (digit > floor((maxInt - i) / w)) {
|
|
10904
|
-
error("overflow");
|
|
10905
|
-
}
|
|
10906
|
-
i += digit * w;
|
|
10907
|
-
const t = k4 <= bias2 ? tMin : k4 >= bias2 + tMax ? tMax : k4 - bias2;
|
|
10908
|
-
if (digit < t) {
|
|
10909
|
-
break;
|
|
10910
|
-
}
|
|
10911
|
-
const baseMinusT = base - t;
|
|
10912
|
-
if (w > floor(maxInt / baseMinusT)) {
|
|
10913
|
-
error("overflow");
|
|
10914
|
-
}
|
|
10915
|
-
w *= baseMinusT;
|
|
10916
|
-
}
|
|
10917
|
-
const out = output.length + 1;
|
|
10918
|
-
bias2 = adapt(i - oldi, out, oldi == 0);
|
|
10919
|
-
if (floor(i / out) > maxInt - n2) {
|
|
10920
|
-
error("overflow");
|
|
10921
|
-
}
|
|
10922
|
-
n2 += floor(i / out);
|
|
10923
|
-
i %= out;
|
|
10924
|
-
output.splice(i++, 0, n2);
|
|
10925
|
-
}
|
|
10926
|
-
return String.fromCodePoint(...output);
|
|
10927
|
-
}
|
|
10928
|
-
function toUnicode(input) {
|
|
10929
|
-
return mapDomain(input, function(string) {
|
|
10930
|
-
return regexPunycode.test(string) ? decode(string.slice(4).toLowerCase()) : string;
|
|
10931
|
-
});
|
|
10932
|
-
}
|
|
10933
|
-
|
|
10934
|
-
// ../../internal/utils/src/url.ts
|
|
10899
|
+
// ../asset-parse/src/model.ts
|
|
10900
|
+
var AssetModel = /* @__PURE__ */ ((AssetModel2) => {
|
|
10901
|
+
AssetModel2["Addon"] = "addon";
|
|
10902
|
+
AssetModel2["App"] = "app";
|
|
10903
|
+
AssetModel2["Bot"] = "bot";
|
|
10904
|
+
AssetModel2["BusinessProfile"] = "business-profile";
|
|
10905
|
+
AssetModel2["Catalog"] = "catalog";
|
|
10906
|
+
AssetModel2["Collection"] = "collection";
|
|
10907
|
+
AssetModel2["Channel"] = "channel";
|
|
10908
|
+
AssetModel2["Group"] = "group";
|
|
10909
|
+
AssetModel2["Post"] = "post";
|
|
10910
|
+
AssetModel2["Profile"] = "profile";
|
|
10911
|
+
AssetModel2["Short"] = "short";
|
|
10912
|
+
AssetModel2["Video"] = "video";
|
|
10913
|
+
AssetModel2["Space"] = "space";
|
|
10914
|
+
AssetModel2["Issue"] = "issue";
|
|
10915
|
+
AssetModel2["PullRequest"] = "pull-request";
|
|
10916
|
+
AssetModel2["Discussion"] = "discussion";
|
|
10917
|
+
AssetModel2["Repository"] = "repository";
|
|
10918
|
+
AssetModel2["Article"] = "Article";
|
|
10919
|
+
AssetModel2["Comment"] = "comment";
|
|
10920
|
+
AssetModel2["List"] = "list";
|
|
10921
|
+
AssetModel2["Subreddit"] = "subreddit";
|
|
10922
|
+
AssetModel2["Community"] = "community";
|
|
10923
|
+
AssetModel2["MiniApp"] = "mini-app";
|
|
10924
|
+
AssetModel2["Developer"] = "developer";
|
|
10925
|
+
return AssetModel2;
|
|
10926
|
+
})(AssetModel || {});
|
|
10935
10927
|
function isUrl(input) {
|
|
10936
10928
|
if (input.trim() === "") {
|
|
10937
10929
|
return false;
|
|
@@ -10941,21 +10933,6 @@ function isUrl(input) {
|
|
|
10941
10933
|
}
|
|
10942
10934
|
return URL.canParse(input) || URL.canParse(`https://${input}`);
|
|
10943
10935
|
}
|
|
10944
|
-
function isEmail(input) {
|
|
10945
|
-
if (input.trim() === "") {
|
|
10946
|
-
return false;
|
|
10947
|
-
}
|
|
10948
|
-
const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
|
|
10949
|
-
return emailRegex.test(input);
|
|
10950
|
-
}
|
|
10951
|
-
function removeHttpProtocol(input) {
|
|
10952
|
-
return input.replace(/^https?:\/\//, "");
|
|
10953
|
-
}
|
|
10954
|
-
function stripDomainWildcardPrefix(domain) {
|
|
10955
|
-
const trimmedDomain = domain.trim();
|
|
10956
|
-
const strippedDomain = trimmedDomain.startsWith("*.") ? trimmedDomain.slice(2) : trimmedDomain;
|
|
10957
|
-
return strippedDomain.length > 0 ? strippedDomain : null;
|
|
10958
|
-
}
|
|
10959
10936
|
function getNormalizedUrl(input) {
|
|
10960
10937
|
if (!isUrl(input)) {
|
|
10961
10938
|
throw new Error(`Invalid URL: ${input}`);
|
|
@@ -10979,20 +10956,15 @@ function getNormalizedUrl(input) {
|
|
|
10979
10956
|
throw new Error(`Invalid URL: ${input}`);
|
|
10980
10957
|
}
|
|
10981
10958
|
}
|
|
10982
|
-
|
|
10983
|
-
if (!
|
|
10984
|
-
|
|
10985
|
-
return input;
|
|
10959
|
+
var ensureHttpsPrefix = (url) => {
|
|
10960
|
+
if (!url.startsWith("http")) {
|
|
10961
|
+
return `https://${url}`;
|
|
10986
10962
|
}
|
|
10987
|
-
return
|
|
10988
|
-
}
|
|
10989
|
-
function getRefangedUrl(input) {
|
|
10990
|
-
return input.replace(/hxxps/gi, "https").replace(/hxxp/gi, "http").replace(/\[:\/{2}\]/g, "://").replace(/\[\.\]/g, ".");
|
|
10991
|
-
}
|
|
10963
|
+
return url.replace(/^https?:\/{1,2}/, "https://");
|
|
10964
|
+
};
|
|
10992
10965
|
function getHostname(input) {
|
|
10993
10966
|
try {
|
|
10994
|
-
|
|
10995
|
-
return normalizedUrl.hostname;
|
|
10967
|
+
return getNormalizedUrl(input).hostname;
|
|
10996
10968
|
} catch (e4) {
|
|
10997
10969
|
return null;
|
|
10998
10970
|
}
|
|
@@ -11029,62 +11001,8 @@ function trimDomainToLevels(domain, options = { levels: 4 }) {
|
|
|
11029
11001
|
const trimmedSubdomains = subdomains.slice(Math.max(eTLDPlusOneIndex - (options.levels - 1), 0)).join(".");
|
|
11030
11002
|
return trimmedSubdomains;
|
|
11031
11003
|
}
|
|
11032
|
-
var ensureHttpsPrefix = (url) => {
|
|
11033
|
-
if (!url.startsWith("http")) {
|
|
11034
|
-
return `https://${url}`;
|
|
11035
|
-
}
|
|
11036
|
-
return url.replace(/^https?:\/{1,2}/, "https://");
|
|
11037
|
-
};
|
|
11038
|
-
function containsPunycode(url) {
|
|
11039
|
-
return url.indexOf("xn--") !== -1;
|
|
11040
|
-
}
|
|
11041
|
-
function toUnicode2(url) {
|
|
11042
|
-
return toUnicode(url);
|
|
11043
|
-
}
|
|
11044
|
-
function convertHttpsToHttp(url) {
|
|
11045
|
-
if (url.startsWith("https://")) {
|
|
11046
|
-
const httpUrl = new URL(url);
|
|
11047
|
-
httpUrl.protocol = "http:";
|
|
11048
|
-
return httpUrl.toString();
|
|
11049
|
-
}
|
|
11050
|
-
throw new Error(`URL is not HTTPS: ${url}`);
|
|
11051
|
-
}
|
|
11052
|
-
function generateCanonicalIPFSUrl(content) {
|
|
11053
|
-
if (!content) {
|
|
11054
|
-
return content;
|
|
11055
|
-
}
|
|
11056
|
-
if (content.includes("ipfs.io")) {
|
|
11057
|
-
return content;
|
|
11058
|
-
}
|
|
11059
|
-
if (content.startsWith("Qm") || content.startsWith("bafy")) {
|
|
11060
|
-
return `ipfs.io/ipfs/${content}`;
|
|
11061
|
-
}
|
|
11062
|
-
return content;
|
|
11063
|
-
}
|
|
11064
|
-
function isWalrusSite(content) {
|
|
11065
|
-
return content.includes(".walrus.site") || content.includes(".walrus.host") || content.includes(".wal.app") || content.includes(".wal.site");
|
|
11066
|
-
}
|
|
11067
|
-
function getFaviconUrl(content) {
|
|
11068
|
-
const normalizedUrl = getNormalizedUrl(content);
|
|
11069
|
-
return `https://icons.duckduckgo.com/ip3/${normalizedUrl.hostname}.ico`;
|
|
11070
|
-
}
|
|
11071
|
-
function sanitizeHttpUrl(value) {
|
|
11072
|
-
if (typeof value !== "string" || value.length === 0) {
|
|
11073
|
-
return null;
|
|
11074
|
-
}
|
|
11075
|
-
try {
|
|
11076
|
-
const parsed = new URL(value);
|
|
11077
|
-
if (parsed.protocol !== "http:" && parsed.protocol !== "https:") {
|
|
11078
|
-
return null;
|
|
11079
|
-
}
|
|
11080
|
-
return parsed.toString();
|
|
11081
|
-
} catch (e4) {
|
|
11082
|
-
return null;
|
|
11083
|
-
}
|
|
11084
|
-
}
|
|
11085
|
-
var URL_REGEX = /https?:\/\/[^\s"'<>\])]*/g;
|
|
11086
11004
|
|
|
11087
|
-
//
|
|
11005
|
+
// ../asset-parse/src/phone.ts
|
|
11088
11006
|
var phone_exports = {};
|
|
11089
11007
|
__export(phone_exports, {
|
|
11090
11008
|
PHONE_NUMBER_REGEX: () => PHONE_NUMBER_REGEX,
|
|
@@ -11211,10 +11129,202 @@ function normalizePhoneNumber(phone) {
|
|
|
11211
11129
|
return hasPlus ? `+${digitsOnly}` : digitsOnly;
|
|
11212
11130
|
}
|
|
11213
11131
|
|
|
11214
|
-
// ../../internal/utils/src/
|
|
11215
|
-
var
|
|
11216
|
-
|
|
11217
|
-
|
|
11132
|
+
// ../../internal/utils/src/punycode.ts
|
|
11133
|
+
var maxInt = 2147483647;
|
|
11134
|
+
var base = 36;
|
|
11135
|
+
var tMin = 1;
|
|
11136
|
+
var tMax = 26;
|
|
11137
|
+
var skew = 38;
|
|
11138
|
+
var damp = 700;
|
|
11139
|
+
var initialBias = 72;
|
|
11140
|
+
var initialN = 128;
|
|
11141
|
+
var delimiter = "-";
|
|
11142
|
+
var regexPunycode = /^xn--/;
|
|
11143
|
+
var regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g;
|
|
11144
|
+
var errors = {
|
|
11145
|
+
overflow: "Overflow: input needs wider integers to process",
|
|
11146
|
+
"not-basic": "Illegal input >= 0x80 (not a basic code point)",
|
|
11147
|
+
"invalid-input": "Invalid input"
|
|
11148
|
+
};
|
|
11149
|
+
var baseMinusTMin = base - tMin;
|
|
11150
|
+
var floor = Math.floor;
|
|
11151
|
+
function error(type) {
|
|
11152
|
+
throw new RangeError(errors[type]);
|
|
11153
|
+
}
|
|
11154
|
+
function mapDomain(domain, callback) {
|
|
11155
|
+
const parts = domain.split("@");
|
|
11156
|
+
let result = "";
|
|
11157
|
+
if (parts.length > 1) {
|
|
11158
|
+
result = parts[0] + "@";
|
|
11159
|
+
domain = parts[1];
|
|
11160
|
+
}
|
|
11161
|
+
domain = domain.replace(regexSeparators, ".");
|
|
11162
|
+
const labels = domain.split(".");
|
|
11163
|
+
const encoded = labels.map(callback).join(".");
|
|
11164
|
+
return result + encoded;
|
|
11165
|
+
}
|
|
11166
|
+
function basicToDigit(codePoint) {
|
|
11167
|
+
if (codePoint >= 48 && codePoint < 58) {
|
|
11168
|
+
return 26 + (codePoint - 48);
|
|
11169
|
+
}
|
|
11170
|
+
if (codePoint >= 65 && codePoint < 91) {
|
|
11171
|
+
return codePoint - 65;
|
|
11172
|
+
}
|
|
11173
|
+
if (codePoint >= 97 && codePoint < 123) {
|
|
11174
|
+
return codePoint - 97;
|
|
11175
|
+
}
|
|
11176
|
+
return base;
|
|
11177
|
+
}
|
|
11178
|
+
function adapt(delta, numPoints, firstTime) {
|
|
11179
|
+
let k4 = 0;
|
|
11180
|
+
delta = firstTime ? floor(delta / damp) : delta >> 1;
|
|
11181
|
+
delta += floor(delta / numPoints);
|
|
11182
|
+
for (
|
|
11183
|
+
;
|
|
11184
|
+
/* no initialization */
|
|
11185
|
+
delta > baseMinusTMin * tMax >> 1;
|
|
11186
|
+
k4 += base
|
|
11187
|
+
) {
|
|
11188
|
+
delta = floor(delta / baseMinusTMin);
|
|
11189
|
+
}
|
|
11190
|
+
return floor(k4 + (baseMinusTMin + 1) * delta / (delta + skew));
|
|
11191
|
+
}
|
|
11192
|
+
function decode(input) {
|
|
11193
|
+
const output = [];
|
|
11194
|
+
const inputLength = input.length;
|
|
11195
|
+
let i = 0;
|
|
11196
|
+
let n2 = initialN;
|
|
11197
|
+
let bias2 = initialBias;
|
|
11198
|
+
let basic = input.lastIndexOf(delimiter);
|
|
11199
|
+
if (basic < 0) {
|
|
11200
|
+
basic = 0;
|
|
11201
|
+
}
|
|
11202
|
+
for (let j = 0; j < basic; ++j) {
|
|
11203
|
+
if (input.charCodeAt(j) >= 128) {
|
|
11204
|
+
error("not-basic");
|
|
11205
|
+
}
|
|
11206
|
+
output.push(input.charCodeAt(j));
|
|
11207
|
+
}
|
|
11208
|
+
for (let index = basic > 0 ? basic + 1 : 0; index < inputLength; ) {
|
|
11209
|
+
const oldi = i;
|
|
11210
|
+
for (let w = 1, k4 = base; ; k4 += base) {
|
|
11211
|
+
if (index >= inputLength) {
|
|
11212
|
+
error("invalid-input");
|
|
11213
|
+
}
|
|
11214
|
+
const digit = basicToDigit(input.charCodeAt(index++));
|
|
11215
|
+
if (digit >= base) {
|
|
11216
|
+
error("invalid-input");
|
|
11217
|
+
}
|
|
11218
|
+
if (digit > floor((maxInt - i) / w)) {
|
|
11219
|
+
error("overflow");
|
|
11220
|
+
}
|
|
11221
|
+
i += digit * w;
|
|
11222
|
+
const t = k4 <= bias2 ? tMin : k4 >= bias2 + tMax ? tMax : k4 - bias2;
|
|
11223
|
+
if (digit < t) {
|
|
11224
|
+
break;
|
|
11225
|
+
}
|
|
11226
|
+
const baseMinusT = base - t;
|
|
11227
|
+
if (w > floor(maxInt / baseMinusT)) {
|
|
11228
|
+
error("overflow");
|
|
11229
|
+
}
|
|
11230
|
+
w *= baseMinusT;
|
|
11231
|
+
}
|
|
11232
|
+
const out = output.length + 1;
|
|
11233
|
+
bias2 = adapt(i - oldi, out, oldi == 0);
|
|
11234
|
+
if (floor(i / out) > maxInt - n2) {
|
|
11235
|
+
error("overflow");
|
|
11236
|
+
}
|
|
11237
|
+
n2 += floor(i / out);
|
|
11238
|
+
i %= out;
|
|
11239
|
+
output.splice(i++, 0, n2);
|
|
11240
|
+
}
|
|
11241
|
+
return String.fromCodePoint(...output);
|
|
11242
|
+
}
|
|
11243
|
+
function toUnicode(input) {
|
|
11244
|
+
return mapDomain(input, function(string) {
|
|
11245
|
+
return regexPunycode.test(string) ? decode(string.slice(4).toLowerCase()) : string;
|
|
11246
|
+
});
|
|
11247
|
+
}
|
|
11248
|
+
|
|
11249
|
+
// ../../internal/utils/src/url.ts
|
|
11250
|
+
function isEmail(input) {
|
|
11251
|
+
if (input.trim() === "") {
|
|
11252
|
+
return false;
|
|
11253
|
+
}
|
|
11254
|
+
const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
|
|
11255
|
+
return emailRegex.test(input);
|
|
11256
|
+
}
|
|
11257
|
+
function removeHttpProtocol(input) {
|
|
11258
|
+
return input.replace(/^https?:\/\//, "");
|
|
11259
|
+
}
|
|
11260
|
+
function stripDomainWildcardPrefix(domain) {
|
|
11261
|
+
const trimmedDomain = domain.trim();
|
|
11262
|
+
const strippedDomain = trimmedDomain.startsWith("*.") ? trimmedDomain.slice(2) : trimmedDomain;
|
|
11263
|
+
return strippedDomain.length > 0 ? strippedDomain : null;
|
|
11264
|
+
}
|
|
11265
|
+
function getDefangedUrl(input) {
|
|
11266
|
+
if (!isUrl(input)) {
|
|
11267
|
+
console.warn(`[getDefangedUrl] Invalid URL: ${input}, returning input as-is`);
|
|
11268
|
+
return input;
|
|
11269
|
+
}
|
|
11270
|
+
return input.replace(/\./g, "[.]").replace(/(https:\/\/)/g, "hxxps://").replace(/(http:\/\/)/g, "hxxp://").replace(/:\/\//g, "[://]");
|
|
11271
|
+
}
|
|
11272
|
+
function getRefangedUrl(input) {
|
|
11273
|
+
return input.replace(/hxxps/gi, "https").replace(/hxxp/gi, "http").replace(/\[:\/{2}\]/g, "://").replace(/\[\.\]/g, ".");
|
|
11274
|
+
}
|
|
11275
|
+
function containsPunycode(url) {
|
|
11276
|
+
return url.indexOf("xn--") !== -1;
|
|
11277
|
+
}
|
|
11278
|
+
function toUnicode2(url) {
|
|
11279
|
+
return toUnicode(url);
|
|
11280
|
+
}
|
|
11281
|
+
function convertHttpsToHttp(url) {
|
|
11282
|
+
if (url.startsWith("https://")) {
|
|
11283
|
+
const httpUrl = new URL(url);
|
|
11284
|
+
httpUrl.protocol = "http:";
|
|
11285
|
+
return httpUrl.toString();
|
|
11286
|
+
}
|
|
11287
|
+
throw new Error(`URL is not HTTPS: ${url}`);
|
|
11288
|
+
}
|
|
11289
|
+
function generateCanonicalIPFSUrl(content) {
|
|
11290
|
+
if (!content) {
|
|
11291
|
+
return content;
|
|
11292
|
+
}
|
|
11293
|
+
if (content.includes("ipfs.io")) {
|
|
11294
|
+
return content;
|
|
11295
|
+
}
|
|
11296
|
+
if (content.startsWith("Qm") || content.startsWith("bafy")) {
|
|
11297
|
+
return `ipfs.io/ipfs/${content}`;
|
|
11298
|
+
}
|
|
11299
|
+
return content;
|
|
11300
|
+
}
|
|
11301
|
+
function isWalrusSite(content) {
|
|
11302
|
+
return content.includes(".walrus.site") || content.includes(".walrus.host") || content.includes(".wal.app") || content.includes(".wal.site");
|
|
11303
|
+
}
|
|
11304
|
+
function getFaviconUrl(content) {
|
|
11305
|
+
const normalizedUrl = getNormalizedUrl(content);
|
|
11306
|
+
return `https://icons.duckduckgo.com/ip3/${normalizedUrl.hostname}.ico`;
|
|
11307
|
+
}
|
|
11308
|
+
function sanitizeHttpUrl(value) {
|
|
11309
|
+
if (typeof value !== "string" || value.length === 0) {
|
|
11310
|
+
return null;
|
|
11311
|
+
}
|
|
11312
|
+
try {
|
|
11313
|
+
const parsed = new URL(value);
|
|
11314
|
+
if (parsed.protocol !== "http:" && parsed.protocol !== "https:") {
|
|
11315
|
+
return null;
|
|
11316
|
+
}
|
|
11317
|
+
return parsed.toString();
|
|
11318
|
+
} catch (e4) {
|
|
11319
|
+
return null;
|
|
11320
|
+
}
|
|
11321
|
+
}
|
|
11322
|
+
var URL_REGEX = /https?:\/\/[^\s"'<>\])]*/g;
|
|
11323
|
+
|
|
11324
|
+
// ../../internal/utils/src/email.ts
|
|
11325
|
+
var email_exports = {};
|
|
11326
|
+
__export(email_exports, {
|
|
11327
|
+
extractTextFromGmailPayload: () => extractTextFromGmailPayload,
|
|
11218
11328
|
getDomainFromEmail: () => getDomainFromEmail,
|
|
11219
11329
|
getNameFromEmail: () => getNameFromEmail
|
|
11220
11330
|
});
|
|
@@ -11457,816 +11567,6 @@ function countPatternMatches(content, pattern, maxMatches = DEFAULT_MAX_MATCHES)
|
|
|
11457
11567
|
return count;
|
|
11458
11568
|
}
|
|
11459
11569
|
|
|
11460
|
-
// ../../internal/utils/src/itunes-api.ts
|
|
11461
|
-
var itunes_api_exports = {};
|
|
11462
|
-
__export(itunes_api_exports, {
|
|
11463
|
-
APP_STORE_COUNTRIES: () => APP_STORE_COUNTRIES,
|
|
11464
|
-
fetchItunesAppData: () => fetchItunesAppData,
|
|
11465
|
-
fetchItunesSearchResults: () => fetchItunesSearchResults,
|
|
11466
|
-
getAllAppStoreCountryCodes: () => getAllAppStoreCountryCodes,
|
|
11467
|
-
getAppStoreCountryName: () => getAppStoreCountryName,
|
|
11468
|
-
isValidAppStoreCountryCode: () => isValidAppStoreCountryCode,
|
|
11469
|
-
selectBestArtworkUrl: () => selectBestArtworkUrl
|
|
11470
|
-
});
|
|
11471
|
-
var APP_STORE_COUNTRIES = [
|
|
11472
|
-
{ code: "al", name: "Albania" },
|
|
11473
|
-
{ code: "dz", name: "Algeria" },
|
|
11474
|
-
{ code: "ao", name: "Angola" },
|
|
11475
|
-
{ code: "ai", name: "Anguilla" },
|
|
11476
|
-
{ code: "ag", name: "Antigua and Barbuda" },
|
|
11477
|
-
{ code: "ar", name: "Argentina" },
|
|
11478
|
-
{ code: "am", name: "Armenia" },
|
|
11479
|
-
{ code: "au", name: "Australia" },
|
|
11480
|
-
{ code: "at", name: "Austria" },
|
|
11481
|
-
{ code: "az", name: "Azerbaijan" },
|
|
11482
|
-
{ code: "bs", name: "Bahamas" },
|
|
11483
|
-
{ code: "bh", name: "Bahrain" },
|
|
11484
|
-
{ code: "bb", name: "Barbados" },
|
|
11485
|
-
{ code: "by", name: "Belarus" },
|
|
11486
|
-
{ code: "be", name: "Belgium" },
|
|
11487
|
-
{ code: "bz", name: "Belize" },
|
|
11488
|
-
{ code: "bj", name: "Benin" },
|
|
11489
|
-
{ code: "bm", name: "Bermuda" },
|
|
11490
|
-
{ code: "bt", name: "Bhutan" },
|
|
11491
|
-
{ code: "bo", name: "Bolivia" },
|
|
11492
|
-
{ code: "bw", name: "Botswana" },
|
|
11493
|
-
{ code: "br", name: "Brazil" },
|
|
11494
|
-
{ code: "vg", name: "British Virgin Islands" },
|
|
11495
|
-
{ code: "bn", name: "Brunei" },
|
|
11496
|
-
{ code: "bg", name: "Bulgaria" },
|
|
11497
|
-
{ code: "bf", name: "Burkina Faso" },
|
|
11498
|
-
{ code: "kh", name: "Cambodia" },
|
|
11499
|
-
{ code: "ca", name: "Canada" },
|
|
11500
|
-
{ code: "cv", name: "Cape Verde" },
|
|
11501
|
-
{ code: "ky", name: "Cayman Islands" },
|
|
11502
|
-
{ code: "cl", name: "Chile" },
|
|
11503
|
-
{ code: "td", name: "Chad" },
|
|
11504
|
-
{ code: "cn", name: "China" },
|
|
11505
|
-
{ code: "co", name: "Colombia" },
|
|
11506
|
-
{ code: "cd", name: "Congo" },
|
|
11507
|
-
{ code: "cr", name: "Costa Rica" },
|
|
11508
|
-
{ code: "hr", name: "Croatia" },
|
|
11509
|
-
{ code: "cy", name: "Cyprus" },
|
|
11510
|
-
{ code: "cz", name: "Czechia" },
|
|
11511
|
-
{ code: "dk", name: "Denmark" },
|
|
11512
|
-
{ code: "dm", name: "Dominica" },
|
|
11513
|
-
{ code: "do", name: "Dominican Republic" },
|
|
11514
|
-
{ code: "ec", name: "Ecuador" },
|
|
11515
|
-
{ code: "eg", name: "Egypt" },
|
|
11516
|
-
{ code: "sv", name: "El Salvador" },
|
|
11517
|
-
{ code: "ee", name: "Estonia" },
|
|
11518
|
-
{ code: "fj", name: "Fiji" },
|
|
11519
|
-
{ code: "fi", name: "Finland" },
|
|
11520
|
-
{ code: "fr", name: "France" },
|
|
11521
|
-
{ code: "de", name: "Germany" },
|
|
11522
|
-
{ code: "gm", name: "Gambia" },
|
|
11523
|
-
{ code: "gb", name: "United Kingdom" },
|
|
11524
|
-
{ code: "gh", name: "Ghana" },
|
|
11525
|
-
{ code: "gr", name: "Greece" },
|
|
11526
|
-
{ code: "gd", name: "Grenada" },
|
|
11527
|
-
{ code: "gt", name: "Guatemala" },
|
|
11528
|
-
{ code: "gw", name: "Guinea-bissau" },
|
|
11529
|
-
{ code: "gy", name: "Guyana" },
|
|
11530
|
-
{ code: "hn", name: "Honduras" },
|
|
11531
|
-
{ code: "hk", name: "Hong Kong" },
|
|
11532
|
-
{ code: "hu", name: "Hungary" },
|
|
11533
|
-
{ code: "is", name: "Iceland" },
|
|
11534
|
-
{ code: "in", name: "India" },
|
|
11535
|
-
{ code: "id", name: "Indonesia" },
|
|
11536
|
-
{ code: "ie", name: "Ireland" },
|
|
11537
|
-
{ code: "il", name: "Israel" },
|
|
11538
|
-
{ code: "it", name: "Italy" },
|
|
11539
|
-
{ code: "jm", name: "Jamaica" },
|
|
11540
|
-
{ code: "jp", name: "Japan" },
|
|
11541
|
-
{ code: "jo", name: "Jordan" },
|
|
11542
|
-
{ code: "kz", name: "Kazakhstan" },
|
|
11543
|
-
{ code: "ke", name: "Kenya" },
|
|
11544
|
-
{ code: "kw", name: "Kuwait" },
|
|
11545
|
-
{ code: "kg", name: "Kyrgyzstan" },
|
|
11546
|
-
{ code: "la", name: "Lao Peoples Democratic Republic" },
|
|
11547
|
-
{ code: "lv", name: "Latvia" },
|
|
11548
|
-
{ code: "lb", name: "Lebanon" },
|
|
11549
|
-
{ code: "li", name: "Liberia" },
|
|
11550
|
-
{ code: "lt", name: "Lithuania" },
|
|
11551
|
-
{ code: "lu", name: "Luxembourg" },
|
|
11552
|
-
{ code: "mo", name: "Macao" },
|
|
11553
|
-
{ code: "mk", name: "North Macedonia" },
|
|
11554
|
-
{ code: "mg", name: "Madagascar" },
|
|
11555
|
-
{ code: "mw", name: "Malawi" },
|
|
11556
|
-
{ code: "my", name: "Malaysia" },
|
|
11557
|
-
{ code: "ml", name: "Mali" },
|
|
11558
|
-
{ code: "mt", name: "Malta" },
|
|
11559
|
-
{ code: "mr", name: "Mauritania" },
|
|
11560
|
-
{ code: "mu", name: "Mauritius" },
|
|
11561
|
-
{ code: "mx", name: "Mexico" },
|
|
11562
|
-
{ code: "fm", name: "Micronesia" },
|
|
11563
|
-
{ code: "md", name: "Moldova" },
|
|
11564
|
-
{ code: "mn", name: "Mongolia" },
|
|
11565
|
-
{ code: "ms", name: "Montserrat" },
|
|
11566
|
-
{ code: "mz", name: "Mozambique" },
|
|
11567
|
-
{ code: "na", name: "Namibia" },
|
|
11568
|
-
{ code: "np", name: "Nepal" },
|
|
11569
|
-
{ code: "nl", name: "Netherlands" },
|
|
11570
|
-
{ code: "nz", name: "New Zealand" },
|
|
11571
|
-
{ code: "ni", name: "Nicaragua" },
|
|
11572
|
-
{ code: "ne", name: "Niger" },
|
|
11573
|
-
{ code: "ng", name: "Nigeria" },
|
|
11574
|
-
{ code: "no", name: "Norway" },
|
|
11575
|
-
{ code: "om", name: "Oman" },
|
|
11576
|
-
{ code: "pk", name: "Pakistan" },
|
|
11577
|
-
{ code: "pw", name: "Palau" },
|
|
11578
|
-
{ code: "pa", name: "Panama" },
|
|
11579
|
-
{ code: "pg", name: "Papua New Guinea" },
|
|
11580
|
-
{ code: "py", name: "Paraguay" },
|
|
11581
|
-
{ code: "pe", name: "Peru" },
|
|
11582
|
-
{ code: "ph", name: "Philippines" },
|
|
11583
|
-
{ code: "pl", name: "Poland" },
|
|
11584
|
-
{ code: "pt", name: "Portugal" },
|
|
11585
|
-
{ code: "qa", name: "Qatar" },
|
|
11586
|
-
{ code: "ro", name: "Romania" },
|
|
11587
|
-
{ code: "ru", name: "Russia" },
|
|
11588
|
-
{ code: "st", name: "Sao Tome & Principe" },
|
|
11589
|
-
{ code: "sa", name: "Saudi Arabia" },
|
|
11590
|
-
{ code: "sn", name: "Senegal" },
|
|
11591
|
-
{ code: "sc", name: "Seychelles" },
|
|
11592
|
-
{ code: "sl", name: "Sierra Leone" },
|
|
11593
|
-
{ code: "sg", name: "Singapore" },
|
|
11594
|
-
{ code: "sk", name: "Slovakia" },
|
|
11595
|
-
{ code: "si", name: "Slovenia" },
|
|
11596
|
-
{ code: "sb", name: "Solomon Islands" },
|
|
11597
|
-
{ code: "za", name: "South Africa" },
|
|
11598
|
-
{ code: "kr", name: "South Korea" },
|
|
11599
|
-
{ code: "es", name: "Spain" },
|
|
11600
|
-
{ code: "lk", name: "Sri Lanka" },
|
|
11601
|
-
{ code: "kn", name: "St. Kitts and Nevis" },
|
|
11602
|
-
{ code: "lc", name: "St. Lucia" },
|
|
11603
|
-
{ code: "vc", name: "St. Vincent & The Grenadines" },
|
|
11604
|
-
{ code: "sr", name: "Suriname" },
|
|
11605
|
-
{ code: "sz", name: "Swaziland" },
|
|
11606
|
-
{ code: "se", name: "Sweden" },
|
|
11607
|
-
{ code: "ch", name: "Switzerland" },
|
|
11608
|
-
{ code: "tw", name: "Taiwan" },
|
|
11609
|
-
{ code: "tj", name: "Tajikistan" },
|
|
11610
|
-
{ code: "tz", name: "Tanzania" },
|
|
11611
|
-
{ code: "th", name: "Thailand" },
|
|
11612
|
-
{ code: "tt", name: "Trinidad and Tobago" },
|
|
11613
|
-
{ code: "tn", name: "Tunisia" },
|
|
11614
|
-
{ code: "tr", name: "Turkey" },
|
|
11615
|
-
{ code: "tm", name: "Turkmenistan" },
|
|
11616
|
-
{ code: "tc", name: "Turks and Caicos" },
|
|
11617
|
-
{ code: "ug", name: "Uganda" },
|
|
11618
|
-
{ code: "ua", name: "Ukraine" },
|
|
11619
|
-
{ code: "ae", name: "United Arab Emirates" },
|
|
11620
|
-
{ code: "us", name: "United States" },
|
|
11621
|
-
{ code: "uy", name: "Uruguay" },
|
|
11622
|
-
{ code: "uz", name: "Uzbekistan" },
|
|
11623
|
-
{ code: "ve", name: "Venezuela" },
|
|
11624
|
-
{ code: "vn", name: "Vietnam" },
|
|
11625
|
-
{ code: "ye", name: "Yemen" },
|
|
11626
|
-
{ code: "zw", name: "Zimbabwe" }
|
|
11627
|
-
];
|
|
11628
|
-
var APP_STORE_COUNTRY_MAP = new Map(
|
|
11629
|
-
APP_STORE_COUNTRIES.map((country) => [country.code, country.name])
|
|
11630
|
-
);
|
|
11631
|
-
var APP_STORE_CODES_SET = new Set(APP_STORE_COUNTRIES.map((country) => country.code));
|
|
11632
|
-
var APP_STORE_CODES_ARRAY = Array.from(APP_STORE_CODES_SET).sort();
|
|
11633
|
-
function getAppStoreCountryName(code) {
|
|
11634
|
-
return APP_STORE_COUNTRY_MAP.get(code);
|
|
11635
|
-
}
|
|
11636
|
-
function getAllAppStoreCountryCodes() {
|
|
11637
|
-
return APP_STORE_CODES_ARRAY;
|
|
11638
|
-
}
|
|
11639
|
-
function isValidAppStoreCountryCode(code) {
|
|
11640
|
-
return APP_STORE_CODES_SET.has(code);
|
|
11641
|
-
}
|
|
11642
|
-
function selectBestArtworkUrl(appData) {
|
|
11643
|
-
return appData.artworkUrl512 || appData.artworkUrl100 || appData.artworkUrl60;
|
|
11644
|
-
}
|
|
11645
|
-
function fetchItunesSearchResults(term, country = "us", limit = 10) {
|
|
11646
|
-
return __async(this, null, function* () {
|
|
11647
|
-
const params = new URLSearchParams({
|
|
11648
|
-
media: "software",
|
|
11649
|
-
term,
|
|
11650
|
-
country,
|
|
11651
|
-
lang: "en_us",
|
|
11652
|
-
entity: "software",
|
|
11653
|
-
explicit: "yes",
|
|
11654
|
-
limit: String(limit)
|
|
11655
|
-
});
|
|
11656
|
-
const response = yield fetch(`https://itunes.apple.com/search?${params.toString()}`, {
|
|
11657
|
-
headers: { "User-Agent": "ChainPatrol/1.0 (https://chainpatrol.io)" }
|
|
11658
|
-
});
|
|
11659
|
-
if (!response.ok) {
|
|
11660
|
-
throw new Error(`iTunes API returned ${response.status} ${response.statusText}`);
|
|
11661
|
-
}
|
|
11662
|
-
const data = yield response.json();
|
|
11663
|
-
return data.results.map((r) => ({
|
|
11664
|
-
trackId: r.trackId,
|
|
11665
|
-
trackName: r.trackName,
|
|
11666
|
-
trackViewUrl: r.trackViewUrl,
|
|
11667
|
-
releaseDate: r.releaseDate,
|
|
11668
|
-
artistName: r.artistName,
|
|
11669
|
-
bundleId: r.bundleId
|
|
11670
|
-
}));
|
|
11671
|
-
});
|
|
11672
|
-
}
|
|
11673
|
-
function fetchItunesAppData(appId, country = "us") {
|
|
11674
|
-
return __async(this, null, function* () {
|
|
11675
|
-
try {
|
|
11676
|
-
const apiUrl = `https://itunes.apple.com/lookup?id=${appId}&country=${country}&entity=software`;
|
|
11677
|
-
const response = yield fetch(apiUrl, {
|
|
11678
|
-
headers: {
|
|
11679
|
-
"User-Agent": "ChainPatrol/1.0 (https://chainpatrol.io)"
|
|
11680
|
-
}
|
|
11681
|
-
});
|
|
11682
|
-
if (!response.ok) {
|
|
11683
|
-
throw new Error(
|
|
11684
|
-
`iTunes API request failed: ${response.status} ${response.statusText}`
|
|
11685
|
-
);
|
|
11686
|
-
}
|
|
11687
|
-
const data = yield response.json();
|
|
11688
|
-
if (data.resultCount > 0 && data.results.length > 0) {
|
|
11689
|
-
return data.results[0];
|
|
11690
|
-
}
|
|
11691
|
-
return null;
|
|
11692
|
-
} catch (error2) {
|
|
11693
|
-
console.error("Error fetching iTunes app data", { error: error2 });
|
|
11694
|
-
return null;
|
|
11695
|
-
}
|
|
11696
|
-
});
|
|
11697
|
-
}
|
|
11698
|
-
|
|
11699
|
-
// ../../internal/utils/src/google-play-api.ts
|
|
11700
|
-
var GOOGLE_PLAY_COUNTRIES = [
|
|
11701
|
-
{ code: "af", name: "Afghanistan" },
|
|
11702
|
-
{ code: "al", name: "Albania" },
|
|
11703
|
-
{ code: "dz", name: "Algeria" },
|
|
11704
|
-
{ code: "as", name: "American Samoa" },
|
|
11705
|
-
{ code: "ad", name: "Andorra" },
|
|
11706
|
-
{ code: "ao", name: "Angola" },
|
|
11707
|
-
{ code: "ai", name: "Anguilla" },
|
|
11708
|
-
{ code: "aq", name: "Antarctica" },
|
|
11709
|
-
{ code: "ag", name: "Antigua and Barbuda" },
|
|
11710
|
-
{ code: "ar", name: "Argentina" },
|
|
11711
|
-
{ code: "am", name: "Armenia" },
|
|
11712
|
-
{ code: "aw", name: "Aruba" },
|
|
11713
|
-
{ code: "au", name: "Australia" },
|
|
11714
|
-
{ code: "at", name: "Austria" },
|
|
11715
|
-
{ code: "az", name: "Azerbaijan" },
|
|
11716
|
-
{ code: "bs", name: "Bahamas" },
|
|
11717
|
-
{ code: "bh", name: "Bahrain" },
|
|
11718
|
-
{ code: "bd", name: "Bangladesh" },
|
|
11719
|
-
{ code: "bb", name: "Barbados" },
|
|
11720
|
-
{ code: "by", name: "Belarus" },
|
|
11721
|
-
{ code: "be", name: "Belgium" },
|
|
11722
|
-
{ code: "bz", name: "Belize" },
|
|
11723
|
-
{ code: "bj", name: "Benin" },
|
|
11724
|
-
{ code: "bm", name: "Bermuda" },
|
|
11725
|
-
{ code: "bt", name: "Bhutan" },
|
|
11726
|
-
{ code: "bo", name: "Bolivia" },
|
|
11727
|
-
{ code: "ba", name: "Bosnia and Herzegovina" },
|
|
11728
|
-
{ code: "bw", name: "Botswana" },
|
|
11729
|
-
{ code: "bv", name: "Bouvet Island" },
|
|
11730
|
-
{ code: "br", name: "Brazil" },
|
|
11731
|
-
{ code: "io", name: "British Indian Ocean Territory" },
|
|
11732
|
-
{ code: "bn", name: "Brunei Darussalam" },
|
|
11733
|
-
{ code: "bg", name: "Bulgaria" },
|
|
11734
|
-
{ code: "bf", name: "Burkina Faso" },
|
|
11735
|
-
{ code: "bi", name: "Burundi" },
|
|
11736
|
-
{ code: "kh", name: "Cambodia" },
|
|
11737
|
-
{ code: "cm", name: "Cameroon" },
|
|
11738
|
-
{ code: "ca", name: "Canada" },
|
|
11739
|
-
{ code: "cv", name: "Cape Verde" },
|
|
11740
|
-
{ code: "ky", name: "Cayman Islands" },
|
|
11741
|
-
{ code: "cf", name: "Central African Republic" },
|
|
11742
|
-
{ code: "td", name: "Chad" },
|
|
11743
|
-
{ code: "cl", name: "Chile" },
|
|
11744
|
-
{ code: "cn", name: "China" },
|
|
11745
|
-
{ code: "cx", name: "Christmas Island" },
|
|
11746
|
-
{ code: "cc", name: "Cocos (Keeling) Islands" },
|
|
11747
|
-
{ code: "co", name: "Colombia" },
|
|
11748
|
-
{ code: "km", name: "Comoros" },
|
|
11749
|
-
{ code: "cg", name: "Congo" },
|
|
11750
|
-
{ code: "cd", name: "Congo, the Democratic Republic of the" },
|
|
11751
|
-
{ code: "ck", name: "Cook Islands" },
|
|
11752
|
-
{ code: "cr", name: "Costa Rica" },
|
|
11753
|
-
{ code: "ci", name: "Cote D'ivoire" },
|
|
11754
|
-
{ code: "hr", name: "Croatia" },
|
|
11755
|
-
{ code: "cu", name: "Cuba" },
|
|
11756
|
-
{ code: "cy", name: "Cyprus" },
|
|
11757
|
-
{ code: "cz", name: "Czech Republic" },
|
|
11758
|
-
{ code: "dk", name: "Denmark" },
|
|
11759
|
-
{ code: "dj", name: "Djibouti" },
|
|
11760
|
-
{ code: "dm", name: "Dominica" },
|
|
11761
|
-
{ code: "do", name: "Dominican Republic" },
|
|
11762
|
-
{ code: "ec", name: "Ecuador" },
|
|
11763
|
-
{ code: "eg", name: "Egypt" },
|
|
11764
|
-
{ code: "sv", name: "El Salvador" },
|
|
11765
|
-
{ code: "gq", name: "Equatorial Guinea" },
|
|
11766
|
-
{ code: "er", name: "Eritrea" },
|
|
11767
|
-
{ code: "ee", name: "Estonia" },
|
|
11768
|
-
{ code: "et", name: "Ethiopia" },
|
|
11769
|
-
{ code: "fk", name: "Falkland Islands (Malvinas)" },
|
|
11770
|
-
{ code: "fo", name: "Faroe Islands" },
|
|
11771
|
-
{ code: "fj", name: "Fiji" },
|
|
11772
|
-
{ code: "fi", name: "Finland" },
|
|
11773
|
-
{ code: "fr", name: "France" },
|
|
11774
|
-
{ code: "gf", name: "French Guiana" },
|
|
11775
|
-
{ code: "pf", name: "French Polynesia" },
|
|
11776
|
-
{ code: "tf", name: "French Southern Territories" },
|
|
11777
|
-
{ code: "ga", name: "Gabon" },
|
|
11778
|
-
{ code: "gm", name: "Gambia" },
|
|
11779
|
-
{ code: "ge", name: "Georgia" },
|
|
11780
|
-
{ code: "de", name: "Germany" },
|
|
11781
|
-
{ code: "gh", name: "Ghana" },
|
|
11782
|
-
{ code: "gi", name: "Gibraltar" },
|
|
11783
|
-
{ code: "gr", name: "Greece" },
|
|
11784
|
-
{ code: "gl", name: "Greenland" },
|
|
11785
|
-
{ code: "gd", name: "Grenada" },
|
|
11786
|
-
{ code: "gp", name: "Guadeloupe" },
|
|
11787
|
-
{ code: "gu", name: "Guam" },
|
|
11788
|
-
{ code: "gt", name: "Guatemala" },
|
|
11789
|
-
{ code: "gg", name: "Guernsey" },
|
|
11790
|
-
{ code: "gn", name: "Guinea" },
|
|
11791
|
-
{ code: "gw", name: "Guinea-Bissau" },
|
|
11792
|
-
{ code: "gy", name: "Guyana" },
|
|
11793
|
-
{ code: "ht", name: "Haiti" },
|
|
11794
|
-
{ code: "hm", name: "Heard Island and Mcdonald Islands" },
|
|
11795
|
-
{ code: "va", name: "Holy See (Vatican City State)" },
|
|
11796
|
-
{ code: "hn", name: "Honduras" },
|
|
11797
|
-
{ code: "hk", name: "Hong Kong" },
|
|
11798
|
-
{ code: "hu", name: "Hungary" },
|
|
11799
|
-
{ code: "is", name: "Iceland" },
|
|
11800
|
-
{ code: "in", name: "India" },
|
|
11801
|
-
{ code: "id", name: "Indonesia" },
|
|
11802
|
-
{ code: "ir", name: "Iran, Islamic Republic of" },
|
|
11803
|
-
{ code: "iq", name: "Iraq" },
|
|
11804
|
-
{ code: "ie", name: "Ireland" },
|
|
11805
|
-
{ code: "im", name: "Isle of Man" },
|
|
11806
|
-
{ code: "il", name: "Israel" },
|
|
11807
|
-
{ code: "it", name: "Italy" },
|
|
11808
|
-
{ code: "je", name: "Jersey" },
|
|
11809
|
-
{ code: "jm", name: "Jamaica" },
|
|
11810
|
-
{ code: "jp", name: "Japan" },
|
|
11811
|
-
{ code: "jo", name: "Jordan" },
|
|
11812
|
-
{ code: "kz", name: "Kazakhstan" },
|
|
11813
|
-
{ code: "ke", name: "Kenya" },
|
|
11814
|
-
{ code: "ki", name: "Kiribati" },
|
|
11815
|
-
{ code: "kp", name: "Korea, Democratic People's Republic of" },
|
|
11816
|
-
{ code: "kr", name: "Korea, Republic of" },
|
|
11817
|
-
{ code: "kw", name: "Kuwait" },
|
|
11818
|
-
{ code: "kg", name: "Kyrgyzstan" },
|
|
11819
|
-
{ code: "la", name: "Lao People's Democratic Republic" },
|
|
11820
|
-
{ code: "lv", name: "Latvia" },
|
|
11821
|
-
{ code: "lb", name: "Lebanon" },
|
|
11822
|
-
{ code: "ls", name: "Lesotho" },
|
|
11823
|
-
{ code: "lr", name: "Liberia" },
|
|
11824
|
-
{ code: "ly", name: "Libyan Arab Jamahiriya" },
|
|
11825
|
-
{ code: "li", name: "Liechtenstein" },
|
|
11826
|
-
{ code: "lt", name: "Lithuania" },
|
|
11827
|
-
{ code: "lu", name: "Luxembourg" },
|
|
11828
|
-
{ code: "mo", name: "Macao" },
|
|
11829
|
-
{ code: "mk", name: "Macedonia, the Former Yugoslav Republic of" },
|
|
11830
|
-
{ code: "mg", name: "Madagascar" },
|
|
11831
|
-
{ code: "mw", name: "Malawi" },
|
|
11832
|
-
{ code: "my", name: "Malaysia" },
|
|
11833
|
-
{ code: "mv", name: "Maldives" },
|
|
11834
|
-
{ code: "ml", name: "Mali" },
|
|
11835
|
-
{ code: "mt", name: "Malta" },
|
|
11836
|
-
{ code: "mh", name: "Marshall Islands" },
|
|
11837
|
-
{ code: "mq", name: "Martinique" },
|
|
11838
|
-
{ code: "mr", name: "Mauritania" },
|
|
11839
|
-
{ code: "mu", name: "Mauritius" },
|
|
11840
|
-
{ code: "yt", name: "Mayotte" },
|
|
11841
|
-
{ code: "mx", name: "Mexico" },
|
|
11842
|
-
{ code: "fm", name: "Micronesia, Federated States of" },
|
|
11843
|
-
{ code: "md", name: "Moldova, Republic of" },
|
|
11844
|
-
{ code: "mc", name: "Monaco" },
|
|
11845
|
-
{ code: "mn", name: "Mongolia" },
|
|
11846
|
-
{ code: "me", name: "Montenegro" },
|
|
11847
|
-
{ code: "ms", name: "Montserrat" },
|
|
11848
|
-
{ code: "ma", name: "Morocco" },
|
|
11849
|
-
{ code: "mz", name: "Mozambique" },
|
|
11850
|
-
{ code: "mm", name: "Myanmar" },
|
|
11851
|
-
{ code: "na", name: "Namibia" },
|
|
11852
|
-
{ code: "nr", name: "Nauru" },
|
|
11853
|
-
{ code: "np", name: "Nepal" },
|
|
11854
|
-
{ code: "nl", name: "Netherlands" },
|
|
11855
|
-
{ code: "an", name: "Netherlands Antilles" },
|
|
11856
|
-
{ code: "nc", name: "New Caledonia" },
|
|
11857
|
-
{ code: "nz", name: "New Zealand" },
|
|
11858
|
-
{ code: "ni", name: "Nicaragua" },
|
|
11859
|
-
{ code: "ne", name: "Niger" },
|
|
11860
|
-
{ code: "ng", name: "Nigeria" },
|
|
11861
|
-
{ code: "nu", name: "Niue" },
|
|
11862
|
-
{ code: "nf", name: "Norfolk Island" },
|
|
11863
|
-
{ code: "mp", name: "Northern Mariana Islands" },
|
|
11864
|
-
{ code: "no", name: "Norway" },
|
|
11865
|
-
{ code: "om", name: "Oman" },
|
|
11866
|
-
{ code: "pk", name: "Pakistan" },
|
|
11867
|
-
{ code: "pw", name: "Palau" },
|
|
11868
|
-
{ code: "ps", name: "Palestinian Territory, Occupied" },
|
|
11869
|
-
{ code: "pa", name: "Panama" },
|
|
11870
|
-
{ code: "pg", name: "Papua New Guinea" },
|
|
11871
|
-
{ code: "py", name: "Paraguay" },
|
|
11872
|
-
{ code: "pe", name: "Peru" },
|
|
11873
|
-
{ code: "ph", name: "Philippines" },
|
|
11874
|
-
{ code: "pn", name: "Pitcairn" },
|
|
11875
|
-
{ code: "pl", name: "Poland" },
|
|
11876
|
-
{ code: "pt", name: "Portugal" },
|
|
11877
|
-
{ code: "pr", name: "Puerto Rico" },
|
|
11878
|
-
{ code: "qa", name: "Qatar" },
|
|
11879
|
-
{ code: "re", name: "Reunion" },
|
|
11880
|
-
{ code: "ro", name: "Romania" },
|
|
11881
|
-
{ code: "ru", name: "Russian Federation" },
|
|
11882
|
-
{ code: "rw", name: "Rwanda" },
|
|
11883
|
-
{ code: "sh", name: "Saint Helena" },
|
|
11884
|
-
{ code: "kn", name: "Saint Kitts and Nevis" },
|
|
11885
|
-
{ code: "lc", name: "Saint Lucia" },
|
|
11886
|
-
{ code: "pm", name: "Saint Pierre and Miquelon" },
|
|
11887
|
-
{ code: "vc", name: "Saint Vincent and the Grenadines" },
|
|
11888
|
-
{ code: "ws", name: "Samoa" },
|
|
11889
|
-
{ code: "sm", name: "San Marino" },
|
|
11890
|
-
{ code: "st", name: "Sao Tome and Principe" },
|
|
11891
|
-
{ code: "sa", name: "Saudi Arabia" },
|
|
11892
|
-
{ code: "sn", name: "Senegal" },
|
|
11893
|
-
{ code: "rs", name: "Serbia" },
|
|
11894
|
-
{ code: "sc", name: "Seychelles" },
|
|
11895
|
-
{ code: "sl", name: "Sierra Leone" },
|
|
11896
|
-
{ code: "sg", name: "Singapore" },
|
|
11897
|
-
{ code: "sk", name: "Slovakia" },
|
|
11898
|
-
{ code: "si", name: "Slovenia" },
|
|
11899
|
-
{ code: "sb", name: "Solomon Islands" },
|
|
11900
|
-
{ code: "so", name: "Somalia" },
|
|
11901
|
-
{ code: "za", name: "South Africa" },
|
|
11902
|
-
{ code: "gs", name: "South Georgia and the South Sandwich Islands" },
|
|
11903
|
-
{ code: "es", name: "Spain" },
|
|
11904
|
-
{ code: "lk", name: "Sri Lanka" },
|
|
11905
|
-
{ code: "sd", name: "Sudan" },
|
|
11906
|
-
{ code: "sr", name: "Suriname" },
|
|
11907
|
-
{ code: "sj", name: "Svalbard and Jan Mayen" },
|
|
11908
|
-
{ code: "sz", name: "Swaziland" },
|
|
11909
|
-
{ code: "se", name: "Sweden" },
|
|
11910
|
-
{ code: "ch", name: "Switzerland" },
|
|
11911
|
-
{ code: "sy", name: "Syrian Arab Republic" },
|
|
11912
|
-
{ code: "tw", name: "Taiwan, Province of China" },
|
|
11913
|
-
{ code: "tj", name: "Tajikistan" },
|
|
11914
|
-
{ code: "tz", name: "Tanzania, United Republic of" },
|
|
11915
|
-
{ code: "th", name: "Thailand" },
|
|
11916
|
-
{ code: "tl", name: "Timor-Leste" },
|
|
11917
|
-
{ code: "tg", name: "Togo" },
|
|
11918
|
-
{ code: "tk", name: "Tokelau" },
|
|
11919
|
-
{ code: "to", name: "Tonga" },
|
|
11920
|
-
{ code: "tt", name: "Trinidad and Tobago" },
|
|
11921
|
-
{ code: "tn", name: "Tunisia" },
|
|
11922
|
-
{ code: "tr", name: "Turkiye" },
|
|
11923
|
-
{ code: "tm", name: "Turkmenistan" },
|
|
11924
|
-
{ code: "tc", name: "Turks and Caicos Islands" },
|
|
11925
|
-
{ code: "tv", name: "Tuvalu" },
|
|
11926
|
-
{ code: "ug", name: "Uganda" },
|
|
11927
|
-
{ code: "ua", name: "Ukraine" },
|
|
11928
|
-
{ code: "ae", name: "United Arab Emirates" },
|
|
11929
|
-
{ code: "uk", name: "United Kingdom" },
|
|
11930
|
-
{ code: "gb", name: "United Kingdom" },
|
|
11931
|
-
{ code: "us", name: "United States" },
|
|
11932
|
-
{ code: "um", name: "United States Minor Outlying Islands" },
|
|
11933
|
-
{ code: "uy", name: "Uruguay" },
|
|
11934
|
-
{ code: "uz", name: "Uzbekistan" },
|
|
11935
|
-
{ code: "vu", name: "Vanuatu" },
|
|
11936
|
-
{ code: "ve", name: "Venezuela" },
|
|
11937
|
-
{ code: "vn", name: "Viet Nam" },
|
|
11938
|
-
{ code: "vg", name: "Virgin Islands, British" },
|
|
11939
|
-
{ code: "vi", name: "Virgin Islands, U.S." },
|
|
11940
|
-
{ code: "wf", name: "Wallis and Futuna" },
|
|
11941
|
-
{ code: "eh", name: "Western Sahara" },
|
|
11942
|
-
{ code: "ye", name: "Yemen" },
|
|
11943
|
-
{ code: "zm", name: "Zambia" },
|
|
11944
|
-
{ code: "zw", name: "Zimbabwe" }
|
|
11945
|
-
];
|
|
11946
|
-
var GOOGLE_PLAY_COUNTRY_MAP = new Map(
|
|
11947
|
-
GOOGLE_PLAY_COUNTRIES.map((country) => [country.code, country.name])
|
|
11948
|
-
);
|
|
11949
|
-
var GOOGLE_PLAY_CODES_SET = new Set(
|
|
11950
|
-
GOOGLE_PLAY_COUNTRIES.map((country) => country.code)
|
|
11951
|
-
);
|
|
11952
|
-
Array.from(GOOGLE_PLAY_CODES_SET).sort();
|
|
11953
|
-
function getGooglePlayCountryName(code) {
|
|
11954
|
-
return GOOGLE_PLAY_COUNTRY_MAP.get(code);
|
|
11955
|
-
}
|
|
11956
|
-
|
|
11957
|
-
// ../../internal/utils/src/country-codes.ts
|
|
11958
|
-
var country_codes_exports = {};
|
|
11959
|
-
__export(country_codes_exports, {
|
|
11960
|
-
APPLE_ONLY_COUNTRY_CODES: () => APPLE_ONLY_COUNTRY_CODES,
|
|
11961
|
-
COUNTRY_NAMES: () => COUNTRY_NAMES,
|
|
11962
|
-
GOOGLE_ONLY_COUNTRY_CODES: () => GOOGLE_ONLY_COUNTRY_CODES,
|
|
11963
|
-
SHARED_COUNTRY_CODES: () => SHARED_COUNTRY_CODES,
|
|
11964
|
-
countryCodeToFlag: () => countryCodeToFlag,
|
|
11965
|
-
getAllCountryCodes: () => getAllCountryCodes,
|
|
11966
|
-
getCountryName: () => getCountryName,
|
|
11967
|
-
isValidAppleCountryCode: () => isValidAppleCountryCode,
|
|
11968
|
-
isValidGoogleCountryCode: () => isValidGoogleCountryCode
|
|
11969
|
-
});
|
|
11970
|
-
function createCountryLists() {
|
|
11971
|
-
const appleCodesSet = new Set(APP_STORE_COUNTRIES.map((c2) => c2.code));
|
|
11972
|
-
const googleCodesSet = new Set(GOOGLE_PLAY_COUNTRIES.map((c2) => c2.code));
|
|
11973
|
-
const shared2 = [];
|
|
11974
|
-
const appleOnly2 = [];
|
|
11975
|
-
const googleOnly2 = [];
|
|
11976
|
-
appleCodesSet.forEach((code) => {
|
|
11977
|
-
if (googleCodesSet.has(code)) {
|
|
11978
|
-
shared2.push(code);
|
|
11979
|
-
} else {
|
|
11980
|
-
appleOnly2.push(code);
|
|
11981
|
-
}
|
|
11982
|
-
});
|
|
11983
|
-
googleCodesSet.forEach((code) => {
|
|
11984
|
-
if (!appleCodesSet.has(code)) {
|
|
11985
|
-
googleOnly2.push(code);
|
|
11986
|
-
}
|
|
11987
|
-
});
|
|
11988
|
-
return {
|
|
11989
|
-
shared: shared2.sort(),
|
|
11990
|
-
appleOnly: appleOnly2.sort(),
|
|
11991
|
-
googleOnly: googleOnly2.sort()
|
|
11992
|
-
};
|
|
11993
|
-
}
|
|
11994
|
-
var { shared, appleOnly, googleOnly } = createCountryLists();
|
|
11995
|
-
var SHARED_COUNTRY_CODES = shared;
|
|
11996
|
-
var APPLE_ONLY_COUNTRY_CODES = appleOnly;
|
|
11997
|
-
var GOOGLE_ONLY_COUNTRY_CODES = googleOnly;
|
|
11998
|
-
function isValidGoogleCountryCode(code) {
|
|
11999
|
-
return SHARED_COUNTRY_CODES.includes(code) || GOOGLE_ONLY_COUNTRY_CODES.includes(code);
|
|
12000
|
-
}
|
|
12001
|
-
function isValidAppleCountryCode(code) {
|
|
12002
|
-
return SHARED_COUNTRY_CODES.includes(code) || APPLE_ONLY_COUNTRY_CODES.includes(code);
|
|
12003
|
-
}
|
|
12004
|
-
function getCountryName(code) {
|
|
12005
|
-
return getAppStoreCountryName(code) || getGooglePlayCountryName(code);
|
|
12006
|
-
}
|
|
12007
|
-
function getAllCountryCodes(platform) {
|
|
12008
|
-
if (platform === "apple") {
|
|
12009
|
-
return [...SHARED_COUNTRY_CODES, ...APPLE_ONLY_COUNTRY_CODES].sort();
|
|
12010
|
-
} else {
|
|
12011
|
-
return [...SHARED_COUNTRY_CODES, ...GOOGLE_ONLY_COUNTRY_CODES].sort();
|
|
12012
|
-
}
|
|
12013
|
-
}
|
|
12014
|
-
var COUNTRY_NAMES = {
|
|
12015
|
-
AD: "Andorra",
|
|
12016
|
-
AE: "United Arab Emirates",
|
|
12017
|
-
AF: "Afghanistan",
|
|
12018
|
-
AG: "Antigua and Barbuda",
|
|
12019
|
-
AI: "Anguilla",
|
|
12020
|
-
AL: "Albania",
|
|
12021
|
-
AM: "Armenia",
|
|
12022
|
-
AO: "Angola",
|
|
12023
|
-
AQ: "Antarctica",
|
|
12024
|
-
AR: "Argentina",
|
|
12025
|
-
AS: "American Samoa",
|
|
12026
|
-
AT: "Austria",
|
|
12027
|
-
AU: "Australia",
|
|
12028
|
-
AW: "Aruba",
|
|
12029
|
-
AX: "\xC5land Islands",
|
|
12030
|
-
AZ: "Azerbaijan",
|
|
12031
|
-
BA: "Bosnia and Herzegovina",
|
|
12032
|
-
BB: "Barbados",
|
|
12033
|
-
BD: "Bangladesh",
|
|
12034
|
-
BE: "Belgium",
|
|
12035
|
-
BF: "Burkina Faso",
|
|
12036
|
-
BG: "Bulgaria",
|
|
12037
|
-
BH: "Bahrain",
|
|
12038
|
-
BI: "Burundi",
|
|
12039
|
-
BJ: "Benin",
|
|
12040
|
-
BL: "Saint Barth\xE9lemy",
|
|
12041
|
-
BM: "Bermuda",
|
|
12042
|
-
BN: "Brunei",
|
|
12043
|
-
BO: "Bolivia",
|
|
12044
|
-
BQ: "Caribbean Netherlands",
|
|
12045
|
-
BR: "Brazil",
|
|
12046
|
-
BS: "Bahamas",
|
|
12047
|
-
BT: "Bhutan",
|
|
12048
|
-
BV: "Bouvet Island",
|
|
12049
|
-
BW: "Botswana",
|
|
12050
|
-
BY: "Belarus",
|
|
12051
|
-
BZ: "Belize",
|
|
12052
|
-
CA: "Canada",
|
|
12053
|
-
CC: "Cocos (Keeling) Islands",
|
|
12054
|
-
CD: "DR Congo",
|
|
12055
|
-
CF: "Central African Republic",
|
|
12056
|
-
CG: "Republic of the Congo",
|
|
12057
|
-
CH: "Switzerland",
|
|
12058
|
-
CI: "C\xF4te d'Ivoire",
|
|
12059
|
-
CK: "Cook Islands",
|
|
12060
|
-
CL: "Chile",
|
|
12061
|
-
CM: "Cameroon",
|
|
12062
|
-
CN: "China",
|
|
12063
|
-
CO: "Colombia",
|
|
12064
|
-
CR: "Costa Rica",
|
|
12065
|
-
CU: "Cuba",
|
|
12066
|
-
CV: "Cape Verde",
|
|
12067
|
-
CW: "Cura\xE7ao",
|
|
12068
|
-
CX: "Christmas Island",
|
|
12069
|
-
CY: "Cyprus",
|
|
12070
|
-
CZ: "Czechia",
|
|
12071
|
-
DE: "Germany",
|
|
12072
|
-
DJ: "Djibouti",
|
|
12073
|
-
DK: "Denmark",
|
|
12074
|
-
DM: "Dominica",
|
|
12075
|
-
DO: "Dominican Republic",
|
|
12076
|
-
DZ: "Algeria",
|
|
12077
|
-
EC: "Ecuador",
|
|
12078
|
-
EE: "Estonia",
|
|
12079
|
-
EG: "Egypt",
|
|
12080
|
-
EH: "Western Sahara",
|
|
12081
|
-
ER: "Eritrea",
|
|
12082
|
-
ES: "Spain",
|
|
12083
|
-
ET: "Ethiopia",
|
|
12084
|
-
FI: "Finland",
|
|
12085
|
-
FJ: "Fiji",
|
|
12086
|
-
FK: "Falkland Islands",
|
|
12087
|
-
FM: "Micronesia",
|
|
12088
|
-
FO: "Faroe Islands",
|
|
12089
|
-
FR: "France",
|
|
12090
|
-
GA: "Gabon",
|
|
12091
|
-
GB: "United Kingdom",
|
|
12092
|
-
GD: "Grenada",
|
|
12093
|
-
GE: "Georgia",
|
|
12094
|
-
GF: "French Guiana",
|
|
12095
|
-
GG: "Guernsey",
|
|
12096
|
-
GH: "Ghana",
|
|
12097
|
-
GI: "Gibraltar",
|
|
12098
|
-
GL: "Greenland",
|
|
12099
|
-
GM: "Gambia",
|
|
12100
|
-
GN: "Guinea",
|
|
12101
|
-
GP: "Guadeloupe",
|
|
12102
|
-
GQ: "Equatorial Guinea",
|
|
12103
|
-
GR: "Greece",
|
|
12104
|
-
GS: "South Georgia",
|
|
12105
|
-
GT: "Guatemala",
|
|
12106
|
-
GU: "Guam",
|
|
12107
|
-
GW: "Guinea-Bissau",
|
|
12108
|
-
GY: "Guyana",
|
|
12109
|
-
HK: "Hong Kong",
|
|
12110
|
-
HM: "Heard Island and McDonald Islands",
|
|
12111
|
-
HN: "Honduras",
|
|
12112
|
-
HR: "Croatia",
|
|
12113
|
-
HT: "Haiti",
|
|
12114
|
-
HU: "Hungary",
|
|
12115
|
-
ID: "Indonesia",
|
|
12116
|
-
IE: "Ireland",
|
|
12117
|
-
IL: "Israel",
|
|
12118
|
-
IM: "Isle of Man",
|
|
12119
|
-
IN: "India",
|
|
12120
|
-
IO: "British Indian Ocean Territory",
|
|
12121
|
-
IQ: "Iraq",
|
|
12122
|
-
IR: "Iran",
|
|
12123
|
-
IS: "Iceland",
|
|
12124
|
-
IT: "Italy",
|
|
12125
|
-
JE: "Jersey",
|
|
12126
|
-
JM: "Jamaica",
|
|
12127
|
-
JO: "Jordan",
|
|
12128
|
-
JP: "Japan",
|
|
12129
|
-
KE: "Kenya",
|
|
12130
|
-
KG: "Kyrgyzstan",
|
|
12131
|
-
KH: "Cambodia",
|
|
12132
|
-
KI: "Kiribati",
|
|
12133
|
-
KM: "Comoros",
|
|
12134
|
-
KN: "Saint Kitts and Nevis",
|
|
12135
|
-
KP: "North Korea",
|
|
12136
|
-
KR: "South Korea",
|
|
12137
|
-
KW: "Kuwait",
|
|
12138
|
-
KY: "Cayman Islands",
|
|
12139
|
-
KZ: "Kazakhstan",
|
|
12140
|
-
LA: "Laos",
|
|
12141
|
-
LB: "Lebanon",
|
|
12142
|
-
LC: "Saint Lucia",
|
|
12143
|
-
LI: "Liechtenstein",
|
|
12144
|
-
LK: "Sri Lanka",
|
|
12145
|
-
LR: "Liberia",
|
|
12146
|
-
LS: "Lesotho",
|
|
12147
|
-
LT: "Lithuania",
|
|
12148
|
-
LU: "Luxembourg",
|
|
12149
|
-
LV: "Latvia",
|
|
12150
|
-
LY: "Libya",
|
|
12151
|
-
MA: "Morocco",
|
|
12152
|
-
MC: "Monaco",
|
|
12153
|
-
MD: "Moldova",
|
|
12154
|
-
ME: "Montenegro",
|
|
12155
|
-
MF: "Saint Martin",
|
|
12156
|
-
MG: "Madagascar",
|
|
12157
|
-
MH: "Marshall Islands",
|
|
12158
|
-
MK: "North Macedonia",
|
|
12159
|
-
ML: "Mali",
|
|
12160
|
-
MM: "Myanmar",
|
|
12161
|
-
MN: "Mongolia",
|
|
12162
|
-
MO: "Macau",
|
|
12163
|
-
MP: "Northern Mariana Islands",
|
|
12164
|
-
MQ: "Martinique",
|
|
12165
|
-
MR: "Mauritania",
|
|
12166
|
-
MS: "Montserrat",
|
|
12167
|
-
MT: "Malta",
|
|
12168
|
-
MU: "Mauritius",
|
|
12169
|
-
MV: "Maldives",
|
|
12170
|
-
MW: "Malawi",
|
|
12171
|
-
MX: "Mexico",
|
|
12172
|
-
MY: "Malaysia",
|
|
12173
|
-
MZ: "Mozambique",
|
|
12174
|
-
NA: "Namibia",
|
|
12175
|
-
NC: "New Caledonia",
|
|
12176
|
-
NE: "Niger",
|
|
12177
|
-
NF: "Norfolk Island",
|
|
12178
|
-
NG: "Nigeria",
|
|
12179
|
-
NI: "Nicaragua",
|
|
12180
|
-
NL: "Netherlands",
|
|
12181
|
-
NO: "Norway",
|
|
12182
|
-
NP: "Nepal",
|
|
12183
|
-
NR: "Nauru",
|
|
12184
|
-
NU: "Niue",
|
|
12185
|
-
NZ: "New Zealand",
|
|
12186
|
-
OM: "Oman",
|
|
12187
|
-
PA: "Panama",
|
|
12188
|
-
PE: "Peru",
|
|
12189
|
-
PF: "French Polynesia",
|
|
12190
|
-
PG: "Papua New Guinea",
|
|
12191
|
-
PH: "Philippines",
|
|
12192
|
-
PK: "Pakistan",
|
|
12193
|
-
PL: "Poland",
|
|
12194
|
-
PM: "Saint Pierre and Miquelon",
|
|
12195
|
-
PN: "Pitcairn Islands",
|
|
12196
|
-
PR: "Puerto Rico",
|
|
12197
|
-
PS: "Palestine",
|
|
12198
|
-
PT: "Portugal",
|
|
12199
|
-
PW: "Palau",
|
|
12200
|
-
PY: "Paraguay",
|
|
12201
|
-
QA: "Qatar",
|
|
12202
|
-
RE: "R\xE9union",
|
|
12203
|
-
RO: "Romania",
|
|
12204
|
-
RS: "Serbia",
|
|
12205
|
-
RU: "Russia",
|
|
12206
|
-
RW: "Rwanda",
|
|
12207
|
-
SA: "Saudi Arabia",
|
|
12208
|
-
SB: "Solomon Islands",
|
|
12209
|
-
SC: "Seychelles",
|
|
12210
|
-
SD: "Sudan",
|
|
12211
|
-
SE: "Sweden",
|
|
12212
|
-
SG: "Singapore",
|
|
12213
|
-
SH: "Saint Helena",
|
|
12214
|
-
SI: "Slovenia",
|
|
12215
|
-
SJ: "Svalbard and Jan Mayen",
|
|
12216
|
-
SK: "Slovakia",
|
|
12217
|
-
SL: "Sierra Leone",
|
|
12218
|
-
SM: "San Marino",
|
|
12219
|
-
SN: "Senegal",
|
|
12220
|
-
SO: "Somalia",
|
|
12221
|
-
SR: "Suriname",
|
|
12222
|
-
SS: "South Sudan",
|
|
12223
|
-
ST: "S\xE3o Tom\xE9 and Pr\xEDncipe",
|
|
12224
|
-
SV: "El Salvador",
|
|
12225
|
-
SX: "Sint Maarten",
|
|
12226
|
-
SY: "Syria",
|
|
12227
|
-
SZ: "Eswatini",
|
|
12228
|
-
TC: "Turks and Caicos Islands",
|
|
12229
|
-
TD: "Chad",
|
|
12230
|
-
TF: "French Southern Territories",
|
|
12231
|
-
TG: "Togo",
|
|
12232
|
-
TH: "Thailand",
|
|
12233
|
-
TJ: "Tajikistan",
|
|
12234
|
-
TK: "Tokelau",
|
|
12235
|
-
TL: "Timor-Leste",
|
|
12236
|
-
TM: "Turkmenistan",
|
|
12237
|
-
TN: "Tunisia",
|
|
12238
|
-
TO: "Tonga",
|
|
12239
|
-
TR: "Turkey",
|
|
12240
|
-
TT: "Trinidad and Tobago",
|
|
12241
|
-
TV: "Tuvalu",
|
|
12242
|
-
TW: "Taiwan",
|
|
12243
|
-
TZ: "Tanzania",
|
|
12244
|
-
UA: "Ukraine",
|
|
12245
|
-
UG: "Uganda",
|
|
12246
|
-
UM: "U.S. Minor Outlying Islands",
|
|
12247
|
-
US: "United States",
|
|
12248
|
-
UY: "Uruguay",
|
|
12249
|
-
UZ: "Uzbekistan",
|
|
12250
|
-
VA: "Vatican City",
|
|
12251
|
-
VC: "Saint Vincent and the Grenadines",
|
|
12252
|
-
VE: "Venezuela",
|
|
12253
|
-
VG: "British Virgin Islands",
|
|
12254
|
-
VI: "U.S. Virgin Islands",
|
|
12255
|
-
VN: "Vietnam",
|
|
12256
|
-
VU: "Vanuatu",
|
|
12257
|
-
WF: "Wallis and Futuna",
|
|
12258
|
-
WS: "Samoa",
|
|
12259
|
-
XK: "Kosovo",
|
|
12260
|
-
YE: "Yemen",
|
|
12261
|
-
YT: "Mayotte",
|
|
12262
|
-
ZA: "South Africa",
|
|
12263
|
-
ZM: "Zambia",
|
|
12264
|
-
ZW: "Zimbabwe"
|
|
12265
|
-
};
|
|
12266
|
-
function countryCodeToFlag(code) {
|
|
12267
|
-
return code.toUpperCase().split("").map((c2) => String.fromCodePoint(127462 + c2.charCodeAt(0) - 65)).join("");
|
|
12268
|
-
}
|
|
12269
|
-
|
|
12270
11570
|
// ../../internal/utils/src/text.ts
|
|
12271
11571
|
var text_exports = {};
|
|
12272
11572
|
__export(text_exports, {
|
|
@@ -12820,241 +12120,6 @@ zod.z.object({
|
|
|
12820
12120
|
})
|
|
12821
12121
|
)
|
|
12822
12122
|
});
|
|
12823
|
-
|
|
12824
|
-
// ../../internal/asset/src/parse/caip2.ts
|
|
12825
|
-
var SUPPORTED_CHAINS = {
|
|
12826
|
-
// EIP155 chains (Ethereum Virtual Machine compatible)
|
|
12827
|
-
ETHEREUM_MAINNET: {
|
|
12828
|
-
chainId: "eip155:1",
|
|
12829
|
-
namespace: "eip155",
|
|
12830
|
-
reference: "1",
|
|
12831
|
-
name: "Ethereum Mainnet",
|
|
12832
|
-
shortName: "Ethereum",
|
|
12833
|
-
explorerUrl: "https://etherscan.io",
|
|
12834
|
-
explorerName: "Etherscan"
|
|
12835
|
-
},
|
|
12836
|
-
OPTIMISM: {
|
|
12837
|
-
chainId: "eip155:10",
|
|
12838
|
-
namespace: "eip155",
|
|
12839
|
-
reference: "10",
|
|
12840
|
-
name: "Optimism",
|
|
12841
|
-
shortName: "Optimism",
|
|
12842
|
-
explorerUrl: "https://optimistic.etherscan.io",
|
|
12843
|
-
explorerName: "Optimism Explorer"
|
|
12844
|
-
},
|
|
12845
|
-
POLYGON: {
|
|
12846
|
-
chainId: "eip155:137",
|
|
12847
|
-
namespace: "eip155",
|
|
12848
|
-
reference: "137",
|
|
12849
|
-
name: "Polygon",
|
|
12850
|
-
shortName: "Polygon",
|
|
12851
|
-
explorerUrl: "https://polygonscan.com",
|
|
12852
|
-
explorerName: "PolygonScan"
|
|
12853
|
-
},
|
|
12854
|
-
ARBITRUM: {
|
|
12855
|
-
chainId: "eip155:42161",
|
|
12856
|
-
namespace: "eip155",
|
|
12857
|
-
reference: "42161",
|
|
12858
|
-
name: "Arbitrum",
|
|
12859
|
-
shortName: "Arbitrum",
|
|
12860
|
-
explorerUrl: "https://arbiscan.io",
|
|
12861
|
-
explorerName: "Arbiscan"
|
|
12862
|
-
},
|
|
12863
|
-
BASE: {
|
|
12864
|
-
chainId: "eip155:8453",
|
|
12865
|
-
namespace: "eip155",
|
|
12866
|
-
reference: "8453",
|
|
12867
|
-
name: "Base",
|
|
12868
|
-
shortName: "Base",
|
|
12869
|
-
explorerUrl: "https://basescan.org",
|
|
12870
|
-
explorerName: "BaseScan"
|
|
12871
|
-
},
|
|
12872
|
-
CELO: {
|
|
12873
|
-
chainId: "eip155:42220",
|
|
12874
|
-
namespace: "eip155",
|
|
12875
|
-
reference: "42220",
|
|
12876
|
-
name: "Celo",
|
|
12877
|
-
shortName: "Celo",
|
|
12878
|
-
explorerUrl: "https://celoscan.io",
|
|
12879
|
-
explorerName: "CeloScan"
|
|
12880
|
-
},
|
|
12881
|
-
PLASMA: {
|
|
12882
|
-
chainId: "eip155:9745",
|
|
12883
|
-
namespace: "eip155",
|
|
12884
|
-
reference: "9745",
|
|
12885
|
-
name: "Plasma",
|
|
12886
|
-
shortName: "Plasma",
|
|
12887
|
-
explorerUrl: "https://plasmascan.to",
|
|
12888
|
-
explorerName: "PlasmaScan"
|
|
12889
|
-
},
|
|
12890
|
-
BSC: {
|
|
12891
|
-
chainId: "eip155:56",
|
|
12892
|
-
namespace: "eip155",
|
|
12893
|
-
reference: "56",
|
|
12894
|
-
name: "Binance Smart Chain",
|
|
12895
|
-
shortName: "BSC",
|
|
12896
|
-
explorerUrl: "https://bscscan.com",
|
|
12897
|
-
explorerName: "BscScan"
|
|
12898
|
-
},
|
|
12899
|
-
LINEA: {
|
|
12900
|
-
chainId: "eip155:59144",
|
|
12901
|
-
namespace: "eip155",
|
|
12902
|
-
reference: "59144",
|
|
12903
|
-
name: "Linea",
|
|
12904
|
-
shortName: "Linea",
|
|
12905
|
-
explorerUrl: "https://lineascan.build",
|
|
12906
|
-
explorerName: "LineaScan"
|
|
12907
|
-
},
|
|
12908
|
-
MONAD: {
|
|
12909
|
-
chainId: "eip155:143",
|
|
12910
|
-
namespace: "eip155",
|
|
12911
|
-
reference: "143",
|
|
12912
|
-
name: "Monad",
|
|
12913
|
-
shortName: "Monad",
|
|
12914
|
-
explorerUrl: "https://monadvision.com",
|
|
12915
|
-
explorerName: "MonadVision"
|
|
12916
|
-
},
|
|
12917
|
-
INK: {
|
|
12918
|
-
chainId: "eip155:57073",
|
|
12919
|
-
namespace: "eip155",
|
|
12920
|
-
reference: "57073",
|
|
12921
|
-
name: "Ink",
|
|
12922
|
-
shortName: "Ink",
|
|
12923
|
-
explorerUrl: "https://explorer.inkonchain.com",
|
|
12924
|
-
explorerName: "Ink Explorer"
|
|
12925
|
-
},
|
|
12926
|
-
SHAPE: {
|
|
12927
|
-
chainId: "eip155:360",
|
|
12928
|
-
namespace: "eip155",
|
|
12929
|
-
reference: "360",
|
|
12930
|
-
name: "Shape",
|
|
12931
|
-
shortName: "Shape",
|
|
12932
|
-
explorerUrl: "https://shapescan.xyz",
|
|
12933
|
-
explorerName: "ShapeScan"
|
|
12934
|
-
},
|
|
12935
|
-
SONEIUM: {
|
|
12936
|
-
chainId: "eip155:1868",
|
|
12937
|
-
namespace: "eip155",
|
|
12938
|
-
reference: "1868",
|
|
12939
|
-
name: "Soneium",
|
|
12940
|
-
shortName: "Soneium",
|
|
12941
|
-
explorerUrl: "https://soneium.blockscout.com",
|
|
12942
|
-
explorerName: "Soneium Blockscout"
|
|
12943
|
-
},
|
|
12944
|
-
UNICHAIN: {
|
|
12945
|
-
chainId: "eip155:130",
|
|
12946
|
-
namespace: "eip155",
|
|
12947
|
-
reference: "130",
|
|
12948
|
-
name: "Unichain",
|
|
12949
|
-
shortName: "Unichain",
|
|
12950
|
-
explorerUrl: "https://unichain.blockscout.com",
|
|
12951
|
-
explorerName: "Unichain Blockscout"
|
|
12952
|
-
},
|
|
12953
|
-
WORLD_CHAIN: {
|
|
12954
|
-
chainId: "eip155:480",
|
|
12955
|
-
namespace: "eip155",
|
|
12956
|
-
reference: "480",
|
|
12957
|
-
name: "World Chain",
|
|
12958
|
-
shortName: "World Chain",
|
|
12959
|
-
explorerUrl: "https://worldscan.org",
|
|
12960
|
-
explorerName: "WorldScan"
|
|
12961
|
-
},
|
|
12962
|
-
// Non-EVM chains
|
|
12963
|
-
SOLANA_MAINNET: {
|
|
12964
|
-
chainId: "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp",
|
|
12965
|
-
namespace: "solana",
|
|
12966
|
-
reference: "5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp",
|
|
12967
|
-
name: "Solana Mainnet",
|
|
12968
|
-
shortName: "Solana",
|
|
12969
|
-
explorerUrl: "https://solscan.io",
|
|
12970
|
-
explorerName: "Solscan"
|
|
12971
|
-
},
|
|
12972
|
-
STELLAR_PUBNET: {
|
|
12973
|
-
chainId: "stellar:pubnet",
|
|
12974
|
-
namespace: "stellar",
|
|
12975
|
-
reference: "pubnet",
|
|
12976
|
-
name: "Stellar",
|
|
12977
|
-
shortName: "Stellar",
|
|
12978
|
-
explorerUrl: "https://stellar.expert/explorer/public",
|
|
12979
|
-
explorerName: "Stellar Expert"
|
|
12980
|
-
},
|
|
12981
|
-
TRON_MAINNET: {
|
|
12982
|
-
chainId: "tron:mainnet",
|
|
12983
|
-
namespace: "tron",
|
|
12984
|
-
reference: "mainnet",
|
|
12985
|
-
name: "Tron",
|
|
12986
|
-
shortName: "Tron",
|
|
12987
|
-
explorerUrl: "https://tronscan.org",
|
|
12988
|
-
explorerName: "TronScan"
|
|
12989
|
-
},
|
|
12990
|
-
BITCOIN_MAINNET: {
|
|
12991
|
-
chainId: "bip122:000000000019d6689c085ae165831e93-p2wpkh",
|
|
12992
|
-
namespace: "bip122",
|
|
12993
|
-
reference: "000000000019d6689c085ae165831e93-p2wpkh",
|
|
12994
|
-
name: "Bitcoin (P2WPKH)",
|
|
12995
|
-
shortName: "Bitcoin",
|
|
12996
|
-
explorerUrl: "https://mempool.space",
|
|
12997
|
-
explorerName: "Mempool"
|
|
12998
|
-
},
|
|
12999
|
-
CARDANO_MAINNET: {
|
|
13000
|
-
chainId: "cip34:1-764824073",
|
|
13001
|
-
namespace: "cip34",
|
|
13002
|
-
reference: "1-764824073",
|
|
13003
|
-
name: "Cardano",
|
|
13004
|
-
shortName: "Cardano",
|
|
13005
|
-
explorerUrl: "https://cardanoscan.io",
|
|
13006
|
-
explorerName: "CardanoScan"
|
|
13007
|
-
},
|
|
13008
|
-
SUI_MAINNET: {
|
|
13009
|
-
chainId: "sui:mainnet",
|
|
13010
|
-
namespace: "sui",
|
|
13011
|
-
reference: "mainnet",
|
|
13012
|
-
name: "Sui Mainnet",
|
|
13013
|
-
shortName: "Sui",
|
|
13014
|
-
explorerUrl: "https://suiscan.xyz",
|
|
13015
|
-
explorerName: "SuiScan"
|
|
13016
|
-
}
|
|
13017
|
-
};
|
|
13018
|
-
Object.fromEntries(
|
|
13019
|
-
Object.values(SUPPORTED_CHAINS).map((chain) => [chain.shortName, chain])
|
|
13020
|
-
);
|
|
13021
|
-
Object.fromEntries(
|
|
13022
|
-
Object.values(SUPPORTED_CHAINS).map((chain) => [chain.chainId, chain])
|
|
13023
|
-
);
|
|
13024
|
-
Object.values(SUPPORTED_CHAINS).filter(
|
|
13025
|
-
(chain) => chain.namespace === "eip155"
|
|
13026
|
-
);
|
|
13027
|
-
|
|
13028
|
-
// ../../internal/asset/src/parse/model.ts
|
|
13029
|
-
var AssetModel = /* @__PURE__ */ ((AssetModel2) => {
|
|
13030
|
-
AssetModel2["Addon"] = "addon";
|
|
13031
|
-
AssetModel2["App"] = "app";
|
|
13032
|
-
AssetModel2["Bot"] = "bot";
|
|
13033
|
-
AssetModel2["BusinessProfile"] = "business-profile";
|
|
13034
|
-
AssetModel2["Catalog"] = "catalog";
|
|
13035
|
-
AssetModel2["Collection"] = "collection";
|
|
13036
|
-
AssetModel2["Channel"] = "channel";
|
|
13037
|
-
AssetModel2["Group"] = "group";
|
|
13038
|
-
AssetModel2["Post"] = "post";
|
|
13039
|
-
AssetModel2["Profile"] = "profile";
|
|
13040
|
-
AssetModel2["Short"] = "short";
|
|
13041
|
-
AssetModel2["Video"] = "video";
|
|
13042
|
-
AssetModel2["Space"] = "space";
|
|
13043
|
-
AssetModel2["Issue"] = "issue";
|
|
13044
|
-
AssetModel2["PullRequest"] = "pull-request";
|
|
13045
|
-
AssetModel2["Discussion"] = "discussion";
|
|
13046
|
-
AssetModel2["Repository"] = "repository";
|
|
13047
|
-
AssetModel2["Article"] = "Article";
|
|
13048
|
-
AssetModel2["Comment"] = "comment";
|
|
13049
|
-
AssetModel2["List"] = "list";
|
|
13050
|
-
AssetModel2["Subreddit"] = "subreddit";
|
|
13051
|
-
AssetModel2["Community"] = "community";
|
|
13052
|
-
AssetModel2["MiniApp"] = "mini-app";
|
|
13053
|
-
AssetModel2["Developer"] = "developer";
|
|
13054
|
-
return AssetModel2;
|
|
13055
|
-
})(AssetModel || {});
|
|
13056
|
-
|
|
13057
|
-
// ../../internal/validation/src/assets/parse.ts
|
|
13058
12123
|
zod.z.object({
|
|
13059
12124
|
content: zod.z.string().min(1, "Input string is required").describe("The asset content to parse (URL, address, etc.)")
|
|
13060
12125
|
}).describe("Parse asset request body");
|
|
@@ -13151,6 +12216,7 @@ zod.z.object({
|
|
|
13151
12216
|
}).optional(),
|
|
13152
12217
|
isOverviewManuallyEdited: zod.z.boolean().optional(),
|
|
13153
12218
|
overviewDisplayLocation: zod.z.enum(["cover", "separate"]).default("cover"),
|
|
12219
|
+
coverVersion: zod.z.enum(["v1", "v2"]).default("v1"),
|
|
13154
12220
|
showCaseStudyOrgNames: zod.z.boolean().default(true),
|
|
13155
12221
|
showSimilarThreats: zod.z.boolean().default(true),
|
|
13156
12222
|
threatAnalysisType: zod.z.enum(["threats_blocked", "takedowns_completed"]).default("threats_blocked"),
|
|
@@ -13441,11 +12507,11 @@ var parseNamed_default = parseNamed;
|
|
|
13441
12507
|
|
|
13442
12508
|
// ../../node_modules/culori/src/rgb/parseHex.js
|
|
13443
12509
|
var hex = /^#?([0-9a-f]{8}|[0-9a-f]{6}|[0-9a-f]{4}|[0-9a-f]{3})$/i;
|
|
13444
|
-
var
|
|
12510
|
+
var parseHex = (color) => {
|
|
13445
12511
|
let match2;
|
|
13446
12512
|
return (match2 = color.match(hex)) ? parseNumber_default(parseInt(match2[1], 16), match2[1].length) : void 0;
|
|
13447
12513
|
};
|
|
13448
|
-
var parseHex_default =
|
|
12514
|
+
var parseHex_default = parseHex;
|
|
13449
12515
|
|
|
13450
12516
|
// ../../node_modules/culori/src/util/regex.js
|
|
13451
12517
|
var num = "([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)";
|