@seedprotocol/eas 0.6.10 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api.d.ts +7 -0
- package/dist/api.d.ts.map +1 -1
- package/dist/easEndpoint-BYyoBW_s.js.map +1 -1
- package/dist/easPropertyCanonical.d.ts +14 -1
- package/dist/easPropertyCanonical.d.ts.map +1 -1
- package/dist/graphql/fragments/Attestation.d.ts.map +1 -1
- package/dist/graphql/gql/fragment-masking.d.ts +1 -1
- package/dist/graphql/gql/fragment-masking.d.ts.map +1 -1
- package/dist/graphql/gql/gql.d.ts +3 -3
- package/dist/graphql/gql/gql.d.ts.map +1 -1
- package/dist/graphql/gql/graphql.d.ts +2 -1
- package/dist/graphql/gql/graphql.d.ts.map +1 -1
- package/dist/index.js +243 -155
- package/dist/index.js.map +1 -1
- package/dist/node.js.map +1 -1
- package/dist/queries.d.ts +1 -1
- package/dist/queries.d.ts.map +1 -1
- package/dist/stores/schemaUidCache.d.ts +23 -0
- package/dist/stores/schemaUidCache.d.ts.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,25 +1,24 @@
|
|
|
1
|
-
import { _ as e, a as t, c as n, d as r, f as i, g as a, h as o, i as s, l as c, m as l, n as u, o as d, p as f, r as p, s as ee, t as
|
|
2
|
-
import { keccak_256 as
|
|
3
|
-
import { bytesToHex as
|
|
4
|
-
import "graphql";
|
|
1
|
+
import { _ as e, a as t, c as n, d as r, f as i, g as a, h as o, i as s, l as c, m as l, n as u, o as d, p as f, r as p, s as ee, t as te, u as ne } from "./easEndpoint-BYyoBW_s.js";
|
|
2
|
+
import { keccak_256 as re } from "@noble/hashes/sha3";
|
|
3
|
+
import { bytesToHex as ie, utf8ToBytes as ae } from "@noble/hashes/utils";
|
|
5
4
|
//#region src/keccak.ts
|
|
6
|
-
function
|
|
7
|
-
let t = typeof e == "string" ?
|
|
8
|
-
return re(
|
|
5
|
+
function m(e) {
|
|
6
|
+
let t = typeof e == "string" ? ae(e) : e;
|
|
7
|
+
return ie(re(t));
|
|
9
8
|
}
|
|
10
9
|
//#endregion
|
|
11
10
|
//#region src/utils.ts
|
|
12
|
-
var
|
|
13
|
-
function
|
|
11
|
+
var h = (e) => e.replace(/([a-z])([A-Z])/g, "$1_$2").toLowerCase();
|
|
12
|
+
function g(e) {
|
|
14
13
|
let t = e.toLowerCase().replace(/^0x/, "");
|
|
15
14
|
if (t.length !== 40 || !/^[0-9a-f]+$/.test(t)) return e;
|
|
16
|
-
let n =
|
|
15
|
+
let n = m(t), r = "0x";
|
|
17
16
|
for (let e = 0; e < 40; e++) r += parseInt(n[e], 16) >= 8 ? t[e].toUpperCase() : t[e];
|
|
18
17
|
return r;
|
|
19
18
|
}
|
|
20
19
|
//#endregion
|
|
21
20
|
//#region src/easPropertyCanonical.ts
|
|
22
|
-
|
|
21
|
+
var oe = (e) => {
|
|
23
22
|
let t = /* @__PURE__ */ new Map();
|
|
24
23
|
for (let n of e) {
|
|
25
24
|
let e = n.schemaId;
|
|
@@ -27,11 +26,18 @@ function v(e) {
|
|
|
27
26
|
let r = `${n.refUID ?? ""}:${e}`, i = t.get(r), a = n.timeCreated ?? 0, o = i?.timeCreated ?? 0;
|
|
28
27
|
(!i || a > o) && t.set(r, n);
|
|
29
28
|
}
|
|
30
|
-
return
|
|
29
|
+
return t;
|
|
30
|
+
};
|
|
31
|
+
function se(e, t) {
|
|
32
|
+
let n = oe(e.filter((e) => !e.revoked));
|
|
33
|
+
if (t?.ifAllRevoked !== "newestRevoked") return [...n.values()];
|
|
34
|
+
let r = oe(e.filter((e) => e.revoked));
|
|
35
|
+
for (let [e, t] of r) n.has(e) || n.set(e, t);
|
|
36
|
+
return [...n.values()];
|
|
31
37
|
}
|
|
32
38
|
//#endregion
|
|
33
39
|
//#region src/easRevokedFilter.ts
|
|
34
|
-
function
|
|
40
|
+
function _(e) {
|
|
35
41
|
let t = { revoked: { equals: !1 } }, n = Array.isArray(e.AND) ? e.AND : [];
|
|
36
42
|
return {
|
|
37
43
|
...e,
|
|
@@ -40,8 +46,8 @@ function y(e) {
|
|
|
40
46
|
}
|
|
41
47
|
//#endregion
|
|
42
48
|
//#region src/graphql/gql/gql.ts
|
|
43
|
-
var
|
|
44
|
-
"\n fragment attestationFields on Attestation {\n id\n decodedDataJson\n attester\n schema {\n schemaNames {\n name\n }\n }\n refUID\n revoked\n schemaId\n txid\n timeCreated\n time\n isOffchain\n }\n": {
|
|
49
|
+
var ce = {
|
|
50
|
+
"\n fragment attestationFields on Attestation {\n id\n decodedDataJson\n attester\n schema {\n schemaNames {\n name\n }\n }\n refUID\n revoked\n revocationTime\n schemaId\n txid\n timeCreated\n time\n isOffchain\n }\n": {
|
|
45
51
|
kind: "Document",
|
|
46
52
|
definitions: [{
|
|
47
53
|
kind: "FragmentDefinition",
|
|
@@ -121,6 +127,13 @@ var ae = {
|
|
|
121
127
|
value: "revoked"
|
|
122
128
|
}
|
|
123
129
|
},
|
|
130
|
+
{
|
|
131
|
+
kind: "Field",
|
|
132
|
+
name: {
|
|
133
|
+
kind: "Name",
|
|
134
|
+
value: "revocationTime"
|
|
135
|
+
}
|
|
136
|
+
},
|
|
124
137
|
{
|
|
125
138
|
kind: "Field",
|
|
126
139
|
name: {
|
|
@@ -1047,6 +1060,13 @@ var ae = {
|
|
|
1047
1060
|
value: "revoked"
|
|
1048
1061
|
}
|
|
1049
1062
|
},
|
|
1063
|
+
{
|
|
1064
|
+
kind: "Field",
|
|
1065
|
+
name: {
|
|
1066
|
+
kind: "Name",
|
|
1067
|
+
value: "revocationTime"
|
|
1068
|
+
}
|
|
1069
|
+
},
|
|
1050
1070
|
{
|
|
1051
1071
|
kind: "Field",
|
|
1052
1072
|
name: {
|
|
@@ -1254,6 +1274,13 @@ var ae = {
|
|
|
1254
1274
|
value: "revoked"
|
|
1255
1275
|
}
|
|
1256
1276
|
},
|
|
1277
|
+
{
|
|
1278
|
+
kind: "Field",
|
|
1279
|
+
name: {
|
|
1280
|
+
kind: "Name",
|
|
1281
|
+
value: "revocationTime"
|
|
1282
|
+
}
|
|
1283
|
+
},
|
|
1257
1284
|
{
|
|
1258
1285
|
kind: "Field",
|
|
1259
1286
|
name: {
|
|
@@ -1461,6 +1488,13 @@ var ae = {
|
|
|
1461
1488
|
value: "revoked"
|
|
1462
1489
|
}
|
|
1463
1490
|
},
|
|
1491
|
+
{
|
|
1492
|
+
kind: "Field",
|
|
1493
|
+
name: {
|
|
1494
|
+
kind: "Name",
|
|
1495
|
+
value: "revocationTime"
|
|
1496
|
+
}
|
|
1497
|
+
},
|
|
1464
1498
|
{
|
|
1465
1499
|
kind: "Field",
|
|
1466
1500
|
name: {
|
|
@@ -1668,6 +1702,13 @@ var ae = {
|
|
|
1668
1702
|
value: "revoked"
|
|
1669
1703
|
}
|
|
1670
1704
|
},
|
|
1705
|
+
{
|
|
1706
|
+
kind: "Field",
|
|
1707
|
+
name: {
|
|
1708
|
+
kind: "Name",
|
|
1709
|
+
value: "revocationTime"
|
|
1710
|
+
}
|
|
1711
|
+
},
|
|
1671
1712
|
{
|
|
1672
1713
|
kind: "Field",
|
|
1673
1714
|
name: {
|
|
@@ -2059,6 +2100,13 @@ var ae = {
|
|
|
2059
2100
|
value: "revoked"
|
|
2060
2101
|
}
|
|
2061
2102
|
},
|
|
2103
|
+
{
|
|
2104
|
+
kind: "Field",
|
|
2105
|
+
name: {
|
|
2106
|
+
kind: "Name",
|
|
2107
|
+
value: "revocationTime"
|
|
2108
|
+
}
|
|
2109
|
+
},
|
|
2062
2110
|
{
|
|
2063
2111
|
kind: "Field",
|
|
2064
2112
|
name: {
|
|
@@ -2099,56 +2147,58 @@ var ae = {
|
|
|
2099
2147
|
}]
|
|
2100
2148
|
}
|
|
2101
2149
|
};
|
|
2102
|
-
function
|
|
2103
|
-
return
|
|
2150
|
+
function v(e) {
|
|
2151
|
+
return ce[e] ?? {};
|
|
2104
2152
|
}
|
|
2105
2153
|
//#endregion
|
|
2106
2154
|
//#region src/queries.ts
|
|
2107
|
-
var
|
|
2108
|
-
let r = a.getQueryClient(), i = e.getEasClient(), o = n ?
|
|
2155
|
+
var y = v("\n query GetSchemas($where: SchemaWhereInput!) {\n schemas: schemata(where: $where) {\n id\n schema\n schemaNames {\n name\n }\n }\n }\n"), b = v("\n query GetSchemaByName($where: SchemaWhereInput!) {\n schemas: schemata(where: $where) {\n id\n schema\n schemaNames {\n name\n }\n }\n }\n"), x = v("\n query GetSeeds($where: AttestationWhereInput!, $take: Int, $skip: Int) {\n itemSeeds: attestations(where: $where, orderBy: [{ timeCreated: desc }], take: $take, skip: $skip) {\n id\n decodedDataJson\n attester\n schema {\n schemaNames {\n name\n }\n }\n refUID\n revoked\n revocationTime\n schemaId\n timeCreated\n isOffchain\n }\n }\n"), le = v("\n query GetSeedIds($where: AttestationWhereInput!) {\n itemSeedIds: attestations(where: $where, orderBy: [{ timeCreated: desc }]) {\n id\n }\n }\n"), ue = v("\n query GetStorageTransactionId($where: AttestationWhereInput!) {\n storageTransactionId: attestations(\n where: $where\n orderBy: [{ timeCreated: desc }]\n ) {\n id\n decodedDataJson\n }\n }\n"), S = v("\n query GetVersions($where: AttestationWhereInput!) {\n itemVersions: attestations(\n where: $where\n orderBy: [{ timeCreated: desc }]\n ) {\n ...attestationFields\n }\n }\n"), C = v("\n query GetProperties($where: AttestationWhereInput!) {\n itemProperties: attestations(\n where: $where\n orderBy: [{ timeCreated: desc }]\n ) {\n ...attestationFields\n }\n }\n"), de = v("\n query GetAllPropertiesForAllVersions($where: AttestationWhereInput!) {\n allProperties: attestations(\n where: $where\n orderBy: [{ timeCreated: desc }]\n ) {\n ...attestationFields\n }\n }\n"), fe = v("\n query GetFilesMetadata($where: AttestationWhereInput!) {\n filesMetadata: attestations(\n where: $where\n orderBy: [{ timeCreated: desc }]\n ) {\n ...attestationFields\n }\n }\n"), pe = v("\n query GetImageSeeds($where: AttestationWhereInput!) {\n imageSeeds: attestations(where: $where, orderBy: [{ timeCreated: desc }]) {\n id\n decodedDataJson\n attester\n schema {\n schemaNames {\n name\n }\n }\n refUID\n revoked\n schemaId\n txid\n timeCreated\n time\n isOffchain\n }\n }\n"), me = v("\n query GetImageVersions($where: AttestationWhereInput!) {\n imageVersions: attestations(\n where: $where\n orderBy: [{ timeCreated: desc }]\n ) {\n ...attestationFields\n }\n }\n"), he = async ({ seedUids: t, excludeRevoked: n = !0 }) => {
|
|
2156
|
+
let r = a.getQueryClient(), i = e.getEasClient(), o = n ? _({ refUID: { in: t } }) : { refUID: { in: t } }, { itemVersions: s } = await r.fetchQuery({
|
|
2109
2157
|
queryKey: [
|
|
2110
2158
|
"getVersionsForAllModels",
|
|
2111
2159
|
[...t].sort(),
|
|
2112
2160
|
n
|
|
2113
2161
|
],
|
|
2114
|
-
queryFn: async () => i.request(
|
|
2162
|
+
queryFn: async () => i.request(S, { where: o })
|
|
2115
2163
|
});
|
|
2116
2164
|
return s;
|
|
2117
|
-
},
|
|
2118
|
-
let r = a.getQueryClient(), i = e.getEasClient(), o = n ?
|
|
2165
|
+
}, w = async ({ versionUids: t, excludeRevoked: n = !0 }) => {
|
|
2166
|
+
let r = a.getQueryClient(), i = e.getEasClient(), o = n ? _({ refUID: { in: t } }) : { refUID: { in: t } }, { itemProperties: s } = await r.fetchQuery({
|
|
2119
2167
|
queryKey: [
|
|
2120
2168
|
"getPropertiesForAllModels",
|
|
2121
2169
|
[...t].sort(),
|
|
2122
2170
|
n
|
|
2123
2171
|
],
|
|
2124
|
-
queryFn: async () => i.request(
|
|
2172
|
+
queryFn: async () => i.request(C, { where: o })
|
|
2125
2173
|
});
|
|
2126
2174
|
return s;
|
|
2127
|
-
},
|
|
2175
|
+
}, ge = async (e) => se(await w(e)), T = async ({ schemaName: t }) => {
|
|
2176
|
+
let n = a.getQueryClient(), r = e.getEasClient();
|
|
2177
|
+
if (!n || !r) return;
|
|
2178
|
+
let { schemas: i } = await n.fetchQuery({
|
|
2179
|
+
queryKey: ["getEasSchemaUidBySchemaName", t],
|
|
2180
|
+
queryFn: async () => r.request(y, { where: { schema: { endsWith: t } } })
|
|
2181
|
+
});
|
|
2182
|
+
if (i && i.length !== 0) return i[0].id;
|
|
2183
|
+
}, _e = async ({ schemaName: e }) => {
|
|
2128
2184
|
try {
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
queryKey: ["getEasSchemaUidBySchemaName"],
|
|
2133
|
-
queryFn: async () => r.request(x, { where: { schema: { endsWith: t } } })
|
|
2134
|
-
});
|
|
2135
|
-
return !i || i.length === 0 ? void 0 : i[0].id;
|
|
2136
|
-
} catch (e) {
|
|
2137
|
-
process.env.NODE_ENV === "development" && console.warn(`Failed to fetch schema for schema name ${t}:`, e);
|
|
2185
|
+
return await T({ schemaName: e });
|
|
2186
|
+
} catch (t) {
|
|
2187
|
+
process.env.NODE_ENV === "development" && console.warn(`Failed to fetch schema for schema name ${e}:`, t);
|
|
2138
2188
|
return;
|
|
2139
2189
|
}
|
|
2140
|
-
},
|
|
2190
|
+
}, ve = async ({ schemaUids: t, addresses: n, excludeRevoked: r = !0 }) => {
|
|
2141
2191
|
let i = {
|
|
2142
2192
|
attester: { in: n.map((e) => {
|
|
2143
2193
|
try {
|
|
2144
|
-
return
|
|
2194
|
+
return g(e);
|
|
2145
2195
|
} catch {
|
|
2146
2196
|
return e;
|
|
2147
2197
|
}
|
|
2148
2198
|
}) },
|
|
2149
2199
|
schemaId: { in: t }
|
|
2150
2200
|
};
|
|
2151
|
-
r && (i =
|
|
2201
|
+
r && (i = _(i));
|
|
2152
2202
|
let o = a.getQueryClient(), s = e.getEasClient(), { itemSeeds: c } = await o.fetchQuery({
|
|
2153
2203
|
queryKey: [
|
|
2154
2204
|
"getSeedsForAllModels",
|
|
@@ -2156,12 +2206,12 @@ var x = b("\n query GetSchemas($where: SchemaWhereInput!) {\n schemas: schem
|
|
|
2156
2206
|
[...t].sort(),
|
|
2157
2207
|
[...n].sort()
|
|
2158
2208
|
],
|
|
2159
|
-
queryFn: async () => s.request(
|
|
2209
|
+
queryFn: async () => s.request(x, { where: i })
|
|
2160
2210
|
});
|
|
2161
2211
|
return c;
|
|
2162
|
-
},
|
|
2212
|
+
}, E = async (t, n = 10, r) => {
|
|
2163
2213
|
let i = r ?? 0, o = {
|
|
2164
|
-
where:
|
|
2214
|
+
where: _({ schema: { is: { schemaNames: { some: { name: { equals: t } } } } } }),
|
|
2165
2215
|
take: n,
|
|
2166
2216
|
skip: i
|
|
2167
2217
|
}, s = a.getQueryClient(), c = e.getEasClient(), { itemSeeds: l } = await s.fetchQuery({
|
|
@@ -2171,54 +2221,54 @@ var x = b("\n query GetSchemas($where: SchemaWhereInput!) {\n schemas: schem
|
|
|
2171
2221
|
n,
|
|
2172
2222
|
i
|
|
2173
2223
|
],
|
|
2174
|
-
queryFn: async () => c.request(
|
|
2224
|
+
queryFn: async () => c.request(x, o)
|
|
2175
2225
|
});
|
|
2176
2226
|
return l;
|
|
2177
|
-
},
|
|
2227
|
+
}, ye = async (e, t = 10) => (await E(e, t)).map((e) => e.id), be = "0x0000000000000000000000000000000000000000", xe = "0x", Se = "0x0000000000000000000000000000000000000000000000000000000000000000", Ce = typeof process < "u" && process.env?.NEXT_PUBLIC_EAS_ENDPOINT || typeof process < "u" && process.env?.EAS_ENDPOINT || "https://optimism-sepolia.easscan.org/graphql";
|
|
2178
2228
|
//#endregion
|
|
2179
2229
|
//#region src/easUid.ts
|
|
2180
|
-
function
|
|
2230
|
+
function D(e) {
|
|
2181
2231
|
if (e == null || e === "" || e === "NULL") return !0;
|
|
2182
2232
|
let t = e.trim();
|
|
2183
2233
|
return t === "" || t.toLowerCase() === "0x0000000000000000000000000000000000000000000000000000000000000000";
|
|
2184
2234
|
}
|
|
2185
|
-
function
|
|
2186
|
-
if (
|
|
2235
|
+
function O(e) {
|
|
2236
|
+
if (D(e)) return !1;
|
|
2187
2237
|
let t = String(e).trim();
|
|
2188
2238
|
if (!/^0x/i.test(t)) return !1;
|
|
2189
2239
|
let n = t.slice(2);
|
|
2190
2240
|
return n.length === 64 && /^[0-9a-fA-F]{64}$/.test(n);
|
|
2191
2241
|
}
|
|
2192
|
-
function
|
|
2242
|
+
function k(e) {
|
|
2193
2243
|
if (e == null || e === "") return "";
|
|
2194
2244
|
let t = String(e).trim();
|
|
2195
2245
|
return ("0x" + (t.startsWith("0x") || t.startsWith("0X") ? t.slice(2) : t).replace(/[^0-9a-fA-F]/g, "0").padStart(64, "0").slice(-64)).toLowerCase();
|
|
2196
2246
|
}
|
|
2197
2247
|
//#endregion
|
|
2198
2248
|
//#region src/domainOwnershipHelpers.ts
|
|
2199
|
-
var
|
|
2200
|
-
function
|
|
2249
|
+
var we = "string domain,address claimer,string method,bytes32 challengeHash,uint64 verifiedAt,string registryCreationDate,string registryExpirationDate,bytes32 registryFingerprint,string scope", A = "seedprotocol.domainOwnership", Te = "dns-txt-challenge", Ee = "registrable", j = "_seedprotocol-challenge", De = 2592e5, Oe = 31536e6, ke = 31536e3;
|
|
2250
|
+
function M(e) {
|
|
2201
2251
|
return new TextEncoder().encode(e);
|
|
2202
2252
|
}
|
|
2203
|
-
function
|
|
2253
|
+
function N(e) {
|
|
2204
2254
|
return e.trim().toLowerCase().replace(/\.$/, "");
|
|
2205
2255
|
}
|
|
2206
|
-
function
|
|
2256
|
+
function P(e) {
|
|
2207
2257
|
let t = e.trim();
|
|
2208
2258
|
try {
|
|
2209
|
-
return
|
|
2259
|
+
return g(t).toLowerCase();
|
|
2210
2260
|
} catch {
|
|
2211
2261
|
return t.toLowerCase();
|
|
2212
2262
|
}
|
|
2213
2263
|
}
|
|
2214
|
-
function
|
|
2215
|
-
return `${
|
|
2264
|
+
function Ae(e) {
|
|
2265
|
+
return `${j}.${N(e)}`;
|
|
2216
2266
|
}
|
|
2217
|
-
function
|
|
2218
|
-
let t =
|
|
2267
|
+
function je(e) {
|
|
2268
|
+
let t = P(e.claimer);
|
|
2219
2269
|
return `token=${e.token},addr=${t},expiry=${e.expiry}`;
|
|
2220
2270
|
}
|
|
2221
|
-
function
|
|
2271
|
+
function Me(e) {
|
|
2222
2272
|
let t = e.replace(/^"+|"+$/g, "").trim(), n = /* @__PURE__ */ new Map();
|
|
2223
2273
|
for (let e of t.split(",")) {
|
|
2224
2274
|
let t = e.indexOf("=");
|
|
@@ -2229,59 +2279,59 @@ function ke(e) {
|
|
|
2229
2279
|
let r = n.get("token"), i = n.get("addr") ?? n.get("claimer"), a = n.get("expiry");
|
|
2230
2280
|
return !r || !i || !a ? null : {
|
|
2231
2281
|
token: r,
|
|
2232
|
-
claimer:
|
|
2282
|
+
claimer: P(i),
|
|
2233
2283
|
expiry: a
|
|
2234
2284
|
};
|
|
2235
2285
|
}
|
|
2236
|
-
function
|
|
2237
|
-
let t =
|
|
2238
|
-
return "0x" +
|
|
2286
|
+
function Ne(e) {
|
|
2287
|
+
let t = N(e.domain), n = P(e.claimer), r = (e.scope ?? "registrable").trim();
|
|
2288
|
+
return "0x" + m(M(`${t}|${n}|${e.token}|${r}`));
|
|
2239
2289
|
}
|
|
2240
|
-
function
|
|
2290
|
+
function F(e) {
|
|
2241
2291
|
let t = {
|
|
2242
|
-
domain:
|
|
2292
|
+
domain: N(e.domain),
|
|
2243
2293
|
creationDate: (e.creationDate ?? "").trim(),
|
|
2244
2294
|
registrarIanaId: (e.registrarIanaId ?? "").trim()
|
|
2245
2295
|
};
|
|
2246
|
-
return "0x" +
|
|
2296
|
+
return "0x" + m(M(JSON.stringify(t)));
|
|
2247
2297
|
}
|
|
2248
|
-
function
|
|
2249
|
-
return typeof e == "string" ?
|
|
2298
|
+
function I(e) {
|
|
2299
|
+
return typeof e == "string" ? k(e) : e && typeof e == "object" && "hex" in e ? k(String(e.hex)) : k(String(e ?? ""));
|
|
2250
2300
|
}
|
|
2251
|
-
function
|
|
2301
|
+
function L(e) {
|
|
2252
2302
|
return typeof e == "string" ? e : e && typeof e == "object" && "value" in e ? String(e.value ?? "") : String(e ?? "");
|
|
2253
2303
|
}
|
|
2254
|
-
function
|
|
2304
|
+
function R(e) {
|
|
2255
2305
|
if (typeof e == "number" && Number.isFinite(e)) return Math.trunc(e);
|
|
2256
2306
|
if (typeof e == "bigint") return Number(e);
|
|
2257
2307
|
if (typeof e == "string" && e.trim() !== "") {
|
|
2258
2308
|
let t = Number(e);
|
|
2259
2309
|
return Number.isFinite(t) ? Math.trunc(t) : 0;
|
|
2260
2310
|
}
|
|
2261
|
-
return e && typeof e == "object" && "value" in e ?
|
|
2311
|
+
return e && typeof e == "object" && "value" in e ? R(e.value) : 0;
|
|
2262
2312
|
}
|
|
2263
|
-
function
|
|
2313
|
+
function z(e) {
|
|
2264
2314
|
let t = typeof e == "string" ? JSON.parse(e) : e, n = /* @__PURE__ */ new Map();
|
|
2265
2315
|
for (let e of t) e?.name && n.set(e.name, e);
|
|
2266
2316
|
return {
|
|
2267
|
-
domain:
|
|
2268
|
-
claimer:
|
|
2269
|
-
method:
|
|
2270
|
-
challengeHash:
|
|
2271
|
-
verifiedAt:
|
|
2272
|
-
registryCreationDate:
|
|
2273
|
-
registryExpirationDate:
|
|
2274
|
-
registryFingerprint:
|
|
2275
|
-
scope:
|
|
2317
|
+
domain: N(L(n.get("domain")?.value)),
|
|
2318
|
+
claimer: P(L(n.get("claimer")?.value)),
|
|
2319
|
+
method: L(n.get("method")?.value),
|
|
2320
|
+
challengeHash: I(n.get("challengeHash")?.value),
|
|
2321
|
+
verifiedAt: R(n.get("verifiedAt")?.value),
|
|
2322
|
+
registryCreationDate: L(n.get("registryCreationDate")?.value),
|
|
2323
|
+
registryExpirationDate: L(n.get("registryExpirationDate")?.value),
|
|
2324
|
+
registryFingerprint: I(n.get("registryFingerprint")?.value),
|
|
2325
|
+
scope: L(n.get("scope")?.value)
|
|
2276
2326
|
};
|
|
2277
2327
|
}
|
|
2278
|
-
function
|
|
2328
|
+
function Pe(e) {
|
|
2279
2329
|
if (!e?.trim()) return null;
|
|
2280
2330
|
let t = Date.parse(e);
|
|
2281
2331
|
return Number.isFinite(t) ? Math.floor(t / 1e3) : null;
|
|
2282
2332
|
}
|
|
2283
|
-
function
|
|
2284
|
-
let t = Math.floor((e.now ?? Date.now()) / 1e3), n = [], r = e.softStaleMs ?? 31536e6, i = e.expirationTime, a =
|
|
2333
|
+
function Fe(e) {
|
|
2334
|
+
let t = Math.floor((e.now ?? Date.now()) / 1e3), n = [], r = e.softStaleMs ?? 31536e6, i = e.expirationTime, a = Pe(e.decoded.registryExpirationDate);
|
|
2285
2335
|
if (typeof i == "number" && i > 0 && t >= i || a != null && t >= a) return {
|
|
2286
2336
|
status: "expired",
|
|
2287
2337
|
warnings: n
|
|
@@ -2290,11 +2340,11 @@ function Me(e) {
|
|
|
2290
2340
|
status: "unknown",
|
|
2291
2341
|
warnings: n
|
|
2292
2342
|
};
|
|
2293
|
-
if (e.registrySnapshot !== void 0) return
|
|
2343
|
+
if (e.registrySnapshot !== void 0) return k(F({
|
|
2294
2344
|
domain: e.decoded.domain,
|
|
2295
2345
|
creationDate: e.registrySnapshot.creationDate,
|
|
2296
2346
|
registrarIanaId: e.registrySnapshot.registrarIanaId
|
|
2297
|
-
})) ===
|
|
2347
|
+
})) === k(e.decoded.registryFingerprint) ? {
|
|
2298
2348
|
status: "valid",
|
|
2299
2349
|
warnings: n
|
|
2300
2350
|
} : (n.push("Registry creation date or registrar IANA id no longer matches attestation fingerprint"), {
|
|
@@ -2312,42 +2362,42 @@ function Me(e) {
|
|
|
2312
2362
|
}
|
|
2313
2363
|
//#endregion
|
|
2314
2364
|
//#region src/domainOwnership.ts
|
|
2315
|
-
function
|
|
2365
|
+
function B(e) {
|
|
2316
2366
|
return e.trim().toLowerCase().replace(/\.$/, "");
|
|
2317
2367
|
}
|
|
2318
|
-
async function
|
|
2368
|
+
async function Ie(t) {
|
|
2319
2369
|
let { toolAddresses: n, domains: r, claimers: i, schemaUid: o, excludeRevoked: s = !0 } = t;
|
|
2320
2370
|
if (!n.length) return [];
|
|
2321
2371
|
let c = n.map((e) => {
|
|
2322
2372
|
try {
|
|
2323
|
-
return
|
|
2373
|
+
return g(e);
|
|
2324
2374
|
} catch {
|
|
2325
2375
|
return e;
|
|
2326
2376
|
}
|
|
2327
2377
|
}), l = { attester: { in: c } };
|
|
2328
|
-
o ? l.schemaId = { equals: o } : l.schema = { is: { schemaNames: { some: { name: { equals:
|
|
2378
|
+
o ? l.schemaId = { equals: o } : l.schema = { is: { schemaNames: { some: { name: { equals: A } } } } }, i?.length && (l.recipient = { in: i.map((e) => {
|
|
2329
2379
|
try {
|
|
2330
|
-
return
|
|
2380
|
+
return g(e);
|
|
2331
2381
|
} catch {
|
|
2332
2382
|
return e;
|
|
2333
2383
|
}
|
|
2334
|
-
}) }), s && (l =
|
|
2384
|
+
}) }), s && (l = _(l));
|
|
2335
2385
|
let u = a.getQueryClient(), d = e.getEasClient(), { itemSeeds: f } = await u.fetchQuery({
|
|
2336
2386
|
queryKey: [
|
|
2337
2387
|
"getDomainOwnershipFromEas",
|
|
2338
2388
|
s,
|
|
2339
2389
|
o ?? "seedprotocol.domainOwnership",
|
|
2340
2390
|
[...c].sort(),
|
|
2341
|
-
[...(r ?? []).map(
|
|
2391
|
+
[...(r ?? []).map(B)].sort(),
|
|
2342
2392
|
[...i ?? []].map((e) => e.toLowerCase()).sort()
|
|
2343
2393
|
],
|
|
2344
|
-
queryFn: async () => d.request(
|
|
2394
|
+
queryFn: async () => d.request(x, { where: l })
|
|
2345
2395
|
});
|
|
2346
2396
|
if (!r?.length) return f;
|
|
2347
|
-
let p = new Set(r.map(
|
|
2397
|
+
let p = new Set(r.map(B));
|
|
2348
2398
|
return f.filter((e) => {
|
|
2349
2399
|
try {
|
|
2350
|
-
let t =
|
|
2400
|
+
let t = z(e.decodedDataJson ?? "[]");
|
|
2351
2401
|
return p.has(t.domain);
|
|
2352
2402
|
} catch {
|
|
2353
2403
|
return !1;
|
|
@@ -2356,44 +2406,44 @@ async function Ne(t) {
|
|
|
2356
2406
|
}
|
|
2357
2407
|
//#endregion
|
|
2358
2408
|
//#region src/publishAuthorizationHelpers.ts
|
|
2359
|
-
var
|
|
2360
|
-
function
|
|
2409
|
+
var Le = "address identity,address sessionKey,address app,string scopes,uint64 grantedAt,uint64 expiresAt,bytes32 permissionsHash", V = "seedprotocol.publishAuthorization", Re = "publish,revoke", ze = 31536e3;
|
|
2410
|
+
function H(e) {
|
|
2361
2411
|
let t = e.trim();
|
|
2362
2412
|
try {
|
|
2363
|
-
return
|
|
2413
|
+
return g(t).toLowerCase();
|
|
2364
2414
|
} catch {
|
|
2365
2415
|
return t.toLowerCase();
|
|
2366
2416
|
}
|
|
2367
2417
|
}
|
|
2368
|
-
function
|
|
2369
|
-
return typeof e == "string" ?
|
|
2418
|
+
function Be(e) {
|
|
2419
|
+
return typeof e == "string" ? k(e) : e && typeof e == "object" && "hex" in e ? k(String(e.hex)) : k(String(e ?? ""));
|
|
2370
2420
|
}
|
|
2371
|
-
function
|
|
2421
|
+
function U(e) {
|
|
2372
2422
|
return typeof e == "string" ? e : e && typeof e == "object" && "value" in e ? String(e.value ?? "") : String(e ?? "");
|
|
2373
2423
|
}
|
|
2374
|
-
function
|
|
2424
|
+
function W(e) {
|
|
2375
2425
|
if (typeof e == "number" && Number.isFinite(e)) return Math.trunc(e);
|
|
2376
2426
|
if (typeof e == "bigint") return Number(e);
|
|
2377
2427
|
if (typeof e == "string" && e.trim() !== "") {
|
|
2378
2428
|
let t = Number(e);
|
|
2379
2429
|
return Number.isFinite(t) ? Math.trunc(t) : 0;
|
|
2380
2430
|
}
|
|
2381
|
-
return e && typeof e == "object" && "value" in e ?
|
|
2431
|
+
return e && typeof e == "object" && "value" in e ? W(e.value) : 0;
|
|
2382
2432
|
}
|
|
2383
|
-
function
|
|
2433
|
+
function Ve(e) {
|
|
2384
2434
|
let t = typeof e == "string" ? JSON.parse(e) : e, n = /* @__PURE__ */ new Map();
|
|
2385
2435
|
for (let e of t) e?.name && n.set(e.name, e);
|
|
2386
2436
|
return {
|
|
2387
|
-
identity: U(
|
|
2388
|
-
sessionKey: U(
|
|
2389
|
-
app: U(
|
|
2390
|
-
scopes:
|
|
2391
|
-
grantedAt:
|
|
2392
|
-
expiresAt:
|
|
2393
|
-
permissionsHash:
|
|
2437
|
+
identity: H(U(n.get("identity")?.value)),
|
|
2438
|
+
sessionKey: H(U(n.get("sessionKey")?.value)),
|
|
2439
|
+
app: H(U(n.get("app")?.value)),
|
|
2440
|
+
scopes: U(n.get("scopes")?.value),
|
|
2441
|
+
grantedAt: W(n.get("grantedAt")?.value),
|
|
2442
|
+
expiresAt: W(n.get("expiresAt")?.value),
|
|
2443
|
+
permissionsHash: Be(n.get("permissionsHash")?.value)
|
|
2394
2444
|
};
|
|
2395
2445
|
}
|
|
2396
|
-
function
|
|
2446
|
+
function He(e) {
|
|
2397
2447
|
let t = Math.floor((e.now ?? Date.now()) / 1e3), n = [], r = e.expectedScopes ?? "publish,revoke", i = e.expirationTime, a = e.decoded.expiresAt;
|
|
2398
2448
|
return typeof i == "number" && i > 0 && t >= i || a > 0 && t >= a ? {
|
|
2399
2449
|
status: "expired",
|
|
@@ -2409,26 +2459,26 @@ function Re(e) {
|
|
|
2409
2459
|
warnings: n
|
|
2410
2460
|
});
|
|
2411
2461
|
}
|
|
2412
|
-
function
|
|
2413
|
-
return "0x" +
|
|
2462
|
+
function Ue(e) {
|
|
2463
|
+
return "0x" + m(new TextEncoder().encode(e));
|
|
2414
2464
|
}
|
|
2415
2465
|
//#endregion
|
|
2416
2466
|
//#region src/publishAuthorization.ts
|
|
2417
|
-
async function
|
|
2467
|
+
async function We(t = {}) {
|
|
2418
2468
|
let { identities: n, sessionKeys: r, apps: i, schemaUid: o, excludeRevoked: s = !0 } = t, c = {};
|
|
2419
|
-
o ? c.schemaId = { equals: o } : c.schema = { is: { schemaNames: { some: { name: { equals:
|
|
2469
|
+
o ? c.schemaId = { equals: o } : c.schema = { is: { schemaNames: { some: { name: { equals: V } } } } }, n?.length && (c.attester = { in: n.map((e) => {
|
|
2420
2470
|
try {
|
|
2421
|
-
return
|
|
2471
|
+
return g(e);
|
|
2422
2472
|
} catch {
|
|
2423
2473
|
return e;
|
|
2424
2474
|
}
|
|
2425
2475
|
}) }), r?.length && (c.recipient = { in: r.map((e) => {
|
|
2426
2476
|
try {
|
|
2427
|
-
return
|
|
2477
|
+
return g(e);
|
|
2428
2478
|
} catch {
|
|
2429
2479
|
return e;
|
|
2430
2480
|
}
|
|
2431
|
-
}) }), s && (c =
|
|
2481
|
+
}) }), s && (c = _(c));
|
|
2432
2482
|
let l = a.getQueryClient(), u = e.getEasClient(), { itemSeeds: d } = await l.fetchQuery({
|
|
2433
2483
|
queryKey: [
|
|
2434
2484
|
"getPublishAuthorizationFromEas",
|
|
@@ -2438,13 +2488,13 @@ async function Be(t = {}) {
|
|
|
2438
2488
|
[...r ?? []].map((e) => e.toLowerCase()).sort(),
|
|
2439
2489
|
[...i ?? []].map((e) => e.toLowerCase()).sort()
|
|
2440
2490
|
],
|
|
2441
|
-
queryFn: async () => u.request(
|
|
2491
|
+
queryFn: async () => u.request(x, { where: c })
|
|
2442
2492
|
});
|
|
2443
2493
|
if (!i?.length) return d;
|
|
2444
2494
|
let f = new Set(i.map((e) => e.toLowerCase()));
|
|
2445
2495
|
return d.filter((e) => {
|
|
2446
2496
|
try {
|
|
2447
|
-
let t =
|
|
2497
|
+
let t = Ve(e.decodedDataJson ?? "[]");
|
|
2448
2498
|
return f.has(t.app.toLowerCase());
|
|
2449
2499
|
} catch {
|
|
2450
2500
|
return !1;
|
|
@@ -2453,54 +2503,54 @@ async function Be(t = {}) {
|
|
|
2453
2503
|
}
|
|
2454
2504
|
//#endregion
|
|
2455
2505
|
//#region src/publishedByHelpers.ts
|
|
2456
|
-
var
|
|
2457
|
-
function
|
|
2506
|
+
var Ge = "bytes32 seedUid,bytes32 versionUid,bytes32[] attestationUids,bytes32 batchHash,string toolName,string toolVersion", Ke = "seedprotocol.publishedBy";
|
|
2507
|
+
function qe(e) {
|
|
2458
2508
|
let t = e.startsWith("0x") || e.startsWith("0X") ? e.slice(2) : e, n = new Uint8Array(t.length / 2);
|
|
2459
2509
|
for (let e = 0; e < n.length; e++) n[e] = parseInt(t.slice(e * 2, e * 2 + 2), 16);
|
|
2460
2510
|
return n;
|
|
2461
2511
|
}
|
|
2462
|
-
function
|
|
2463
|
-
let t = [...e].map((e) =>
|
|
2464
|
-
if (t.length === 0) return "0x" +
|
|
2512
|
+
function Je(e) {
|
|
2513
|
+
let t = [...e].map((e) => k(e)).filter((e) => e !== "" && O(e)).sort();
|
|
2514
|
+
if (t.length === 0) return "0x" + m(/* @__PURE__ */ new Uint8Array());
|
|
2465
2515
|
let n = new Uint8Array(t.length * 32);
|
|
2466
|
-
for (let e = 0; e < t.length; e++) n.set(
|
|
2467
|
-
return "0x" +
|
|
2516
|
+
for (let e = 0; e < t.length; e++) n.set(qe(t[e]), e * 32);
|
|
2517
|
+
return "0x" + m(n);
|
|
2468
2518
|
}
|
|
2469
|
-
function
|
|
2470
|
-
return
|
|
2519
|
+
function Ye(e) {
|
|
2520
|
+
return k(Je(e.attestationUids)) === k(e.batchHash);
|
|
2471
2521
|
}
|
|
2472
|
-
function
|
|
2473
|
-
return typeof e == "string" ?
|
|
2522
|
+
function G(e) {
|
|
2523
|
+
return typeof e == "string" ? k(e) : e && typeof e == "object" && "hex" in e ? k(String(e.hex)) : k(String(e ?? ""));
|
|
2474
2524
|
}
|
|
2475
|
-
function
|
|
2525
|
+
function Xe(e) {
|
|
2476
2526
|
return typeof e == "string" ? e : e && typeof e == "object" && "value" in e ? String(e.value ?? "") : String(e ?? "");
|
|
2477
2527
|
}
|
|
2478
|
-
function
|
|
2528
|
+
function Ze(e) {
|
|
2479
2529
|
let t = typeof e == "string" ? JSON.parse(e) : e, n = /* @__PURE__ */ new Map();
|
|
2480
2530
|
for (let e of t) e?.name && n.set(e.name, e);
|
|
2481
2531
|
let r = n.get("attestationUids")?.value, i = [];
|
|
2482
|
-
return Array.isArray(r) ? i = r.map((e) =>
|
|
2483
|
-
seedUid:
|
|
2484
|
-
versionUid:
|
|
2532
|
+
return Array.isArray(r) ? i = r.map((e) => G(e)) : r && typeof r == "object" && Array.isArray(r.value) && (i = r.value.map((e) => G(e))), {
|
|
2533
|
+
seedUid: G(n.get("seedUid")?.value),
|
|
2534
|
+
versionUid: G(n.get("versionUid")?.value),
|
|
2485
2535
|
attestationUids: i,
|
|
2486
|
-
batchHash:
|
|
2487
|
-
toolName:
|
|
2488
|
-
toolVersion:
|
|
2536
|
+
batchHash: G(n.get("batchHash")?.value),
|
|
2537
|
+
toolName: Xe(n.get("toolName")?.value),
|
|
2538
|
+
toolVersion: Xe(n.get("toolVersion")?.value)
|
|
2489
2539
|
};
|
|
2490
2540
|
}
|
|
2491
2541
|
//#endregion
|
|
2492
2542
|
//#region src/publishedBy.ts
|
|
2493
|
-
async function
|
|
2543
|
+
async function Qe(t) {
|
|
2494
2544
|
let { toolAddresses: n, refUIDs: r, schemaUid: i, excludeRevoked: o = !0 } = t;
|
|
2495
2545
|
if (!n.length) return [];
|
|
2496
2546
|
let s = n.map((e) => {
|
|
2497
2547
|
try {
|
|
2498
|
-
return
|
|
2548
|
+
return g(e);
|
|
2499
2549
|
} catch {
|
|
2500
2550
|
return e;
|
|
2501
2551
|
}
|
|
2502
2552
|
}), c = { attester: { in: s } };
|
|
2503
|
-
i ? c.schemaId = { equals: i } : c.schema = { is: { schemaNames: { some: { name: { equals:
|
|
2553
|
+
i ? c.schemaId = { equals: i } : c.schema = { is: { schemaNames: { some: { name: { equals: Ke } } } } }, r?.length && (c.refUID = { in: r }), o && (c = _(c));
|
|
2504
2554
|
let l = a.getQueryClient(), u = e.getEasClient(), { itemSeeds: d } = await l.fetchQuery({
|
|
2505
2555
|
queryKey: [
|
|
2506
2556
|
"getPublishedByFromEas",
|
|
@@ -2509,28 +2559,66 @@ async function Ge(t) {
|
|
|
2509
2559
|
[...s].sort(),
|
|
2510
2560
|
[...r ?? []].sort()
|
|
2511
2561
|
],
|
|
2512
|
-
queryFn: async () => u.request(
|
|
2562
|
+
queryFn: async () => u.request(x, { where: c })
|
|
2513
2563
|
});
|
|
2514
2564
|
return d;
|
|
2515
2565
|
}
|
|
2516
2566
|
//#endregion
|
|
2517
2567
|
//#region src/stores/schemaUidCache.ts
|
|
2518
|
-
var
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
}
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
}), e;
|
|
2568
|
+
var K = /* @__PURE__ */ new Map(), q = /* @__PURE__ */ new Map(), $e = 3e5, J = /* @__PURE__ */ new Map(), Y = /* @__PURE__ */ new Map(), X = /* @__PURE__ */ new Map(), Z = 0, et = (e) => {
|
|
2569
|
+
let t = "";
|
|
2570
|
+
try {
|
|
2571
|
+
t = p();
|
|
2572
|
+
} catch {}
|
|
2573
|
+
return `${t}\n${e}`;
|
|
2574
|
+
}, Q = async (e, t) => {
|
|
2575
|
+
let n = et(e), r = Y.get(n);
|
|
2576
|
+
if (r !== void 0) {
|
|
2577
|
+
if (Date.now() < r) return;
|
|
2578
|
+
Y.delete(n);
|
|
2530
2579
|
}
|
|
2531
|
-
|
|
2580
|
+
let i = X.get(n);
|
|
2581
|
+
if (i) return i;
|
|
2582
|
+
let a = Z, o = t().then((e) => (!e && a === Z && Y.set(n, Date.now() + $e), e)).finally(() => {
|
|
2583
|
+
X.get(n) === o && X.delete(n);
|
|
2584
|
+
});
|
|
2585
|
+
return X.set(n, o), o;
|
|
2586
|
+
}, $ = () => {
|
|
2587
|
+
Z++, Y.clear(), X.clear();
|
|
2588
|
+
}, tt = () => {
|
|
2589
|
+
K.clear(), q.clear(), J.clear(), $();
|
|
2590
|
+
}, nt = ({ text: e, schemaUid: t }) => {
|
|
2591
|
+
K.set(h(e), t), $();
|
|
2592
|
+
}, rt = ({ modelName: e, schemaUid: t }) => {
|
|
2593
|
+
q.set(e.toLowerCase(), t), $();
|
|
2594
|
+
}, it = (e) => q.get(e.toLowerCase()), at = async ({ schemaText: e }) => {
|
|
2595
|
+
let t = h(e);
|
|
2596
|
+
if (!K.has(t)) {
|
|
2597
|
+
let e;
|
|
2598
|
+
try {
|
|
2599
|
+
e = await Q(`schemaName:${t}`, () => T({ schemaName: t }));
|
|
2600
|
+
} catch (e) {
|
|
2601
|
+
process.env.NODE_ENV === "development" && console.warn(`Failed to fetch schema for schema name ${t}:`, e);
|
|
2602
|
+
return;
|
|
2603
|
+
}
|
|
2604
|
+
return e && K.set(t, e), e;
|
|
2605
|
+
}
|
|
2606
|
+
return K.get(t);
|
|
2607
|
+
}, ot = async (t) => {
|
|
2608
|
+
let n = et(t), r = J.get(n);
|
|
2609
|
+
if (r) return r;
|
|
2610
|
+
let i = a.getQueryClient(), o = e.getEasClient();
|
|
2611
|
+
if (!i || !o) return;
|
|
2612
|
+
let s = await Q(`definition:${t}`, async () => {
|
|
2613
|
+
let e = await i.fetchQuery({
|
|
2614
|
+
queryKey: ["getSchemaByDefinition", t],
|
|
2615
|
+
queryFn: async () => o.request(b, { where: { schema: { equals: t } } })
|
|
2616
|
+
}), n = e?.schemas ?? e?.data?.schemas;
|
|
2617
|
+
return Array.isArray(n) && n.length > 0 ? n[0].id : void 0;
|
|
2618
|
+
});
|
|
2619
|
+
return s && J.set(n, s), s;
|
|
2532
2620
|
};
|
|
2533
2621
|
//#endregion
|
|
2534
|
-
export { e as BaseEasClient, e as EasClient, a as BaseQueryClient, c as DEFAULT_EAS_CHAIN_ID,
|
|
2622
|
+
export { e as BaseEasClient, e as EasClient, a as BaseQueryClient, c as DEFAULT_EAS_CHAIN_ID, De as DOMAIN_OWNERSHIP_CHALLENGE_TTL_MS, ke as DOMAIN_OWNERSHIP_DEFAULT_EXPIRATION_SECS, Te as DOMAIN_OWNERSHIP_METHOD, we as DOMAIN_OWNERSHIP_SCHEMA_DEF, A as DOMAIN_OWNERSHIP_SCHEMA_NAME, Ee as DOMAIN_OWNERSHIP_SCOPE_REGISTRABLE, Oe as DOMAIN_OWNERSHIP_SOFT_STALE_MS, j as DOMAIN_OWNERSHIP_TXT_LABEL, ne as EAS_CHAIN_DEPLOYMENTS, Ce as EAS_ENDPOINT, de as GET_ALL_PROPERTIES_FOR_ALL_VERSIONS, fe as GET_FILES_METADATA, pe as GET_IMAGE_SEEDS, me as GET_IMAGE_VERSIONS, C as GET_PROPERTIES, y as GET_SCHEMAS, b as GET_SCHEMA_BY_NAME, x as GET_SEEDS, le as GET_SEED_IDS, ue as GET_STORAGE_TRANSACTION_ID, S as GET_VERSIONS, r as OP_STACK_EAS_CONTRACT_ADDRESS, i as OP_STACK_SCHEMA_REGISTRY_ADDRESS, Ge as PUBLISHED_BY_SCHEMA_DEF, Ke as PUBLISHED_BY_SCHEMA_NAME, ze as PUBLISH_AUTHORIZATION_DEFAULT_EXPIRATION_SECS, Le as PUBLISH_AUTHORIZATION_SCHEMA_DEF, V as PUBLISH_AUTHORIZATION_SCHEMA_NAME, Re as PUBLISH_AUTHORIZATION_SCOPES, $e as SCHEMA_LOOKUP_MISS_TTL_MS, be as ZERO_ADDRESS, xe as ZERO_BYTES, Se as ZERO_BYTES32, Fe as assessDomainOwnership, He as assessPublishAuthorization, je as buildDomainOwnershipTxtValue, Q as cachedSchemaLookup, g as checksumAddress, $ as clearSchemaLookupMisses, te as configureEasReadChain, z as decodeDomainOwnershipData, Ve as decodePublishAuthorizationData, Ze as decodePublishedByData, Ae as domainOwnershipTxtName, u as expectEasReadChain, T as fetchEasSchemaUidBySchemaName, ge as getCanonicalItemPropertiesFromEas, Ie as getDomainOwnershipFromEas, f as getEasAttestationExplorerUrl, l as getEasChainDeployment, p as getEasEndpoint, s as getEasReadChainId, _e as getEasSchemaUidBySchemaName, ot as getEasSchemaUidForExactDefinition, at as getEasSchemaUidForSchemaDefinition, w as getItemPropertiesFromEas, he as getItemVersionsFromEas, We as getPublishAuthorizationFromEas, Qe as getPublishedByFromEas, it as getSchemaUidForModelFromCache, ye as getSeedUidsBySchemaName, E as getSeedsBySchemaName, ve as getSeedsFromSchemaUids, Ne as hashDomainOwnershipChallenge, F as hashDomainRegistryFingerprint, Ue as hashPublishAuthorizationMaterial, Je as hashPublishedByBatch, t as isEasReadChainConfigured, d as isEasReadChainSettled, D as isPlaceholderUid, O as isValidEasAttestationUid, k as normalizeBytes32Hex, Me as parseDomainOwnershipTxtValue, se as pickLatestPropertyAttestationsByRefAndSchema, ee as resetEasReadChain, tt as resetSchemaUidCaches, o as resolveEasChainDeployment, rt as setSchemaUidForModel, nt as setSchemaUidForSchemaDefinition, h as toSnakeCase, Ye as verifyPublishedByBatch, n as whenEasReadChainSettled, _ as withExcludeRevokedFilter };
|
|
2535
2623
|
|
|
2536
2624
|
//# sourceMappingURL=index.js.map
|