bitbadgesjs-sdk 0.3.71 → 0.3.73
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 +1 -2
- package/dist/api-indexer/BitBadgesApi.d.ts.map +1 -1
- package/dist/api-indexer/BitBadgesApi.js +522 -457
- package/dist/api-indexer/BitBadgesApi.js.map +1 -1
- package/dist/api-indexer/BitBadgesUserInfo.d.ts +2 -25
- package/dist/api-indexer/BitBadgesUserInfo.d.ts.map +1 -1
- package/dist/api-indexer/BitBadgesUserInfo.js +1 -82
- package/dist/api-indexer/BitBadgesUserInfo.js.map +1 -1
- package/dist/api-indexer/docs/docs.d.ts +1 -14
- package/dist/api-indexer/docs/docs.d.ts.map +1 -1
- package/dist/api-indexer/docs/docs.js +1 -29
- package/dist/api-indexer/docs/docs.js.map +1 -1
- package/dist/api-indexer/docs/interfaces.d.ts +0 -8
- package/dist/api-indexer/docs/interfaces.d.ts.map +1 -1
- package/dist/api-indexer/requests/requests.d.ts +3 -1
- package/dist/api-indexer/requests/requests.d.ts.map +1 -1
- package/dist/api-indexer/requests/requests.js.map +1 -1
- package/dist/api-indexer/requests/routes.d.ts +0 -1
- package/dist/api-indexer/requests/routes.d.ts.map +1 -1
- package/dist/api-indexer/requests/routes.js +0 -1
- package/dist/api-indexer/requests/routes.js.map +1 -1
- package/dist/chain-drivers/verifySig.d.ts +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -2921,9 +2921,6 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
2921
2921
|
return Promise.reject(error);
|
|
2922
2922
|
}
|
|
2923
2923
|
}
|
|
2924
|
-
async getFollowDetails(payload) {
|
|
2925
|
-
return await BitBadgesUserInfo_1.BitBadgesUserInfo.GetFollowDetails(this, payload);
|
|
2926
|
-
}
|
|
2927
2924
|
async getClaimAlerts(payload) {
|
|
2928
2925
|
try {
|
|
2929
2926
|
const validateRes = (input => {
|
|
@@ -3544,21 +3541,21 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3544
3541
|
const errors = [];
|
|
3545
3542
|
const __is = input => {
|
|
3546
3543
|
const $io0 = input => Array.isArray(input.claims) && input.claims.every(elem => "object" === typeof elem && null !== elem && $io1(elem));
|
|
3547
|
-
const $io1 = input => (undefined === input.
|
|
3548
|
-
const $io2 = input =>
|
|
3549
|
-
const $io3 = input =>
|
|
3544
|
+
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)));
|
|
3545
|
+
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));
|
|
3546
|
+
const $io3 = input => Array.isArray(input.balances) && input.balances.every(elem => "object" === typeof elem && null !== elem && $io4(elem));
|
|
3547
|
+
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)));
|
|
3548
|
+
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);
|
|
3549
|
+
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);
|
|
3550
|
+
const $io8 = 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) && $io9(input.socials)) && (undefined === input.offChainTransferabilityInfo || "object" === typeof input.offChainTransferabilityInfo && null !== input.offChainTransferabilityInfo && $io10(input.offChainTransferabilityInfo)) && (undefined === input.attributes || Array.isArray(input.attributes) && input.attributes.every(elem => "object" === typeof elem && null !== elem && $io11(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);
|
|
3551
|
+
const $io9 = input => Object.keys(input).every(key => {
|
|
3550
3552
|
const value = input[key];
|
|
3551
3553
|
if (undefined === value)
|
|
3552
3554
|
return true;
|
|
3553
3555
|
return "string" === typeof value;
|
|
3554
3556
|
});
|
|
3555
|
-
const $
|
|
3556
|
-
const $
|
|
3557
|
-
const $io6 = input => Array.isArray(input.manualBalances) && input.manualBalances.every(elem => "object" === typeof elem && null !== elem && $io7(elem)) && ("object" === typeof input.incrementedBalances && null !== input.incrementedBalances && $io10(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));
|
|
3558
|
-
const $io7 = input => Array.isArray(input.balances) && input.balances.every(elem => "object" === typeof elem && null !== elem && $io8(elem));
|
|
3559
|
-
const $io8 = 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 && $io9(elem))) && (Array.isArray(input.ownershipTimes) && input.ownershipTimes.every(elem => "object" === typeof elem && null !== elem && $io9(elem)));
|
|
3560
|
-
const $io9 = 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);
|
|
3561
|
-
const $io10 = input => Array.isArray(input.startBalances) && input.startBalances.every(elem => "object" === typeof elem && null !== elem && $io8(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);
|
|
3557
|
+
const $io10 = input => "string" === typeof input.host && "string" === typeof input.assignMethod;
|
|
3558
|
+
const $io11 = 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);
|
|
3562
3559
|
const $io12 = input => (undefined === input.resetState || "boolean" === typeof input.resetState) && (undefined === input.newState || "object" === typeof input.newState && null !== input.newState && false === Array.isArray(input.newState) && $io13(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);
|
|
3563
3560
|
const $io13 = input => true;
|
|
3564
3561
|
return "object" === typeof input && null !== input && $io0(input);
|
|
@@ -3584,15 +3581,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3584
3581
|
expected: "Array<CreateClaimRequest<NumberType>>",
|
|
3585
3582
|
value: input.claims
|
|
3586
3583
|
})].every(flag => flag);
|
|
3587
|
-
const $vo1 = (input, _path, _exceptionable = true) => [undefined === input.
|
|
3588
|
-
path: _path + ".metadata",
|
|
3589
|
-
expected: "(iMetadata<NumberType> | undefined)",
|
|
3590
|
-
value: input.metadata
|
|
3591
|
-
})) && $vo2(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
3592
|
-
path: _path + ".metadata",
|
|
3593
|
-
expected: "(iMetadata<NumberType> | undefined)",
|
|
3594
|
-
value: input.metadata
|
|
3595
|
-
}), undefined === input.seedCode || "string" === typeof input.seedCode || $report(_exceptionable, {
|
|
3584
|
+
const $vo1 = (input, _path, _exceptionable = true) => [undefined === input.seedCode || "string" === typeof input.seedCode || $report(_exceptionable, {
|
|
3596
3585
|
path: _path + ".seedCode",
|
|
3597
3586
|
expected: "(string | undefined)",
|
|
3598
3587
|
value: input.seedCode
|
|
@@ -3604,7 +3593,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3604
3593
|
path: _path + ".balancesToSet",
|
|
3605
3594
|
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
3606
3595
|
value: input.balancesToSet
|
|
3607
|
-
})) && $
|
|
3596
|
+
})) && $vo2(input.balancesToSet, _path + ".balancesToSet", true && _exceptionable) || $report(_exceptionable, {
|
|
3608
3597
|
path: _path + ".balancesToSet",
|
|
3609
3598
|
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
3610
3599
|
value: input.balancesToSet
|
|
@@ -3616,6 +3605,14 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3616
3605
|
path: _path + ".approach",
|
|
3617
3606
|
expected: "(string | undefined)",
|
|
3618
3607
|
value: input.approach
|
|
3608
|
+
}), undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
3609
|
+
path: _path + ".metadata",
|
|
3610
|
+
expected: "(iMetadata<NumberType> | undefined)",
|
|
3611
|
+
value: input.metadata
|
|
3612
|
+
})) && $vo8(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
3613
|
+
path: _path + ".metadata",
|
|
3614
|
+
expected: "(iMetadata<NumberType> | undefined)",
|
|
3615
|
+
value: input.metadata
|
|
3619
3616
|
}), undefined === input.assignMethod || "string" === typeof input.assignMethod || $report(_exceptionable, {
|
|
3620
3617
|
path: _path + ".assignMethod",
|
|
3621
3618
|
expected: "(string | undefined)",
|
|
@@ -3649,129 +3646,16 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3649
3646
|
expected: "Array<ManagePluginRequest>",
|
|
3650
3647
|
value: input.plugins
|
|
3651
3648
|
})].every(flag => flag);
|
|
3652
|
-
const $vo2 = (input, _path, _exceptionable = true) => [
|
|
3653
|
-
path: _path + ".name",
|
|
3654
|
-
expected: "string",
|
|
3655
|
-
value: input.name
|
|
3656
|
-
}), "string" === typeof input.description || $report(_exceptionable, {
|
|
3657
|
-
path: _path + ".description",
|
|
3658
|
-
expected: "string",
|
|
3659
|
-
value: input.description
|
|
3660
|
-
}), "string" === typeof input.image || $report(_exceptionable, {
|
|
3661
|
-
path: _path + ".image",
|
|
3662
|
-
expected: "string",
|
|
3663
|
-
value: input.image
|
|
3664
|
-
}), undefined === input.video || "string" === typeof input.video || $report(_exceptionable, {
|
|
3665
|
-
path: _path + ".video",
|
|
3666
|
-
expected: "(string | undefined)",
|
|
3667
|
-
value: input.video
|
|
3668
|
-
}), undefined === input.category || "string" === typeof input.category || $report(_exceptionable, {
|
|
3669
|
-
path: _path + ".category",
|
|
3670
|
-
expected: "(string | undefined)",
|
|
3671
|
-
value: input.category
|
|
3672
|
-
}), undefined === input.externalUrl || "string" === typeof input.externalUrl || $report(_exceptionable, {
|
|
3673
|
-
path: _path + ".externalUrl",
|
|
3674
|
-
expected: "(string | undefined)",
|
|
3675
|
-
value: input.externalUrl
|
|
3676
|
-
}), undefined === input.tags || (Array.isArray(input.tags) || $report(_exceptionable, {
|
|
3677
|
-
path: _path + ".tags",
|
|
3678
|
-
expected: "(Array<string> | undefined)",
|
|
3679
|
-
value: input.tags
|
|
3680
|
-
})) && input.tags.map((elem, _index3) => "string" === typeof elem || $report(_exceptionable, {
|
|
3681
|
-
path: _path + ".tags[" + _index3 + "]",
|
|
3682
|
-
expected: "string",
|
|
3683
|
-
value: elem
|
|
3684
|
-
})).every(flag => flag) || $report(_exceptionable, {
|
|
3685
|
-
path: _path + ".tags",
|
|
3686
|
-
expected: "(Array<string> | undefined)",
|
|
3687
|
-
value: input.tags
|
|
3688
|
-
}), undefined === input.socials || ("object" === typeof input.socials && null !== input.socials && false === Array.isArray(input.socials) || $report(_exceptionable, {
|
|
3689
|
-
path: _path + ".socials",
|
|
3690
|
-
expected: "(__type | undefined)",
|
|
3691
|
-
value: input.socials
|
|
3692
|
-
})) && $vo3(input.socials, _path + ".socials", true && _exceptionable) || $report(_exceptionable, {
|
|
3693
|
-
path: _path + ".socials",
|
|
3694
|
-
expected: "(__type | undefined)",
|
|
3695
|
-
value: input.socials
|
|
3696
|
-
}), undefined === input.offChainTransferabilityInfo || ("object" === typeof input.offChainTransferabilityInfo && null !== input.offChainTransferabilityInfo || $report(_exceptionable, {
|
|
3697
|
-
path: _path + ".offChainTransferabilityInfo",
|
|
3698
|
-
expected: "(__type.o1 | undefined)",
|
|
3699
|
-
value: input.offChainTransferabilityInfo
|
|
3700
|
-
})) && $vo4(input.offChainTransferabilityInfo, _path + ".offChainTransferabilityInfo", true && _exceptionable) || $report(_exceptionable, {
|
|
3701
|
-
path: _path + ".offChainTransferabilityInfo",
|
|
3702
|
-
expected: "(__type.o1 | undefined)",
|
|
3703
|
-
value: input.offChainTransferabilityInfo
|
|
3704
|
-
}), undefined === input.attributes || (Array.isArray(input.attributes) || $report(_exceptionable, {
|
|
3705
|
-
path: _path + ".attributes",
|
|
3706
|
-
expected: "(Array<__type> | undefined)",
|
|
3707
|
-
value: input.attributes
|
|
3708
|
-
})) && input.attributes.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
3709
|
-
path: _path + ".attributes[" + _index4 + "]",
|
|
3710
|
-
expected: "__type.o2",
|
|
3711
|
-
value: elem
|
|
3712
|
-
})) && $vo5(elem, _path + ".attributes[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3713
|
-
path: _path + ".attributes[" + _index4 + "]",
|
|
3714
|
-
expected: "__type.o2",
|
|
3715
|
-
value: elem
|
|
3716
|
-
})).every(flag => flag) || $report(_exceptionable, {
|
|
3717
|
-
path: _path + ".attributes",
|
|
3718
|
-
expected: "(Array<__type> | undefined)",
|
|
3719
|
-
value: input.attributes
|
|
3720
|
-
}), undefined === input.fetchedAtBlock || "string" === typeof input.fetchedAtBlock || "number" === typeof input.fetchedAtBlock || "bigint" === typeof input.fetchedAtBlock || $report(_exceptionable, {
|
|
3721
|
-
path: _path + ".fetchedAtBlock",
|
|
3722
|
-
expected: "(bigint | number | string | undefined)",
|
|
3723
|
-
value: input.fetchedAtBlock
|
|
3724
|
-
}), undefined === input.fetchedAt || "string" === typeof input.fetchedAt || "number" === typeof input.fetchedAt || "bigint" === typeof input.fetchedAt || $report(_exceptionable, {
|
|
3725
|
-
path: _path + ".fetchedAt",
|
|
3726
|
-
expected: "(bigint | number | string | undefined)",
|
|
3727
|
-
value: input.fetchedAt
|
|
3728
|
-
}), undefined === input._isUpdating || "boolean" === typeof input._isUpdating || $report(_exceptionable, {
|
|
3729
|
-
path: _path + "._isUpdating",
|
|
3730
|
-
expected: "(boolean | undefined)",
|
|
3731
|
-
value: input._isUpdating
|
|
3732
|
-
})].every(flag => flag);
|
|
3733
|
-
const $vo3 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
3734
|
-
const value = input[key];
|
|
3735
|
-
if (undefined === value)
|
|
3736
|
-
return true;
|
|
3737
|
-
return "string" === typeof value || $report(_exceptionable, {
|
|
3738
|
-
path: _path + $join(key),
|
|
3739
|
-
expected: "string",
|
|
3740
|
-
value: value
|
|
3741
|
-
});
|
|
3742
|
-
}).every(flag => flag)].every(flag => flag);
|
|
3743
|
-
const $vo4 = (input, _path, _exceptionable = true) => ["string" === typeof input.host || $report(_exceptionable, {
|
|
3744
|
-
path: _path + ".host",
|
|
3745
|
-
expected: "string",
|
|
3746
|
-
value: input.host
|
|
3747
|
-
}), "string" === typeof input.assignMethod || $report(_exceptionable, {
|
|
3748
|
-
path: _path + ".assignMethod",
|
|
3749
|
-
expected: "string",
|
|
3750
|
-
value: input.assignMethod
|
|
3751
|
-
})].every(flag => flag);
|
|
3752
|
-
const $vo5 = (input, _path, _exceptionable = true) => [undefined === input.type || "date" === input.type || "url" === input.type || $report(_exceptionable, {
|
|
3753
|
-
path: _path + ".type",
|
|
3754
|
-
expected: "(\"date\" | \"url\" | undefined)",
|
|
3755
|
-
value: input.type
|
|
3756
|
-
}), "string" === typeof input.name || $report(_exceptionable, {
|
|
3757
|
-
path: _path + ".name",
|
|
3758
|
-
expected: "string",
|
|
3759
|
-
value: input.name
|
|
3760
|
-
}), "string" === typeof input.value || "number" === typeof input.value || "boolean" === typeof input.value || $report(_exceptionable, {
|
|
3761
|
-
path: _path + ".value",
|
|
3762
|
-
expected: "(boolean | number | string)",
|
|
3763
|
-
value: input.value
|
|
3764
|
-
})].every(flag => flag);
|
|
3765
|
-
const $vo6 = (input, _path, _exceptionable = true) => [(Array.isArray(input.manualBalances) || $report(_exceptionable, {
|
|
3649
|
+
const $vo2 = (input, _path, _exceptionable = true) => [(Array.isArray(input.manualBalances) || $report(_exceptionable, {
|
|
3766
3650
|
path: _path + ".manualBalances",
|
|
3767
3651
|
expected: "Array<iManualBalances<NumberType>>",
|
|
3768
3652
|
value: input.manualBalances
|
|
3769
|
-
})) && input.manualBalances.map((elem,
|
|
3770
|
-
path: _path + ".manualBalances[" +
|
|
3653
|
+
})) && input.manualBalances.map((elem, _index3) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
3654
|
+
path: _path + ".manualBalances[" + _index3 + "]",
|
|
3771
3655
|
expected: "iManualBalances<NumberType>",
|
|
3772
3656
|
value: elem
|
|
3773
|
-
})) && $
|
|
3774
|
-
path: _path + ".manualBalances[" +
|
|
3657
|
+
})) && $vo3(elem, _path + ".manualBalances[" + _index3 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3658
|
+
path: _path + ".manualBalances[" + _index3 + "]",
|
|
3775
3659
|
expected: "iManualBalances<NumberType>",
|
|
3776
3660
|
value: elem
|
|
3777
3661
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -3782,7 +3666,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3782
3666
|
path: _path + ".incrementedBalances",
|
|
3783
3667
|
expected: "iIncrementedBalances<NumberType>",
|
|
3784
3668
|
value: input.incrementedBalances
|
|
3785
|
-
})) && $
|
|
3669
|
+
})) && $vo6(input.incrementedBalances, _path + ".incrementedBalances", true && _exceptionable) || $report(_exceptionable, {
|
|
3786
3670
|
path: _path + ".incrementedBalances",
|
|
3787
3671
|
expected: "iIncrementedBalances<NumberType>",
|
|
3788
3672
|
value: input.incrementedBalances
|
|
@@ -3790,21 +3674,21 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3790
3674
|
path: _path + ".orderCalculationMethod",
|
|
3791
3675
|
expected: "iPredeterminedOrderCalculationMethod",
|
|
3792
3676
|
value: input.orderCalculationMethod
|
|
3793
|
-
})) && $
|
|
3677
|
+
})) && $vo7(input.orderCalculationMethod, _path + ".orderCalculationMethod", true && _exceptionable) || $report(_exceptionable, {
|
|
3794
3678
|
path: _path + ".orderCalculationMethod",
|
|
3795
3679
|
expected: "iPredeterminedOrderCalculationMethod",
|
|
3796
3680
|
value: input.orderCalculationMethod
|
|
3797
3681
|
})].every(flag => flag);
|
|
3798
|
-
const $
|
|
3682
|
+
const $vo3 = (input, _path, _exceptionable = true) => [(Array.isArray(input.balances) || $report(_exceptionable, {
|
|
3799
3683
|
path: _path + ".balances",
|
|
3800
3684
|
expected: "Array<iBalance<NumberType>>",
|
|
3801
3685
|
value: input.balances
|
|
3802
|
-
})) && input.balances.map((elem,
|
|
3803
|
-
path: _path + ".balances[" +
|
|
3686
|
+
})) && input.balances.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
3687
|
+
path: _path + ".balances[" + _index4 + "]",
|
|
3804
3688
|
expected: "iBalance<NumberType>",
|
|
3805
3689
|
value: elem
|
|
3806
|
-
})) && $
|
|
3807
|
-
path: _path + ".balances[" +
|
|
3690
|
+
})) && $vo4(elem, _path + ".balances[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3691
|
+
path: _path + ".balances[" + _index4 + "]",
|
|
3808
3692
|
expected: "iBalance<NumberType>",
|
|
3809
3693
|
value: elem
|
|
3810
3694
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -3812,7 +3696,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3812
3696
|
expected: "Array<iBalance<NumberType>>",
|
|
3813
3697
|
value: input.balances
|
|
3814
3698
|
})].every(flag => flag);
|
|
3815
|
-
const $
|
|
3699
|
+
const $vo4 = (input, _path, _exceptionable = true) => ["string" === typeof input.amount || "number" === typeof input.amount || "bigint" === typeof input.amount || $report(_exceptionable, {
|
|
3816
3700
|
path: _path + ".amount",
|
|
3817
3701
|
expected: "(bigint | number | string)",
|
|
3818
3702
|
value: input.amount
|
|
@@ -3820,12 +3704,12 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3820
3704
|
path: _path + ".badgeIds",
|
|
3821
3705
|
expected: "Array<iUintRange<NumberType>>",
|
|
3822
3706
|
value: input.badgeIds
|
|
3823
|
-
})) && input.badgeIds.map((elem,
|
|
3824
|
-
path: _path + ".badgeIds[" +
|
|
3707
|
+
})) && input.badgeIds.map((elem, _index5) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
3708
|
+
path: _path + ".badgeIds[" + _index5 + "]",
|
|
3825
3709
|
expected: "iUintRange<NumberType>",
|
|
3826
3710
|
value: elem
|
|
3827
|
-
})) && $
|
|
3828
|
-
path: _path + ".badgeIds[" +
|
|
3711
|
+
})) && $vo5(elem, _path + ".badgeIds[" + _index5 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3712
|
+
path: _path + ".badgeIds[" + _index5 + "]",
|
|
3829
3713
|
expected: "iUintRange<NumberType>",
|
|
3830
3714
|
value: elem
|
|
3831
3715
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -3836,12 +3720,12 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3836
3720
|
path: _path + ".ownershipTimes",
|
|
3837
3721
|
expected: "Array<iUintRange<NumberType>>",
|
|
3838
3722
|
value: input.ownershipTimes
|
|
3839
|
-
})) && input.ownershipTimes.map((elem,
|
|
3840
|
-
path: _path + ".ownershipTimes[" +
|
|
3723
|
+
})) && input.ownershipTimes.map((elem, _index6) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
3724
|
+
path: _path + ".ownershipTimes[" + _index6 + "]",
|
|
3841
3725
|
expected: "iUintRange<NumberType>",
|
|
3842
3726
|
value: elem
|
|
3843
|
-
})) && $
|
|
3844
|
-
path: _path + ".ownershipTimes[" +
|
|
3727
|
+
})) && $vo5(elem, _path + ".ownershipTimes[" + _index6 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3728
|
+
path: _path + ".ownershipTimes[" + _index6 + "]",
|
|
3845
3729
|
expected: "iUintRange<NumberType>",
|
|
3846
3730
|
value: elem
|
|
3847
3731
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -3849,7 +3733,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3849
3733
|
expected: "Array<iUintRange<NumberType>>",
|
|
3850
3734
|
value: input.ownershipTimes
|
|
3851
3735
|
})].every(flag => flag);
|
|
3852
|
-
const $
|
|
3736
|
+
const $vo5 = (input, _path, _exceptionable = true) => ["string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start || $report(_exceptionable, {
|
|
3853
3737
|
path: _path + ".start",
|
|
3854
3738
|
expected: "(bigint | number | string)",
|
|
3855
3739
|
value: input.start
|
|
@@ -3858,16 +3742,16 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3858
3742
|
expected: "(bigint | number | string)",
|
|
3859
3743
|
value: input.end
|
|
3860
3744
|
})].every(flag => flag);
|
|
3861
|
-
const $
|
|
3745
|
+
const $vo6 = (input, _path, _exceptionable = true) => [(Array.isArray(input.startBalances) || $report(_exceptionable, {
|
|
3862
3746
|
path: _path + ".startBalances",
|
|
3863
3747
|
expected: "Array<iBalance<NumberType>>",
|
|
3864
3748
|
value: input.startBalances
|
|
3865
|
-
})) && input.startBalances.map((elem,
|
|
3866
|
-
path: _path + ".startBalances[" +
|
|
3749
|
+
})) && input.startBalances.map((elem, _index7) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
3750
|
+
path: _path + ".startBalances[" + _index7 + "]",
|
|
3867
3751
|
expected: "iBalance<NumberType>",
|
|
3868
3752
|
value: elem
|
|
3869
|
-
})) && $
|
|
3870
|
-
path: _path + ".startBalances[" +
|
|
3753
|
+
})) && $vo4(elem, _path + ".startBalances[" + _index7 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3754
|
+
path: _path + ".startBalances[" + _index7 + "]",
|
|
3871
3755
|
expected: "iBalance<NumberType>",
|
|
3872
3756
|
value: elem
|
|
3873
3757
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -3883,7 +3767,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3883
3767
|
expected: "(bigint | number | string)",
|
|
3884
3768
|
value: input.incrementOwnershipTimesBy
|
|
3885
3769
|
})].every(flag => flag);
|
|
3886
|
-
const $
|
|
3770
|
+
const $vo7 = (input, _path, _exceptionable = true) => ["boolean" === typeof input.useOverallNumTransfers || $report(_exceptionable, {
|
|
3887
3771
|
path: _path + ".useOverallNumTransfers",
|
|
3888
3772
|
expected: "boolean",
|
|
3889
3773
|
value: input.useOverallNumTransfers
|
|
@@ -3908,6 +3792,119 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
3908
3792
|
expected: "string",
|
|
3909
3793
|
value: input.challengeTrackerId
|
|
3910
3794
|
})].every(flag => flag);
|
|
3795
|
+
const $vo8 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || $report(_exceptionable, {
|
|
3796
|
+
path: _path + ".name",
|
|
3797
|
+
expected: "string",
|
|
3798
|
+
value: input.name
|
|
3799
|
+
}), "string" === typeof input.description || $report(_exceptionable, {
|
|
3800
|
+
path: _path + ".description",
|
|
3801
|
+
expected: "string",
|
|
3802
|
+
value: input.description
|
|
3803
|
+
}), "string" === typeof input.image || $report(_exceptionable, {
|
|
3804
|
+
path: _path + ".image",
|
|
3805
|
+
expected: "string",
|
|
3806
|
+
value: input.image
|
|
3807
|
+
}), undefined === input.video || "string" === typeof input.video || $report(_exceptionable, {
|
|
3808
|
+
path: _path + ".video",
|
|
3809
|
+
expected: "(string | undefined)",
|
|
3810
|
+
value: input.video
|
|
3811
|
+
}), undefined === input.category || "string" === typeof input.category || $report(_exceptionable, {
|
|
3812
|
+
path: _path + ".category",
|
|
3813
|
+
expected: "(string | undefined)",
|
|
3814
|
+
value: input.category
|
|
3815
|
+
}), undefined === input.externalUrl || "string" === typeof input.externalUrl || $report(_exceptionable, {
|
|
3816
|
+
path: _path + ".externalUrl",
|
|
3817
|
+
expected: "(string | undefined)",
|
|
3818
|
+
value: input.externalUrl
|
|
3819
|
+
}), undefined === input.tags || (Array.isArray(input.tags) || $report(_exceptionable, {
|
|
3820
|
+
path: _path + ".tags",
|
|
3821
|
+
expected: "(Array<string> | undefined)",
|
|
3822
|
+
value: input.tags
|
|
3823
|
+
})) && input.tags.map((elem, _index8) => "string" === typeof elem || $report(_exceptionable, {
|
|
3824
|
+
path: _path + ".tags[" + _index8 + "]",
|
|
3825
|
+
expected: "string",
|
|
3826
|
+
value: elem
|
|
3827
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
3828
|
+
path: _path + ".tags",
|
|
3829
|
+
expected: "(Array<string> | undefined)",
|
|
3830
|
+
value: input.tags
|
|
3831
|
+
}), undefined === input.socials || ("object" === typeof input.socials && null !== input.socials && false === Array.isArray(input.socials) || $report(_exceptionable, {
|
|
3832
|
+
path: _path + ".socials",
|
|
3833
|
+
expected: "(__type | undefined)",
|
|
3834
|
+
value: input.socials
|
|
3835
|
+
})) && $vo9(input.socials, _path + ".socials", true && _exceptionable) || $report(_exceptionable, {
|
|
3836
|
+
path: _path + ".socials",
|
|
3837
|
+
expected: "(__type | undefined)",
|
|
3838
|
+
value: input.socials
|
|
3839
|
+
}), undefined === input.offChainTransferabilityInfo || ("object" === typeof input.offChainTransferabilityInfo && null !== input.offChainTransferabilityInfo || $report(_exceptionable, {
|
|
3840
|
+
path: _path + ".offChainTransferabilityInfo",
|
|
3841
|
+
expected: "(__type.o1 | undefined)",
|
|
3842
|
+
value: input.offChainTransferabilityInfo
|
|
3843
|
+
})) && $vo10(input.offChainTransferabilityInfo, _path + ".offChainTransferabilityInfo", true && _exceptionable) || $report(_exceptionable, {
|
|
3844
|
+
path: _path + ".offChainTransferabilityInfo",
|
|
3845
|
+
expected: "(__type.o1 | undefined)",
|
|
3846
|
+
value: input.offChainTransferabilityInfo
|
|
3847
|
+
}), undefined === input.attributes || (Array.isArray(input.attributes) || $report(_exceptionable, {
|
|
3848
|
+
path: _path + ".attributes",
|
|
3849
|
+
expected: "(Array<__type> | undefined)",
|
|
3850
|
+
value: input.attributes
|
|
3851
|
+
})) && input.attributes.map((elem, _index9) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
3852
|
+
path: _path + ".attributes[" + _index9 + "]",
|
|
3853
|
+
expected: "__type.o2",
|
|
3854
|
+
value: elem
|
|
3855
|
+
})) && $vo11(elem, _path + ".attributes[" + _index9 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
3856
|
+
path: _path + ".attributes[" + _index9 + "]",
|
|
3857
|
+
expected: "__type.o2",
|
|
3858
|
+
value: elem
|
|
3859
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
3860
|
+
path: _path + ".attributes",
|
|
3861
|
+
expected: "(Array<__type> | undefined)",
|
|
3862
|
+
value: input.attributes
|
|
3863
|
+
}), undefined === input.fetchedAtBlock || "string" === typeof input.fetchedAtBlock || "number" === typeof input.fetchedAtBlock || "bigint" === typeof input.fetchedAtBlock || $report(_exceptionable, {
|
|
3864
|
+
path: _path + ".fetchedAtBlock",
|
|
3865
|
+
expected: "(bigint | number | string | undefined)",
|
|
3866
|
+
value: input.fetchedAtBlock
|
|
3867
|
+
}), undefined === input.fetchedAt || "string" === typeof input.fetchedAt || "number" === typeof input.fetchedAt || "bigint" === typeof input.fetchedAt || $report(_exceptionable, {
|
|
3868
|
+
path: _path + ".fetchedAt",
|
|
3869
|
+
expected: "(bigint | number | string | undefined)",
|
|
3870
|
+
value: input.fetchedAt
|
|
3871
|
+
}), undefined === input._isUpdating || "boolean" === typeof input._isUpdating || $report(_exceptionable, {
|
|
3872
|
+
path: _path + "._isUpdating",
|
|
3873
|
+
expected: "(boolean | undefined)",
|
|
3874
|
+
value: input._isUpdating
|
|
3875
|
+
})].every(flag => flag);
|
|
3876
|
+
const $vo9 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
3877
|
+
const value = input[key];
|
|
3878
|
+
if (undefined === value)
|
|
3879
|
+
return true;
|
|
3880
|
+
return "string" === typeof value || $report(_exceptionable, {
|
|
3881
|
+
path: _path + $join(key),
|
|
3882
|
+
expected: "string",
|
|
3883
|
+
value: value
|
|
3884
|
+
});
|
|
3885
|
+
}).every(flag => flag)].every(flag => flag);
|
|
3886
|
+
const $vo10 = (input, _path, _exceptionable = true) => ["string" === typeof input.host || $report(_exceptionable, {
|
|
3887
|
+
path: _path + ".host",
|
|
3888
|
+
expected: "string",
|
|
3889
|
+
value: input.host
|
|
3890
|
+
}), "string" === typeof input.assignMethod || $report(_exceptionable, {
|
|
3891
|
+
path: _path + ".assignMethod",
|
|
3892
|
+
expected: "string",
|
|
3893
|
+
value: input.assignMethod
|
|
3894
|
+
})].every(flag => flag);
|
|
3895
|
+
const $vo11 = (input, _path, _exceptionable = true) => [undefined === input.type || "date" === input.type || "url" === input.type || $report(_exceptionable, {
|
|
3896
|
+
path: _path + ".type",
|
|
3897
|
+
expected: "(\"date\" | \"url\" | undefined)",
|
|
3898
|
+
value: input.type
|
|
3899
|
+
}), "string" === typeof input.name || $report(_exceptionable, {
|
|
3900
|
+
path: _path + ".name",
|
|
3901
|
+
expected: "string",
|
|
3902
|
+
value: input.name
|
|
3903
|
+
}), "string" === typeof input.value || "number" === typeof input.value || "boolean" === typeof input.value || $report(_exceptionable, {
|
|
3904
|
+
path: _path + ".value",
|
|
3905
|
+
expected: "(boolean | number | string)",
|
|
3906
|
+
value: input.value
|
|
3907
|
+
})].every(flag => flag);
|
|
3911
3908
|
const $vo12 = (input, _path, _exceptionable = true) => [undefined === input.resetState || "boolean" === typeof input.resetState || $report(_exceptionable, {
|
|
3912
3909
|
path: _path + ".resetState",
|
|
3913
3910
|
expected: "(boolean | undefined)",
|
|
@@ -4040,23 +4037,23 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4040
4037
|
const errors = [];
|
|
4041
4038
|
const __is = input => {
|
|
4042
4039
|
const $io0 = input => Array.isArray(input.claims) && input.claims.every(elem => "object" === typeof elem && null !== elem && $io1(elem));
|
|
4043
|
-
const $io1 = input =>
|
|
4044
|
-
const $io2 = input =>
|
|
4045
|
-
const $io3 = input =>
|
|
4040
|
+
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);
|
|
4041
|
+
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));
|
|
4042
|
+
const $io3 = input => Array.isArray(input.balances) && input.balances.every(elem => "object" === typeof elem && null !== elem && $io4(elem));
|
|
4043
|
+
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)));
|
|
4044
|
+
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);
|
|
4045
|
+
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);
|
|
4046
|
+
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);
|
|
4047
|
+
const $io9 = input => true;
|
|
4048
|
+
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);
|
|
4049
|
+
const $io11 = input => Object.keys(input).every(key => {
|
|
4046
4050
|
const value = input[key];
|
|
4047
4051
|
if (undefined === value)
|
|
4048
4052
|
return true;
|
|
4049
4053
|
return "string" === typeof value;
|
|
4050
4054
|
});
|
|
4051
|
-
const $
|
|
4052
|
-
const $
|
|
4053
|
-
const $io6 = input => Array.isArray(input.manualBalances) && input.manualBalances.every(elem => "object" === typeof elem && null !== elem && $io7(elem)) && ("object" === typeof input.incrementedBalances && null !== input.incrementedBalances && $io10(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));
|
|
4054
|
-
const $io7 = input => Array.isArray(input.balances) && input.balances.every(elem => "object" === typeof elem && null !== elem && $io8(elem));
|
|
4055
|
-
const $io8 = 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 && $io9(elem))) && (Array.isArray(input.ownershipTimes) && input.ownershipTimes.every(elem => "object" === typeof elem && null !== elem && $io9(elem)));
|
|
4056
|
-
const $io9 = 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);
|
|
4057
|
-
const $io10 = input => Array.isArray(input.startBalances) && input.startBalances.every(elem => "object" === typeof elem && null !== elem && $io8(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);
|
|
4058
|
-
const $io12 = input => "object" === typeof input.publicState && null !== input.publicState && true && (undefined === input.privateState || "object" === typeof input.privateState && null !== input.privateState && false === Array.isArray(input.privateState) && $io13(input.privateState)) && (undefined === input.resetState || "boolean" === typeof input.resetState) && (undefined === input.newState || "object" === typeof input.newState && null !== input.newState && false === Array.isArray(input.newState) && $io13(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);
|
|
4059
|
-
const $io13 = input => true;
|
|
4055
|
+
const $io12 = input => "string" === typeof input.host && "string" === typeof input.assignMethod;
|
|
4056
|
+
const $io13 = 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);
|
|
4060
4057
|
return "object" === typeof input && null !== input && $io0(input);
|
|
4061
4058
|
};
|
|
4062
4059
|
if (false === __is(input)) {
|
|
@@ -4080,15 +4077,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4080
4077
|
expected: "Array<Omit<iClaimDetails<NumberType>, \"seedCode\">>",
|
|
4081
4078
|
value: input.claims
|
|
4082
4079
|
})].every(flag => flag);
|
|
4083
|
-
const $vo1 = (input, _path, _exceptionable = true) => [
|
|
4084
|
-
path: _path + ".metadata",
|
|
4085
|
-
expected: "(iMetadata<NumberType> | undefined)",
|
|
4086
|
-
value: input.metadata
|
|
4087
|
-
})) && $vo2(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
4088
|
-
path: _path + ".metadata",
|
|
4089
|
-
expected: "(iMetadata<NumberType> | undefined)",
|
|
4090
|
-
value: input.metadata
|
|
4091
|
-
}), "string" === typeof input.claimId || $report(_exceptionable, {
|
|
4080
|
+
const $vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.claimId || $report(_exceptionable, {
|
|
4092
4081
|
path: _path + ".claimId",
|
|
4093
4082
|
expected: "string",
|
|
4094
4083
|
value: input.claimId
|
|
@@ -4096,7 +4085,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4096
4085
|
path: _path + ".balancesToSet",
|
|
4097
4086
|
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
4098
4087
|
value: input.balancesToSet
|
|
4099
|
-
})) && $
|
|
4088
|
+
})) && $vo2(input.balancesToSet, _path + ".balancesToSet", true && _exceptionable) || $report(_exceptionable, {
|
|
4100
4089
|
path: _path + ".balancesToSet",
|
|
4101
4090
|
expected: "(iPredeterminedBalances<NumberType> | undefined)",
|
|
4102
4091
|
value: input.balancesToSet
|
|
@@ -4105,153 +4094,48 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4105
4094
|
expected: "Array<IntegrationPluginDetails<string>>",
|
|
4106
4095
|
value: input.plugins
|
|
4107
4096
|
})) && input.plugins.map((elem, _index2) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4108
|
-
path: _path + ".plugins[" + _index2 + "]",
|
|
4109
|
-
expected: "IntegrationPluginDetails<string>",
|
|
4110
|
-
value: elem
|
|
4111
|
-
})) && $
|
|
4112
|
-
path: _path + ".plugins[" + _index2 + "]",
|
|
4113
|
-
expected: "IntegrationPluginDetails<string>",
|
|
4114
|
-
value: elem
|
|
4115
|
-
})).every(flag => flag) || $report(_exceptionable, {
|
|
4116
|
-
path: _path + ".plugins",
|
|
4117
|
-
expected: "Array<IntegrationPluginDetails<string>>",
|
|
4118
|
-
value: input.plugins
|
|
4119
|
-
}), undefined === input.manualDistribution || "boolean" === typeof input.manualDistribution || $report(_exceptionable, {
|
|
4120
|
-
path: _path + ".manualDistribution",
|
|
4121
|
-
expected: "(boolean | undefined)",
|
|
4122
|
-
value: input.manualDistribution
|
|
4123
|
-
}), undefined === input.approach || "string" === typeof input.approach || $report(_exceptionable, {
|
|
4124
|
-
path: _path + ".approach",
|
|
4125
|
-
expected: "(string | undefined)",
|
|
4126
|
-
value: input.approach
|
|
4127
|
-
}), undefined === input.
|
|
4128
|
-
path: _path + ".
|
|
4129
|
-
expected: "(
|
|
4130
|
-
value: input.
|
|
4131
|
-
})
|
|
4132
|
-
|
|
4133
|
-
|
|
4134
|
-
|
|
4135
|
-
|
|
4136
|
-
}), "string" === typeof input.description || $report(_exceptionable, {
|
|
4137
|
-
path: _path + ".description",
|
|
4138
|
-
expected: "string",
|
|
4139
|
-
value: input.description
|
|
4140
|
-
}), "string" === typeof input.image || $report(_exceptionable, {
|
|
4141
|
-
path: _path + ".image",
|
|
4142
|
-
expected: "string",
|
|
4143
|
-
value: input.image
|
|
4144
|
-
}), undefined === input.video || "string" === typeof input.video || $report(_exceptionable, {
|
|
4145
|
-
path: _path + ".video",
|
|
4146
|
-
expected: "(string | undefined)",
|
|
4147
|
-
value: input.video
|
|
4148
|
-
}), undefined === input.category || "string" === typeof input.category || $report(_exceptionable, {
|
|
4149
|
-
path: _path + ".category",
|
|
4150
|
-
expected: "(string | undefined)",
|
|
4151
|
-
value: input.category
|
|
4152
|
-
}), undefined === input.externalUrl || "string" === typeof input.externalUrl || $report(_exceptionable, {
|
|
4153
|
-
path: _path + ".externalUrl",
|
|
4154
|
-
expected: "(string | undefined)",
|
|
4155
|
-
value: input.externalUrl
|
|
4156
|
-
}), undefined === input.tags || (Array.isArray(input.tags) || $report(_exceptionable, {
|
|
4157
|
-
path: _path + ".tags",
|
|
4158
|
-
expected: "(Array<string> | undefined)",
|
|
4159
|
-
value: input.tags
|
|
4160
|
-
})) && input.tags.map((elem, _index3) => "string" === typeof elem || $report(_exceptionable, {
|
|
4161
|
-
path: _path + ".tags[" + _index3 + "]",
|
|
4162
|
-
expected: "string",
|
|
4163
|
-
value: elem
|
|
4164
|
-
})).every(flag => flag) || $report(_exceptionable, {
|
|
4165
|
-
path: _path + ".tags",
|
|
4166
|
-
expected: "(Array<string> | undefined)",
|
|
4167
|
-
value: input.tags
|
|
4168
|
-
}), undefined === input.socials || ("object" === typeof input.socials && null !== input.socials && false === Array.isArray(input.socials) || $report(_exceptionable, {
|
|
4169
|
-
path: _path + ".socials",
|
|
4170
|
-
expected: "(__type | undefined)",
|
|
4171
|
-
value: input.socials
|
|
4172
|
-
})) && $vo3(input.socials, _path + ".socials", true && _exceptionable) || $report(_exceptionable, {
|
|
4173
|
-
path: _path + ".socials",
|
|
4174
|
-
expected: "(__type | undefined)",
|
|
4175
|
-
value: input.socials
|
|
4176
|
-
}), undefined === input.offChainTransferabilityInfo || ("object" === typeof input.offChainTransferabilityInfo && null !== input.offChainTransferabilityInfo || $report(_exceptionable, {
|
|
4177
|
-
path: _path + ".offChainTransferabilityInfo",
|
|
4178
|
-
expected: "(__type.o1 | undefined)",
|
|
4179
|
-
value: input.offChainTransferabilityInfo
|
|
4180
|
-
})) && $vo4(input.offChainTransferabilityInfo, _path + ".offChainTransferabilityInfo", true && _exceptionable) || $report(_exceptionable, {
|
|
4181
|
-
path: _path + ".offChainTransferabilityInfo",
|
|
4182
|
-
expected: "(__type.o1 | undefined)",
|
|
4183
|
-
value: input.offChainTransferabilityInfo
|
|
4184
|
-
}), undefined === input.attributes || (Array.isArray(input.attributes) || $report(_exceptionable, {
|
|
4185
|
-
path: _path + ".attributes",
|
|
4186
|
-
expected: "(Array<__type> | undefined)",
|
|
4187
|
-
value: input.attributes
|
|
4188
|
-
})) && input.attributes.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4189
|
-
path: _path + ".attributes[" + _index4 + "]",
|
|
4190
|
-
expected: "__type.o2",
|
|
4191
|
-
value: elem
|
|
4192
|
-
})) && $vo5(elem, _path + ".attributes[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4193
|
-
path: _path + ".attributes[" + _index4 + "]",
|
|
4194
|
-
expected: "__type.o2",
|
|
4195
|
-
value: elem
|
|
4196
|
-
})).every(flag => flag) || $report(_exceptionable, {
|
|
4197
|
-
path: _path + ".attributes",
|
|
4198
|
-
expected: "(Array<__type> | undefined)",
|
|
4199
|
-
value: input.attributes
|
|
4200
|
-
}), undefined === input.fetchedAtBlock || "string" === typeof input.fetchedAtBlock || "number" === typeof input.fetchedAtBlock || "bigint" === typeof input.fetchedAtBlock || $report(_exceptionable, {
|
|
4201
|
-
path: _path + ".fetchedAtBlock",
|
|
4202
|
-
expected: "(bigint | number | string | undefined)",
|
|
4203
|
-
value: input.fetchedAtBlock
|
|
4204
|
-
}), undefined === input.fetchedAt || "string" === typeof input.fetchedAt || "number" === typeof input.fetchedAt || "bigint" === typeof input.fetchedAt || $report(_exceptionable, {
|
|
4205
|
-
path: _path + ".fetchedAt",
|
|
4206
|
-
expected: "(bigint | number | string | undefined)",
|
|
4207
|
-
value: input.fetchedAt
|
|
4208
|
-
}), undefined === input._isUpdating || "boolean" === typeof input._isUpdating || $report(_exceptionable, {
|
|
4209
|
-
path: _path + "._isUpdating",
|
|
4210
|
-
expected: "(boolean | undefined)",
|
|
4211
|
-
value: input._isUpdating
|
|
4212
|
-
})].every(flag => flag);
|
|
4213
|
-
const $vo3 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
4214
|
-
const value = input[key];
|
|
4215
|
-
if (undefined === value)
|
|
4216
|
-
return true;
|
|
4217
|
-
return "string" === typeof value || $report(_exceptionable, {
|
|
4218
|
-
path: _path + $join(key),
|
|
4219
|
-
expected: "string",
|
|
4220
|
-
value: value
|
|
4221
|
-
});
|
|
4222
|
-
}).every(flag => flag)].every(flag => flag);
|
|
4223
|
-
const $vo4 = (input, _path, _exceptionable = true) => ["string" === typeof input.host || $report(_exceptionable, {
|
|
4224
|
-
path: _path + ".host",
|
|
4225
|
-
expected: "string",
|
|
4226
|
-
value: input.host
|
|
4227
|
-
}), "string" === typeof input.assignMethod || $report(_exceptionable, {
|
|
4097
|
+
path: _path + ".plugins[" + _index2 + "]",
|
|
4098
|
+
expected: "IntegrationPluginDetails<string>",
|
|
4099
|
+
value: elem
|
|
4100
|
+
})) && $vo8(elem, _path + ".plugins[" + _index2 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4101
|
+
path: _path + ".plugins[" + _index2 + "]",
|
|
4102
|
+
expected: "IntegrationPluginDetails<string>",
|
|
4103
|
+
value: elem
|
|
4104
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
4105
|
+
path: _path + ".plugins",
|
|
4106
|
+
expected: "Array<IntegrationPluginDetails<string>>",
|
|
4107
|
+
value: input.plugins
|
|
4108
|
+
}), undefined === input.manualDistribution || "boolean" === typeof input.manualDistribution || $report(_exceptionable, {
|
|
4109
|
+
path: _path + ".manualDistribution",
|
|
4110
|
+
expected: "(boolean | undefined)",
|
|
4111
|
+
value: input.manualDistribution
|
|
4112
|
+
}), undefined === input.approach || "string" === typeof input.approach || $report(_exceptionable, {
|
|
4113
|
+
path: _path + ".approach",
|
|
4114
|
+
expected: "(string | undefined)",
|
|
4115
|
+
value: input.approach
|
|
4116
|
+
}), undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
4117
|
+
path: _path + ".metadata",
|
|
4118
|
+
expected: "(iMetadata<NumberType> | undefined)",
|
|
4119
|
+
value: input.metadata
|
|
4120
|
+
})) && $vo10(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
4121
|
+
path: _path + ".metadata",
|
|
4122
|
+
expected: "(iMetadata<NumberType> | undefined)",
|
|
4123
|
+
value: input.metadata
|
|
4124
|
+
}), undefined === input.assignMethod || "string" === typeof input.assignMethod || $report(_exceptionable, {
|
|
4228
4125
|
path: _path + ".assignMethod",
|
|
4229
|
-
expected: "string",
|
|
4126
|
+
expected: "(string | undefined)",
|
|
4230
4127
|
value: input.assignMethod
|
|
4231
4128
|
})].every(flag => flag);
|
|
4232
|
-
const $
|
|
4233
|
-
path: _path + ".type",
|
|
4234
|
-
expected: "(\"date\" | \"url\" | undefined)",
|
|
4235
|
-
value: input.type
|
|
4236
|
-
}), "string" === typeof input.name || $report(_exceptionable, {
|
|
4237
|
-
path: _path + ".name",
|
|
4238
|
-
expected: "string",
|
|
4239
|
-
value: input.name
|
|
4240
|
-
}), "string" === typeof input.value || "number" === typeof input.value || "boolean" === typeof input.value || $report(_exceptionable, {
|
|
4241
|
-
path: _path + ".value",
|
|
4242
|
-
expected: "(boolean | number | string)",
|
|
4243
|
-
value: input.value
|
|
4244
|
-
})].every(flag => flag);
|
|
4245
|
-
const $vo6 = (input, _path, _exceptionable = true) => [(Array.isArray(input.manualBalances) || $report(_exceptionable, {
|
|
4129
|
+
const $vo2 = (input, _path, _exceptionable = true) => [(Array.isArray(input.manualBalances) || $report(_exceptionable, {
|
|
4246
4130
|
path: _path + ".manualBalances",
|
|
4247
4131
|
expected: "Array<iManualBalances<NumberType>>",
|
|
4248
4132
|
value: input.manualBalances
|
|
4249
|
-
})) && input.manualBalances.map((elem,
|
|
4250
|
-
path: _path + ".manualBalances[" +
|
|
4133
|
+
})) && input.manualBalances.map((elem, _index3) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4134
|
+
path: _path + ".manualBalances[" + _index3 + "]",
|
|
4251
4135
|
expected: "iManualBalances<NumberType>",
|
|
4252
4136
|
value: elem
|
|
4253
|
-
})) && $
|
|
4254
|
-
path: _path + ".manualBalances[" +
|
|
4137
|
+
})) && $vo3(elem, _path + ".manualBalances[" + _index3 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4138
|
+
path: _path + ".manualBalances[" + _index3 + "]",
|
|
4255
4139
|
expected: "iManualBalances<NumberType>",
|
|
4256
4140
|
value: elem
|
|
4257
4141
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -4262,7 +4146,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4262
4146
|
path: _path + ".incrementedBalances",
|
|
4263
4147
|
expected: "iIncrementedBalances<NumberType>",
|
|
4264
4148
|
value: input.incrementedBalances
|
|
4265
|
-
})) && $
|
|
4149
|
+
})) && $vo6(input.incrementedBalances, _path + ".incrementedBalances", true && _exceptionable) || $report(_exceptionable, {
|
|
4266
4150
|
path: _path + ".incrementedBalances",
|
|
4267
4151
|
expected: "iIncrementedBalances<NumberType>",
|
|
4268
4152
|
value: input.incrementedBalances
|
|
@@ -4270,21 +4154,21 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4270
4154
|
path: _path + ".orderCalculationMethod",
|
|
4271
4155
|
expected: "iPredeterminedOrderCalculationMethod",
|
|
4272
4156
|
value: input.orderCalculationMethod
|
|
4273
|
-
})) && $
|
|
4157
|
+
})) && $vo7(input.orderCalculationMethod, _path + ".orderCalculationMethod", true && _exceptionable) || $report(_exceptionable, {
|
|
4274
4158
|
path: _path + ".orderCalculationMethod",
|
|
4275
4159
|
expected: "iPredeterminedOrderCalculationMethod",
|
|
4276
4160
|
value: input.orderCalculationMethod
|
|
4277
4161
|
})].every(flag => flag);
|
|
4278
|
-
const $
|
|
4162
|
+
const $vo3 = (input, _path, _exceptionable = true) => [(Array.isArray(input.balances) || $report(_exceptionable, {
|
|
4279
4163
|
path: _path + ".balances",
|
|
4280
4164
|
expected: "Array<iBalance<NumberType>>",
|
|
4281
4165
|
value: input.balances
|
|
4282
|
-
})) && input.balances.map((elem,
|
|
4283
|
-
path: _path + ".balances[" +
|
|
4166
|
+
})) && input.balances.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4167
|
+
path: _path + ".balances[" + _index4 + "]",
|
|
4284
4168
|
expected: "iBalance<NumberType>",
|
|
4285
4169
|
value: elem
|
|
4286
|
-
})) && $
|
|
4287
|
-
path: _path + ".balances[" +
|
|
4170
|
+
})) && $vo4(elem, _path + ".balances[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4171
|
+
path: _path + ".balances[" + _index4 + "]",
|
|
4288
4172
|
expected: "iBalance<NumberType>",
|
|
4289
4173
|
value: elem
|
|
4290
4174
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -4292,7 +4176,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4292
4176
|
expected: "Array<iBalance<NumberType>>",
|
|
4293
4177
|
value: input.balances
|
|
4294
4178
|
})].every(flag => flag);
|
|
4295
|
-
const $
|
|
4179
|
+
const $vo4 = (input, _path, _exceptionable = true) => ["string" === typeof input.amount || "number" === typeof input.amount || "bigint" === typeof input.amount || $report(_exceptionable, {
|
|
4296
4180
|
path: _path + ".amount",
|
|
4297
4181
|
expected: "(bigint | number | string)",
|
|
4298
4182
|
value: input.amount
|
|
@@ -4300,12 +4184,12 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4300
4184
|
path: _path + ".badgeIds",
|
|
4301
4185
|
expected: "Array<iUintRange<NumberType>>",
|
|
4302
4186
|
value: input.badgeIds
|
|
4303
|
-
})) && input.badgeIds.map((elem,
|
|
4304
|
-
path: _path + ".badgeIds[" +
|
|
4187
|
+
})) && input.badgeIds.map((elem, _index5) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4188
|
+
path: _path + ".badgeIds[" + _index5 + "]",
|
|
4305
4189
|
expected: "iUintRange<NumberType>",
|
|
4306
4190
|
value: elem
|
|
4307
|
-
})) && $
|
|
4308
|
-
path: _path + ".badgeIds[" +
|
|
4191
|
+
})) && $vo5(elem, _path + ".badgeIds[" + _index5 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4192
|
+
path: _path + ".badgeIds[" + _index5 + "]",
|
|
4309
4193
|
expected: "iUintRange<NumberType>",
|
|
4310
4194
|
value: elem
|
|
4311
4195
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -4316,12 +4200,12 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4316
4200
|
path: _path + ".ownershipTimes",
|
|
4317
4201
|
expected: "Array<iUintRange<NumberType>>",
|
|
4318
4202
|
value: input.ownershipTimes
|
|
4319
|
-
})) && input.ownershipTimes.map((elem,
|
|
4320
|
-
path: _path + ".ownershipTimes[" +
|
|
4203
|
+
})) && input.ownershipTimes.map((elem, _index6) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4204
|
+
path: _path + ".ownershipTimes[" + _index6 + "]",
|
|
4321
4205
|
expected: "iUintRange<NumberType>",
|
|
4322
4206
|
value: elem
|
|
4323
|
-
})) && $
|
|
4324
|
-
path: _path + ".ownershipTimes[" +
|
|
4207
|
+
})) && $vo5(elem, _path + ".ownershipTimes[" + _index6 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4208
|
+
path: _path + ".ownershipTimes[" + _index6 + "]",
|
|
4325
4209
|
expected: "iUintRange<NumberType>",
|
|
4326
4210
|
value: elem
|
|
4327
4211
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -4329,7 +4213,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4329
4213
|
expected: "Array<iUintRange<NumberType>>",
|
|
4330
4214
|
value: input.ownershipTimes
|
|
4331
4215
|
})].every(flag => flag);
|
|
4332
|
-
const $
|
|
4216
|
+
const $vo5 = (input, _path, _exceptionable = true) => ["string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start || $report(_exceptionable, {
|
|
4333
4217
|
path: _path + ".start",
|
|
4334
4218
|
expected: "(bigint | number | string)",
|
|
4335
4219
|
value: input.start
|
|
@@ -4338,16 +4222,16 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4338
4222
|
expected: "(bigint | number | string)",
|
|
4339
4223
|
value: input.end
|
|
4340
4224
|
})].every(flag => flag);
|
|
4341
|
-
const $
|
|
4225
|
+
const $vo6 = (input, _path, _exceptionable = true) => [(Array.isArray(input.startBalances) || $report(_exceptionable, {
|
|
4342
4226
|
path: _path + ".startBalances",
|
|
4343
4227
|
expected: "Array<iBalance<NumberType>>",
|
|
4344
4228
|
value: input.startBalances
|
|
4345
|
-
})) && input.startBalances.map((elem,
|
|
4346
|
-
path: _path + ".startBalances[" +
|
|
4229
|
+
})) && input.startBalances.map((elem, _index7) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4230
|
+
path: _path + ".startBalances[" + _index7 + "]",
|
|
4347
4231
|
expected: "iBalance<NumberType>",
|
|
4348
4232
|
value: elem
|
|
4349
|
-
})) && $
|
|
4350
|
-
path: _path + ".startBalances[" +
|
|
4233
|
+
})) && $vo4(elem, _path + ".startBalances[" + _index7 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4234
|
+
path: _path + ".startBalances[" + _index7 + "]",
|
|
4351
4235
|
expected: "iBalance<NumberType>",
|
|
4352
4236
|
value: elem
|
|
4353
4237
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -4363,7 +4247,7 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4363
4247
|
expected: "(bigint | number | string)",
|
|
4364
4248
|
value: input.incrementOwnershipTimesBy
|
|
4365
4249
|
})].every(flag => flag);
|
|
4366
|
-
const $
|
|
4250
|
+
const $vo7 = (input, _path, _exceptionable = true) => ["boolean" === typeof input.useOverallNumTransfers || $report(_exceptionable, {
|
|
4367
4251
|
path: _path + ".useOverallNumTransfers",
|
|
4368
4252
|
expected: "boolean",
|
|
4369
4253
|
value: input.useOverallNumTransfers
|
|
@@ -4388,21 +4272,21 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4388
4272
|
expected: "string",
|
|
4389
4273
|
value: input.challengeTrackerId
|
|
4390
4274
|
})].every(flag => flag);
|
|
4391
|
-
const $
|
|
4275
|
+
const $vo8 = (input, _path, _exceptionable = true) => [("object" === typeof input.publicState && null !== input.publicState && false === Array.isArray(input.publicState) || $report(_exceptionable, {
|
|
4392
4276
|
path: _path + ".publicState",
|
|
4393
|
-
expected: "__type
|
|
4277
|
+
expected: "__type",
|
|
4394
4278
|
value: input.publicState
|
|
4395
|
-
})) && $
|
|
4279
|
+
})) && $vo9(input.publicState, _path + ".publicState", true && _exceptionable) || $report(_exceptionable, {
|
|
4396
4280
|
path: _path + ".publicState",
|
|
4397
|
-
expected: "__type
|
|
4281
|
+
expected: "__type",
|
|
4398
4282
|
value: input.publicState
|
|
4399
4283
|
}), undefined === input.privateState || ("object" === typeof input.privateState && null !== input.privateState && false === Array.isArray(input.privateState) || $report(_exceptionable, {
|
|
4400
4284
|
path: _path + ".privateState",
|
|
4401
|
-
expected: "(__type
|
|
4285
|
+
expected: "(__type | undefined)",
|
|
4402
4286
|
value: input.privateState
|
|
4403
|
-
})) && $
|
|
4287
|
+
})) && $vo9(input.privateState, _path + ".privateState", true && _exceptionable) || $report(_exceptionable, {
|
|
4404
4288
|
path: _path + ".privateState",
|
|
4405
|
-
expected: "(__type
|
|
4289
|
+
expected: "(__type | undefined)",
|
|
4406
4290
|
value: input.privateState
|
|
4407
4291
|
}), undefined === input.resetState || "boolean" === typeof input.resetState || $report(_exceptionable, {
|
|
4408
4292
|
path: _path + ".resetState",
|
|
@@ -4410,11 +4294,11 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4410
4294
|
value: input.resetState
|
|
4411
4295
|
}), undefined === input.newState || ("object" === typeof input.newState && null !== input.newState && false === Array.isArray(input.newState) || $report(_exceptionable, {
|
|
4412
4296
|
path: _path + ".newState",
|
|
4413
|
-
expected: "(__type
|
|
4297
|
+
expected: "(__type | undefined)",
|
|
4414
4298
|
value: input.newState
|
|
4415
|
-
})) && $
|
|
4299
|
+
})) && $vo9(input.newState, _path + ".newState", true && _exceptionable) || $report(_exceptionable, {
|
|
4416
4300
|
path: _path + ".newState",
|
|
4417
|
-
expected: "(__type
|
|
4301
|
+
expected: "(__type | undefined)",
|
|
4418
4302
|
value: input.newState
|
|
4419
4303
|
}), undefined === input.onlyUpdateProvidedNewState || "boolean" === typeof input.onlyUpdateProvidedNewState || $report(_exceptionable, {
|
|
4420
4304
|
path: _path + ".onlyUpdateProvidedNewState",
|
|
@@ -4430,22 +4314,135 @@ class BitBadgesAPI extends base_1.BaseBitBadgesApi {
|
|
|
4430
4314
|
value: input.pluginId
|
|
4431
4315
|
}), ("object" === typeof input.publicParams && null !== input.publicParams && false === Array.isArray(input.publicParams) || $report(_exceptionable, {
|
|
4432
4316
|
path: _path + ".publicParams",
|
|
4433
|
-
expected: "__type
|
|
4317
|
+
expected: "__type",
|
|
4434
4318
|
value: input.publicParams
|
|
4435
|
-
})) && $
|
|
4319
|
+
})) && $vo9(input.publicParams, _path + ".publicParams", true && _exceptionable) || $report(_exceptionable, {
|
|
4436
4320
|
path: _path + ".publicParams",
|
|
4437
|
-
expected: "__type
|
|
4321
|
+
expected: "__type",
|
|
4438
4322
|
value: input.publicParams
|
|
4439
4323
|
}), ("object" === typeof input.privateParams && null !== input.privateParams && false === Array.isArray(input.privateParams) || $report(_exceptionable, {
|
|
4440
4324
|
path: _path + ".privateParams",
|
|
4441
|
-
expected: "__type
|
|
4325
|
+
expected: "__type",
|
|
4442
4326
|
value: input.privateParams
|
|
4443
|
-
})) && $
|
|
4327
|
+
})) && $vo9(input.privateParams, _path + ".privateParams", true && _exceptionable) || $report(_exceptionable, {
|
|
4444
4328
|
path: _path + ".privateParams",
|
|
4445
|
-
expected: "__type
|
|
4329
|
+
expected: "__type",
|
|
4446
4330
|
value: input.privateParams
|
|
4447
4331
|
})].every(flag => flag);
|
|
4448
|
-
const $
|
|
4332
|
+
const $vo9 = (input, _path, _exceptionable = true) => true;
|
|
4333
|
+
const $vo10 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || $report(_exceptionable, {
|
|
4334
|
+
path: _path + ".name",
|
|
4335
|
+
expected: "string",
|
|
4336
|
+
value: input.name
|
|
4337
|
+
}), "string" === typeof input.description || $report(_exceptionable, {
|
|
4338
|
+
path: _path + ".description",
|
|
4339
|
+
expected: "string",
|
|
4340
|
+
value: input.description
|
|
4341
|
+
}), "string" === typeof input.image || $report(_exceptionable, {
|
|
4342
|
+
path: _path + ".image",
|
|
4343
|
+
expected: "string",
|
|
4344
|
+
value: input.image
|
|
4345
|
+
}), undefined === input.video || "string" === typeof input.video || $report(_exceptionable, {
|
|
4346
|
+
path: _path + ".video",
|
|
4347
|
+
expected: "(string | undefined)",
|
|
4348
|
+
value: input.video
|
|
4349
|
+
}), undefined === input.category || "string" === typeof input.category || $report(_exceptionable, {
|
|
4350
|
+
path: _path + ".category",
|
|
4351
|
+
expected: "(string | undefined)",
|
|
4352
|
+
value: input.category
|
|
4353
|
+
}), undefined === input.externalUrl || "string" === typeof input.externalUrl || $report(_exceptionable, {
|
|
4354
|
+
path: _path + ".externalUrl",
|
|
4355
|
+
expected: "(string | undefined)",
|
|
4356
|
+
value: input.externalUrl
|
|
4357
|
+
}), undefined === input.tags || (Array.isArray(input.tags) || $report(_exceptionable, {
|
|
4358
|
+
path: _path + ".tags",
|
|
4359
|
+
expected: "(Array<string> | undefined)",
|
|
4360
|
+
value: input.tags
|
|
4361
|
+
})) && input.tags.map((elem, _index8) => "string" === typeof elem || $report(_exceptionable, {
|
|
4362
|
+
path: _path + ".tags[" + _index8 + "]",
|
|
4363
|
+
expected: "string",
|
|
4364
|
+
value: elem
|
|
4365
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
4366
|
+
path: _path + ".tags",
|
|
4367
|
+
expected: "(Array<string> | undefined)",
|
|
4368
|
+
value: input.tags
|
|
4369
|
+
}), undefined === input.socials || ("object" === typeof input.socials && null !== input.socials && false === Array.isArray(input.socials) || $report(_exceptionable, {
|
|
4370
|
+
path: _path + ".socials",
|
|
4371
|
+
expected: "(__type.o1 | undefined)",
|
|
4372
|
+
value: input.socials
|
|
4373
|
+
})) && $vo11(input.socials, _path + ".socials", true && _exceptionable) || $report(_exceptionable, {
|
|
4374
|
+
path: _path + ".socials",
|
|
4375
|
+
expected: "(__type.o1 | undefined)",
|
|
4376
|
+
value: input.socials
|
|
4377
|
+
}), undefined === input.offChainTransferabilityInfo || ("object" === typeof input.offChainTransferabilityInfo && null !== input.offChainTransferabilityInfo || $report(_exceptionable, {
|
|
4378
|
+
path: _path + ".offChainTransferabilityInfo",
|
|
4379
|
+
expected: "(__type.o2 | undefined)",
|
|
4380
|
+
value: input.offChainTransferabilityInfo
|
|
4381
|
+
})) && $vo12(input.offChainTransferabilityInfo, _path + ".offChainTransferabilityInfo", true && _exceptionable) || $report(_exceptionable, {
|
|
4382
|
+
path: _path + ".offChainTransferabilityInfo",
|
|
4383
|
+
expected: "(__type.o2 | undefined)",
|
|
4384
|
+
value: input.offChainTransferabilityInfo
|
|
4385
|
+
}), undefined === input.attributes || (Array.isArray(input.attributes) || $report(_exceptionable, {
|
|
4386
|
+
path: _path + ".attributes",
|
|
4387
|
+
expected: "(Array<__type> | undefined)",
|
|
4388
|
+
value: input.attributes
|
|
4389
|
+
})) && input.attributes.map((elem, _index9) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
4390
|
+
path: _path + ".attributes[" + _index9 + "]",
|
|
4391
|
+
expected: "__type.o3",
|
|
4392
|
+
value: elem
|
|
4393
|
+
})) && $vo13(elem, _path + ".attributes[" + _index9 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
4394
|
+
path: _path + ".attributes[" + _index9 + "]",
|
|
4395
|
+
expected: "__type.o3",
|
|
4396
|
+
value: elem
|
|
4397
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
4398
|
+
path: _path + ".attributes",
|
|
4399
|
+
expected: "(Array<__type> | undefined)",
|
|
4400
|
+
value: input.attributes
|
|
4401
|
+
}), undefined === input.fetchedAtBlock || "string" === typeof input.fetchedAtBlock || "number" === typeof input.fetchedAtBlock || "bigint" === typeof input.fetchedAtBlock || $report(_exceptionable, {
|
|
4402
|
+
path: _path + ".fetchedAtBlock",
|
|
4403
|
+
expected: "(bigint | number | string | undefined)",
|
|
4404
|
+
value: input.fetchedAtBlock
|
|
4405
|
+
}), undefined === input.fetchedAt || "string" === typeof input.fetchedAt || "number" === typeof input.fetchedAt || "bigint" === typeof input.fetchedAt || $report(_exceptionable, {
|
|
4406
|
+
path: _path + ".fetchedAt",
|
|
4407
|
+
expected: "(bigint | number | string | undefined)",
|
|
4408
|
+
value: input.fetchedAt
|
|
4409
|
+
}), undefined === input._isUpdating || "boolean" === typeof input._isUpdating || $report(_exceptionable, {
|
|
4410
|
+
path: _path + "._isUpdating",
|
|
4411
|
+
expected: "(boolean | undefined)",
|
|
4412
|
+
value: input._isUpdating
|
|
4413
|
+
})].every(flag => flag);
|
|
4414
|
+
const $vo11 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
4415
|
+
const value = input[key];
|
|
4416
|
+
if (undefined === value)
|
|
4417
|
+
return true;
|
|
4418
|
+
return "string" === typeof value || $report(_exceptionable, {
|
|
4419
|
+
path: _path + $join(key),
|
|
4420
|
+
expected: "string",
|
|
4421
|
+
value: value
|
|
4422
|
+
});
|
|
4423
|
+
}).every(flag => flag)].every(flag => flag);
|
|
4424
|
+
const $vo12 = (input, _path, _exceptionable = true) => ["string" === typeof input.host || $report(_exceptionable, {
|
|
4425
|
+
path: _path + ".host",
|
|
4426
|
+
expected: "string",
|
|
4427
|
+
value: input.host
|
|
4428
|
+
}), "string" === typeof input.assignMethod || $report(_exceptionable, {
|
|
4429
|
+
path: _path + ".assignMethod",
|
|
4430
|
+
expected: "string",
|
|
4431
|
+
value: input.assignMethod
|
|
4432
|
+
})].every(flag => flag);
|
|
4433
|
+
const $vo13 = (input, _path, _exceptionable = true) => [undefined === input.type || "date" === input.type || "url" === input.type || $report(_exceptionable, {
|
|
4434
|
+
path: _path + ".type",
|
|
4435
|
+
expected: "(\"date\" | \"url\" | undefined)",
|
|
4436
|
+
value: input.type
|
|
4437
|
+
}), "string" === typeof input.name || $report(_exceptionable, {
|
|
4438
|
+
path: _path + ".name",
|
|
4439
|
+
expected: "string",
|
|
4440
|
+
value: input.name
|
|
4441
|
+
}), "string" === typeof input.value || "number" === typeof input.value || "boolean" === typeof input.value || $report(_exceptionable, {
|
|
4442
|
+
path: _path + ".value",
|
|
4443
|
+
expected: "(boolean | number | string)",
|
|
4444
|
+
value: input.value
|
|
4445
|
+
})].every(flag => flag);
|
|
4449
4446
|
return ("object" === typeof input && null !== input || $report(true, {
|
|
4450
4447
|
path: _path + "",
|
|
4451
4448
|
expected: "UpdateClaimPayload",
|
|
@@ -5219,11 +5216,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5219
5216
|
const validateRes = (input => {
|
|
5220
5217
|
const errors = [];
|
|
5221
5218
|
const __is = input => {
|
|
5222
|
-
const $io0 = input => "string" === typeof input.pluginId && ("Stateless" === input.stateFunctionPreset || "Usernames" === input.stateFunctionPreset || "ClaimToken" === input.stateFunctionPreset || "CustomResponseHandler" === input.stateFunctionPreset || "CompletelyCustom" === input.stateFunctionPreset || "ClaimNumbers" === input.stateFunctionPreset || "StateTransitions" === input.stateFunctionPreset) && "boolean" === typeof input.duplicatesAllowed && "boolean" === typeof input.reuseForNonIndexed && "boolean" === typeof input.reuseForLists && "boolean" === typeof input.requiresUserInputs && ("object" === typeof input.metadata && null !== input.metadata && $io1(input.metadata)) && (undefined === input.userInputRedirect || "object" === typeof input.userInputRedirect && null !== input.userInputRedirect && $io2(input.userInputRedirect)) && (undefined === input.claimCreatorRedirect || "object" === typeof input.claimCreatorRedirect && null !== input.claimCreatorRedirect && $
|
|
5219
|
+
const $io0 = input => "string" === typeof input.pluginId && ("Stateless" === input.stateFunctionPreset || "Usernames" === input.stateFunctionPreset || "ClaimToken" === input.stateFunctionPreset || "CustomResponseHandler" === input.stateFunctionPreset || "CompletelyCustom" === input.stateFunctionPreset || "ClaimNumbers" === input.stateFunctionPreset || "StateTransitions" === input.stateFunctionPreset) && "boolean" === typeof input.duplicatesAllowed && "boolean" === typeof input.reuseForNonIndexed && "boolean" === typeof input.reuseForLists && "boolean" === typeof input.requiresUserInputs && ("object" === typeof input.metadata && null !== input.metadata && $io1(input.metadata)) && (undefined === input.userInputRedirect || "object" === typeof input.userInputRedirect && null !== input.userInputRedirect && $io2(input.userInputRedirect)) && (undefined === input.userInputsSchema || Array.isArray(input.userInputsSchema) && input.userInputsSchema.every(elem => "object" === typeof elem && null !== elem && $io3(elem))) && (undefined === input.claimCreatorRedirect || "object" === typeof input.claimCreatorRedirect && null !== input.claimCreatorRedirect && $io4(input.claimCreatorRedirect)) && (undefined === input.verificationCall || "object" === typeof input.verificationCall && null !== input.verificationCall && $io5(input.verificationCall)) && "boolean" === typeof input.toPublish && (undefined === input.approvedUsers || Array.isArray(input.approvedUsers) && input.approvedUsers.every(elem => "string" === typeof elem));
|
|
5223
5220
|
const $io1 = input => "string" === typeof input.name && "string" === typeof input.description && "string" === typeof input.image && (undefined === input.documentation || "string" === typeof input.documentation) && (undefined === input.sourceCode || "string" === typeof input.sourceCode) && (undefined === input.supportLink || "string" === typeof input.supportLink) && "string" === typeof input.createdBy;
|
|
5224
5221
|
const $io2 = input => "string" === typeof input.baseUri;
|
|
5225
|
-
const $io3 = input => "string" === typeof input.
|
|
5226
|
-
const $io4 = input => "string" === typeof input.
|
|
5222
|
+
const $io3 = input => "string" === typeof input.key && "string" === typeof input.label && ("string" === input.type || "number" === input.type || "boolean" === input.type || "date" === input.type || "url" === input.type) && (undefined === input.helper || "string" === typeof input.helper);
|
|
5223
|
+
const $io4 = input => "string" === typeof input.baseUri;
|
|
5224
|
+
const $io5 = input => "string" === typeof input.uri && ("POST" === input.method || "GET" === input.method || "PUT" === input.method || "DELETE" === input.method) && (undefined === input.passAddress || "boolean" === typeof input.passAddress) && (undefined === input.passDiscord || "boolean" === typeof input.passDiscord) && (undefined === input.passEmail || "boolean" === typeof input.passEmail) && (undefined === input.passTwitter || "boolean" === typeof input.passTwitter) && (undefined === input.passGoogle || "boolean" === typeof input.passGoogle) && (undefined === input.passGithub || "boolean" === typeof input.passGithub) && (undefined === input.passTwitch || "boolean" === typeof input.passTwitch);
|
|
5227
5225
|
return "object" === typeof input && null !== input && $io0(input);
|
|
5228
5226
|
};
|
|
5229
5227
|
if (false === __is(input)) {
|
|
@@ -5269,11 +5267,27 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5269
5267
|
path: _path + ".userInputRedirect",
|
|
5270
5268
|
expected: "(__type.o1 | undefined)",
|
|
5271
5269
|
value: input.userInputRedirect
|
|
5270
|
+
}), undefined === input.userInputsSchema || (Array.isArray(input.userInputsSchema) || $report(_exceptionable, {
|
|
5271
|
+
path: _path + ".userInputsSchema",
|
|
5272
|
+
expected: "(Array<JsonBodyInputSchema> | undefined)",
|
|
5273
|
+
value: input.userInputsSchema
|
|
5274
|
+
})) && input.userInputsSchema.map((elem, _index1) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
5275
|
+
path: _path + ".userInputsSchema[" + _index1 + "]",
|
|
5276
|
+
expected: "JsonBodyInputSchema",
|
|
5277
|
+
value: elem
|
|
5278
|
+
})) && $vo3(elem, _path + ".userInputsSchema[" + _index1 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
5279
|
+
path: _path + ".userInputsSchema[" + _index1 + "]",
|
|
5280
|
+
expected: "JsonBodyInputSchema",
|
|
5281
|
+
value: elem
|
|
5282
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
5283
|
+
path: _path + ".userInputsSchema",
|
|
5284
|
+
expected: "(Array<JsonBodyInputSchema> | undefined)",
|
|
5285
|
+
value: input.userInputsSchema
|
|
5272
5286
|
}), undefined === input.claimCreatorRedirect || ("object" === typeof input.claimCreatorRedirect && null !== input.claimCreatorRedirect || $report(_exceptionable, {
|
|
5273
5287
|
path: _path + ".claimCreatorRedirect",
|
|
5274
5288
|
expected: "(__type.o2 | undefined)",
|
|
5275
5289
|
value: input.claimCreatorRedirect
|
|
5276
|
-
})) && $
|
|
5290
|
+
})) && $vo4(input.claimCreatorRedirect, _path + ".claimCreatorRedirect", true && _exceptionable) || $report(_exceptionable, {
|
|
5277
5291
|
path: _path + ".claimCreatorRedirect",
|
|
5278
5292
|
expected: "(__type.o2 | undefined)",
|
|
5279
5293
|
value: input.claimCreatorRedirect
|
|
@@ -5281,7 +5295,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5281
5295
|
path: _path + ".verificationCall",
|
|
5282
5296
|
expected: "(__type.o3 | undefined)",
|
|
5283
5297
|
value: input.verificationCall
|
|
5284
|
-
})) && $
|
|
5298
|
+
})) && $vo5(input.verificationCall, _path + ".verificationCall", true && _exceptionable) || $report(_exceptionable, {
|
|
5285
5299
|
path: _path + ".verificationCall",
|
|
5286
5300
|
expected: "(__type.o3 | undefined)",
|
|
5287
5301
|
value: input.verificationCall
|
|
@@ -5293,8 +5307,8 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5293
5307
|
path: _path + ".approvedUsers",
|
|
5294
5308
|
expected: "(Array<string> | undefined)",
|
|
5295
5309
|
value: input.approvedUsers
|
|
5296
|
-
})) && input.approvedUsers.map((elem,
|
|
5297
|
-
path: _path + ".approvedUsers[" +
|
|
5310
|
+
})) && input.approvedUsers.map((elem, _index2) => "string" === typeof elem || $report(_exceptionable, {
|
|
5311
|
+
path: _path + ".approvedUsers[" + _index2 + "]",
|
|
5298
5312
|
expected: "string",
|
|
5299
5313
|
value: elem
|
|
5300
5314
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -5336,12 +5350,29 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5336
5350
|
expected: "string",
|
|
5337
5351
|
value: input.baseUri
|
|
5338
5352
|
})].every(flag => flag);
|
|
5339
|
-
const $vo3 = (input, _path, _exceptionable = true) => ["string" === typeof input.
|
|
5353
|
+
const $vo3 = (input, _path, _exceptionable = true) => ["string" === typeof input.key || $report(_exceptionable, {
|
|
5354
|
+
path: _path + ".key",
|
|
5355
|
+
expected: "string",
|
|
5356
|
+
value: input.key
|
|
5357
|
+
}), "string" === typeof input.label || $report(_exceptionable, {
|
|
5358
|
+
path: _path + ".label",
|
|
5359
|
+
expected: "string",
|
|
5360
|
+
value: input.label
|
|
5361
|
+
}), "string" === input.type || "number" === input.type || "boolean" === input.type || "date" === input.type || "url" === input.type || $report(_exceptionable, {
|
|
5362
|
+
path: _path + ".type",
|
|
5363
|
+
expected: "(\"boolean\" | \"date\" | \"number\" | \"string\" | \"url\")",
|
|
5364
|
+
value: input.type
|
|
5365
|
+
}), undefined === input.helper || "string" === typeof input.helper || $report(_exceptionable, {
|
|
5366
|
+
path: _path + ".helper",
|
|
5367
|
+
expected: "(string | undefined)",
|
|
5368
|
+
value: input.helper
|
|
5369
|
+
})].every(flag => flag);
|
|
5370
|
+
const $vo4 = (input, _path, _exceptionable = true) => ["string" === typeof input.baseUri || $report(_exceptionable, {
|
|
5340
5371
|
path: _path + ".baseUri",
|
|
5341
5372
|
expected: "string",
|
|
5342
5373
|
value: input.baseUri
|
|
5343
5374
|
})].every(flag => flag);
|
|
5344
|
-
const $
|
|
5375
|
+
const $vo5 = (input, _path, _exceptionable = true) => ["string" === typeof input.uri || $report(_exceptionable, {
|
|
5345
5376
|
path: _path + ".uri",
|
|
5346
5377
|
expected: "string",
|
|
5347
5378
|
value: input.uri
|
|
@@ -5412,11 +5443,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5412
5443
|
const validateRes = (input => {
|
|
5413
5444
|
const errors = [];
|
|
5414
5445
|
const __is = input => {
|
|
5415
|
-
const $io0 = input => "string" === typeof input.pluginId && (undefined === input.duplicatesAllowed || "boolean" === typeof input.duplicatesAllowed) && (undefined === input.reuseForNonIndexed || "boolean" === typeof input.reuseForNonIndexed) && (undefined === input.reuseForLists || "boolean" === typeof input.reuseForLists) && (undefined === input.requiresUserInputs || "boolean" === typeof input.requiresUserInputs) && (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $io1(input.metadata)) && (undefined === input.userInputRedirect || "object" === typeof input.userInputRedirect && null !== input.userInputRedirect && $
|
|
5446
|
+
const $io0 = input => "string" === typeof input.pluginId && (undefined === input.duplicatesAllowed || "boolean" === typeof input.duplicatesAllowed) && (undefined === input.reuseForNonIndexed || "boolean" === typeof input.reuseForNonIndexed) && (undefined === input.reuseForLists || "boolean" === typeof input.reuseForLists) && (undefined === input.requiresUserInputs || "boolean" === typeof input.requiresUserInputs) && (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $io1(input.metadata)) && (undefined === input.userInputsSchema || Array.isArray(input.userInputsSchema) && input.userInputsSchema.every(elem => "object" === typeof elem && null !== elem && $io2(elem))) && (undefined === input.userInputRedirect || "object" === typeof input.userInputRedirect && null !== input.userInputRedirect && $io3(input.userInputRedirect)) && (undefined === input.claimCreatorRedirect || "object" === typeof input.claimCreatorRedirect && null !== input.claimCreatorRedirect && $io4(input.claimCreatorRedirect)) && (undefined === input.verificationCall || "object" === typeof input.verificationCall && null !== input.verificationCall && $io5(input.verificationCall)) && (undefined === input.toPublish || "boolean" === typeof input.toPublish) && (undefined === input.approvedUsers || Array.isArray(input.approvedUsers) && input.approvedUsers.every(elem => "string" === typeof elem)) && (undefined === input.rotatePluginSecret || "boolean" === typeof input.rotatePluginSecret);
|
|
5416
5447
|
const $io1 = input => "string" === typeof input.name && "string" === typeof input.description && "string" === typeof input.image && (undefined === input.documentation || "string" === typeof input.documentation) && (undefined === input.sourceCode || "string" === typeof input.sourceCode) && (undefined === input.supportLink || "string" === typeof input.supportLink);
|
|
5417
|
-
const $io2 = input => "string" === typeof input.
|
|
5448
|
+
const $io2 = input => "string" === typeof input.key && "string" === typeof input.label && ("string" === input.type || "number" === input.type || "boolean" === input.type || "date" === input.type || "url" === input.type) && (undefined === input.helper || "string" === typeof input.helper);
|
|
5418
5449
|
const $io3 = input => "string" === typeof input.baseUri;
|
|
5419
|
-
const $io4 = input => "string" === typeof input.
|
|
5450
|
+
const $io4 = input => "string" === typeof input.baseUri;
|
|
5451
|
+
const $io5 = input => "string" === typeof input.uri && ("POST" === input.method || "GET" === input.method || "PUT" === input.method || "DELETE" === input.method) && (undefined === input.passAddress || "boolean" === typeof input.passAddress) && (undefined === input.passDiscord || "boolean" === typeof input.passDiscord) && (undefined === input.passEmail || "boolean" === typeof input.passEmail) && (undefined === input.passTwitter || "boolean" === typeof input.passTwitter) && (undefined === input.passGoogle || "boolean" === typeof input.passGoogle) && (undefined === input.passGithub || "boolean" === typeof input.passGithub) && (undefined === input.passTwitch || "boolean" === typeof input.passTwitch);
|
|
5420
5452
|
return "object" === typeof input && null !== input && $io0(input);
|
|
5421
5453
|
};
|
|
5422
5454
|
if (false === __is(input)) {
|
|
@@ -5450,11 +5482,27 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5450
5482
|
path: _path + ".metadata",
|
|
5451
5483
|
expected: "(__type | undefined)",
|
|
5452
5484
|
value: input.metadata
|
|
5485
|
+
}), undefined === input.userInputsSchema || (Array.isArray(input.userInputsSchema) || $report(_exceptionable, {
|
|
5486
|
+
path: _path + ".userInputsSchema",
|
|
5487
|
+
expected: "(Array<JsonBodyInputSchema> | undefined)",
|
|
5488
|
+
value: input.userInputsSchema
|
|
5489
|
+
})) && input.userInputsSchema.map((elem, _index1) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
5490
|
+
path: _path + ".userInputsSchema[" + _index1 + "]",
|
|
5491
|
+
expected: "JsonBodyInputSchema",
|
|
5492
|
+
value: elem
|
|
5493
|
+
})) && $vo2(elem, _path + ".userInputsSchema[" + _index1 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
5494
|
+
path: _path + ".userInputsSchema[" + _index1 + "]",
|
|
5495
|
+
expected: "JsonBodyInputSchema",
|
|
5496
|
+
value: elem
|
|
5497
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
5498
|
+
path: _path + ".userInputsSchema",
|
|
5499
|
+
expected: "(Array<JsonBodyInputSchema> | undefined)",
|
|
5500
|
+
value: input.userInputsSchema
|
|
5453
5501
|
}), undefined === input.userInputRedirect || ("object" === typeof input.userInputRedirect && null !== input.userInputRedirect || $report(_exceptionable, {
|
|
5454
5502
|
path: _path + ".userInputRedirect",
|
|
5455
5503
|
expected: "(__type.o1 | undefined)",
|
|
5456
5504
|
value: input.userInputRedirect
|
|
5457
|
-
})) && $
|
|
5505
|
+
})) && $vo3(input.userInputRedirect, _path + ".userInputRedirect", true && _exceptionable) || $report(_exceptionable, {
|
|
5458
5506
|
path: _path + ".userInputRedirect",
|
|
5459
5507
|
expected: "(__type.o1 | undefined)",
|
|
5460
5508
|
value: input.userInputRedirect
|
|
@@ -5462,7 +5510,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5462
5510
|
path: _path + ".claimCreatorRedirect",
|
|
5463
5511
|
expected: "(__type.o2 | undefined)",
|
|
5464
5512
|
value: input.claimCreatorRedirect
|
|
5465
|
-
})) && $
|
|
5513
|
+
})) && $vo4(input.claimCreatorRedirect, _path + ".claimCreatorRedirect", true && _exceptionable) || $report(_exceptionable, {
|
|
5466
5514
|
path: _path + ".claimCreatorRedirect",
|
|
5467
5515
|
expected: "(__type.o2 | undefined)",
|
|
5468
5516
|
value: input.claimCreatorRedirect
|
|
@@ -5470,7 +5518,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5470
5518
|
path: _path + ".verificationCall",
|
|
5471
5519
|
expected: "(__type.o3 | undefined)",
|
|
5472
5520
|
value: input.verificationCall
|
|
5473
|
-
})) && $
|
|
5521
|
+
})) && $vo5(input.verificationCall, _path + ".verificationCall", true && _exceptionable) || $report(_exceptionable, {
|
|
5474
5522
|
path: _path + ".verificationCall",
|
|
5475
5523
|
expected: "(__type.o3 | undefined)",
|
|
5476
5524
|
value: input.verificationCall
|
|
@@ -5482,8 +5530,8 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5482
5530
|
path: _path + ".approvedUsers",
|
|
5483
5531
|
expected: "(Array<string> | undefined)",
|
|
5484
5532
|
value: input.approvedUsers
|
|
5485
|
-
})) && input.approvedUsers.map((elem,
|
|
5486
|
-
path: _path + ".approvedUsers[" +
|
|
5533
|
+
})) && input.approvedUsers.map((elem, _index2) => "string" === typeof elem || $report(_exceptionable, {
|
|
5534
|
+
path: _path + ".approvedUsers[" + _index2 + "]",
|
|
5487
5535
|
expected: "string",
|
|
5488
5536
|
value: elem
|
|
5489
5537
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -5520,17 +5568,34 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
5520
5568
|
expected: "(string | undefined)",
|
|
5521
5569
|
value: input.supportLink
|
|
5522
5570
|
})].every(flag => flag);
|
|
5523
|
-
const $vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.
|
|
5571
|
+
const $vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.key || $report(_exceptionable, {
|
|
5572
|
+
path: _path + ".key",
|
|
5573
|
+
expected: "string",
|
|
5574
|
+
value: input.key
|
|
5575
|
+
}), "string" === typeof input.label || $report(_exceptionable, {
|
|
5576
|
+
path: _path + ".label",
|
|
5577
|
+
expected: "string",
|
|
5578
|
+
value: input.label
|
|
5579
|
+
}), "string" === input.type || "number" === input.type || "boolean" === input.type || "date" === input.type || "url" === input.type || $report(_exceptionable, {
|
|
5580
|
+
path: _path + ".type",
|
|
5581
|
+
expected: "(\"boolean\" | \"date\" | \"number\" | \"string\" | \"url\")",
|
|
5582
|
+
value: input.type
|
|
5583
|
+
}), undefined === input.helper || "string" === typeof input.helper || $report(_exceptionable, {
|
|
5584
|
+
path: _path + ".helper",
|
|
5585
|
+
expected: "(string | undefined)",
|
|
5586
|
+
value: input.helper
|
|
5587
|
+
})].every(flag => flag);
|
|
5588
|
+
const $vo3 = (input, _path, _exceptionable = true) => ["string" === typeof input.baseUri || $report(_exceptionable, {
|
|
5524
5589
|
path: _path + ".baseUri",
|
|
5525
5590
|
expected: "string",
|
|
5526
5591
|
value: input.baseUri
|
|
5527
5592
|
})].every(flag => flag);
|
|
5528
|
-
const $
|
|
5593
|
+
const $vo4 = (input, _path, _exceptionable = true) => ["string" === typeof input.baseUri || $report(_exceptionable, {
|
|
5529
5594
|
path: _path + ".baseUri",
|
|
5530
5595
|
expected: "string",
|
|
5531
5596
|
value: input.baseUri
|
|
5532
5597
|
})].every(flag => flag);
|
|
5533
|
-
const $
|
|
5598
|
+
const $vo5 = (input, _path, _exceptionable = true) => ["string" === typeof input.uri || $report(_exceptionable, {
|
|
5534
5599
|
path: _path + ".uri",
|
|
5535
5600
|
expected: "string",
|
|
5536
5601
|
value: input.uri
|
|
@@ -6114,23 +6179,23 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6114
6179
|
const errors = [];
|
|
6115
6180
|
const __is = input => {
|
|
6116
6181
|
const $io0 = input => undefined === input.contents || Array.isArray(input.contents) && input.contents.every(elem => "object" === typeof elem && null !== elem && $iu0(elem));
|
|
6117
|
-
const $io1 = input => (undefined === input.metadata || "object" === typeof input.metadata && null !== input.metadata && $
|
|
6118
|
-
const $io2 = input =>
|
|
6119
|
-
const $io3 = input =>
|
|
6182
|
+
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);
|
|
6183
|
+
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);
|
|
6184
|
+
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);
|
|
6185
|
+
const $io4 = input => Object.keys(input).every(key => {
|
|
6120
6186
|
const value = input[key];
|
|
6121
6187
|
if (undefined === value)
|
|
6122
6188
|
return true;
|
|
6123
6189
|
return "string" === typeof value;
|
|
6124
6190
|
});
|
|
6125
|
-
const $
|
|
6126
|
-
const $
|
|
6127
|
-
const $
|
|
6128
|
-
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);
|
|
6191
|
+
const $io5 = input => "string" === typeof input.host && "string" === typeof input.assignMethod;
|
|
6192
|
+
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);
|
|
6193
|
+
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);
|
|
6129
6194
|
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);
|
|
6130
6195
|
const $io9 = input => true;
|
|
6131
6196
|
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);
|
|
6132
|
-
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@
|
|
6133
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
6197
|
+
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@200"] && Object.keys(input).every(key => {
|
|
6198
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@200"].some(prop => key === prop))
|
|
6134
6199
|
return true;
|
|
6135
6200
|
const value = input[key];
|
|
6136
6201
|
if (undefined === value)
|
|
@@ -6140,14 +6205,14 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6140
6205
|
return true;
|
|
6141
6206
|
});
|
|
6142
6207
|
const $iu0 = input => (() => {
|
|
6143
|
-
if (undefined !== input.
|
|
6144
|
-
return $
|
|
6145
|
-
else if (undefined !== input.
|
|
6146
|
-
return $
|
|
6208
|
+
if (undefined !== input.badgeIds)
|
|
6209
|
+
return $io1(input);
|
|
6210
|
+
else if (undefined !== input.name)
|
|
6211
|
+
return $io3(input);
|
|
6147
6212
|
else if (undefined !== input.leaves)
|
|
6148
6213
|
return $io8(input);
|
|
6149
6214
|
else
|
|
6150
|
-
return $
|
|
6215
|
+
return $io7(input);
|
|
6151
6216
|
})();
|
|
6152
6217
|
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
6153
6218
|
};
|
|
@@ -6157,7 +6222,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6157
6222
|
const $join = typia_1.default.validate.join;
|
|
6158
6223
|
const $vo0 = (input, _path, _exceptionable = true) => [undefined === input.contents || (Array.isArray(input.contents) || $report(_exceptionable, {
|
|
6159
6224
|
path: _path + ".contents",
|
|
6160
|
-
expected: "(Array<
|
|
6225
|
+
expected: "(Array<iBadgeMetadataDetails<NumberType> | iMetadata<NumberType> | iCollectionMetadataDetails<NumberType> | iChallengeDetails<...>> | undefined)",
|
|
6161
6226
|
value: input.contents
|
|
6162
6227
|
})) && input.contents.map((elem, _index1) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
6163
6228
|
path: _path + ".contents[" + _index1 + "]",
|
|
@@ -6169,14 +6234,30 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6169
6234
|
value: elem
|
|
6170
6235
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
6171
6236
|
path: _path + ".contents",
|
|
6172
|
-
expected: "(Array<
|
|
6237
|
+
expected: "(Array<iBadgeMetadataDetails<NumberType> | iMetadata<NumberType> | iCollectionMetadataDetails<NumberType> | iChallengeDetails<...>> | undefined)",
|
|
6173
6238
|
value: input.contents
|
|
6174
6239
|
})].every(flag => flag);
|
|
6175
|
-
const $vo1 = (input, _path, _exceptionable = true) => [
|
|
6240
|
+
const $vo1 = (input, _path, _exceptionable = true) => [(Array.isArray(input.badgeIds) || $report(_exceptionable, {
|
|
6241
|
+
path: _path + ".badgeIds",
|
|
6242
|
+
expected: "Array<iUintRange<NumberType>>",
|
|
6243
|
+
value: input.badgeIds
|
|
6244
|
+
})) && input.badgeIds.map((elem, _index2) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
6245
|
+
path: _path + ".badgeIds[" + _index2 + "]",
|
|
6246
|
+
expected: "iUintRange<NumberType>",
|
|
6247
|
+
value: elem
|
|
6248
|
+
})) && $vo2(elem, _path + ".badgeIds[" + _index2 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
6249
|
+
path: _path + ".badgeIds[" + _index2 + "]",
|
|
6250
|
+
expected: "iUintRange<NumberType>",
|
|
6251
|
+
value: elem
|
|
6252
|
+
})).every(flag => flag) || $report(_exceptionable, {
|
|
6253
|
+
path: _path + ".badgeIds",
|
|
6254
|
+
expected: "Array<iUintRange<NumberType>>",
|
|
6255
|
+
value: input.badgeIds
|
|
6256
|
+
}), undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
6176
6257
|
path: _path + ".metadata",
|
|
6177
6258
|
expected: "(iMetadata<NumberType> | undefined)",
|
|
6178
6259
|
value: input.metadata
|
|
6179
|
-
})) && $
|
|
6260
|
+
})) && $vo3(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
6180
6261
|
path: _path + ".metadata",
|
|
6181
6262
|
expected: "(iMetadata<NumberType> | undefined)",
|
|
6182
6263
|
value: input.metadata
|
|
@@ -6197,7 +6278,16 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6197
6278
|
expected: "(boolean | undefined)",
|
|
6198
6279
|
value: input.toUploadToIpfs
|
|
6199
6280
|
})].every(flag => flag);
|
|
6200
|
-
const $vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.
|
|
6281
|
+
const $vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start || $report(_exceptionable, {
|
|
6282
|
+
path: _path + ".start",
|
|
6283
|
+
expected: "(bigint | number | string)",
|
|
6284
|
+
value: input.start
|
|
6285
|
+
}), "string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end || $report(_exceptionable, {
|
|
6286
|
+
path: _path + ".end",
|
|
6287
|
+
expected: "(bigint | number | string)",
|
|
6288
|
+
value: input.end
|
|
6289
|
+
})].every(flag => flag);
|
|
6290
|
+
const $vo3 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || $report(_exceptionable, {
|
|
6201
6291
|
path: _path + ".name",
|
|
6202
6292
|
expected: "string",
|
|
6203
6293
|
value: input.name
|
|
@@ -6225,8 +6315,8 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6225
6315
|
path: _path + ".tags",
|
|
6226
6316
|
expected: "(Array<string> | undefined)",
|
|
6227
6317
|
value: input.tags
|
|
6228
|
-
})) && input.tags.map((elem,
|
|
6229
|
-
path: _path + ".tags[" +
|
|
6318
|
+
})) && input.tags.map((elem, _index3) => "string" === typeof elem || $report(_exceptionable, {
|
|
6319
|
+
path: _path + ".tags[" + _index3 + "]",
|
|
6230
6320
|
expected: "string",
|
|
6231
6321
|
value: elem
|
|
6232
6322
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -6237,7 +6327,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6237
6327
|
path: _path + ".socials",
|
|
6238
6328
|
expected: "(__type | undefined)",
|
|
6239
6329
|
value: input.socials
|
|
6240
|
-
})) && $
|
|
6330
|
+
})) && $vo4(input.socials, _path + ".socials", true && _exceptionable) || $report(_exceptionable, {
|
|
6241
6331
|
path: _path + ".socials",
|
|
6242
6332
|
expected: "(__type | undefined)",
|
|
6243
6333
|
value: input.socials
|
|
@@ -6245,7 +6335,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6245
6335
|
path: _path + ".offChainTransferabilityInfo",
|
|
6246
6336
|
expected: "(__type.o1 | undefined)",
|
|
6247
6337
|
value: input.offChainTransferabilityInfo
|
|
6248
|
-
})) && $
|
|
6338
|
+
})) && $vo5(input.offChainTransferabilityInfo, _path + ".offChainTransferabilityInfo", true && _exceptionable) || $report(_exceptionable, {
|
|
6249
6339
|
path: _path + ".offChainTransferabilityInfo",
|
|
6250
6340
|
expected: "(__type.o1 | undefined)",
|
|
6251
6341
|
value: input.offChainTransferabilityInfo
|
|
@@ -6253,12 +6343,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6253
6343
|
path: _path + ".attributes",
|
|
6254
6344
|
expected: "(Array<__type> | undefined)",
|
|
6255
6345
|
value: input.attributes
|
|
6256
|
-
})) && input.attributes.map((elem,
|
|
6257
|
-
path: _path + ".attributes[" +
|
|
6346
|
+
})) && input.attributes.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
6347
|
+
path: _path + ".attributes[" + _index4 + "]",
|
|
6258
6348
|
expected: "__type.o2",
|
|
6259
6349
|
value: elem
|
|
6260
|
-
})) && $
|
|
6261
|
-
path: _path + ".attributes[" +
|
|
6350
|
+
})) && $vo6(elem, _path + ".attributes[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
6351
|
+
path: _path + ".attributes[" + _index4 + "]",
|
|
6262
6352
|
expected: "__type.o2",
|
|
6263
6353
|
value: elem
|
|
6264
6354
|
})).every(flag => flag) || $report(_exceptionable, {
|
|
@@ -6278,7 +6368,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6278
6368
|
expected: "(boolean | undefined)",
|
|
6279
6369
|
value: input._isUpdating
|
|
6280
6370
|
})].every(flag => flag);
|
|
6281
|
-
const $
|
|
6371
|
+
const $vo4 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
6282
6372
|
const value = input[key];
|
|
6283
6373
|
if (undefined === value)
|
|
6284
6374
|
return true;
|
|
@@ -6288,7 +6378,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6288
6378
|
value: value
|
|
6289
6379
|
});
|
|
6290
6380
|
}).every(flag => flag)].every(flag => flag);
|
|
6291
|
-
const $
|
|
6381
|
+
const $vo5 = (input, _path, _exceptionable = true) => ["string" === typeof input.host || $report(_exceptionable, {
|
|
6292
6382
|
path: _path + ".host",
|
|
6293
6383
|
expected: "string",
|
|
6294
6384
|
value: input.host
|
|
@@ -6297,7 +6387,7 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6297
6387
|
expected: "string",
|
|
6298
6388
|
value: input.assignMethod
|
|
6299
6389
|
})].every(flag => flag);
|
|
6300
|
-
const $
|
|
6390
|
+
const $vo6 = (input, _path, _exceptionable = true) => [undefined === input.type || "date" === input.type || "url" === input.type || $report(_exceptionable, {
|
|
6301
6391
|
path: _path + ".type",
|
|
6302
6392
|
expected: "(\"date\" | \"url\" | undefined)",
|
|
6303
6393
|
value: input.type
|
|
@@ -6310,27 +6400,11 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6310
6400
|
expected: "(boolean | number | string)",
|
|
6311
6401
|
value: input.value
|
|
6312
6402
|
})].every(flag => flag);
|
|
6313
|
-
const $
|
|
6314
|
-
path: _path + ".badgeIds",
|
|
6315
|
-
expected: "Array<iUintRange<NumberType>>",
|
|
6316
|
-
value: input.badgeIds
|
|
6317
|
-
})) && input.badgeIds.map((elem, _index4) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
|
6318
|
-
path: _path + ".badgeIds[" + _index4 + "]",
|
|
6319
|
-
expected: "iUintRange<NumberType>",
|
|
6320
|
-
value: elem
|
|
6321
|
-
})) && $vo7(elem, _path + ".badgeIds[" + _index4 + "]", true && _exceptionable) || $report(_exceptionable, {
|
|
6322
|
-
path: _path + ".badgeIds[" + _index4 + "]",
|
|
6323
|
-
expected: "iUintRange<NumberType>",
|
|
6324
|
-
value: elem
|
|
6325
|
-
})).every(flag => flag) || $report(_exceptionable, {
|
|
6326
|
-
path: _path + ".badgeIds",
|
|
6327
|
-
expected: "Array<iUintRange<NumberType>>",
|
|
6328
|
-
value: input.badgeIds
|
|
6329
|
-
}), undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
6403
|
+
const $vo7 = (input, _path, _exceptionable = true) => [undefined === input.metadata || ("object" === typeof input.metadata && null !== input.metadata || $report(_exceptionable, {
|
|
6330
6404
|
path: _path + ".metadata",
|
|
6331
6405
|
expected: "(iMetadata<NumberType> | undefined)",
|
|
6332
6406
|
value: input.metadata
|
|
6333
|
-
})) && $
|
|
6407
|
+
})) && $vo3(input.metadata, _path + ".metadata", true && _exceptionable) || $report(_exceptionable, {
|
|
6334
6408
|
path: _path + ".metadata",
|
|
6335
6409
|
expected: "(iMetadata<NumberType> | undefined)",
|
|
6336
6410
|
value: input.metadata
|
|
@@ -6351,15 +6425,6 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6351
6425
|
expected: "(boolean | undefined)",
|
|
6352
6426
|
value: input.toUploadToIpfs
|
|
6353
6427
|
})].every(flag => flag);
|
|
6354
|
-
const $vo7 = (input, _path, _exceptionable = true) => ["string" === typeof input.start || "number" === typeof input.start || "bigint" === typeof input.start || $report(_exceptionable, {
|
|
6355
|
-
path: _path + ".start",
|
|
6356
|
-
expected: "(bigint | number | string)",
|
|
6357
|
-
value: input.start
|
|
6358
|
-
}), "string" === typeof input.end || "number" === typeof input.end || "bigint" === typeof input.end || $report(_exceptionable, {
|
|
6359
|
-
path: _path + ".end",
|
|
6360
|
-
expected: "(bigint | number | string)",
|
|
6361
|
-
value: input.end
|
|
6362
|
-
})].every(flag => flag);
|
|
6363
6428
|
const $vo8 = (input, _path, _exceptionable = true) => [(Array.isArray(input.leaves) || $report(_exceptionable, {
|
|
6364
6429
|
path: _path + ".leaves",
|
|
6365
6430
|
expected: "Array<string>",
|
|
@@ -6483,12 +6548,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6483
6548
|
path: _path + ".length",
|
|
6484
6549
|
expected: "number",
|
|
6485
6550
|
value: input.length
|
|
6486
|
-
}), "Uint8Array" === input["__@toStringTag@
|
|
6487
|
-
path: _path + "[\"__@toStringTag@
|
|
6551
|
+
}), "Uint8Array" === input["__@toStringTag@200"] || $report(_exceptionable, {
|
|
6552
|
+
path: _path + "[\"__@toStringTag@200\"]",
|
|
6488
6553
|
expected: "\"Uint8Array\"",
|
|
6489
|
-
value: input["__@toStringTag@
|
|
6554
|
+
value: input["__@toStringTag@200"]
|
|
6490
6555
|
}), false === _exceptionable || Object.keys(input).map(key => {
|
|
6491
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
6556
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@200"].some(prop => key === prop))
|
|
6492
6557
|
return true;
|
|
6493
6558
|
const value = input[key];
|
|
6494
6559
|
if (undefined === value)
|
|
@@ -6502,14 +6567,14 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6502
6567
|
return true;
|
|
6503
6568
|
}).every(flag => flag)].every(flag => flag);
|
|
6504
6569
|
const $vu0 = (input, _path, _exceptionable = true) => (() => {
|
|
6505
|
-
if (undefined !== input.
|
|
6506
|
-
return $
|
|
6507
|
-
else if (undefined !== input.
|
|
6508
|
-
return $
|
|
6570
|
+
if (undefined !== input.badgeIds)
|
|
6571
|
+
return $vo1(input, _path, true && _exceptionable);
|
|
6572
|
+
else if (undefined !== input.name)
|
|
6573
|
+
return $vo3(input, _path, true && _exceptionable);
|
|
6509
6574
|
else if (undefined !== input.leaves)
|
|
6510
6575
|
return $vo8(input, _path, true && _exceptionable);
|
|
6511
6576
|
else
|
|
6512
|
-
return $
|
|
6577
|
+
return $vo7(input, _path, true && _exceptionable);
|
|
6513
6578
|
})();
|
|
6514
6579
|
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $report(true, {
|
|
6515
6580
|
path: _path + "",
|
|
@@ -6551,8 +6616,8 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6551
6616
|
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);
|
|
6552
6617
|
const $io4 = input => true;
|
|
6553
6618
|
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);
|
|
6554
|
-
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@
|
|
6555
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
6619
|
+
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@200"] && Object.keys(input).every(key => {
|
|
6620
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@200"].some(prop => key === prop))
|
|
6556
6621
|
return true;
|
|
6557
6622
|
const value = input[key];
|
|
6558
6623
|
if (undefined === value)
|
|
@@ -6766,12 +6831,12 @@ class BitBadgesAdminAPI extends BitBadgesAPI {
|
|
|
6766
6831
|
path: _path + ".length",
|
|
6767
6832
|
expected: "number",
|
|
6768
6833
|
value: input.length
|
|
6769
|
-
}), "Uint8Array" === input["__@toStringTag@
|
|
6770
|
-
path: _path + "[\"__@toStringTag@
|
|
6834
|
+
}), "Uint8Array" === input["__@toStringTag@200"] || $report(_exceptionable, {
|
|
6835
|
+
path: _path + "[\"__@toStringTag@200\"]",
|
|
6771
6836
|
expected: "\"Uint8Array\"",
|
|
6772
|
-
value: input["__@toStringTag@
|
|
6837
|
+
value: input["__@toStringTag@200"]
|
|
6773
6838
|
}), false === _exceptionable || Object.keys(input).map(key => {
|
|
6774
|
-
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@
|
|
6839
|
+
if (["BYTES_PER_ELEMENT", "buffer", "byteLength", "byteOffset", "length", "__@toStringTag@200"].some(prop => key === prop))
|
|
6775
6840
|
return true;
|
|
6776
6841
|
const value = input[key];
|
|
6777
6842
|
if (undefined === value)
|