bitbadgesjs-sdk 0.3.50 → 0.3.52
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-indexer/BitBadgesApi.d.ts +5 -5
- package/dist/api-indexer/BitBadgesApi.d.ts.map +1 -1
- package/dist/api-indexer/BitBadgesApi.js +300 -287
- package/dist/api-indexer/BitBadgesApi.js.map +1 -1
- package/dist/api-indexer/BitBadgesUserInfo.d.ts +8 -8
- package/dist/api-indexer/BitBadgesUserInfo.d.ts.map +1 -1
- package/dist/api-indexer/BitBadgesUserInfo.js +15 -15
- package/dist/api-indexer/BitBadgesUserInfo.js.map +1 -1
- package/dist/api-indexer/docs/docs.d.ts +9 -8
- package/dist/api-indexer/docs/docs.d.ts.map +1 -1
- package/dist/api-indexer/docs/docs.js +11 -9
- package/dist/api-indexer/docs/docs.js.map +1 -1
- package/dist/api-indexer/docs/interfaces.d.ts +3 -3
- package/dist/api-indexer/docs/interfaces.d.ts.map +1 -1
- package/dist/api-indexer/docs/interfaces.js.map +1 -1
- package/dist/api-indexer/requests/requests.d.ts +32 -35
- package/dist/api-indexer/requests/requests.d.ts.map +1 -1
- package/dist/api-indexer/requests/requests.js +17 -20
- package/dist/api-indexer/requests/requests.js.map +1 -1
- package/dist/api-indexer/requests/routes.d.ts +2 -2
- package/dist/api-indexer/requests/routes.d.ts.map +1 -1
- package/dist/api-indexer/requests/routes.js +2 -2
- package/dist/api-indexer/requests/routes.js.map +1 -1
- package/dist/core/blockin.d.ts +8 -8
- package/dist/core/blockin.d.ts.map +1 -1
- package/dist/core/blockin.js +17 -17
- package/dist/core/blockin.js.map +1 -1
- package/dist/core/secrets.d.ts +10 -9
- package/dist/core/secrets.d.ts.map +1 -1
- package/dist/core/secrets.js +13 -11
- package/dist/core/secrets.js.map +1 -1
- package/dist/core/transfers.d.ts.map +1 -1
- package/dist/core/transfers.js +2 -2
- package/dist/core/transfers.js.map +1 -1
- package/dist/interfaces/badges/core.d.ts +6 -5
- package/dist/interfaces/badges/core.d.ts.map +1 -1
- package/dist/transactions/amino/registry.js +16 -16
- package/dist/transactions/amino/registry.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -2
|
@@ -1579,8 +1579,8 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
1579
1579
|
const validateRes = (input => {
|
|
1580
1580
|
const errors = [];
|
|
1581
1581
|
const __is = input => {
|
|
1582
|
-
const $io0 = input => "string" === typeof input.name && "string" === typeof input.description && "string" === typeof input.image && "string" === typeof input.message && "string" === typeof input.signature && (undefined === input.publicKey || "string" === typeof input.publicKey) && "boolean" === typeof input.allowReuseOfBitBadgesSignIn && (undefined === input.
|
|
1583
|
-
const $io1 = input => (undefined === input.entropies || Array.isArray(input.entropies) && input.entropies.every(elem => "string" === typeof elem)) && (undefined === input.updateHistory || Array.isArray(input.updateHistory) && input.updateHistory.every(elem => "object" === typeof elem && null !== elem && $io2(elem))) && ("plaintext" === input.messageFormat || "json" === input.messageFormat) && "string" === typeof input.createdBy && ("object" === typeof input.proofOfIssuance && null !== input.proofOfIssuance && $io3(input.proofOfIssuance)) && ("bbs" === input.scheme || "standard" === input.scheme) && (Array.isArray(input.
|
|
1582
|
+
const $io0 = input => "string" === typeof input.name && "string" === typeof input.description && "string" === typeof input.image && "string" === typeof input.message && "string" === typeof input.signature && (undefined === input.publicKey || "string" === typeof input.publicKey) && "boolean" === typeof input.allowReuseOfBitBadgesSignIn && (undefined === input.attestationsPresentations || Array.isArray(input.attestationsPresentations) && input.attestationsPresentations.every(elem => "object" === typeof elem && null !== elem && $io1(elem))) && "string" === typeof input.clientId && (undefined === input.otherSignIns || Array.isArray(input.otherSignIns) && input.otherSignIns.every(elem => "discord" === elem || "github" === elem || "google" === elem || "twitter" === elem)) && (undefined === input.redirectUri || "string" === typeof input.redirectUri) && (undefined === input.state || "string" === typeof input.state);
|
|
1583
|
+
const $io1 = input => (undefined === input.entropies || Array.isArray(input.entropies) && input.entropies.every(elem => "string" === typeof elem)) && (undefined === input.updateHistory || Array.isArray(input.updateHistory) && input.updateHistory.every(elem => "object" === typeof elem && null !== elem && $io2(elem))) && ("plaintext" === input.messageFormat || "json" === input.messageFormat) && "string" === typeof input.createdBy && ("object" === typeof input.proofOfIssuance && null !== input.proofOfIssuance && $io3(input.proofOfIssuance)) && ("bbs" === input.scheme || "standard" === input.scheme) && (Array.isArray(input.attestationMessages) && input.attestationMessages.every(elem => "string" === typeof elem)) && ("object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof && $io4(input.dataIntegrityProof)) && "string" === typeof input.name && "string" === typeof input.image && "string" === typeof input.description && (undefined === input.anchors || Array.isArray(input.anchors) && input.anchors.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $io5(elem)));
|
|
1584
1584
|
const $io2 = input => "string" === typeof input.txHash && ("string" === typeof input.block || "number" === typeof input.block || "bigint" === typeof input.block) && ("string" === typeof input.blockTimestamp || "number" === typeof input.blockTimestamp || "bigint" === typeof input.blockTimestamp) && ("string" === typeof input.timestamp || "number" === typeof input.timestamp || "bigint" === typeof input.timestamp);
|
|
1585
1585
|
const $io3 = input => "string" === typeof input.message && "string" === typeof input.signature && "string" === typeof input.signer && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
1586
1586
|
const $io4 = input => "string" === typeof input.signature && "string" === typeof input.signer && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
@@ -1618,22 +1618,22 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
1618
1618
|
path: _path + ".allowReuseOfBitBadgesSignIn",
|
|
1619
1619
|
expected: "boolean",
|
|
1620
1620
|
value: input.allowReuseOfBitBadgesSignIn
|
|
1621
|
-
}), undefined === input.
|
|
1622
|
-
path: _path + ".
|
|
1623
|
-
expected: "(Array<
|
|
1624
|
-
value: input.
|
|
1625
|
-
})) && input.
|
|
1626
|
-
path: _path + ".
|
|
1627
|
-
expected: "
|
|
1628
|
-
value: elem
|
|
1629
|
-
})) && $vo1(elem, _path + ".
|
|
1630
|
-
path: _path + ".
|
|
1631
|
-
expected: "
|
|
1621
|
+
}), undefined === input.attestationsPresentations || (Array.isArray(input.attestationsPresentations) || $report(_exceptionable, {
|
|
1622
|
+
path: _path + ".attestationsPresentations",
|
|
1623
|
+
expected: "(Array<iAttestationsProof<NumberType>> | undefined)",
|
|
1624
|
+
value: input.attestationsPresentations
|
|
1625
|
+
})) && input.attestationsPresentations.map((elem, _index1) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
1626
|
+
path: _path + ".attestationsPresentations[" + _index1 + "]",
|
|
1627
|
+
expected: "iAttestationsProof<NumberType>",
|
|
1628
|
+
value: elem
|
|
1629
|
+
})) && $vo1(elem, _path + ".attestationsPresentations[" + _index1 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
1630
|
+
path: _path + ".attestationsPresentations[" + _index1 + "]",
|
|
1631
|
+
expected: "iAttestationsProof<NumberType>",
|
|
1632
1632
|
value: elem
|
|
1633
1633
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
1634
|
-
path: _path + ".
|
|
1635
|
-
expected: "(Array<
|
|
1636
|
-
value: input.
|
|
1634
|
+
path: _path + ".attestationsPresentations",
|
|
1635
|
+
expected: "(Array<iAttestationsProof<NumberType>> | undefined)",
|
|
1636
|
+
value: input.attestationsPresentations
|
|
1637
1637
|
}), "string" === typeof input.clientId || $report(_exceptionable, {
|
|
1638
1638
|
path: _path + ".clientId",
|
|
1639
1639
|
expected: "string",
|
|
@@ -1707,18 +1707,18 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
1707
1707
|
path: _path + ".scheme",
|
|
1708
1708
|
expected: "(\"bbs\" | \"standard\")",
|
|
1709
1709
|
value: input.scheme
|
|
1710
|
-
}), (Array.isArray(input.
|
|
1711
|
-
path: _path + ".
|
|
1710
|
+
}), (Array.isArray(input.attestationMessages) || $report(_exceptionable, {
|
|
1711
|
+
path: _path + ".attestationMessages",
|
|
1712
1712
|
expected: "Array<string>",
|
|
1713
|
-
value: input.
|
|
1714
|
-
})) && input.
|
|
1715
|
-
path: _path + ".
|
|
1713
|
+
value: input.attestationMessages
|
|
1714
|
+
})) && input.attestationMessages.map((elem, _index5) => "string" === typeof elem || $report(_exceptionable, {
|
|
1715
|
+
path: _path + ".attestationMessages[" + _index5 + "]",
|
|
1716
1716
|
expected: "string",
|
|
1717
1717
|
value: elem
|
|
1718
1718
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
1719
|
-
path: _path + ".
|
|
1719
|
+
path: _path + ".attestationMessages",
|
|
1720
1720
|
expected: "Array<string>",
|
|
1721
|
-
value: input.
|
|
1721
|
+
value: input.attestationMessages
|
|
1722
1722
|
}), ("object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof || $report(_exceptionable, {
|
|
1723
1723
|
path: _path + ".dataIntegrityProof",
|
|
1724
1724
|
expected: "__type.o1",
|
|
@@ -1890,7 +1890,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
1890
1890
|
const validateRes = (input => {
|
|
1891
1891
|
const errors = [];
|
|
1892
1892
|
const __is = input => {
|
|
1893
|
-
const $io0 = input => (undefined === input.options || "object" === typeof input.options && null !== input.options && false === Array.isArray(input.options) && $io1(input.options)) && (undefined === input.
|
|
1893
|
+
const $io0 = input => (undefined === input.options || "object" === typeof input.options && null !== input.options && false === Array.isArray(input.options) && $io1(input.options)) && (undefined === input.attestationsPresentations || Array.isArray(input.attestationsPresentations) && input.attestationsPresentations.every(elem => "object" === typeof elem && null !== elem && $io10(elem))) && "string" === typeof input.message && "string" === typeof input.signature && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
1894
1894
|
const $io1 = input => (undefined === input.expectedChallengeParams || "object" === typeof input.expectedChallengeParams && null !== input.expectedChallengeParams && false === Array.isArray(input.expectedChallengeParams) && $io2(input.expectedChallengeParams)) && (undefined === input.beforeVerification || true) && (undefined === input.balancesSnapshot || "object" === typeof input.balancesSnapshot && null !== input.balancesSnapshot && false === Array.isArray(input.balancesSnapshot) && $io9(input.balancesSnapshot)) && (undefined === input.skipTimestampVerification || "boolean" === typeof input.skipTimestampVerification) && (undefined === input.skipAssetVerification || "boolean" === typeof input.skipAssetVerification) && (undefined === input.earliestIssuedAt || "string" === typeof input.earliestIssuedAt) && (undefined === input.issuedAtTimeWindowMs || "number" === typeof input.issuedAtTimeWindowMs) && (undefined === input.skipSignatureVerification || "boolean" === typeof input.skipSignatureVerification);
|
|
1895
1895
|
const $io2 = input => (undefined === input.domain || "string" === typeof input.domain) && (undefined === input.statement || "string" === typeof input.statement) && (undefined === input.address || "string" === typeof input.address) && (undefined === input.uri || "string" === typeof input.uri) && (undefined === input.nonce || "string" === typeof input.nonce) && (undefined === input.version || "string" === typeof input.version) && (undefined === input.chainId || "string" === typeof input.chainId) && (undefined === input.issuedAt || "string" === typeof input.issuedAt) && (undefined === input.expirationDate || "string" === typeof input.expirationDate) && (undefined === input.notBefore || "string" === typeof input.notBefore) && (undefined === input.resources || Array.isArray(input.resources) && input.resources.every(elem => "string" === typeof elem)) && (undefined === input.assetOwnershipRequirements || "object" === typeof input.assetOwnershipRequirements && null !== input.assetOwnershipRequirements && $iu0(input.assetOwnershipRequirements));
|
|
1896
1896
|
const $io3 = input => Array.isArray(input.$and) && input.$and.every(elem => "object" === typeof elem && null !== elem && $iu0(elem));
|
|
@@ -1900,7 +1900,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
1900
1900
|
const $io7 = input => ("string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start) && ("string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end);
|
|
1901
1901
|
const $io8 = input => undefined === input.numMatchesForVerification || "string" === typeof input.numMatchesForVerification || "number" === typeof input.numMatchesForVerification || "bigint" === typeof input.numMatchesForVerification;
|
|
1902
1902
|
const $io9 = input => true;
|
|
1903
|
-
const $io10 = input => "string" === typeof input.createdBy && ("bbs" === input.scheme || "standard" === input.scheme) && ("plaintext" === input.messageFormat || "json" === input.messageFormat) && (Array.isArray(input.
|
|
1903
|
+
const $io10 = input => "string" === typeof input.createdBy && ("bbs" === input.scheme || "standard" === input.scheme) && ("plaintext" === input.messageFormat || "json" === input.messageFormat) && (Array.isArray(input.attestationMessages) && input.attestationMessages.every(elem => "string" === typeof elem)) && ("object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof && $io11(input.dataIntegrityProof)) && ("object" === typeof input.proofOfIssuance && null !== input.proofOfIssuance && $io12(input.proofOfIssuance)) && "string" === typeof input.name && "string" === typeof input.image && "string" === typeof input.description && (undefined === input.entropies || Array.isArray(input.entropies) && input.entropies.every(elem => "string" === typeof elem)) && (undefined === input.updateHistory || Array.isArray(input.updateHistory) && input.updateHistory.every(elem => "object" === typeof elem && null !== elem && $io13(elem))) && (undefined === input.anchors || Array.isArray(input.anchors) && input.anchors.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $io14(elem)));
|
|
1904
1904
|
const $io11 = input => "string" === typeof input.signature && "string" === typeof input.signer && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
1905
1905
|
const $io12 = input => "string" === typeof input.message && "string" === typeof input.signer && "string" === typeof input.signature && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
1906
1906
|
const $io13 = input => "string" === typeof input.txHash && ("string" === typeof input.block || "number" === typeof input.block || "bigint" === typeof input.block) && ("string" === typeof input.blockTimestamp || "number" === typeof input.blockTimestamp || "bigint" === typeof input.blockTimestamp) && ("string" === typeof input.timestamp || "number" === typeof input.timestamp || "bigint" === typeof input.timestamp);
|
|
@@ -1928,22 +1928,22 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
1928
1928
|
path: _path + ".options",
|
|
1929
1929
|
expected: "(VerifyChallengeOptions | undefined)",
|
|
1930
1930
|
value: input.options
|
|
1931
|
-
}), undefined === input.
|
|
1932
|
-
path: _path + ".
|
|
1933
|
-
expected: "(Array<
|
|
1934
|
-
value: input.
|
|
1935
|
-
})) && input.
|
|
1936
|
-
path: _path + ".
|
|
1937
|
-
expected: "
|
|
1938
|
-
value: elem
|
|
1939
|
-
})) && $vo10(elem, _path + ".
|
|
1940
|
-
path: _path + ".
|
|
1941
|
-
expected: "
|
|
1931
|
+
}), undefined === input.attestationsPresentations || (Array.isArray(input.attestationsPresentations) || $report(_exceptionable, {
|
|
1932
|
+
path: _path + ".attestationsPresentations",
|
|
1933
|
+
expected: "(Array<AttestationsProof<NumberType>> | undefined)",
|
|
1934
|
+
value: input.attestationsPresentations
|
|
1935
|
+
})) && input.attestationsPresentations.map((elem, _index1) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
1936
|
+
path: _path + ".attestationsPresentations[" + _index1 + "]",
|
|
1937
|
+
expected: "AttestationsProof<NumberType>",
|
|
1938
|
+
value: elem
|
|
1939
|
+
})) && $vo10(elem, _path + ".attestationsPresentations[" + _index1 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
1940
|
+
path: _path + ".attestationsPresentations[" + _index1 + "]",
|
|
1941
|
+
expected: "AttestationsProof<NumberType>",
|
|
1942
1942
|
value: elem
|
|
1943
1943
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
1944
|
-
path: _path + ".
|
|
1945
|
-
expected: "(Array<
|
|
1946
|
-
value: input.
|
|
1944
|
+
path: _path + ".attestationsPresentations",
|
|
1945
|
+
expected: "(Array<AttestationsProof<NumberType>> | undefined)",
|
|
1946
|
+
value: input.attestationsPresentations
|
|
1947
1947
|
}), "string" === typeof input.message || $report(_exceptionable, {
|
|
1948
1948
|
path: _path + ".message",
|
|
1949
1949
|
expected: "string",
|
|
@@ -2206,18 +2206,18 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
2206
2206
|
path: _path + ".messageFormat",
|
|
2207
2207
|
expected: "(\"json\" | \"plaintext\")",
|
|
2208
2208
|
value: input.messageFormat
|
|
2209
|
-
}), (Array.isArray(input.
|
|
2210
|
-
path: _path + ".
|
|
2209
|
+
}), (Array.isArray(input.attestationMessages) || $report(_exceptionable, {
|
|
2210
|
+
path: _path + ".attestationMessages",
|
|
2211
2211
|
expected: "Array<string>",
|
|
2212
|
-
value: input.
|
|
2213
|
-
})) && input.
|
|
2214
|
-
path: _path + ".
|
|
2212
|
+
value: input.attestationMessages
|
|
2213
|
+
})) && input.attestationMessages.map((elem, _index8) => "string" === typeof elem || $report(_exceptionable, {
|
|
2214
|
+
path: _path + ".attestationMessages[" + _index8 + "]",
|
|
2215
2215
|
expected: "string",
|
|
2216
2216
|
value: elem
|
|
2217
2217
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
2218
|
-
path: _path + ".
|
|
2218
|
+
path: _path + ".attestationMessages",
|
|
2219
2219
|
expected: "Array<string>",
|
|
2220
|
-
value: input.
|
|
2220
|
+
value: input.attestationMessages
|
|
2221
2221
|
}), ("object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof || $report(_exceptionable, {
|
|
2222
2222
|
path: _path + ".dataIntegrityProof",
|
|
2223
2223
|
expected: "__type.o1",
|
|
@@ -2894,28 +2894,33 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
2894
2894
|
return Promise.reject(error);
|
|
2895
2895
|
}
|
|
2896
2896
|
}
|
|
2897
|
-
async
|
|
2897
|
+
async getAttestation(payload) {
|
|
2898
2898
|
try {
|
|
2899
2899
|
const validateRes = (input => {
|
|
2900
2900
|
const errors = [];
|
|
2901
2901
|
const __is = input => {
|
|
2902
|
-
|
|
2902
|
+
const $io0 = input => (undefined === input.addKey || "string" === typeof input.addKey) && (undefined === input.attestationId || "string" === typeof input.attestationId);
|
|
2903
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
2903
2904
|
};
|
|
2904
2905
|
if (false === __is(input)) {
|
|
2905
2906
|
const $report = typia_1.default.validate.report(errors);
|
|
2906
2907
|
((input, _path, _exceptionable = true) => {
|
|
2907
|
-
const $vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.
|
|
2908
|
-
path: _path + ".
|
|
2909
|
-
expected: "string",
|
|
2910
|
-
value: input.
|
|
2908
|
+
const $vo0 = (input, _path, _exceptionable = true) => [undefined === input.addKey || "string" === typeof input.addKey || $report(_exceptionable, {
|
|
2909
|
+
path: _path + ".addKey",
|
|
2910
|
+
expected: "(string | undefined)",
|
|
2911
|
+
value: input.addKey
|
|
2912
|
+
}), undefined === input.attestationId || "string" === typeof input.attestationId || $report(_exceptionable, {
|
|
2913
|
+
path: _path + ".attestationId",
|
|
2914
|
+
expected: "(string | undefined)",
|
|
2915
|
+
value: input.attestationId
|
|
2911
2916
|
})].every(flag => flag);
|
|
2912
|
-
return ("object" === typeof input && null !== input || $report(true, {
|
|
2917
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $report(true, {
|
|
2913
2918
|
path: _path + "",
|
|
2914
|
-
expected: "
|
|
2919
|
+
expected: "GetAttestationPayload",
|
|
2915
2920
|
value: input
|
|
2916
2921
|
})) && $vo0(input, _path + "", true) || $report(true, {
|
|
2917
2922
|
path: _path + "",
|
|
2918
|
-
expected: "
|
|
2923
|
+
expected: "GetAttestationPayload",
|
|
2919
2924
|
value: input
|
|
2920
2925
|
});
|
|
2921
2926
|
})(input, "$input", true);
|
|
@@ -2930,20 +2935,20 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
2930
2935
|
if (!validateRes.success) {
|
|
2931
2936
|
throw new Error('Invalid payload: ' + JSON.stringify(validateRes.errors));
|
|
2932
2937
|
}
|
|
2933
|
-
const response = await this.axios.post(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.
|
|
2934
|
-
return new requests_1.
|
|
2938
|
+
const response = await this.axios.post(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.GetAttestationsRoute()}`, payload);
|
|
2939
|
+
return new requests_1.GetAttestationSuccessResponse(response.data).convert(this.ConvertFunction);
|
|
2935
2940
|
}
|
|
2936
2941
|
catch (error) {
|
|
2937
2942
|
await this.handleApiError(error);
|
|
2938
2943
|
return Promise.reject(error);
|
|
2939
2944
|
}
|
|
2940
2945
|
}
|
|
2941
|
-
async
|
|
2946
|
+
async createAttestation(payload) {
|
|
2942
2947
|
try {
|
|
2943
2948
|
const validateRes = (input => {
|
|
2944
2949
|
const errors = [];
|
|
2945
2950
|
const __is = input => {
|
|
2946
|
-
const $io0 = input => "object" === typeof input.proofOfIssuance && null !== input.proofOfIssuance && $io1(input.proofOfIssuance) && ("plaintext" === input.messageFormat || "json" === input.messageFormat) && ("bbs" === input.scheme || "standard" === input.scheme) && "string" === typeof input.type && (Array.isArray(input.
|
|
2951
|
+
const $io0 = input => "object" === typeof input.proofOfIssuance && null !== input.proofOfIssuance && $io1(input.proofOfIssuance) && ("plaintext" === input.messageFormat || "json" === input.messageFormat) && ("bbs" === input.scheme || "standard" === input.scheme) && "string" === typeof input.type && (Array.isArray(input.attestationMessages) && input.attestationMessages.every(elem => "string" === typeof elem)) && ("object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof && $io2(input.dataIntegrityProof)) && "string" === typeof input.name && "string" === typeof input.image && "string" === typeof input.description;
|
|
2947
2952
|
const $io1 = input => "string" === typeof input.message && "string" === typeof input.signature && "string" === typeof input.signer && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
2948
2953
|
const $io2 = input => "string" === typeof input.signature && "string" === typeof input.signer && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
2949
2954
|
return "object" === typeof input && null !== input && $io0(input);
|
|
@@ -2971,18 +2976,18 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
2971
2976
|
path: _path + ".type",
|
|
2972
2977
|
expected: "string",
|
|
2973
2978
|
value: input.type
|
|
2974
|
-
}), (Array.isArray(input.
|
|
2975
|
-
path: _path + ".
|
|
2979
|
+
}), (Array.isArray(input.attestationMessages) || $report(_exceptionable, {
|
|
2980
|
+
path: _path + ".attestationMessages",
|
|
2976
2981
|
expected: "Array<string>",
|
|
2977
|
-
value: input.
|
|
2978
|
-
})) && input.
|
|
2979
|
-
path: _path + ".
|
|
2982
|
+
value: input.attestationMessages
|
|
2983
|
+
})) && input.attestationMessages.map((elem, _index1) => "string" === typeof elem || $report(_exceptionable, {
|
|
2984
|
+
path: _path + ".attestationMessages[" + _index1 + "]",
|
|
2980
2985
|
expected: "string",
|
|
2981
2986
|
value: elem
|
|
2982
2987
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
2983
|
-
path: _path + ".
|
|
2988
|
+
path: _path + ".attestationMessages",
|
|
2984
2989
|
expected: "Array<string>",
|
|
2985
|
-
value: input.
|
|
2990
|
+
value: input.attestationMessages
|
|
2986
2991
|
}), ("object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof || $report(_exceptionable, {
|
|
2987
2992
|
path: _path + ".dataIntegrityProof",
|
|
2988
2993
|
expected: "__type.o1",
|
|
@@ -3036,11 +3041,11 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3036
3041
|
})].every(flag => flag);
|
|
3037
3042
|
return ("object" === typeof input && null !== input || $report(true, {
|
|
3038
3043
|
path: _path + "",
|
|
3039
|
-
expected: "
|
|
3044
|
+
expected: "CreateAttestationPayload",
|
|
3040
3045
|
value: input
|
|
3041
3046
|
})) && $vo0(input, _path + "", true) || $report(true, {
|
|
3042
3047
|
path: _path + "",
|
|
3043
|
-
expected: "
|
|
3048
|
+
expected: "CreateAttestationPayload",
|
|
3044
3049
|
value: input
|
|
3045
3050
|
});
|
|
3046
3051
|
})(input, "$input", true);
|
|
@@ -3055,36 +3060,36 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3055
3060
|
if (!validateRes.success) {
|
|
3056
3061
|
throw new Error('Invalid payload: ' + JSON.stringify(validateRes.errors));
|
|
3057
3062
|
}
|
|
3058
|
-
const response = await this.axios.post(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.
|
|
3059
|
-
return new requests_1.
|
|
3063
|
+
const response = await this.axios.post(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.CRUDAttestationRoute()}`, payload);
|
|
3064
|
+
return new requests_1.CreateAttestationSuccessResponse(response.data);
|
|
3060
3065
|
}
|
|
3061
3066
|
catch (error) {
|
|
3062
3067
|
await this.handleApiError(error);
|
|
3063
3068
|
return Promise.reject(error);
|
|
3064
3069
|
}
|
|
3065
3070
|
}
|
|
3066
|
-
async
|
|
3071
|
+
async deleteAttestation(payload) {
|
|
3067
3072
|
try {
|
|
3068
3073
|
const validateRes = (input => {
|
|
3069
3074
|
const errors = [];
|
|
3070
3075
|
const __is = input => {
|
|
3071
|
-
return "object" === typeof input && null !== input && "string" === typeof input.
|
|
3076
|
+
return "object" === typeof input && null !== input && "string" === typeof input.attestationId;
|
|
3072
3077
|
};
|
|
3073
3078
|
if (false === __is(input)) {
|
|
3074
3079
|
const $report = typia_1.default.validate.report(errors);
|
|
3075
3080
|
((input, _path, _exceptionable = true) => {
|
|
3076
|
-
const $vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.
|
|
3077
|
-
path: _path + ".
|
|
3081
|
+
const $vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.attestationId || $report(_exceptionable, {
|
|
3082
|
+
path: _path + ".attestationId",
|
|
3078
3083
|
expected: "string",
|
|
3079
|
-
value: input.
|
|
3084
|
+
value: input.attestationId
|
|
3080
3085
|
})].every(flag => flag);
|
|
3081
3086
|
return ("object" === typeof input && null !== input || $report(true, {
|
|
3082
3087
|
path: _path + "",
|
|
3083
|
-
expected: "
|
|
3088
|
+
expected: "DeleteAttestationPayload",
|
|
3084
3089
|
value: input
|
|
3085
3090
|
})) && $vo0(input, _path + "", true) || $report(true, {
|
|
3086
3091
|
path: _path + "",
|
|
3087
|
-
expected: "
|
|
3092
|
+
expected: "DeleteAttestationPayload",
|
|
3088
3093
|
value: input
|
|
3089
3094
|
});
|
|
3090
3095
|
})(input, "$input", true);
|
|
@@ -3099,35 +3104,43 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3099
3104
|
if (!validateRes.success) {
|
|
3100
3105
|
throw new Error('Invalid payload: ' + JSON.stringify(validateRes.errors));
|
|
3101
3106
|
}
|
|
3102
|
-
const response = await this.axios.delete(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.
|
|
3107
|
+
const response = await this.axios.delete(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.CRUDAttestationRoute()}`, {
|
|
3103
3108
|
data: payload
|
|
3104
3109
|
});
|
|
3105
|
-
return new requests_1.
|
|
3110
|
+
return new requests_1.DeleteAttestationSuccessResponse(response.data);
|
|
3106
3111
|
}
|
|
3107
3112
|
catch (error) {
|
|
3108
3113
|
await this.handleApiError(error);
|
|
3109
3114
|
return Promise.reject(error);
|
|
3110
3115
|
}
|
|
3111
3116
|
}
|
|
3112
|
-
async
|
|
3117
|
+
async updateAttestation(payload) {
|
|
3113
3118
|
try {
|
|
3114
3119
|
const validateRes = (input => {
|
|
3115
3120
|
const errors = [];
|
|
3116
3121
|
const __is = input => {
|
|
3117
|
-
const $io0 = input => "string" === typeof input.
|
|
3122
|
+
const $io0 = input => (undefined === input.attestationId || "string" === typeof input.attestationId) && (undefined === input.addKey || "string" === typeof input.addKey) && (undefined === input.rotateAddKey || "boolean" === typeof input.rotateAddKey) && (undefined === input.holdersToSet || Array.isArray(input.holdersToSet) && input.holdersToSet.every(elem => "object" === typeof elem && null !== elem && $io1(elem))) && (undefined === input.anchorsToAdd || Array.isArray(input.anchorsToAdd) && input.anchorsToAdd.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $io2(elem))) && (undefined === input.proofOfIssuance || "object" === typeof input.proofOfIssuance && null !== input.proofOfIssuance && $io3(input.proofOfIssuance)) && (undefined === input.messageFormat || "plaintext" === input.messageFormat || "json" === input.messageFormat) && (undefined === input.scheme || "bbs" === input.scheme || "standard" === input.scheme) && (undefined === input.type || "string" === typeof input.type) && (undefined === input.attestationMessages || Array.isArray(input.attestationMessages) && input.attestationMessages.every(elem => "string" === typeof elem)) && (undefined === input.dataIntegrityProof || "object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof && $io4(input.dataIntegrityProof)) && (undefined === input.name || "string" === typeof input.name) && (undefined === input.image || "string" === typeof input.image) && (undefined === input.description || "string" === typeof input.description);
|
|
3118
3123
|
const $io1 = input => "string" === typeof input.cosmosAddress && (undefined === input["delete"] || "boolean" === typeof input["delete"]);
|
|
3119
3124
|
const $io2 = input => (undefined === input.txHash || "string" === typeof input.txHash) && (undefined === input.message || "string" === typeof input.message);
|
|
3120
3125
|
const $io3 = input => "string" === typeof input.message && "string" === typeof input.signer && "string" === typeof input.signature && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
3121
3126
|
const $io4 = input => "string" === typeof input.signature && "string" === typeof input.signer && (undefined === input.publicKey || "string" === typeof input.publicKey);
|
|
3122
|
-
return "object" === typeof input && null !== input && $io0(input);
|
|
3127
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
3123
3128
|
};
|
|
3124
3129
|
if (false === __is(input)) {
|
|
3125
3130
|
const $report = typia_1.default.validate.report(errors);
|
|
3126
3131
|
((input, _path, _exceptionable = true) => {
|
|
3127
|
-
const $vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.
|
|
3128
|
-
path: _path + ".
|
|
3129
|
-
expected: "string",
|
|
3130
|
-
value: input.
|
|
3132
|
+
const $vo0 = (input, _path, _exceptionable = true) => [undefined === input.attestationId || "string" === typeof input.attestationId || $report(_exceptionable, {
|
|
3133
|
+
path: _path + ".attestationId",
|
|
3134
|
+
expected: "(string | undefined)",
|
|
3135
|
+
value: input.attestationId
|
|
3136
|
+
}), undefined === input.addKey || "string" === typeof input.addKey || $report(_exceptionable, {
|
|
3137
|
+
path: _path + ".addKey",
|
|
3138
|
+
expected: "(string | undefined)",
|
|
3139
|
+
value: input.addKey
|
|
3140
|
+
}), undefined === input.rotateAddKey || "boolean" === typeof input.rotateAddKey || $report(_exceptionable, {
|
|
3141
|
+
path: _path + ".rotateAddKey",
|
|
3142
|
+
expected: "(boolean | undefined)",
|
|
3143
|
+
value: input.rotateAddKey
|
|
3131
3144
|
}), undefined === input.holdersToSet || (Array.isArray(input.holdersToSet) || $report(_exceptionable, {
|
|
3132
3145
|
path: _path + ".holdersToSet",
|
|
3133
3146
|
expected: "(Array<__type> | undefined)",
|
|
@@ -3180,18 +3193,18 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3180
3193
|
path: _path + ".type",
|
|
3181
3194
|
expected: "(string | undefined)",
|
|
3182
3195
|
value: input.type
|
|
3183
|
-
}), undefined === input.
|
|
3184
|
-
path: _path + ".
|
|
3196
|
+
}), undefined === input.attestationMessages || (Array.isArray(input.attestationMessages) || $report(_exceptionable, {
|
|
3197
|
+
path: _path + ".attestationMessages",
|
|
3185
3198
|
expected: "(Array<string> | undefined)",
|
|
3186
|
-
value: input.
|
|
3187
|
-
})) && input.
|
|
3188
|
-
path: _path + ".
|
|
3199
|
+
value: input.attestationMessages
|
|
3200
|
+
})) && input.attestationMessages.map((elem, _index3) => "string" === typeof elem || $report(_exceptionable, {
|
|
3201
|
+
path: _path + ".attestationMessages[" + _index3 + "]",
|
|
3189
3202
|
expected: "string",
|
|
3190
3203
|
value: elem
|
|
3191
3204
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
3192
|
-
path: _path + ".
|
|
3205
|
+
path: _path + ".attestationMessages",
|
|
3193
3206
|
expected: "(Array<string> | undefined)",
|
|
3194
|
-
value: input.
|
|
3207
|
+
value: input.attestationMessages
|
|
3195
3208
|
}), undefined === input.dataIntegrityProof || ("object" === typeof input.dataIntegrityProof && null !== input.dataIntegrityProof || $report(_exceptionable, {
|
|
3196
3209
|
path: _path + ".dataIntegrityProof",
|
|
3197
3210
|
expected: "(__type.o3 | undefined)",
|
|
@@ -3261,13 +3274,13 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3261
3274
|
expected: "(string | undefined)",
|
|
3262
3275
|
value: input.publicKey
|
|
3263
3276
|
})].every(flag => flag);
|
|
3264
|
-
return ("object" === typeof input && null !== input || $report(true, {
|
|
3277
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $report(true, {
|
|
3265
3278
|
path: _path + "",
|
|
3266
|
-
expected: "
|
|
3279
|
+
expected: "UpdateAttestationPayload",
|
|
3267
3280
|
value: input
|
|
3268
3281
|
})) && $vo0(input, _path + "", true) || $report(true, {
|
|
3269
3282
|
path: _path + "",
|
|
3270
|
-
expected: "
|
|
3283
|
+
expected: "UpdateAttestationPayload",
|
|
3271
3284
|
value: input
|
|
3272
3285
|
});
|
|
3273
3286
|
})(input, "$input", true);
|
|
@@ -3282,8 +3295,8 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3282
3295
|
if (!validateRes.success) {
|
|
3283
3296
|
throw new Error('Invalid payload: ' + JSON.stringify(validateRes.errors));
|
|
3284
3297
|
}
|
|
3285
|
-
const response = await this.axios.put(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.
|
|
3286
|
-
return new requests_1.
|
|
3298
|
+
const response = await this.axios.put(`${this.BACKEND_URL}${routes_1.BitBadgesApiRoutes.CRUDAttestationRoute()}`, payload);
|
|
3299
|
+
return new requests_1.UpdateAttestationSuccessResponse(response.data);
|
|
3287
3300
|
}
|
|
3288
3301
|
catch (error) {
|
|
3289
3302
|
await this.handleApiError(error);
|
|
@@ -3296,7 +3309,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3296
3309
|
const errors = [];
|
|
3297
3310
|
const __is = input => {
|
|
3298
3311
|
const $io0 = input => Array.isArray(input.claims) && input.claims.every(elem => "object" === typeof elem && null !== elem && $io1(elem));
|
|
3299
|
-
const $io1 = input => "string" === typeof input.claimId && (undefined === input.balancesToSet || "object" === typeof input.balancesToSet && null !== input.balancesToSet && $io2(input.balancesToSet)) && (undefined === input.manualDistribution || "boolean" === typeof input.manualDistribution) && (undefined === input.approach || "string" === typeof input.approach) && (undefined === input.
|
|
3312
|
+
const $io1 = input => (undefined === input.seedCode || "string" === typeof input.seedCode) && "string" === typeof input.claimId && (undefined === input.balancesToSet || "object" === typeof input.balancesToSet && null !== input.balancesToSet && $io2(input.balancesToSet)) && (undefined === input.manualDistribution || "boolean" === typeof input.manualDistribution) && (undefined === input.approach || "string" === typeof input.approach) && (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $io8(input.metadata)) && (undefined === input.assignMethod || "string" === typeof input.assignMethod) && (undefined === input.listId || "string" === typeof input.listId) && (undefined === input.collectionId || "string" === typeof input.collectionId || "number" === typeof input.collectionId || "bigint" === typeof input.collectionId) && (undefined === input.cid || "string" === typeof input.cid) && (Array.isArray(input.plugins) && input.plugins.every(elem => "object" === typeof elem && null !== elem && $io12(elem)));
|
|
3300
3313
|
const $io2 = input => Array.isArray(input.manualBalances) && input.manualBalances.every(elem => "object" === typeof elem && null !== elem && $io3(elem)) && ("object" === typeof input.incrementedBalances && null !== input.incrementedBalances && $io6(input.incrementedBalances)) && ("object" === typeof input.orderCalculationMethod && null !== input.orderCalculationMethod && ("boolean" === typeof input.orderCalculationMethod.useOverallNumTransfers && "boolean" === typeof input.orderCalculationMethod.usePerToAddressNumTransfers && "boolean" === typeof input.orderCalculationMethod.usePerFromAddressNumTransfers && "boolean" === typeof input.orderCalculationMethod.usePerInitiatedByAddressNumTransfers && "boolean" === typeof input.orderCalculationMethod.useMerkleChallengeLeafIndex && "string" === typeof input.orderCalculationMethod.challengeTrackerId));
|
|
3301
3314
|
const $io3 = input => Array.isArray(input.balances) && input.balances.every(elem => "object" === typeof elem && null !== elem && $io4(elem));
|
|
3302
3315
|
const $io4 = input => ("string" === typeof input.amount || "number" === typeof input.amount || "bigint" === typeof input.amount) && (Array.isArray(input.badgeIds) && input.badgeIds.every(elem => "object" === typeof elem && null !== elem && $io5(elem))) && (Array.isArray(input.ownershipTimes) && input.ownershipTimes.every(elem => "object" === typeof elem && null !== elem && $io5(elem)));
|
|
@@ -3336,7 +3349,11 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3336
3349
|
expected: "Array<CreateClaimRequest<NumberType>>",
|
|
3337
3350
|
value: input.claims
|
|
3338
3351
|
})].every(flag => flag);
|
|
3339
|
-
const $vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.
|
|
3352
|
+
const $vo1 = (input, _path, _exceptionable = true) => [undefined === input.seedCode || "string" === typeof input.seedCode || $report(_exceptionable, {
|
|
3353
|
+
path: _path + ".seedCode",
|
|
3354
|
+
expected: "(string | undefined)",
|
|
3355
|
+
value: input.seedCode
|
|
3356
|
+
}), "string" === typeof input.claimId || $report(_exceptionable, {
|
|
3340
3357
|
path: _path + ".claimId",
|
|
3341
3358
|
expected: "string",
|
|
3342
3359
|
value: input.claimId
|
|
@@ -3356,10 +3373,6 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3356
3373
|
path: _path + ".approach",
|
|
3357
3374
|
expected: "(string | undefined)",
|
|
3358
3375
|
value: input.approach
|
|
3359
|
-
}), undefined === input.seedCode || "string" === typeof input.seedCode || $report(_exceptionable, {
|
|
3360
|
-
path: _path + ".seedCode",
|
|
3361
|
-
expected: "(string | undefined)",
|
|
3362
|
-
value: input.seedCode
|
|
3363
3376
|
}), undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
3364
3377
|
path: _path + ".metadata",
|
|
3365
3378
|
expected: "(iMetadata<NumberType> | undefined)",
|
|
@@ -3792,14 +3805,14 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3792
3805
|
const errors = [];
|
|
3793
3806
|
const __is = input => {
|
|
3794
3807
|
const $io0 = input => Array.isArray(input.claims) && input.claims.every(elem => "object" === typeof elem && null !== elem && $io1(elem));
|
|
3795
|
-
const $io1 = input =>
|
|
3796
|
-
const $io2 = input =>
|
|
3797
|
-
const $io3 = input =>
|
|
3798
|
-
const $io4 = input =>
|
|
3799
|
-
const $io5 = input =>
|
|
3800
|
-
const $io6 = input =>
|
|
3801
|
-
const $
|
|
3802
|
-
const $
|
|
3808
|
+
const $io1 = input => "string" === typeof input.claimId && (undefined === input.balancesToSet || "object" === typeof input.balancesToSet && null !== input.balancesToSet && $io2(input.balancesToSet)) && (Array.isArray(input.plugins) && input.plugins.every(elem => "object" === typeof elem && null !== elem && $io8(elem))) && (undefined === input.manualDistribution || "boolean" === typeof input.manualDistribution) && (undefined === input.approach || "string" === typeof input.approach) && (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $io10(input.metadata)) && (undefined === input.assignMethod || "string" === typeof input.assignMethod);
|
|
3809
|
+
const $io2 = input => Array.isArray(input.manualBalances) && input.manualBalances.every(elem => "object" === typeof elem && null !== elem && $io3(elem)) && ("object" === typeof input.incrementedBalances && null !== input.incrementedBalances && $io6(input.incrementedBalances)) && ("object" === typeof input.orderCalculationMethod && null !== input.orderCalculationMethod && ("boolean" === typeof input.orderCalculationMethod.useOverallNumTransfers && "boolean" === typeof input.orderCalculationMethod.usePerToAddressNumTransfers && "boolean" === typeof input.orderCalculationMethod.usePerFromAddressNumTransfers && "boolean" === typeof input.orderCalculationMethod.usePerInitiatedByAddressNumTransfers && "boolean" === typeof input.orderCalculationMethod.useMerkleChallengeLeafIndex && "string" === typeof input.orderCalculationMethod.challengeTrackerId));
|
|
3810
|
+
const $io3 = input => Array.isArray(input.balances) && input.balances.every(elem => "object" === typeof elem && null !== elem && $io4(elem));
|
|
3811
|
+
const $io4 = input => ("string" === typeof input.amount || "number" === typeof input.amount || "bigint" === typeof input.amount) && (Array.isArray(input.badgeIds) && input.badgeIds.every(elem => "object" === typeof elem && null !== elem && $io5(elem))) && (Array.isArray(input.ownershipTimes) && input.ownershipTimes.every(elem => "object" === typeof elem && null !== elem && $io5(elem)));
|
|
3812
|
+
const $io5 = input => ("string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start) && ("string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end);
|
|
3813
|
+
const $io6 = input => Array.isArray(input.startBalances) && input.startBalances.every(elem => "object" === typeof elem && null !== elem && $io4(elem)) && ("string" === typeof input.incrementBadgeIdsBy || "number" === typeof input.incrementBadgeIdsBy || "bigint" === typeof input.incrementBadgeIdsBy) && ("string" === typeof input.incrementOwnershipTimesBy || "number" === typeof input.incrementOwnershipTimesBy || "bigint" === typeof input.incrementOwnershipTimesBy);
|
|
3814
|
+
const $io8 = input => "object" === typeof input.publicState && null !== input.publicState && true && (undefined === input.privateState || "object" === typeof input.privateState && null !== input.privateState && false === Array.isArray(input.privateState) && $io9(input.privateState)) && (undefined === input.resetState || "boolean" === typeof input.resetState) && (undefined === input.newState || "object" === typeof input.newState && null !== input.newState && false === Array.isArray(input.newState) && $io9(input.newState)) && (undefined === input.onlyUpdateProvidedNewState || "boolean" === typeof input.onlyUpdateProvidedNewState) && "string" === typeof input.instanceId && "string" === typeof input.pluginId && ("object" === typeof input.publicParams && null !== input.publicParams && true) && ("object" === typeof input.privateParams && null !== input.privateParams && true);
|
|
3815
|
+
const $io9 = input => true;
|
|
3803
3816
|
const $io10 = input => "string" === typeof input.name && "string" === typeof input.description && "string" === typeof input.image && (undefined === input.video || "string" === typeof input.video) && (undefined === input.category || "string" === typeof input.category) && (undefined === input.externalUrl || "string" === typeof input.externalUrl) && (undefined === input.tags || Array.isArray(input.tags) && input.tags.every(elem => "string" === typeof elem)) && (undefined === input.socials || "object" === typeof input.socials && null !== input.socials && false === Array.isArray(input.socials) && $io11(input.socials)) && (undefined === input.offChainTransferabilityInfo || "object" === typeof input.offChainTransferabilityInfo && null !== input.offChainTransferabilityInfo && $io12(input.offChainTransferabilityInfo)) && (undefined === input.attributes || Array.isArray(input.attributes) && input.attributes.every(elem => "object" === typeof elem && null !== elem && $io13(elem))) && (undefined === input.fetchedAtBlock || "string" === typeof input.fetchedAtBlock || "number" === typeof input.fetchedAtBlock || "bigint" === typeof input.fetchedAtBlock) && (undefined === input.fetchedAt || "string" === typeof input.fetchedAt || "number" === typeof input.fetchedAt || "bigint" === typeof input.fetchedAt) && (undefined === input._isUpdating || "boolean" === typeof input._isUpdating);
|
|
3804
3817
|
const $io11 = input => Object.keys(input).every(key => {
|
|
3805
3818
|
const value = input[key];
|
|
@@ -3832,7 +3845,19 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3832
3845
|
expected: "Array<Omit<iClaimDetails<NumberType>, \"seedCode\">>",
|
|
3833
3846
|
value: input.claims
|
|
3834
3847
|
})].every(flag => flag);
|
|
3835
|
-
const $vo1 = (input, _path, _exceptionable = true) => [
|
|
3848
|
+
const $vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.claimId || $report(_exceptionable, {
|
|
3849
|
+
path: _path + ".claimId",
|
|
3850
|
+
expected: "string",
|
|
3851
|
+
value: input.claimId
|
|
3852
|
+
}), undefined === input.balancesToSet || ("object" === typeof input.balancesToSet && null !== input.balancesToSet || $report(_exceptionable, {
|
|
3853
|
+
path: _path + ".balancesToSet",
|
|
3854
|
+
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
3855
|
+
value: input.balancesToSet
|
|
3856
|
+
})) && $vo2(input.balancesToSet, _path + ".balancesToSet", true && _exceptionable) || $report(_exceptionable, {
|
|
3857
|
+
path: _path + ".balancesToSet",
|
|
3858
|
+
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
3859
|
+
value: input.balancesToSet
|
|
3860
|
+
}), (Array.isArray(input.plugins) || $report(_exceptionable, {
|
|
3836
3861
|
path: _path + ".plugins",
|
|
3837
3862
|
expected: "Array<IntegrationPluginDetails<string>>",
|
|
3838
3863
|
value: input.plugins
|
|
@@ -3840,7 +3865,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3840
3865
|
path: _path + ".plugins[" + _index2 + "]",
|
|
3841
3866
|
expected: "IntegrationPluginDetails<string>",
|
|
3842
3867
|
value: elem
|
|
3843
|
-
})) && $
|
|
3868
|
+
})) && $vo8(elem, _path + ".plugins[" + _index2 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3844
3869
|
path: _path + ".plugins[" + _index2 + "]",
|
|
3845
3870
|
expected: "IntegrationPluginDetails<string>",
|
|
3846
3871
|
value: elem
|
|
@@ -3848,18 +3873,6 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3848
3873
|
path: _path + ".plugins",
|
|
3849
3874
|
expected: "Array<IntegrationPluginDetails<string>>",
|
|
3850
3875
|
value: input.plugins
|
|
3851
|
-
}), "string" === typeof input.claimId || $report(_exceptionable, {
|
|
3852
|
-
path: _path + ".claimId",
|
|
3853
|
-
expected: "string",
|
|
3854
|
-
value: input.claimId
|
|
3855
|
-
}), undefined === input.balancesToSet || ("object" === typeof input.balancesToSet && null !== input.balancesToSet || $report(_exceptionable, {
|
|
3856
|
-
path: _path + ".balancesToSet",
|
|
3857
|
-
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
3858
|
-
value: input.balancesToSet
|
|
3859
|
-
})) && $vo4(input.balancesToSet, _path + ".balancesToSet", true && _exceptionable) || $report(_exceptionable, {
|
|
3860
|
-
path: _path + ".balancesToSet",
|
|
3861
|
-
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
3862
|
-
value: input.balancesToSet
|
|
3863
3876
|
}), undefined === input.manualDistribution || "boolean" === typeof input.manualDistribution || $report(_exceptionable, {
|
|
3864
3877
|
path: _path + ".manualDistribution",
|
|
3865
3878
|
expected: "(boolean | undefined)",
|
|
@@ -3881,65 +3894,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3881
3894
|
expected: "(string | undefined)",
|
|
3882
3895
|
value: input.assignMethod
|
|
3883
3896
|
})].every(flag => flag);
|
|
3884
|
-
const $vo2 = (input, _path, _exceptionable = true) => [(
|
|
3885
|
-
path: _path + ".publicState",
|
|
3886
|
-
expected: "__type",
|
|
3887
|
-
value: input.publicState
|
|
3888
|
-
})) && $vo3(input.publicState, _path + ".publicState", true && _exceptionable) || $report(_exceptionable, {
|
|
3889
|
-
path: _path + ".publicState",
|
|
3890
|
-
expected: "__type",
|
|
3891
|
-
value: input.publicState
|
|
3892
|
-
}), undefined === input.privateState || ("object" === typeof input.privateState && null !== input.privateState && false === Array.isArray(input.privateState) || $report(_exceptionable, {
|
|
3893
|
-
path: _path + ".privateState",
|
|
3894
|
-
expected: "(__type | undefined)",
|
|
3895
|
-
value: input.privateState
|
|
3896
|
-
})) && $vo3(input.privateState, _path + ".privateState", true && _exceptionable) || $report(_exceptionable, {
|
|
3897
|
-
path: _path + ".privateState",
|
|
3898
|
-
expected: "(__type | undefined)",
|
|
3899
|
-
value: input.privateState
|
|
3900
|
-
}), undefined === input.resetState || "boolean" === typeof input.resetState || $report(_exceptionable, {
|
|
3901
|
-
path: _path + ".resetState",
|
|
3902
|
-
expected: "(boolean | undefined)",
|
|
3903
|
-
value: input.resetState
|
|
3904
|
-
}), undefined === input.newState || ("object" === typeof input.newState && null !== input.newState && false === Array.isArray(input.newState) || $report(_exceptionable, {
|
|
3905
|
-
path: _path + ".newState",
|
|
3906
|
-
expected: "(__type | undefined)",
|
|
3907
|
-
value: input.newState
|
|
3908
|
-
})) && $vo3(input.newState, _path + ".newState", true && _exceptionable) || $report(_exceptionable, {
|
|
3909
|
-
path: _path + ".newState",
|
|
3910
|
-
expected: "(__type | undefined)",
|
|
3911
|
-
value: input.newState
|
|
3912
|
-
}), undefined === input.onlyUpdateProvidedNewState || "boolean" === typeof input.onlyUpdateProvidedNewState || $report(_exceptionable, {
|
|
3913
|
-
path: _path + ".onlyUpdateProvidedNewState",
|
|
3914
|
-
expected: "(boolean | undefined)",
|
|
3915
|
-
value: input.onlyUpdateProvidedNewState
|
|
3916
|
-
}), "string" === typeof input.instanceId || $report(_exceptionable, {
|
|
3917
|
-
path: _path + ".instanceId",
|
|
3918
|
-
expected: "string",
|
|
3919
|
-
value: input.instanceId
|
|
3920
|
-
}), "string" === typeof input.pluginId || $report(_exceptionable, {
|
|
3921
|
-
path: _path + ".pluginId",
|
|
3922
|
-
expected: "string",
|
|
3923
|
-
value: input.pluginId
|
|
3924
|
-
}), ("object" === typeof input.publicParams && null !== input.publicParams && false === Array.isArray(input.publicParams) || $report(_exceptionable, {
|
|
3925
|
-
path: _path + ".publicParams",
|
|
3926
|
-
expected: "__type",
|
|
3927
|
-
value: input.publicParams
|
|
3928
|
-
})) && $vo3(input.publicParams, _path + ".publicParams", true && _exceptionable) || $report(_exceptionable, {
|
|
3929
|
-
path: _path + ".publicParams",
|
|
3930
|
-
expected: "__type",
|
|
3931
|
-
value: input.publicParams
|
|
3932
|
-
}), ("object" === typeof input.privateParams && null !== input.privateParams && false === Array.isArray(input.privateParams) || $report(_exceptionable, {
|
|
3933
|
-
path: _path + ".privateParams",
|
|
3934
|
-
expected: "__type",
|
|
3935
|
-
value: input.privateParams
|
|
3936
|
-
})) && $vo3(input.privateParams, _path + ".privateParams", true && _exceptionable) || $report(_exceptionable, {
|
|
3937
|
-
path: _path + ".privateParams",
|
|
3938
|
-
expected: "__type",
|
|
3939
|
-
value: input.privateParams
|
|
3940
|
-
})].every(flag => flag);
|
|
3941
|
-
const $vo3 = (input, _path, _exceptionable = true) => true;
|
|
3942
|
-
const $vo4 = (input, _path, _exceptionable = true) => [(Array.isArray(input.manualBalances) || $report(_exceptionable, {
|
|
3897
|
+
const $vo2 = (input, _path, _exceptionable = true) => [(Array.isArray(input.manualBalances) || $report(_exceptionable, {
|
|
3943
3898
|
path: _path + ".manualBalances",
|
|
3944
3899
|
expected: "Array<iManualBalances<NumberType>>",
|
|
3945
3900
|
value: input.manualBalances
|
|
@@ -3947,7 +3902,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3947
3902
|
path: _path + ".manualBalances[" + _index3 + "]",
|
|
3948
3903
|
expected: "iManualBalances<NumberType>",
|
|
3949
3904
|
value: elem
|
|
3950
|
-
})) && $
|
|
3905
|
+
})) && $vo3(elem, _path + ".manualBalances[" + _index3 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3951
3906
|
path: _path + ".manualBalances[" + _index3 + "]",
|
|
3952
3907
|
expected: "iManualBalances<NumberType>",
|
|
3953
3908
|
value: elem
|
|
@@ -3959,7 +3914,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3959
3914
|
path: _path + ".incrementedBalances",
|
|
3960
3915
|
expected: "iIncrementedBalances<NumberType>",
|
|
3961
3916
|
value: input.incrementedBalances
|
|
3962
|
-
})) && $
|
|
3917
|
+
})) && $vo6(input.incrementedBalances, _path + ".incrementedBalances", true && _exceptionable) || $report(_exceptionable, {
|
|
3963
3918
|
path: _path + ".incrementedBalances",
|
|
3964
3919
|
expected: "iIncrementedBalances<NumberType>",
|
|
3965
3920
|
value: input.incrementedBalances
|
|
@@ -3967,12 +3922,12 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3967
3922
|
path: _path + ".orderCalculationMethod",
|
|
3968
3923
|
expected: "iPredeterminedOrderCalculationMethod",
|
|
3969
3924
|
value: input.orderCalculationMethod
|
|
3970
|
-
})) && $
|
|
3925
|
+
})) && $vo7(input.orderCalculationMethod, _path + ".orderCalculationMethod", true && _exceptionable) || $report(_exceptionable, {
|
|
3971
3926
|
path: _path + ".orderCalculationMethod",
|
|
3972
3927
|
expected: "iPredeterminedOrderCalculationMethod",
|
|
3973
3928
|
value: input.orderCalculationMethod
|
|
3974
3929
|
})].every(flag => flag);
|
|
3975
|
-
const $
|
|
3930
|
+
const $vo3 = (input, _path, _exceptionable = true) => [(Array.isArray(input.balances) || $report(_exceptionable, {
|
|
3976
3931
|
path: _path + ".balances",
|
|
3977
3932
|
expected: "Array<iBalance<NumberType>>",
|
|
3978
3933
|
value: input.balances
|
|
@@ -3980,7 +3935,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3980
3935
|
path: _path + ".balances[" + _index4 + "]",
|
|
3981
3936
|
expected: "iBalance<NumberType>",
|
|
3982
3937
|
value: elem
|
|
3983
|
-
})) && $
|
|
3938
|
+
})) && $vo4(elem, _path + ".balances[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3984
3939
|
path: _path + ".balances[" + _index4 + "]",
|
|
3985
3940
|
expected: "iBalance<NumberType>",
|
|
3986
3941
|
value: elem
|
|
@@ -3989,7 +3944,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3989
3944
|
expected: "Array<iBalance<NumberType>>",
|
|
3990
3945
|
value: input.balances
|
|
3991
3946
|
})].every(flag => flag);
|
|
3992
|
-
const $
|
|
3947
|
+
const $vo4 = (input, _path, _exceptionable = true) => ["string" === typeof input.amount || "number" === typeof input.amount || "bigint" === typeof input.amount || $report(_exceptionable, {
|
|
3993
3948
|
path: _path + ".amount",
|
|
3994
3949
|
expected: "(bigint | number | string)",
|
|
3995
3950
|
value: input.amount
|
|
@@ -4001,7 +3956,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4001
3956
|
path: _path + ".badgeIds[" + _index5 + "]",
|
|
4002
3957
|
expected: "iUintRange<NumberType>",
|
|
4003
3958
|
value: elem
|
|
4004
|
-
})) && $
|
|
3959
|
+
})) && $vo5(elem, _path + ".badgeIds[" + _index5 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4005
3960
|
path: _path + ".badgeIds[" + _index5 + "]",
|
|
4006
3961
|
expected: "iUintRange<NumberType>",
|
|
4007
3962
|
value: elem
|
|
@@ -4017,7 +3972,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4017
3972
|
path: _path + ".ownershipTimes[" + _index6 + "]",
|
|
4018
3973
|
expected: "iUintRange<NumberType>",
|
|
4019
3974
|
value: elem
|
|
4020
|
-
})) && $
|
|
3975
|
+
})) && $vo5(elem, _path + ".ownershipTimes[" + _index6 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4021
3976
|
path: _path + ".ownershipTimes[" + _index6 + "]",
|
|
4022
3977
|
expected: "iUintRange<NumberType>",
|
|
4023
3978
|
value: elem
|
|
@@ -4026,7 +3981,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4026
3981
|
expected: "Array<iUintRange<NumberType>>",
|
|
4027
3982
|
value: input.ownershipTimes
|
|
4028
3983
|
})].every(flag => flag);
|
|
4029
|
-
const $
|
|
3984
|
+
const $vo5 = (input, _path, _exceptionable = true) => ["string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start || $report(_exceptionable, {
|
|
4030
3985
|
path: _path + ".start",
|
|
4031
3986
|
expected: "(bigint | number | string)",
|
|
4032
3987
|
value: input.start
|
|
@@ -4035,7 +3990,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4035
3990
|
expected: "(bigint | number | string)",
|
|
4036
3991
|
value: input.end
|
|
4037
3992
|
})].every(flag => flag);
|
|
4038
|
-
const $
|
|
3993
|
+
const $vo6 = (input, _path, _exceptionable = true) => [(Array.isArray(input.startBalances) || $report(_exceptionable, {
|
|
4039
3994
|
path: _path + ".startBalances",
|
|
4040
3995
|
expected: "Array<iBalance<NumberType>>",
|
|
4041
3996
|
value: input.startBalances
|
|
@@ -4043,7 +3998,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4043
3998
|
path: _path + ".startBalances[" + _index7 + "]",
|
|
4044
3999
|
expected: "iBalance<NumberType>",
|
|
4045
4000
|
value: elem
|
|
4046
|
-
})) && $
|
|
4001
|
+
})) && $vo4(elem, _path + ".startBalances[" + _index7 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4047
4002
|
path: _path + ".startBalances[" + _index7 + "]",
|
|
4048
4003
|
expected: "iBalance<NumberType>",
|
|
4049
4004
|
value: elem
|
|
@@ -4060,7 +4015,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4060
4015
|
expected: "(bigint | number | string)",
|
|
4061
4016
|
value: input.incrementOwnershipTimesBy
|
|
4062
4017
|
})].every(flag => flag);
|
|
4063
|
-
const $
|
|
4018
|
+
const $vo7 = (input, _path, _exceptionable = true) => ["boolean" === typeof input.useOverallNumTransfers || $report(_exceptionable, {
|
|
4064
4019
|
path: _path + ".useOverallNumTransfers",
|
|
4065
4020
|
expected: "boolean",
|
|
4066
4021
|
value: input.useOverallNumTransfers
|
|
@@ -4085,6 +4040,64 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4085
4040
|
expected: "string",
|
|
4086
4041
|
value: input.challengeTrackerId
|
|
4087
4042
|
})].every(flag => flag);
|
|
4043
|
+
const $vo8 = (input, _path, _exceptionable = true) => [("object" === typeof input.publicState && null !== input.publicState && false === Array.isArray(input.publicState) || $report(_exceptionable, {
|
|
4044
|
+
path: _path + ".publicState",
|
|
4045
|
+
expected: "__type",
|
|
4046
|
+
value: input.publicState
|
|
4047
|
+
})) && $vo9(input.publicState, _path + ".publicState", true && _exceptionable) || $report(_exceptionable, {
|
|
4048
|
+
path: _path + ".publicState",
|
|
4049
|
+
expected: "__type",
|
|
4050
|
+
value: input.publicState
|
|
4051
|
+
}), undefined === input.privateState || ("object" === typeof input.privateState && null !== input.privateState && false === Array.isArray(input.privateState) || $report(_exceptionable, {
|
|
4052
|
+
path: _path + ".privateState",
|
|
4053
|
+
expected: "(__type | undefined)",
|
|
4054
|
+
value: input.privateState
|
|
4055
|
+
})) && $vo9(input.privateState, _path + ".privateState", true && _exceptionable) || $report(_exceptionable, {
|
|
4056
|
+
path: _path + ".privateState",
|
|
4057
|
+
expected: "(__type | undefined)",
|
|
4058
|
+
value: input.privateState
|
|
4059
|
+
}), undefined === input.resetState || "boolean" === typeof input.resetState || $report(_exceptionable, {
|
|
4060
|
+
path: _path + ".resetState",
|
|
4061
|
+
expected: "(boolean | undefined)",
|
|
4062
|
+
value: input.resetState
|
|
4063
|
+
}), undefined === input.newState || ("object" === typeof input.newState && null !== input.newState && false === Array.isArray(input.newState) || $report(_exceptionable, {
|
|
4064
|
+
path: _path + ".newState",
|
|
4065
|
+
expected: "(__type | undefined)",
|
|
4066
|
+
value: input.newState
|
|
4067
|
+
})) && $vo9(input.newState, _path + ".newState", true && _exceptionable) || $report(_exceptionable, {
|
|
4068
|
+
path: _path + ".newState",
|
|
4069
|
+
expected: "(__type | undefined)",
|
|
4070
|
+
value: input.newState
|
|
4071
|
+
}), undefined === input.onlyUpdateProvidedNewState || "boolean" === typeof input.onlyUpdateProvidedNewState || $report(_exceptionable, {
|
|
4072
|
+
path: _path + ".onlyUpdateProvidedNewState",
|
|
4073
|
+
expected: "(boolean | undefined)",
|
|
4074
|
+
value: input.onlyUpdateProvidedNewState
|
|
4075
|
+
}), "string" === typeof input.instanceId || $report(_exceptionable, {
|
|
4076
|
+
path: _path + ".instanceId",
|
|
4077
|
+
expected: "string",
|
|
4078
|
+
value: input.instanceId
|
|
4079
|
+
}), "string" === typeof input.pluginId || $report(_exceptionable, {
|
|
4080
|
+
path: _path + ".pluginId",
|
|
4081
|
+
expected: "string",
|
|
4082
|
+
value: input.pluginId
|
|
4083
|
+
}), ("object" === typeof input.publicParams && null !== input.publicParams && false === Array.isArray(input.publicParams) || $report(_exceptionable, {
|
|
4084
|
+
path: _path + ".publicParams",
|
|
4085
|
+
expected: "__type",
|
|
4086
|
+
value: input.publicParams
|
|
4087
|
+
})) && $vo9(input.publicParams, _path + ".publicParams", true && _exceptionable) || $report(_exceptionable, {
|
|
4088
|
+
path: _path + ".publicParams",
|
|
4089
|
+
expected: "__type",
|
|
4090
|
+
value: input.publicParams
|
|
4091
|
+
}), ("object" === typeof input.privateParams && null !== input.privateParams && false === Array.isArray(input.privateParams) || $report(_exceptionable, {
|
|
4092
|
+
path: _path + ".privateParams",
|
|
4093
|
+
expected: "__type",
|
|
4094
|
+
value: input.privateParams
|
|
4095
|
+
})) && $vo9(input.privateParams, _path + ".privateParams", true && _exceptionable) || $report(_exceptionable, {
|
|
4096
|
+
path: _path + ".privateParams",
|
|
4097
|
+
expected: "__type",
|
|
4098
|
+
value: input.privateParams
|
|
4099
|
+
})].every(flag => flag);
|
|
4100
|
+
const $vo9 = (input, _path, _exceptionable = true) => true;
|
|
4088
4101
|
const $vo10 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || $report(_exceptionable, {
|
|
4089
4102
|
path: _path + ".name",
|
|
4090
4103
|
expected: "string",
|
|
@@ -5621,23 +5634,23 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5621
5634
|
const errors = [];
|
|
5622
5635
|
const __is = input => {
|
|
5623
5636
|
const $io0 = input => undefined === input.contents || Array.isArray(input.contents) && input.contents.every(elem => "object" === typeof elem && null !== elem && $iu0(elem));
|
|
5624
|
-
const $io1 = input =>
|
|
5625
|
-
const $io2 = input =>
|
|
5637
|
+
const $io1 = input => Array.isArray(input.badgeIds) && input.badgeIds.every(elem => "object" === typeof elem && null !== elem && $io2(elem)) && (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $io3(input.metadata)) && "string" === typeof input.uri && (undefined === input.fetchedUri || "string" === typeof input.fetchedUri) && "string" === typeof input.customData && (undefined === input.toUploadToIpfs || "boolean" === typeof input.toUploadToIpfs);
|
|
5638
|
+
const $io2 = input => ("string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start) && ("string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end);
|
|
5639
|
+
const $io3 = input => "string" === typeof input.name && "string" === typeof input.description && "string" === typeof input.image && (undefined === input.video || "string" === typeof input.video) && (undefined === input.category || "string" === typeof input.category) && (undefined === input.externalUrl || "string" === typeof input.externalUrl) && (undefined === input.tags || Array.isArray(input.tags) && input.tags.every(elem => "string" === typeof elem)) && (undefined === input.socials || "object" === typeof input.socials && null !== input.socials && false === Array.isArray(input.socials) && $io4(input.socials)) && (undefined === input.offChainTransferabilityInfo || "object" === typeof input.offChainTransferabilityInfo && null !== input.offChainTransferabilityInfo && $io5(input.offChainTransferabilityInfo)) && (undefined === input.attributes || Array.isArray(input.attributes) && input.attributes.every(elem => "object" === typeof elem && null !== elem && $io6(elem))) && (undefined === input.fetchedAtBlock || "string" === typeof input.fetchedAtBlock || "number" === typeof input.fetchedAtBlock || "bigint" === typeof input.fetchedAtBlock) && (undefined === input.fetchedAt || "string" === typeof input.fetchedAt || "number" === typeof input.fetchedAt || "bigint" === typeof input.fetchedAt) && (undefined === input._isUpdating || "boolean" === typeof input._isUpdating);
|
|
5640
|
+
const $io4 = input => Object.keys(input).every(key => {
|
|
5626
5641
|
const value = input[key];
|
|
5627
5642
|
if (undefined === value)
|
|
5628
5643
|
return true;
|
|
5629
5644
|
return "string" === typeof value;
|
|
5630
5645
|
});
|
|
5631
|
-
const $
|
|
5632
|
-
const $
|
|
5633
|
-
const $
|
|
5634
|
-
const $io6 = input => ("string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start) && ("string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end);
|
|
5635
|
-
const $io7 = input => (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $io1(input.metadata)) && "string" === typeof input.uri && (undefined === input.fetchedUri || "string" === typeof input.fetchedUri) && "string" === typeof input.customData && (undefined === input.toUploadToIpfs || "boolean" === typeof input.toUploadToIpfs);
|
|
5646
|
+
const $io5 = input => "string" === typeof input.host && "string" === typeof input.assignMethod;
|
|
5647
|
+
const $io6 = input => (undefined === input.type || "date" === input.type || "url" === input.type) && "string" === typeof input.name && ("string" === typeof input.value || "number" === typeof input.value || "boolean" === typeof input.value);
|
|
5648
|
+
const $io7 = input => (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $io3(input.metadata)) && "string" === typeof input.uri && (undefined === input.fetchedUri || "string" === typeof input.fetchedUri) && "string" === typeof input.customData && (undefined === input.toUploadToIpfs || "boolean" === typeof input.toUploadToIpfs);
|
|
5636
5649
|
const $io8 = input => Array.isArray(input.leaves) && input.leaves.every(elem => "string" === typeof elem) && "boolean" === typeof input.isHashed && (undefined === input.preimages || Array.isArray(input.preimages) && input.preimages.every(elem => "string" === typeof elem)) && (undefined === input.seedCode || "string" === typeof input.seedCode) && (undefined === input.tree || "object" === typeof input.tree && null !== input.tree && $io9(input.tree)) && (undefined === input.treeOptions || "object" === typeof input.treeOptions && null !== input.treeOptions && false === Array.isArray(input.treeOptions) && $io10(input.treeOptions)) && (undefined === input.numLeaves || "string" === typeof input.numLeaves || "number" === typeof input.numLeaves || "bigint" === typeof input.numLeaves) && (undefined === input.currCode || "string" === typeof input.currCode || "number" === typeof input.currCode || "bigint" === typeof input.currCode);
|
|
5637
5650
|
const $io9 = input => true;
|
|
5638
5651
|
const $io10 = input => (undefined === input.duplicateOdd || "boolean" === typeof input.duplicateOdd) && (undefined === input.hashLeaves || "boolean" === typeof input.hashLeaves) && (undefined === input.isBitcoinTree || "boolean" === typeof input.isBitcoinTree) && (undefined === input.sortLeaves || "boolean" === typeof input.sortLeaves) && (undefined === input.sortPairs || "boolean" === typeof input.sortPairs) && (undefined === input.sort || "boolean" === typeof input.sort) && (null !== input.fillDefaultHash && (undefined === input.fillDefaultHash || "function" === typeof input.fillDefaultHash || "string" === typeof input.fillDefaultHash || "object" === typeof input.fillDefaultHash && null !== input.fillDefaultHash && $io11(input.fillDefaultHash))) && (undefined === input.complete || "boolean" === typeof input.complete) && (undefined === input.concatenator || true);
|
|
5639
|
-
const $io11 = input => "number" === typeof input.BYTES_PER_ELEMENT && (input.buffer instanceof ArrayBuffer || input.buffer instanceof SharedArrayBuffer) && "number" === typeof input.byteLength && "number" === typeof input.byteOffset && "number" === typeof input.length && "Uint8Array" === input["__@toStringTag@
|
|
5640
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
5652
|
+
const $io11 = input => "number" === typeof input.BYTES_PER_ELEMENT && (input.buffer instanceof ArrayBuffer || input.buffer instanceof SharedArrayBuffer) && "number" === typeof input.byteLength && "number" === typeof input.byteOffset && "number" === typeof input.length && "Uint8Array" === input["__@toStringTag@868"] && Object.keys(input).every(key => {
|
|
5653
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@868"].some(prop => key === prop))
|
|
5641
5654
|
return true;
|
|
5642
5655
|
const value = input[key];
|
|
5643
5656
|
if (undefined === value)
|
|
@@ -5647,10 +5660,10 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5647
5660
|
return true;
|
|
5648
5661
|
});
|
|
5649
5662
|
const $iu0 = input => (() => {
|
|
5650
|
-
if (undefined !== input.
|
|
5663
|
+
if (undefined !== input.badgeIds)
|
|
5651
5664
|
return $io1(input);
|
|
5652
|
-
else if (undefined !== input.
|
|
5653
|
-
return $
|
|
5665
|
+
else if (undefined !== input.name)
|
|
5666
|
+
return $io3(input);
|
|
5654
5667
|
else if (undefined !== input.leaves)
|
|
5655
5668
|
return $io8(input);
|
|
5656
5669
|
else
|
|
@@ -5664,7 +5677,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5664
5677
|
const $join = typia_1.default.validate.join;
|
|
5665
5678
|
const $vo0 = (input, _path, _exceptionable = true) => [undefined === input.contents || (Array.isArray(input.contents) || $report(_exceptionable, {
|
|
5666
5679
|
path: _path + ".contents",
|
|
5667
|
-
expected: "(Array<
|
|
5680
|
+
expected: "(Array<iBadgeMetadataDetails<NumberType> | iMetadata<NumberType> | iCollectionMetadataDetails<NumberType> | iChallengeDetails<...>> | undefined)",
|
|
5668
5681
|
value: input.contents
|
|
5669
5682
|
})) && input.contents.map((elem, _index1) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
5670
5683
|
path: _path + ".contents[" + _index1 + "]",
|
|
@@ -5676,10 +5689,60 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5676
5689
|
value: elem
|
|
5677
5690
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
5678
5691
|
path: _path + ".contents",
|
|
5679
|
-
expected: "(Array<
|
|
5692
|
+
expected: "(Array<iBadgeMetadataDetails<NumberType> | iMetadata<NumberType> | iCollectionMetadataDetails<NumberType> | iChallengeDetails<...>> | undefined)",
|
|
5680
5693
|
value: input.contents
|
|
5681
5694
|
})].every(flag => flag);
|
|
5682
|
-
const $vo1 = (input, _path, _exceptionable = true) => [
|
|
5695
|
+
const $vo1 = (input, _path, _exceptionable = true) => [(Array.isArray(input.badgeIds) || $report(_exceptionable, {
|
|
5696
|
+
path: _path + ".badgeIds",
|
|
5697
|
+
expected: "Array<iUintRange<NumberType>>",
|
|
5698
|
+
value: input.badgeIds
|
|
5699
|
+
})) && input.badgeIds.map((elem, _index2) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
5700
|
+
path: _path + ".badgeIds[" + _index2 + "]",
|
|
5701
|
+
expected: "iUintRange<NumberType>",
|
|
5702
|
+
value: elem
|
|
5703
|
+
})) && $vo2(elem, _path + ".badgeIds[" + _index2 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
5704
|
+
path: _path + ".badgeIds[" + _index2 + "]",
|
|
5705
|
+
expected: "iUintRange<NumberType>",
|
|
5706
|
+
value: elem
|
|
5707
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
5708
|
+
path: _path + ".badgeIds",
|
|
5709
|
+
expected: "Array<iUintRange<NumberType>>",
|
|
5710
|
+
value: input.badgeIds
|
|
5711
|
+
}), undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
5712
|
+
path: _path + ".metadata",
|
|
5713
|
+
expected: "(iMetadata<NumberType> | undefined)",
|
|
5714
|
+
value: input.metadata
|
|
5715
|
+
})) && $vo3(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
5716
|
+
path: _path + ".metadata",
|
|
5717
|
+
expected: "(iMetadata<NumberType> | undefined)",
|
|
5718
|
+
value: input.metadata
|
|
5719
|
+
}), "string" === typeof input.uri || $report(_exceptionable, {
|
|
5720
|
+
path: _path + ".uri",
|
|
5721
|
+
expected: "string",
|
|
5722
|
+
value: input.uri
|
|
5723
|
+
}), undefined === input.fetchedUri || "string" === typeof input.fetchedUri || $report(_exceptionable, {
|
|
5724
|
+
path: _path + ".fetchedUri",
|
|
5725
|
+
expected: "(string | undefined)",
|
|
5726
|
+
value: input.fetchedUri
|
|
5727
|
+
}), "string" === typeof input.customData || $report(_exceptionable, {
|
|
5728
|
+
path: _path + ".customData",
|
|
5729
|
+
expected: "string",
|
|
5730
|
+
value: input.customData
|
|
5731
|
+
}), undefined === input.toUploadToIpfs || "boolean" === typeof input.toUploadToIpfs || $report(_exceptionable, {
|
|
5732
|
+
path: _path + ".toUploadToIpfs",
|
|
5733
|
+
expected: "(boolean | undefined)",
|
|
5734
|
+
value: input.toUploadToIpfs
|
|
5735
|
+
})].every(flag => flag);
|
|
5736
|
+
const $vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start || $report(_exceptionable, {
|
|
5737
|
+
path: _path + ".start",
|
|
5738
|
+
expected: "(bigint | number | string)",
|
|
5739
|
+
value: input.start
|
|
5740
|
+
}), "string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end || $report(_exceptionable, {
|
|
5741
|
+
path: _path + ".end",
|
|
5742
|
+
expected: "(bigint | number | string)",
|
|
5743
|
+
value: input.end
|
|
5744
|
+
})].every(flag => flag);
|
|
5745
|
+
const $vo3 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || $report(_exceptionable, {
|
|
5683
5746
|
path: _path + ".name",
|
|
5684
5747
|
expected: "string",
|
|
5685
5748
|
value: input.name
|
|
@@ -5707,8 +5770,8 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5707
5770
|
path: _path + ".tags",
|
|
5708
5771
|
expected: "(Array<string> | undefined)",
|
|
5709
5772
|
value: input.tags
|
|
5710
|
-
})) && input.tags.map((elem,
|
|
5711
|
-
path: _path + ".tags[" +
|
|
5773
|
+
})) && input.tags.map((elem, _index3) => "string" === typeof elem || $report(_exceptionable, {
|
|
5774
|
+
path: _path + ".tags[" + _index3 + "]",
|
|
5712
5775
|
expected: "string",
|
|
5713
5776
|
value: elem
|
|
5714
5777
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -5719,7 +5782,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5719
5782
|
path: _path + ".socials",
|
|
5720
5783
|
expected: "(__type | undefined)",
|
|
5721
5784
|
value: input.socials
|
|
5722
|
-
})) && $
|
|
5785
|
+
})) && $vo4(input.socials, _path + ".socials", true && _exceptionable) || $report(_exceptionable, {
|
|
5723
5786
|
path: _path + ".socials",
|
|
5724
5787
|
expected: "(__type | undefined)",
|
|
5725
5788
|
value: input.socials
|
|
@@ -5727,7 +5790,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5727
5790
|
path: _path + ".offChainTransferabilityInfo",
|
|
5728
5791
|
expected: "(__type.o1 | undefined)",
|
|
5729
5792
|
value: input.offChainTransferabilityInfo
|
|
5730
|
-
})) && $
|
|
5793
|
+
})) && $vo5(input.offChainTransferabilityInfo, _path + ".offChainTransferabilityInfo", true && _exceptionable) || $report(_exceptionable, {
|
|
5731
5794
|
path: _path + ".offChainTransferabilityInfo",
|
|
5732
5795
|
expected: "(__type.o1 | undefined)",
|
|
5733
5796
|
value: input.offChainTransferabilityInfo
|
|
@@ -5735,12 +5798,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5735
5798
|
path: _path + ".attributes",
|
|
5736
5799
|
expected: "(Array<__type> | undefined)",
|
|
5737
5800
|
value: input.attributes
|
|
5738
|
-
})) && input.attributes.map((elem,
|
|
5739
|
-
path: _path + ".attributes[" +
|
|
5801
|
+
})) && input.attributes.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
5802
|
+
path: _path + ".attributes[" + _index4 + "]",
|
|
5740
5803
|
expected: "__type.o2",
|
|
5741
5804
|
value: elem
|
|
5742
|
-
})) && $
|
|
5743
|
-
path: _path + ".attributes[" +
|
|
5805
|
+
})) && $vo6(elem, _path + ".attributes[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
5806
|
+
path: _path + ".attributes[" + _index4 + "]",
|
|
5744
5807
|
expected: "__type.o2",
|
|
5745
5808
|
value: elem
|
|
5746
5809
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -5760,7 +5823,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5760
5823
|
expected: "(boolean | undefined)",
|
|
5761
5824
|
value: input._isUpdating
|
|
5762
5825
|
})].every(flag => flag);
|
|
5763
|
-
const $
|
|
5826
|
+
const $vo4 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
5764
5827
|
const value = input[key];
|
|
5765
5828
|
if (undefined === value)
|
|
5766
5829
|
return true;
|
|
@@ -5770,7 +5833,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5770
5833
|
value: value
|
|
5771
5834
|
});
|
|
5772
5835
|
}).every(flag => flag)].every(flag => flag);
|
|
5773
|
-
const $
|
|
5836
|
+
const $vo5 = (input, _path, _exceptionable = true) => ["string" === typeof input.host || $report(_exceptionable, {
|
|
5774
5837
|
path: _path + ".host",
|
|
5775
5838
|
expected: "string",
|
|
5776
5839
|
value: input.host
|
|
@@ -5779,7 +5842,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5779
5842
|
expected: "string",
|
|
5780
5843
|
value: input.assignMethod
|
|
5781
5844
|
})].every(flag => flag);
|
|
5782
|
-
const $
|
|
5845
|
+
const $vo6 = (input, _path, _exceptionable = true) => [undefined === input.type || "date" === input.type || "url" === input.type || $report(_exceptionable, {
|
|
5783
5846
|
path: _path + ".type",
|
|
5784
5847
|
expected: "(\"date\" | \"url\" | undefined)",
|
|
5785
5848
|
value: input.type
|
|
@@ -5792,61 +5855,11 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5792
5855
|
expected: "(boolean | number | string)",
|
|
5793
5856
|
value: input.value
|
|
5794
5857
|
})].every(flag => flag);
|
|
5795
|
-
const $vo5 = (input, _path, _exceptionable = true) => [(Array.isArray(input.badgeIds) || $report(_exceptionable, {
|
|
5796
|
-
path: _path + ".badgeIds",
|
|
5797
|
-
expected: "Array<iUintRange<NumberType>>",
|
|
5798
|
-
value: input.badgeIds
|
|
5799
|
-
})) && input.badgeIds.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
5800
|
-
path: _path + ".badgeIds[" + _index4 + "]",
|
|
5801
|
-
expected: "iUintRange<NumberType>",
|
|
5802
|
-
value: elem
|
|
5803
|
-
})) && $vo6(elem, _path + ".badgeIds[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
5804
|
-
path: _path + ".badgeIds[" + _index4 + "]",
|
|
5805
|
-
expected: "iUintRange<NumberType>",
|
|
5806
|
-
value: elem
|
|
5807
|
-
})).every(flag => flag) || $report(_exceptionable, {
|
|
5808
|
-
path: _path + ".badgeIds",
|
|
5809
|
-
expected: "Array<iUintRange<NumberType>>",
|
|
5810
|
-
value: input.badgeIds
|
|
5811
|
-
}), undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
5812
|
-
path: _path + ".metadata",
|
|
5813
|
-
expected: "(iMetadata<NumberType> | undefined)",
|
|
5814
|
-
value: input.metadata
|
|
5815
|
-
})) && $vo1(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
5816
|
-
path: _path + ".metadata",
|
|
5817
|
-
expected: "(iMetadata<NumberType> | undefined)",
|
|
5818
|
-
value: input.metadata
|
|
5819
|
-
}), "string" === typeof input.uri || $report(_exceptionable, {
|
|
5820
|
-
path: _path + ".uri",
|
|
5821
|
-
expected: "string",
|
|
5822
|
-
value: input.uri
|
|
5823
|
-
}), undefined === input.fetchedUri || "string" === typeof input.fetchedUri || $report(_exceptionable, {
|
|
5824
|
-
path: _path + ".fetchedUri",
|
|
5825
|
-
expected: "(string | undefined)",
|
|
5826
|
-
value: input.fetchedUri
|
|
5827
|
-
}), "string" === typeof input.customData || $report(_exceptionable, {
|
|
5828
|
-
path: _path + ".customData",
|
|
5829
|
-
expected: "string",
|
|
5830
|
-
value: input.customData
|
|
5831
|
-
}), undefined === input.toUploadToIpfs || "boolean" === typeof input.toUploadToIpfs || $report(_exceptionable, {
|
|
5832
|
-
path: _path + ".toUploadToIpfs",
|
|
5833
|
-
expected: "(boolean | undefined)",
|
|
5834
|
-
value: input.toUploadToIpfs
|
|
5835
|
-
})].every(flag => flag);
|
|
5836
|
-
const $vo6 = (input, _path, _exceptionable = true) => ["string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start || $report(_exceptionable, {
|
|
5837
|
-
path: _path + ".start",
|
|
5838
|
-
expected: "(bigint | number | string)",
|
|
5839
|
-
value: input.start
|
|
5840
|
-
}), "string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end || $report(_exceptionable, {
|
|
5841
|
-
path: _path + ".end",
|
|
5842
|
-
expected: "(bigint | number | string)",
|
|
5843
|
-
value: input.end
|
|
5844
|
-
})].every(flag => flag);
|
|
5845
5858
|
const $vo7 = (input, _path, _exceptionable = true) => [undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
5846
5859
|
path: _path + ".metadata",
|
|
5847
5860
|
expected: "(iMetadata<NumberType> | undefined)",
|
|
5848
5861
|
value: input.metadata
|
|
5849
|
-
})) && $
|
|
5862
|
+
})) && $vo3(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
5850
5863
|
path: _path + ".metadata",
|
|
5851
5864
|
expected: "(iMetadata<NumberType> | undefined)",
|
|
5852
5865
|
value: input.metadata
|
|
@@ -5990,12 +6003,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5990
6003
|
path: _path + ".length",
|
|
5991
6004
|
expected: "number",
|
|
5992
6005
|
value: input.length
|
|
5993
|
-
}), "Uint8Array" === input["__@toStringTag@
|
|
5994
|
-
path: _path + "[\"__@toStringTag@
|
|
6006
|
+
}), "Uint8Array" === input["__@toStringTag@868"] || $report(_exceptionable, {
|
|
6007
|
+
path: _path + "[\"__@toStringTag@868\"]",
|
|
5995
6008
|
expected: "\"Uint8Array\"",
|
|
5996
|
-
value: input["__@toStringTag@
|
|
6009
|
+
value: input["__@toStringTag@868"]
|
|
5997
6010
|
}), false === _exceptionable || Object.keys(input).map(key => {
|
|
5998
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
6011
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@868"].some(prop => key === prop))
|
|
5999
6012
|
return true;
|
|
6000
6013
|
const value = input[key];
|
|
6001
6014
|
if (undefined === value)
|
|
@@ -6009,10 +6022,10 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6009
6022
|
return true;
|
|
6010
6023
|
}).every(flag => flag)].every(flag => flag);
|
|
6011
6024
|
const $vu0 = (input, _path, _exceptionable = true) => (() => {
|
|
6012
|
-
if (undefined !== input.
|
|
6025
|
+
if (undefined !== input.badgeIds)
|
|
6013
6026
|
return $vo1(input, _path, true && _exceptionable);
|
|
6014
|
-
else if (undefined !== input.
|
|
6015
|
-
return $
|
|
6027
|
+
else if (undefined !== input.name)
|
|
6028
|
+
return $vo3(input, _path, true && _exceptionable);
|
|
6016
6029
|
else if (undefined !== input.leaves)
|
|
6017
6030
|
return $vo8(input, _path, true && _exceptionable);
|
|
6018
6031
|
else
|
|
@@ -6058,8 +6071,8 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6058
6071
|
const $io3 = input => Array.isArray(input.leaves) && input.leaves.every(elem => "string" === typeof elem) && "boolean" === typeof input.isHashed && (undefined === input.preimages || Array.isArray(input.preimages) && input.preimages.every(elem => "string" === typeof elem)) && (undefined === input.seedCode || "string" === typeof input.seedCode) && (undefined === input.tree || "object" === typeof input.tree && null !== input.tree && $io4(input.tree)) && (undefined === input.treeOptions || "object" === typeof input.treeOptions && null !== input.treeOptions && false === Array.isArray(input.treeOptions) && $io5(input.treeOptions)) && (undefined === input.numLeaves || "string" === typeof input.numLeaves || "number" === typeof input.numLeaves || "bigint" === typeof input.numLeaves) && (undefined === input.currCode || "string" === typeof input.currCode || "number" === typeof input.currCode || "bigint" === typeof input.currCode);
|
|
6059
6072
|
const $io4 = input => true;
|
|
6060
6073
|
const $io5 = input => (undefined === input.duplicateOdd || "boolean" === typeof input.duplicateOdd) && (undefined === input.hashLeaves || "boolean" === typeof input.hashLeaves) && (undefined === input.isBitcoinTree || "boolean" === typeof input.isBitcoinTree) && (undefined === input.sortLeaves || "boolean" === typeof input.sortLeaves) && (undefined === input.sortPairs || "boolean" === typeof input.sortPairs) && (undefined === input.sort || "boolean" === typeof input.sort) && (null !== input.fillDefaultHash && (undefined === input.fillDefaultHash || "function" === typeof input.fillDefaultHash || "string" === typeof input.fillDefaultHash || "object" === typeof input.fillDefaultHash && null !== input.fillDefaultHash && $io6(input.fillDefaultHash))) && (undefined === input.complete || "boolean" === typeof input.complete) && (undefined === input.concatenator || true);
|
|
6061
|
-
const $io6 = input => "number" === typeof input.BYTES_PER_ELEMENT && (input.buffer instanceof ArrayBuffer || input.buffer instanceof SharedArrayBuffer) && "number" === typeof input.byteLength && "number" === typeof input.byteOffset && "number" === typeof input.length && "Uint8Array" === input["__@toStringTag@
|
|
6062
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
6074
|
+
const $io6 = input => "number" === typeof input.BYTES_PER_ELEMENT && (input.buffer instanceof ArrayBuffer || input.buffer instanceof SharedArrayBuffer) && "number" === typeof input.byteLength && "number" === typeof input.byteOffset && "number" === typeof input.length && "Uint8Array" === input["__@toStringTag@868"] && Object.keys(input).every(key => {
|
|
6075
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@868"].some(prop => key === prop))
|
|
6063
6076
|
return true;
|
|
6064
6077
|
const value = input[key];
|
|
6065
6078
|
if (undefined === value)
|
|
@@ -6273,12 +6286,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6273
6286
|
path: _path + ".length",
|
|
6274
6287
|
expected: "number",
|
|
6275
6288
|
value: input.length
|
|
6276
|
-
}), "Uint8Array" === input["__@toStringTag@
|
|
6277
|
-
path: _path + "[\"__@toStringTag@
|
|
6289
|
+
}), "Uint8Array" === input["__@toStringTag@868"] || $report(_exceptionable, {
|
|
6290
|
+
path: _path + "[\"__@toStringTag@868\"]",
|
|
6278
6291
|
expected: "\"Uint8Array\"",
|
|
6279
|
-
value: input["__@toStringTag@
|
|
6292
|
+
value: input["__@toStringTag@868"]
|
|
6280
6293
|
}), false === _exceptionable || Object.keys(input).map(key => {
|
|
6281
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
6294
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@868"].some(prop => key === prop))
|
|
6282
6295
|
return true;
|
|
6283
6296
|
const value = input[key];
|
|
6284
6297
|
if (undefined === value)
|