difftreelog
update unique-types-js
in: master
24 files changed
tests/README.mddiffbeforeafterboth--- a/tests/README.md
+++ b/tests/README.md
@@ -5,7 +5,7 @@
1. Checkout polkadot in sibling folder with this project
```bash
git clone https://github.com/paritytech/polkadot.git && cd polkadot
-git checkout release-v0.9.9
+git checkout release-v0.9.12
```
2. Build with nightly-2021-06-28
tests/src/check-event/burnItemEvent.test.tsdiffbeforeafterboth--- a/tests/src/check-event/burnItemEvent.test.ts
+++ b/tests/src/check-event/burnItemEvent.test.ts
@@ -10,7 +10,7 @@
import chaiAsPromised from 'chai-as-promised';
import privateKey from '../substrate/privateKey';
import usingApi, {submitTransactionAsync} from '../substrate/substrate-api';
-import {createCollectionExpectSuccess, createItemExpectSuccess, nftEventMessage} from '../util/helpers';
+import {createCollectionExpectSuccess, createItemExpectSuccess, uniqueEventMessage} from '../util/helpers';
chai.use(chaiAsPromised);
const expect = chai.expect;
@@ -31,7 +31,7 @@
const itemID = await createItemExpectSuccess(alice, collectionID, 'NFT');
const burnItem = api.tx.unique.burnItem(collectionID, itemID, 1);
const events = await submitTransactionAsync(alice, burnItem);
- const msg = JSON.stringify(nftEventMessage(events));
+ const msg = JSON.stringify(uniqueEventMessage(events));
expect(msg).to.be.contain(checkSection);
expect(msg).to.be.contain(checkTreasury);
expect(msg).to.be.contain(checkSystem);
tests/src/check-event/createCollectionEvent.test.tsdiffbeforeafterboth--- a/tests/src/check-event/createCollectionEvent.test.ts
+++ b/tests/src/check-event/createCollectionEvent.test.ts
@@ -10,7 +10,7 @@
import chaiAsPromised from 'chai-as-promised';
import privateKey from '../substrate/privateKey';
import usingApi, {submitTransactionAsync} from '../substrate/substrate-api';
-import {nftEventMessage} from '../util/helpers';
+import {uniqueEventMessage} from '../util/helpers';
chai.use(chaiAsPromised);
const expect = chai.expect;
@@ -29,7 +29,7 @@
await usingApi(async (api: ApiPromise) => {
const tx = api.tx.unique.createCollection([0x31], [0x32], '0x33', 'NFT');
const events = await submitTransactionAsync(alice, tx);
- const msg = JSON.stringify(nftEventMessage(events));
+ const msg = JSON.stringify(uniqueEventMessage(events));
expect(msg).to.be.contain(checkSection);
expect(msg).to.be.contain(checkTreasury);
expect(msg).to.be.contain(checkSystem);
tests/src/check-event/createItemEvent.test.tsdiffbeforeafterboth--- a/tests/src/check-event/createItemEvent.test.ts
+++ b/tests/src/check-event/createItemEvent.test.ts
@@ -10,7 +10,7 @@
import chaiAsPromised from 'chai-as-promised';
import privateKey from '../substrate/privateKey';
import usingApi, {submitTransactionAsync} from '../substrate/substrate-api';
-import {createCollectionExpectSuccess, nftEventMessage, normalizeAccountId} from '../util/helpers';
+import {createCollectionExpectSuccess, uniqueEventMessage, normalizeAccountId} from '../util/helpers';
chai.use(chaiAsPromised);
const expect = chai.expect;
@@ -30,7 +30,7 @@
const collectionID = await createCollectionExpectSuccess();
const createItem = api.tx.unique.createItem(collectionID, normalizeAccountId(alice.address), 'NFT');
const events = await submitTransactionAsync(alice, createItem);
- const msg = JSON.stringify(nftEventMessage(events));
+ const msg = JSON.stringify(uniqueEventMessage(events));
expect(msg).to.be.contain(checkSection);
expect(msg).to.be.contain(checkTreasury);
expect(msg).to.be.contain(checkSystem);
tests/src/check-event/createMultipleItemsEvent.test.tsdiffbeforeafterboth--- a/tests/src/check-event/createMultipleItemsEvent.test.ts
+++ b/tests/src/check-event/createMultipleItemsEvent.test.ts
@@ -10,7 +10,7 @@
import chaiAsPromised from 'chai-as-promised';
import privateKey from '../substrate/privateKey';
import usingApi, {submitTransactionAsync} from '../substrate/substrate-api';
-import {createCollectionExpectSuccess, nftEventMessage, normalizeAccountId} from '../util/helpers';
+import {createCollectionExpectSuccess, uniqueEventMessage, normalizeAccountId} from '../util/helpers';
chai.use(chaiAsPromised);
const expect = chai.expect;
@@ -31,7 +31,7 @@
const args = [{NFT: ['0x31', '0x31']}, {NFT: ['0x32', '0x32']}, {NFT: ['0x33', '0x33']}];
const createMultipleItems = api.tx.unique.createMultipleItems(collectionID, normalizeAccountId(alice.address), args);
const events = await submitTransactionAsync(alice, createMultipleItems);
- const msg = JSON.stringify(nftEventMessage(events));
+ const msg = JSON.stringify(uniqueEventMessage(events));
expect(msg).to.be.contain(checkSection);
expect(msg).to.be.contain(checkTreasury);
expect(msg).to.be.contain(checkSystem);
tests/src/check-event/destroyCollectionEvent.test.tsdiffbeforeafterboth--- a/tests/src/check-event/destroyCollectionEvent.test.ts
+++ b/tests/src/check-event/destroyCollectionEvent.test.ts
@@ -10,7 +10,7 @@
import chaiAsPromised from 'chai-as-promised';
import privateKey from '../substrate/privateKey';
import usingApi, {submitTransactionAsync} from '../substrate/substrate-api';
-import {createCollectionExpectSuccess, nftEventMessage} from '../util/helpers';
+import {createCollectionExpectSuccess, uniqueEventMessage} from '../util/helpers';
chai.use(chaiAsPromised);
const expect = chai.expect;
@@ -29,7 +29,7 @@
const collectionID = await createCollectionExpectSuccess();
const destroyCollection = api.tx.unique.destroyCollection(collectionID);
const events = await submitTransactionAsync(alice, destroyCollection);
- const msg = JSON.stringify(nftEventMessage(events));
+ const msg = JSON.stringify(uniqueEventMessage(events));
expect(msg).to.be.contain(checkTreasury);
expect(msg).to.be.contain(checkSystem);
});
tests/src/check-event/transferEvent.test.tsdiffbeforeafterboth--- a/tests/src/check-event/transferEvent.test.ts
+++ b/tests/src/check-event/transferEvent.test.ts
@@ -10,7 +10,7 @@
import chaiAsPromised from 'chai-as-promised';
import privateKey from '../substrate/privateKey';
import usingApi, {submitTransactionAsync} from '../substrate/substrate-api';
-import {createCollectionExpectSuccess, createItemExpectSuccess, nftEventMessage, normalizeAccountId} from '../util/helpers';
+import {createCollectionExpectSuccess, createItemExpectSuccess, uniqueEventMessage, normalizeAccountId} from '../util/helpers';
chai.use(chaiAsPromised);
const expect = chai.expect;
@@ -33,7 +33,7 @@
const itemID = await createItemExpectSuccess(alice, collectionID, 'NFT');
const transfer = api.tx.unique.transfer(normalizeAccountId(bob.address), collectionID, itemID, 1);
const events = await submitTransactionAsync(alice, transfer);
- const msg = JSON.stringify(nftEventMessage(events));
+ const msg = JSON.stringify(uniqueEventMessage(events));
expect(msg).to.be.contain(checkSection);
expect(msg).to.be.contain(checkTreasury);
expect(msg).to.be.contain(checkSystem);
tests/src/check-event/transferFromEvent.test.tsdiffbeforeafterboth--- a/tests/src/check-event/transferFromEvent.test.ts
+++ b/tests/src/check-event/transferFromEvent.test.ts
@@ -10,7 +10,7 @@
import chaiAsPromised from 'chai-as-promised';
import privateKey from '../substrate/privateKey';
import usingApi, {submitTransactionAsync} from '../substrate/substrate-api';
-import {createCollectionExpectSuccess, createItemExpectSuccess, nftEventMessage, normalizeAccountId} from '../util/helpers';
+import {createCollectionExpectSuccess, createItemExpectSuccess, uniqueEventMessage, normalizeAccountId} from '../util/helpers';
chai.use(chaiAsPromised);
const expect = chai.expect;
@@ -33,7 +33,7 @@
const itemID = await createItemExpectSuccess(alice, collectionID, 'NFT');
const transferFrom = api.tx.unique.transferFrom(normalizeAccountId(alice.address), normalizeAccountId(bob.address), collectionID, itemID, 1);
const events = await submitTransactionAsync(alice, transferFrom);
- const msg = JSON.stringify(nftEventMessage(events));
+ const msg = JSON.stringify(uniqueEventMessage(events));
expect(msg).to.be.contain(checkSection);
expect(msg).to.be.contain(checkTreasury);
expect(msg).to.be.contain(checkSystem);
tests/src/interfaces/augment-api-consts.tsdiffbeforeafterboth--- a/tests/src/interfaces/augment-api-consts.ts
+++ b/tests/src/interfaces/augment-api-consts.ts
@@ -159,7 +159,6 @@
[key: string]: Codec;
};
vesting: {
- maxVestingSchedules: u32 & AugmentedConst<ApiType>;
/**
* The minimum amount transferred to call `vested_transfer`.
**/
tests/src/interfaces/augment-api-errors.tsdiffbeforeafterboth--- a/tests/src/interfaces/augment-api-errors.ts
+++ b/tests/src/interfaces/augment-api-errors.ts
@@ -241,32 +241,6 @@
**/
[key: string]: AugmentedError<ApiType>;
};
- nft: {
- /**
- * Decimal_points parameter must be lower than MAX_DECIMAL_POINTS constant, currently it is 30.
- **/
- CollectionDecimalPointLimitExceeded: AugmentedError<ApiType>;
- /**
- * Collection limit bounds per collection exceeded
- **/
- CollectionLimitBoundsExceeded: AugmentedError<ApiType>;
- /**
- * This address is not set as sponsor, use setCollectionSponsor first.
- **/
- ConfirmUnsetSponsorFail: AugmentedError<ApiType>;
- /**
- * Length of items properties must be greater than 0.
- **/
- EmptyArgument: AugmentedError<ApiType>;
- /**
- * Tried to enable permissions which are only permitted to be disabled
- **/
- OwnerPermissionsCantBeReverted: AugmentedError<ApiType>;
- /**
- * Generic error
- **/
- [key: string]: AugmentedError<ApiType>;
- };
nonfungible: {
/**
* Used amount > 1 with NFT
@@ -390,28 +364,6 @@
* Maximum refungibility exceeded
**/
WrongRefungiblePieces: AugmentedError<ApiType>;
- /**
- * Generic error
- **/
- [key: string]: AugmentedError<ApiType>;
- };
- scheduler: {
- /**
- * Failed to schedule a call
- **/
- FailedToSchedule: AugmentedError<ApiType>;
- /**
- * Cannot find the scheduled call.
- **/
- NotFound: AugmentedError<ApiType>;
- /**
- * Reschedule failed because it does not change scheduled time.
- **/
- RescheduleNoChange: AugmentedError<ApiType>;
- /**
- * Given target block number is in the past.
- **/
- TargetBlockNumberInPast: AugmentedError<ApiType>;
/**
* Generic error
**/
@@ -475,28 +427,57 @@
**/
[key: string]: AugmentedError<ApiType>;
};
+ unique: {
+ /**
+ * Decimal_points parameter must be lower than MAX_DECIMAL_POINTS constant, currently it is 30.
+ **/
+ CollectionDecimalPointLimitExceeded: AugmentedError<ApiType>;
+ /**
+ * Collection limit bounds per collection exceeded
+ **/
+ CollectionLimitBoundsExceeded: AugmentedError<ApiType>;
+ /**
+ * This address is not set as sponsor, use setCollectionSponsor first.
+ **/
+ ConfirmUnsetSponsorFail: AugmentedError<ApiType>;
+ /**
+ * Length of items properties must be greater than 0.
+ **/
+ EmptyArgument: AugmentedError<ApiType>;
+ /**
+ * Tried to enable permissions which are only permitted to be disabled
+ **/
+ OwnerPermissionsCantBeReverted: AugmentedError<ApiType>;
+ /**
+ * Generic error
+ **/
+ [key: string]: AugmentedError<ApiType>;
+ };
vesting: {
/**
- * Amount being transferred is too low to create a vesting schedule.
+ * The vested transfer amount is too low
**/
AmountLow: AugmentedError<ApiType>;
/**
- * The account already has `MaxVestingSchedules` count of schedules and thus
- * cannot add another one. Consider merging existing schedules in order to add another.
+ * Insufficient amount of balance to lock
+ **/
+ InsufficientBalanceToLock: AugmentedError<ApiType>;
+ /**
+ * Failed because the maximum vesting schedules was exceeded
**/
- AtMaxVestingSchedules: AugmentedError<ApiType>;
+ MaxVestingSchedulesExceeded: AugmentedError<ApiType>;
/**
- * Failed to create a new schedule because some parameter was invalid.
+ * This account have too many vesting schedules
**/
- InvalidScheduleParams: AugmentedError<ApiType>;
+ TooManyVestingSchedules: AugmentedError<ApiType>;
/**
- * The account given is not vesting.
+ * Vesting period is zero
**/
- NotVesting: AugmentedError<ApiType>;
+ ZeroVestingPeriod: AugmentedError<ApiType>;
/**
- * An index was out of bounds of the vesting schedules.
+ * Number of vests is zero
**/
- ScheduleIndexOutOfBounds: AugmentedError<ApiType>;
+ ZeroVestingPeriodCount: AugmentedError<ApiType>;
/**
* Generic error
**/
tests/src/interfaces/augment-api-events.tsdiffbeforeafterboth--- a/tests/src/interfaces/augment-api-events.ts
+++ b/tests/src/interfaces/augment-api-events.ts
@@ -2,12 +2,11 @@
/* eslint-disable */
import type { EthereumLog, EvmCoreErrorExitReason } from './ethereum';
-import type { PalletCommonAccountBasicCrossAccountIdRepr } from './nft';
+import type { PalletCommonAccountBasicCrossAccountIdRepr } from './unique';
import type { ApiTypes } from '@polkadot/api/types';
-import type { Bytes, Null, Option, Result, U256, U8aFixed, u128, u32, u64, u8 } from '@polkadot/types';
+import type { Null, Option, Result, U256, U8aFixed, u128, u32, u64, u8 } from '@polkadot/types';
import type { AccountId32, H160, H256 } from '@polkadot/types/interfaces/runtime';
import type { FrameSupportTokensMiscBalanceStatus, FrameSupportWeightsDispatchInfo, SpRuntimeDispatchError, XcmV1MultiLocation, XcmV2Response, XcmV2TraitsError, XcmV2TraitsOutcome, XcmV2Xcm, XcmVersionedMultiAssets, XcmVersionedMultiLocation } from '@polkadot/types/lookup';
-import type { ITuple } from '@polkadot/types/types';
declare module '@polkadot/api/types/events' {
export interface AugmentedEvents<ApiType> {
@@ -389,24 +388,6 @@
**/
[key: string]: AugmentedEvent<ApiType>;
};
- scheduler: {
- /**
- * Canceled some task. \[when, index\]
- **/
- Canceled: AugmentedEvent<ApiType, [u32, u32]>;
- /**
- * Dispatched some task. \[task, id, result\]
- **/
- Dispatched: AugmentedEvent<ApiType, [ITuple<[u32, u32]>, Option<Bytes>, Result<Null, SpRuntimeDispatchError>]>;
- /**
- * Scheduled some task. \[when, index\]
- **/
- Scheduled: AugmentedEvent<ApiType, [u32, u32]>;
- /**
- * Generic event
- **/
- [key: string]: AugmentedEvent<ApiType>;
- };
sudo: {
/**
* The \[sudoer\] just switched identity; the old key is supplied.
@@ -492,15 +473,17 @@
};
vesting: {
/**
- * An \[account\] has become fully vested.
+ * Claimed vesting. \[who, locked_amount\]
+ **/
+ Claimed: AugmentedEvent<ApiType, [AccountId32, u128]>;
+ /**
+ * Added new vesting schedule. \[from, to, vesting_schedule\]
**/
- VestingCompleted: AugmentedEvent<ApiType, [AccountId32]>;
+ VestingScheduleAdded: AugmentedEvent<ApiType, [AccountId32, AccountId32, OrmlVestingVestingSchedule]>;
/**
- * The amount vested has been updated. This could indicate a change in funds available.
- * The balance given is the amount which is left unvested (and thus locked).
- * \[account, unvested\]
+ * Updated vesting schedules. \[who\]
**/
- VestingUpdated: AugmentedEvent<ApiType, [AccountId32, u128]>;
+ VestingSchedulesUpdated: AugmentedEvent<ApiType, [AccountId32]>;
/**
* Generic event
**/
tests/src/interfaces/augment-api-query.tsdiffbeforeafterboth--- a/tests/src/interfaces/augment-api-query.ts
+++ b/tests/src/interfaces/augment-api-query.ts
@@ -2,12 +2,12 @@
/* eslint-disable */
import type { EthereumBlock, EthereumReceipt, EthereumTransactionLegacyTransaction, FpRpcTransactionStatus } from './ethereum';
-import type { NftDataStructsCollection, PalletCommonAccountBasicCrossAccountIdRepr, PalletNonfungibleItemData, PalletRefungibleItemData, PalletUnqSchedulerCallSpec, PalletUnqSchedulerReleases, PalletUnqSchedulerScheduledV2 } from './nft';
import type { CumulusPalletDmpQueueConfigData, CumulusPalletDmpQueuePageIndexData, CumulusPalletParachainSystemRelayStateSnapshotMessagingStateSnapshot, CumulusPalletXcmpQueueInboundStatus, CumulusPalletXcmpQueueOutboundStatus, CumulusPalletXcmpQueueQueueConfigData, PolkadotParachainPrimitivesXcmpMessageFormat, PolkadotPrimitivesV1AbridgedHostConfiguration, PolkadotPrimitivesV1PersistedValidationData } from './polkadot';
+import type { PalletCommonAccountBasicCrossAccountIdRepr, PalletNonfungibleItemData, PalletRefungibleItemData, UpDataStructsCollection, UpDataStructsCollectionStats } from './unique';
import type { ApiTypes } from '@polkadot/api/types';
import type { BTreeMap, Bytes, Option, U256, Vec, bool, u128, u16, u32, u64 } from '@polkadot/types';
import type { AccountId32, H160, H256 } from '@polkadot/types/interfaces/runtime';
-import type { FrameSupportWeightsPerDispatchClassU64, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletTransactionPaymentReleases, PalletTreasuryProposal, PalletVestingReleases, PalletVestingVestingInfo, PolkadotCorePrimitivesOutboundHrmpMessage, PolkadotPrimitivesV1UpgradeRestriction, SpRuntimeGenericDigest } from '@polkadot/types/lookup';
+import type { FrameSupportWeightsPerDispatchClassU64, FrameSystemAccountInfo, FrameSystemEventRecord, FrameSystemLastRuntimeUpgradeInfo, FrameSystemPhase, PalletBalancesAccountData, PalletBalancesBalanceLock, PalletBalancesReleases, PalletBalancesReserveData, PalletTransactionPaymentReleases, PalletTreasuryProposal, PolkadotCorePrimitivesOutboundHrmpMessage, PolkadotPrimitivesV1UpgradeRestriction, SpRuntimeGenericDigest } from '@polkadot/types/lookup';
import type { AnyNumber, ITuple, Observable } from '@polkadot/types/types';
declare module '@polkadot/api/types/storage' {
@@ -58,10 +58,14 @@
/**
* Collection info
**/
- collectionById: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Option<NftDataStructsCollection>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
+ collectionById: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Option<UpDataStructsCollection>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
createdCollectionCount: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
destroyedCollectionCount: AugmentedQuery<ApiType, () => Observable<u32>, []> & QueryableStorageEntry<ApiType, []>;
/**
+ * Not used by code, exists only to provide some types to metadata
+ **/
+ dummyStorageValue: AugmentedQuery<ApiType, () => Observable<Option<ITuple<[UpDataStructsCollectionStats, u32, u32]>>>, []> & QueryableStorageEntry<ApiType, []>;
+ /**
* List of collection admins
**/
isAdmin: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => Observable<bool>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]> & QueryableStorageEntry<ApiType, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;
@@ -171,44 +175,6 @@
**/
[key: string]: QueryableStorageEntry<ApiType>;
};
- nft: {
- /**
- * Used for migrations
- **/
- chainVersion: AugmentedQuery<ApiType, () => Observable<u64>, []> & QueryableStorageEntry<ApiType, []>;
- /**
- * (Collection id (controlled?2), who created (real))
- * TODO: Off chain worker should remove from this map when collection gets removed
- **/
- createItemBasket: AugmentedQuery<ApiType, (arg: ITuple<[u32, AccountId32]> | [u32 | AnyNumber | Uint8Array, AccountId32 | string | Uint8Array]) => Observable<u32>, [ITuple<[u32, AccountId32]>]> & QueryableStorageEntry<ApiType, [ITuple<[u32, AccountId32]>]>;
- /**
- * Collection id (controlled?2), owning user (real)
- **/
- fungibleTransferBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: AccountId32 | string | Uint8Array) => Observable<u32>, [u32, AccountId32]> & QueryableStorageEntry<ApiType, [u32, AccountId32]>;
- /**
- * Collection id (controlled?2), token id (controlled?2)
- **/
- nftTransferBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array) => Observable<u32>, [u32, u32]> & QueryableStorageEntry<ApiType, [u32, u32]>;
- /**
- * Collection id (controlled?2), token id (controlled?2)
- **/
- reFungibleTransferBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array) => Observable<u32>, [u32, u32]> & QueryableStorageEntry<ApiType, [u32, u32]>;
- /**
- * Variable metadata sponsoring
- * Collection id (controlled?2), token id (controlled?2)
- **/
- variableMetaDataBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array) => Observable<Option<u32>>, [u32, u32]> & QueryableStorageEntry<ApiType, [u32, u32]>;
- /**
- * Generic query
- **/
- [key: string]: QueryableStorageEntry<ApiType>;
- };
- nftPayment: {
- /**
- * Generic query
- **/
- [key: string]: QueryableStorageEntry<ApiType>;
- };
nonfungible: {
accountBalance: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => Observable<u32>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]> & QueryableStorageEntry<ApiType, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;
allowance: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array) => Observable<Option<PalletCommonAccountBasicCrossAccountIdRepr>>, [u32, u32]> & QueryableStorageEntry<ApiType, [u32, u32]>;
@@ -383,27 +349,6 @@
**/
[key: string]: QueryableStorageEntry<ApiType>;
};
- scheduler: {
- /**
- * Items to be executed, indexed by the block number that they should be executed on.
- **/
- agenda: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Vec<Option<PalletUnqSchedulerScheduledV2>>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
- /**
- * Lookup from identity to the block number and index of the task.
- **/
- lookup: AugmentedQuery<ApiType, (arg: Bytes | string | Uint8Array) => Observable<Option<ITuple<[u32, u32]>>>, [Bytes]> & QueryableStorageEntry<ApiType, [Bytes]>;
- specAgenda: AugmentedQuery<ApiType, (arg: u32 | AnyNumber | Uint8Array) => Observable<Vec<Option<PalletUnqSchedulerCallSpec>>>, [u32]> & QueryableStorageEntry<ApiType, [u32]>;
- /**
- * Storage version of the pallet.
- *
- * New networks start with last version.
- **/
- storageVersion: AugmentedQuery<ApiType, () => Observable<PalletUnqSchedulerReleases>, []> & QueryableStorageEntry<ApiType, []>;
- /**
- * Generic query
- **/
- [key: string]: QueryableStorageEntry<ApiType>;
- };
sudo: {
/**
* The `AccountId` of the sudo key.
@@ -537,17 +482,51 @@
**/
[key: string]: QueryableStorageEntry<ApiType>;
};
+ unique: {
+ /**
+ * Used for migrations
+ **/
+ chainVersion: AugmentedQuery<ApiType, () => Observable<u64>, []> & QueryableStorageEntry<ApiType, []>;
+ /**
+ * (Collection id (controlled?2), who created (real))
+ * TODO: Off chain worker should remove from this map when collection gets removed
+ **/
+ createItemBasket: AugmentedQuery<ApiType, (arg: ITuple<[u32, AccountId32]> | [u32 | AnyNumber | Uint8Array, AccountId32 | string | Uint8Array]) => Observable<Option<u32>>, [ITuple<[u32, AccountId32]>]> & QueryableStorageEntry<ApiType, [ITuple<[u32, AccountId32]>]>;
+ fungibleApproveBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: AccountId32 | string | Uint8Array) => Observable<Option<u32>>, [u32, AccountId32]> & QueryableStorageEntry<ApiType, [u32, AccountId32]>;
+ /**
+ * Collection id (controlled?2), owning user (real)
+ **/
+ fungibleTransferBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: AccountId32 | string | Uint8Array) => Observable<Option<u32>>, [u32, AccountId32]> & QueryableStorageEntry<ApiType, [u32, AccountId32]>;
+ /**
+ * Approval sponsoring
+ **/
+ nftApproveBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array) => Observable<Option<u32>>, [u32, u32]> & QueryableStorageEntry<ApiType, [u32, u32]>;
+ /**
+ * Collection id (controlled?2), token id (controlled?2)
+ **/
+ nftTransferBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array) => Observable<Option<u32>>, [u32, u32]> & QueryableStorageEntry<ApiType, [u32, u32]>;
+ refungibleApproveBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array, arg3: AccountId32 | string | Uint8Array) => Observable<Option<u32>>, [u32, u32, AccountId32]> & QueryableStorageEntry<ApiType, [u32, u32, AccountId32]>;
+ /**
+ * Collection id (controlled?2), token id (controlled?2)
+ **/
+ reFungibleTransferBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array, arg3: AccountId32 | string | Uint8Array) => Observable<Option<u32>>, [u32, u32, AccountId32]> & QueryableStorageEntry<ApiType, [u32, u32, AccountId32]>;
+ /**
+ * Variable metadata sponsoring
+ * Collection id (controlled?2), token id (controlled?2)
+ **/
+ variableMetaDataBasket: AugmentedQuery<ApiType, (arg1: u32 | AnyNumber | Uint8Array, arg2: u32 | AnyNumber | Uint8Array) => Observable<Option<u32>>, [u32, u32]> & QueryableStorageEntry<ApiType, [u32, u32]>;
+ /**
+ * Generic query
+ **/
+ [key: string]: QueryableStorageEntry<ApiType>;
+ };
vesting: {
/**
- * Storage version of the pallet.
+ * Vesting schedules of an account.
*
- * New networks start with latest version, as determined by the genesis build.
+ * VestingSchedules: map AccountId => Vec<VestingSchedule>
**/
- storageVersion: AugmentedQuery<ApiType, () => Observable<PalletVestingReleases>, []> & QueryableStorageEntry<ApiType, []>;
- /**
- * Information regarding the vesting of a given account.
- **/
- vesting: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Option<Vec<PalletVestingVestingInfo>>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
+ vestingSchedules: AugmentedQuery<ApiType, (arg: AccountId32 | string | Uint8Array) => Observable<Vec<OrmlVestingVestingSchedule>>, [AccountId32]> & QueryableStorageEntry<ApiType, [AccountId32]>;
/**
* Generic query
**/
tests/src/interfaces/augment-api-rpc.tsdiffbeforeafterboth--- a/tests/src/interfaces/augment-api-rpc.ts
+++ b/tests/src/interfaces/augment-api-rpc.ts
@@ -1,7 +1,7 @@
// Auto-generated via `yarn polkadot-types-from-chain`, do not edit
/* eslint-disable */
-import type { NftDataStructsCollection, NftDataStructsCollectionId, NftDataStructsCollectionStats, NftDataStructsTokenId, PalletCommonAccountBasicCrossAccountIdRepr } from './nft';
+import type { PalletCommonAccountBasicCrossAccountIdRepr, UpDataStructsCollection, UpDataStructsCollectionId, UpDataStructsCollectionStats, UpDataStructsTokenId } from './unique';
import type { Bytes, HashMap, Json, Metadata, Null, Option, StorageKey, Text, U256, U64, Vec, bool, u128, u32, u64 } from '@polkadot/types';
import type { ExtrinsicOrHash, ExtrinsicStatus } from '@polkadot/types/interfaces/author';
import type { EpochAuthorship } from '@polkadot/types/interfaces/babe';
@@ -354,68 +354,6 @@
* Returns protocol version.
**/
version: AugmentedRpc<() => Observable<Text>>;
- };
- nft: {
- /**
- * Get amount of different user tokens
- **/
- accountBalance: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, at?: Hash | string | Uint8Array) => Observable<u32>>;
- /**
- * Get tokens owned by account
- **/
- accountTokens: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<NftDataStructsTokenId>>>;
- /**
- * Get admin list
- **/
- adminlist: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<PalletCommonAccountBasicCrossAccountIdRepr>>>;
- /**
- * Get allowed amount
- **/
- allowance: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, sender: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, spender: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, tokenId: NftDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<u128>>;
- /**
- * Check if user is allowed to use collection
- **/
- allowed: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, at?: Hash | string | Uint8Array) => Observable<bool>>;
- /**
- * Get allowlist
- **/
- allowlist: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<PalletCommonAccountBasicCrossAccountIdRepr>>>;
- /**
- * Get amount of specific account token
- **/
- balance: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, tokenId: NftDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<u128>>;
- /**
- * Get collection by specified id
- **/
- collectionById: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Option<NftDataStructsCollection>>>;
- /**
- * Get collection stats
- **/
- collectionStats: AugmentedRpc<(at?: Hash | string | Uint8Array) => Observable<NftDataStructsCollectionStats>>;
- /**
- * Get tokens contained in collection
- **/
- collectionTokens: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<NftDataStructsTokenId>>>;
- /**
- * Get token constant metadata
- **/
- constMetadata: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: NftDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Bytes>>;
- /**
- * Get last token id
- **/
- lastTokenId: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<NftDataStructsTokenId>>;
- /**
- * Check if token exists
- **/
- tokenExists: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: NftDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<bool>>;
- /**
- * Get token owner
- **/
- tokenOwner: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: NftDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<PalletCommonAccountBasicCrossAccountIdRepr>>;
- /**
- * Get token variable metadata
- **/
- variableMetadata: AugmentedRpc<(collection: NftDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: NftDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Bytes>>;
};
offchain: {
/**
@@ -609,6 +547,68 @@
**/
version: AugmentedRpc<() => Observable<Text>>;
};
+ unique: {
+ /**
+ * Get amount of different user tokens
+ **/
+ accountBalance: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, at?: Hash | string | Uint8Array) => Observable<u32>>;
+ /**
+ * Get tokens owned by account
+ **/
+ accountTokens: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<UpDataStructsTokenId>>>;
+ /**
+ * Get admin list
+ **/
+ adminlist: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<PalletCommonAccountBasicCrossAccountIdRepr>>>;
+ /**
+ * Get allowed amount
+ **/
+ allowance: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, sender: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, spender: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, tokenId: UpDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<u128>>;
+ /**
+ * Check if user is allowed to use collection
+ **/
+ allowed: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, at?: Hash | string | Uint8Array) => Observable<bool>>;
+ /**
+ * Get allowlist
+ **/
+ allowlist: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<PalletCommonAccountBasicCrossAccountIdRepr>>>;
+ /**
+ * Get amount of specific account token
+ **/
+ balance: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, account: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, tokenId: UpDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<u128>>;
+ /**
+ * Get collection by specified id
+ **/
+ collectionById: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Option<UpDataStructsCollection>>>;
+ /**
+ * Get collection stats
+ **/
+ collectionStats: AugmentedRpc<(at?: Hash | string | Uint8Array) => Observable<UpDataStructsCollectionStats>>;
+ /**
+ * Get tokens contained in collection
+ **/
+ collectionTokens: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Vec<UpDataStructsTokenId>>>;
+ /**
+ * Get token constant metadata
+ **/
+ constMetadata: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: UpDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Bytes>>;
+ /**
+ * Get last token id
+ **/
+ lastTokenId: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<UpDataStructsTokenId>>;
+ /**
+ * Check if token exists
+ **/
+ tokenExists: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: UpDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<bool>>;
+ /**
+ * Get token owner
+ **/
+ tokenOwner: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: UpDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<PalletCommonAccountBasicCrossAccountIdRepr>>;
+ /**
+ * Get token variable metadata
+ **/
+ variableMetadata: AugmentedRpc<(collection: UpDataStructsCollectionId | AnyNumber | Uint8Array, tokenId: UpDataStructsTokenId | AnyNumber | Uint8Array, at?: Hash | string | Uint8Array) => Observable<Bytes>>;
+ };
web3: {
/**
* Returns current client version.
tests/src/interfaces/augment-api-tx.tsdiffbeforeafterboth2/* eslint-disable */2/* eslint-disable */334import type { EthereumTransactionLegacyTransaction } from './ethereum';4import type { EthereumTransactionLegacyTransaction } from './ethereum';5import type { NftDataStructsAccessMode, NftDataStructsCollectionLimits, NftDataStructsCollectionMode, NftDataStructsCreateItemData, NftDataStructsMetaUpdatePermission, NftDataStructsSchemaVersion, PalletCommonAccountBasicCrossAccountIdRepr } from './nft';6import type { CumulusPrimitivesParachainInherentParachainInherentData } from './polkadot';5import type { CumulusPrimitivesParachainInherentParachainInherentData } from './polkadot';6import type { PalletCommonAccountBasicCrossAccountIdRepr, UpDataStructsAccessMode, UpDataStructsCollectionLimits, UpDataStructsCollectionMode, UpDataStructsCreateItemData, UpDataStructsMetaUpdatePermission, UpDataStructsSchemaVersion } from './unique';7import type { ApiTypes, SubmittableExtrinsic } from '@polkadot/api/types';7import type { ApiTypes, SubmittableExtrinsic } from '@polkadot/api/types';8import type { Bytes, Compact, Option, U256, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types';8import type { Bytes, Compact, Option, U256, Vec, bool, u128, u16, u32, u64 } from '@polkadot/types';9import type { Extrinsic } from '@polkadot/types/interfaces/extrinsics';9import type { Extrinsic } from '@polkadot/types/interfaces/extrinsics';10import type { AccountId32, Call, H160, H256, MultiAddress, Perbill } from '@polkadot/types/interfaces/runtime';10import type { AccountId32, Call, H160, H256, MultiAddress, Perbill } from '@polkadot/types/interfaces/runtime';11import type { PalletVestingVestingInfo, SpCoreChangesTrieChangesTrieConfiguration, XcmV1MultiLocation, XcmV2WeightLimit, XcmVersionedMultiAssets, XcmVersionedMultiLocation, XcmVersionedXcm } from '@polkadot/types/lookup';11import type { SpCoreChangesTrieChangesTrieConfiguration, XcmV1MultiLocation, XcmV2WeightLimit, XcmVersionedMultiAssets, XcmVersionedMultiLocation, XcmVersionedXcm } from '@polkadot/types/lookup';12import type { AnyNumber, ITuple } from '@polkadot/types/types';12import type { AnyNumber, ITuple } from '@polkadot/types/types';131314declare module '@polkadot/api/types/submittable' {14declare module '@polkadot/api/types/submittable' {201 **/201 **/202 [key: string]: SubmittableExtrinsicFunction<ApiType>;202 [key: string]: SubmittableExtrinsicFunction<ApiType>;203 };203 };204 nft: {205 /**206 * Adds an admin of the Collection.207 * NFT Collection can be controlled by multiple admin addresses (some which can also be servers, for example). Admins can issue and burn NFTs, as well as add and remove other admins, but cannot change NFT or Collection ownership.208 * 209 * # Permissions210 * 211 * * Collection Owner.212 * * Collection Admin.213 * 214 * # Arguments215 * 216 * * collection_id: ID of the Collection to add admin for.217 * 218 * * new_admin_id: Address of new admin to add.219 **/220 addCollectionAdmin: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newAdminId: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;221 /**222 * Add an address to allow list.223 * 224 * # Permissions225 * 226 * * Collection Owner227 * * Collection Admin228 * 229 * # Arguments230 * 231 * * collection_id.232 * 233 * * address.234 **/235 addToAllowList: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, address: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;236 /**237 * Set, change, or remove approved address to transfer the ownership of the NFT.238 * 239 * # Permissions240 * 241 * * Collection Owner242 * * Collection Admin243 * * Current NFT owner244 * 245 * # Arguments246 * 247 * * approved: Address that is approved to transfer this NFT or zero (if needed to remove approval).248 * 249 * * collection_id.250 * 251 * * item_id: ID of the item.252 **/253 approve: AugmentedSubmittable<(spender: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, amount: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletCommonAccountBasicCrossAccountIdRepr, u32, u32, u128]>;254 /**255 * Destroys a concrete instance of NFT on behalf of the owner256 * See also: [`approve`]257 * 258 * # Permissions259 * 260 * * Collection Owner.261 * * Collection Admin.262 * * Current NFT Owner.263 * 264 * # Arguments265 * 266 * * collection_id: ID of the collection.267 * 268 * * item_id: ID of NFT to burn.269 * 270 * * from: owner of item271 **/272 burnFrom: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, from: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr, u32, u128]>;273 /**274 * Destroys a concrete instance of NFT.275 * 276 * # Permissions277 * 278 * * Collection Owner.279 * * Collection Admin.280 * * Current NFT Owner.281 * 282 * # Arguments283 * 284 * * collection_id: ID of the collection.285 * 286 * * item_id: ID of NFT to burn.287 **/288 burnItem: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, u32, u128]>;289 /**290 * Change the owner of the collection.291 * 292 * # Permissions293 * 294 * * Collection Owner.295 * 296 * # Arguments297 * 298 * * collection_id.299 * 300 * * new_owner.301 **/302 changeCollectionOwner: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newOwner: AccountId32 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, AccountId32]>;303 /**304 * # Permissions305 * 306 * * Sponsor.307 * 308 * # Arguments309 * 310 * * collection_id.311 **/312 confirmSponsorship: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;313 /**314 * This method creates a Collection of NFTs. Each Token may have multiple properties encoded as an array of bytes of certain length. The initial owner and admin of the collection are set to the address that signed the transaction. Both addresses can be changed later.315 * 316 * # Permissions317 * 318 * * Anyone.319 * 320 * # Arguments321 * 322 * * collection_name: UTF-16 string with collection name (limit 64 characters), will be stored as zero-terminated.323 * 324 * * collection_description: UTF-16 string with collection description (limit 256 characters), will be stored as zero-terminated.325 * 326 * * token_prefix: UTF-8 string with token prefix.327 * 328 * * mode: [CollectionMode] collection type and type dependent data.329 **/330 createCollection: AugmentedSubmittable<(collectionName: Vec<u16> | (u16 | AnyNumber | Uint8Array)[], collectionDescription: Vec<u16> | (u16 | AnyNumber | Uint8Array)[], tokenPrefix: Bytes | string | Uint8Array, mode: NftDataStructsCollectionMode | { NFT: any } | { Fungible: any } | { ReFungible: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Vec<u16>, Vec<u16>, Bytes, NftDataStructsCollectionMode]>;331 /**332 * This method creates a concrete instance of NFT Collection created with CreateCollection method.333 * 334 * # Permissions335 * 336 * * Collection Owner.337 * * Collection Admin.338 * * Anyone if339 * * Allow List is enabled, and340 * * Address is added to allow list, and341 * * MintPermission is enabled (see SetMintPermission method)342 * 343 * # Arguments344 * 345 * * collection_id: ID of the collection.346 * 347 * * owner: Address, initial owner of the NFT.348 * 349 * * data: Token data to store on chain.350 **/351 createItem: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, owner: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, data: NftDataStructsCreateItemData | { NFT: any } | { Fungible: any } | { ReFungible: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr, NftDataStructsCreateItemData]>;352 /**353 * This method creates multiple items in a collection created with CreateCollection method.354 * 355 * # Permissions356 * 357 * * Collection Owner.358 * * Collection Admin.359 * * Anyone if360 * * Allow List is enabled, and361 * * Address is added to allow list, and362 * * MintPermission is enabled (see SetMintPermission method)363 * 364 * # Arguments365 * 366 * * collection_id: ID of the collection.367 * 368 * * itemsData: Array items properties. Each property is an array of bytes itself, see [create_item].369 * 370 * * owner: Address, initial owner of the NFT.371 **/372 createMultipleItems: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, owner: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, itemsData: Vec<NftDataStructsCreateItemData> | (NftDataStructsCreateItemData | { NFT: any } | { Fungible: any } | { ReFungible: any } | string | Uint8Array)[]) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr, Vec<NftDataStructsCreateItemData>]>;373 /**374 * **DANGEROUS**: Destroys collection and all NFTs within this collection. Users irrecoverably lose their assets and may lose real money.375 * 376 * # Permissions377 * 378 * * Collection Owner.379 * 380 * # Arguments381 * 382 * * collection_id: collection to destroy.383 **/384 destroyCollection: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;385 /**386 * Remove admin address of the Collection. An admin address can remove itself. List of admins may become empty, in which case only Collection Owner will be able to add an Admin.387 * 388 * # Permissions389 * 390 * * Collection Owner.391 * * Collection Admin.392 * 393 * # Arguments394 * 395 * * collection_id: ID of the Collection to remove admin for.396 * 397 * * account_id: Address of admin to remove.398 **/399 removeCollectionAdmin: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, accountId: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;400 /**401 * Switch back to pay-per-own-transaction model.402 * 403 * # Permissions404 * 405 * * Collection owner.406 * 407 * # Arguments408 * 409 * * collection_id.410 **/411 removeCollectionSponsor: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;412 /**413 * Remove an address from allow list.414 * 415 * # Permissions416 * 417 * * Collection Owner418 * * Collection Admin419 * 420 * # Arguments421 * 422 * * collection_id.423 * 424 * * address.425 **/426 removeFromAllowList: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, address: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;427 setCollectionLimits: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newLimit: NftDataStructsCollectionLimits | { accountTokenOwnershipLimit?: any; sponsoredDataSize?: any; sponsoredDataRateLimit?: any; tokenLimit?: any; sponsorTransferTimeout?: any; ownerCanTransfer?: any; ownerCanDestroy?: any; transfersEnabled?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, NftDataStructsCollectionLimits]>;428 /**429 * # Permissions430 * 431 * * Collection Owner432 * 433 * # Arguments434 * 435 * * collection_id.436 * 437 * * new_sponsor.438 **/439 setCollectionSponsor: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newSponsor: AccountId32 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, AccountId32]>;440 /**441 * Set const on-chain data schema.442 * 443 * # Permissions444 * 445 * * Collection Owner446 * * Collection Admin447 * 448 * # Arguments449 * 450 * * collection_id.451 * 452 * * schema: String representing the const on-chain data schema.453 **/454 setConstOnChainSchema: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, schema: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Bytes]>;455 /**456 * Set meta_update_permission value for particular collection457 * 458 * # Permissions459 * 460 * * Collection Owner.461 * 462 * # Arguments463 * 464 * * collection_id: ID of the collection.465 * 466 * * value: New flag value.467 **/468 setMetaUpdatePermissionFlag: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, value: NftDataStructsMetaUpdatePermission | 'ItemOwner' | 'Admin' | 'None' | number | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, NftDataStructsMetaUpdatePermission]>;469 /**470 * Allows Anyone to create tokens if:471 * * Allow List is enabled, and472 * * Address is added to allow list, and473 * * This method was called with True parameter474 * 475 * # Permissions476 * * Collection Owner477 * 478 * # Arguments479 * 480 * * collection_id.481 * 482 * * mint_permission: Boolean parameter. If True, allows minting to Anyone with conditions above.483 **/484 setMintPermission: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, mintPermission: bool | boolean | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, bool]>;485 /**486 * Set off-chain data schema.487 * 488 * # Permissions489 * 490 * * Collection Owner491 * * Collection Admin492 * 493 * # Arguments494 * 495 * * collection_id.496 * 497 * * schema: String representing the offchain data schema.498 **/499 setOffchainSchema: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, schema: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Bytes]>;500 /**501 * Toggle between normal and allow list access for the methods with access for `Anyone`.502 * 503 * # Permissions504 * 505 * * Collection Owner.506 * 507 * # Arguments508 * 509 * * collection_id.510 * 511 * * mode: [AccessMode]512 **/513 setPublicAccessMode: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, mode: NftDataStructsAccessMode | 'Normal' | 'AllowList' | number | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, NftDataStructsAccessMode]>;514 /**515 * Set schema standard516 * ImageURL517 * Unique518 * 519 * # Permissions520 * 521 * * Collection Owner522 * * Collection Admin523 * 524 * # Arguments525 * 526 * * collection_id.527 * 528 * * schema: SchemaVersion: enum529 **/530 setSchemaVersion: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, version: NftDataStructsSchemaVersion | 'ImageURL' | 'Unique' | number | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, NftDataStructsSchemaVersion]>;531 /**532 * Set transfers_enabled value for particular collection533 * 534 * # Permissions535 * 536 * * Collection Owner.537 * 538 * # Arguments539 * 540 * * collection_id: ID of the collection.541 * 542 * * value: New flag value.543 **/544 setTransfersEnabledFlag: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, value: bool | boolean | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, bool]>;545 /**546 * Set off-chain data schema.547 * 548 * # Permissions549 * 550 * * Collection Owner551 * * Collection Admin552 * 553 * # Arguments554 * 555 * * collection_id.556 * 557 * * schema: String representing the offchain data schema.558 **/559 setVariableMetaData: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, data: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, u32, Bytes]>;560 /**561 * Set variable on-chain data schema.562 * 563 * # Permissions564 * 565 * * Collection Owner566 * * Collection Admin567 * 568 * # Arguments569 * 570 * * collection_id.571 * 572 * * schema: String representing the variable on-chain data schema.573 **/574 setVariableOnChainSchema: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, schema: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Bytes]>;575 /**576 * Change ownership of the token.577 * 578 * # Permissions579 * 580 * * Collection Owner581 * * Collection Admin582 * * Current NFT owner583 * 584 * # Arguments585 * 586 * * recipient: Address of token recipient.587 * 588 * * collection_id.589 * 590 * * item_id: ID of the item591 * * Non-Fungible Mode: Required.592 * * Fungible Mode: Ignored.593 * * Re-Fungible Mode: Required.594 * 595 * * value: Amount to transfer.596 * * Non-Fungible Mode: Ignored597 * * Fungible Mode: Must specify transferred amount598 * * Re-Fungible Mode: Must specify transferred portion (between 0 and 1)599 **/600 transfer: AugmentedSubmittable<(recipient: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletCommonAccountBasicCrossAccountIdRepr, u32, u32, u128]>;601 /**602 * Change ownership of a NFT on behalf of the owner. See Approve method for additional information. After this method executes, the approval is removed so that the approved address will not be able to transfer this NFT again from this owner.603 * 604 * # Permissions605 * * Collection Owner606 * * Collection Admin607 * * Current NFT owner608 * * Address approved by current NFT owner609 * 610 * # Arguments611 * 612 * * from: Address that owns token.613 * 614 * * recipient: Address of token recipient.615 * 616 * * collection_id.617 * 618 * * item_id: ID of the item.619 * 620 * * value: Amount to transfer.621 **/622 transferFrom: AugmentedSubmittable<(from: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, recipient: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletCommonAccountBasicCrossAccountIdRepr, PalletCommonAccountBasicCrossAccountIdRepr, u32, u32, u128]>;623 /**624 * Generic tx625 **/626 [key: string]: SubmittableExtrinsicFunction<ApiType>;627 };628 nftPayment: {629 /**630 * Generic tx631 **/632 [key: string]: SubmittableExtrinsicFunction<ApiType>;633 };634 parachainSystem: {204 parachainSystem: {635 authorizeUpgrade: AugmentedSubmittable<(codeHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;205 authorizeUpgrade: AugmentedSubmittable<(codeHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;636 enactAuthorizedUpgrade: AugmentedSubmittable<(code: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;206 enactAuthorizedUpgrade: AugmentedSubmittable<(code: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;778 **/348 **/779 [key: string]: SubmittableExtrinsicFunction<ApiType>;349 [key: string]: SubmittableExtrinsicFunction<ApiType>;780 };350 };781 scheduler: {782 /**783 * Cancel an anonymously scheduled task.784 * 785 * # <weight>786 * - S = Number of already scheduled calls787 * - Base Weight: 22.15 + 2.869 * S µs788 * - DB Weight:789 * - Read: Agenda790 * - Write: Agenda, Lookup791 * - Will use base weight of 100 which should be good for up to 30 scheduled calls792 * # </weight>793 **/794 cancel: AugmentedSubmittable<(when: u32 | AnyNumber | Uint8Array, index: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, u32]>;795 /**796 * Cancel a named scheduled task.797 * 798 * # <weight>799 * - S = Number of already scheduled calls800 * - Base Weight: 24.91 + 2.907 * S µs801 * - DB Weight:802 * - Read: Agenda, Lookup803 * - Write: Agenda, Lookup804 * - Will use base weight of 100 which should be good for up to 30 scheduled calls805 * # </weight>806 **/807 cancelNamed: AugmentedSubmittable<(id: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes]>;808 /**809 * Anonymously schedule a task.810 * 811 * # <weight>812 * - S = Number of already scheduled calls813 * - Base Weight: 22.29 + .126 * S µs814 * - DB Weight:815 * - Read: Agenda816 * - Write: Agenda817 * - Will use base weight of 25 which should be good for up to 30 scheduled calls818 * # </weight>819 **/820 schedule: AugmentedSubmittable<(when: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | object | string | Uint8Array, priority: u8 | AnyNumber | Uint8Array, call: Call) => SubmittableExtrinsic<ApiType>, [u32, Option<ITuple<[u32, u32]>>, u8, Call]>;821 /**822 * Anonymously schedule a task after a delay.823 * 824 * # <weight>825 * Same as [`schedule`].826 * # </weight>827 **/828 scheduleAfter: AugmentedSubmittable<(after: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | object | string | Uint8Array, priority: u8 | AnyNumber | Uint8Array, call: Call) => SubmittableExtrinsic<ApiType>, [u32, Option<ITuple<[u32, u32]>>, u8, Call]>;829 /**830 * Schedule a named task.831 * 832 * # <weight>833 * - S = Number of already scheduled calls834 * - Base Weight: 29.6 + .159 * S µs835 * - DB Weight:836 * - Read: Agenda, Lookup837 * - Write: Agenda, Lookup838 * - Will use base weight of 35 which should be good for more than 30 scheduled calls839 * # </weight>840 **/841 scheduleNamed: AugmentedSubmittable<(id: Bytes | string | Uint8Array, when: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | object | string | Uint8Array, priority: u8 | AnyNumber | Uint8Array, call: Call) => SubmittableExtrinsic<ApiType>, [Bytes, u32, Option<ITuple<[u32, u32]>>, u8, Call]>;842 /**843 * Schedule a named task after a delay.844 * 845 * # <weight>846 * Same as [`schedule_named`].847 * # </weight>848 **/849 scheduleNamedAfter: AugmentedSubmittable<(id: Bytes | string | Uint8Array, after: u32 | AnyNumber | Uint8Array, maybePeriodic: Option<ITuple<[u32, u32]>> | null | object | string | Uint8Array, priority: u8 | AnyNumber | Uint8Array, call: Call) => SubmittableExtrinsic<ApiType>, [Bytes, u32, Option<ITuple<[u32, u32]>>, u8, Call]>;850 /**851 * Generic tx852 **/853 [key: string]: SubmittableExtrinsicFunction<ApiType>;854 };855 sudo: {351 sudo: {856 /**352 /**857 * Authenticates the current sudo key and sets the given AccountId (`new`) as the new sudo353 * Authenticates the current sudo key and sets the given AccountId (`new`) as the new sudo878 * - Weight of derivative `call` execution + 10,000.374 * - Weight of derivative `call` execution + 10,000.879 * # </weight>375 * # </weight>880 **/376 **/881 sudo: AugmentedSubmittable<(call: Call) => SubmittableExtrinsic<ApiType>, [Call]>;377 sudo: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, [Call]>;882 /**378 /**883 * Authenticates the sudo key and dispatches a function call with `Signed` origin from379 * Authenticates the sudo key and dispatches a function call with `Signed` origin from884 * a given account.380 * a given account.892 * - Weight of derivative `call` execution + 10,000.388 * - Weight of derivative `call` execution + 10,000.893 * # </weight>389 * # </weight>894 **/390 **/895 sudoAs: AugmentedSubmittable<(who: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, call: Call) => SubmittableExtrinsic<ApiType>, [MultiAddress, Call]>;391 sudoAs: AugmentedSubmittable<(who: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, ) => SubmittableExtrinsic<ApiType>, [MultiAddress, Call]>;896 /**392 /**897 * Authenticates the sudo key and dispatches a function call with `Root` origin.393 * Authenticates the sudo key and dispatches a function call with `Root` origin.898 * This function does not check the weight of the call, and instead allows the394 * This function does not check the weight of the call, and instead allows the905 * - The weight of this call is defined by the caller.401 * - The weight of this call is defined by the caller.906 * # </weight>402 * # </weight>907 **/403 **/908 sudoUncheckedWeight: AugmentedSubmittable<(call: Call, weight: u64 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Call, u64]>;404 sudoUncheckedWeight: AugmentedSubmittable<(, weight: u64 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Call, u64]>;909 /**405 /**910 * Generic tx406 * Generic tx911 **/407 **/1094 **/590 **/1095 [key: string]: SubmittableExtrinsicFunction<ApiType>;591 [key: string]: SubmittableExtrinsicFunction<ApiType>;1096 };592 };1097 vesting: {593 unique: {1098 /**594 /**1099 * Force a vested transfer.595 * Adds an admin of the Collection.596 * NFT Collection can be controlled by multiple admin addresses (some which can also be servers, for example). Admins can issue and burn NFTs, as well as add and remove other admins, but cannot change NFT or Collection ownership.1100 * 597 * 1101 * The dispatch origin for this call must be _Root_.598 * # Permissions1102 * 599 * 1103 * - `source`: The account whose funds should be transferred.600 * * Collection Owner.1104 * - `target`: The account that should be transferred the vested funds.1105 * - `schedule`: The vesting schedule attached to the transfer.601 * * Collection Admin.1106 * 602 * 1107 * Emits `VestingCreated`.603 * # Arguments1108 * 604 * 1109 * NOTE: This will unlock all schedules through the current block.605 * * collection_id: ID of the Collection to add admin for.1110 * 606 * 1111 * # <weight>607 * * new_admin_id: Address of new admin to add.1112 * - `O(1)`.1113 * - DbWeight: 4 Reads, 4 Writes1114 * - Reads: Vesting Storage, Balances Locks, Target Account, Source Account1115 * - Writes: Vesting Storage, Balances Locks, Target Account, Source Account1116 * # </weight>1117 **/608 **/1118 forceVestedTransfer: AugmentedSubmittable<(source: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, target: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, schedule: PalletVestingVestingInfo | { locked?: any; perBlock?: any; startingBlock?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, MultiAddress, PalletVestingVestingInfo]>;609 addCollectionAdmin: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newAdminId: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;1119 /**610 /**1120 * Merge two vesting schedules together, creating a new vesting schedule that unlocks over611 * Add an address to allow list.1121 * the highest possible start and end blocks. If both schedules have already started the1122 * current block will be used as the schedule start; with the caveat that if one schedule1123 * is finished by the current block, the other will be treated as the new merged schedule,1124 * unmodified.1125 * 612 * 1126 * NOTE: If `schedule1_index == schedule2_index` this is a no-op.613 * # Permissions1127 * NOTE: This will unlock all schedules through the current block prior to merging.1128 * NOTE: If both schedules have ended by the current block, no new schedule will be created1129 * and both will be removed.1130 * 614 * 1131 * Merged schedule attributes:615 * * Collection Owner1132 * - `starting_block`: `MAX(schedule1.starting_block, scheduled2.starting_block,1133 * current_block)`.616 * * Collection Admin1134 * - `ending_block`: `MAX(schedule1.ending_block, schedule2.ending_block)`.1135 * - `locked`: `schedule1.locked_at(current_block) + schedule2.locked_at(current_block)`.1136 * 617 * 1137 * The dispatch origin for this call must be _Signed_.618 * # Arguments1138 * 619 * 1139 * - `schedule1_index`: index of the first schedule to merge.620 * * collection_id.1140 * - `schedule2_index`: index of the second schedule to merge.621 * 622 * * address.1141 **/623 **/1142 mergeSchedules: AugmentedSubmittable<(schedule1Index: u32 | AnyNumber | Uint8Array, schedule2Index: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, u32]>;624 addToAllowList: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, address: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;1143 /**625 /**1144 * Unlock any vested funds of the sender account.626 * Set, change, or remove approved address to transfer the ownership of the NFT.1145 * 627 * 1146 * The dispatch origin for this call must be _Signed_ and the sender must have funds still628 * # Permissions1147 * locked under this pallet.1148 * 629 * 1149 * Emits either `VestingCompleted` or `VestingUpdated`.630 * * Collection Owner631 * * Collection Admin632 * * Current NFT owner1150 * 633 * 1151 * # <weight>634 * # Arguments1152 * - `O(1)`.635 * 1153 * - DbWeight: 2 Reads, 2 Writes636 * * approved: Address that is approved to transfer this NFT or zero (if needed to remove approval).1154 * - Reads: Vesting Storage, Balances Locks, [Sender Account]637 * 1155 * - Writes: Vesting Storage, Balances Locks, [Sender Account]638 * * collection_id.639 * 1156 * # </weight>640 * * item_id: ID of the item.1157 **/641 **/1158 vest: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;642 approve: AugmentedSubmittable<(spender: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, amount: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletCommonAccountBasicCrossAccountIdRepr, u32, u32, u128]>;1159 /**643 /**1160 * Create a vested transfer.644 * Destroys a concrete instance of NFT on behalf of the owner645 * See also: [`approve`]1161 * 646 * 1162 * The dispatch origin for this call must be _Signed_.647 * # Permissions1163 * 648 * 1164 * - `target`: The account receiving the vested funds.649 * * Collection Owner.1165 * - `schedule`: The vesting schedule attached to the transfer.650 * * Collection Admin.651 * * Current NFT Owner.1166 * 652 * 1167 * Emits `VestingCreated`.653 * # Arguments1168 * 654 * 1169 * NOTE: This will unlock all schedules through the current block.655 * * collection_id: ID of the collection.1170 * 656 * 1171 * # <weight>657 * * item_id: ID of NFT to burn.1172 * - `O(1)`.1173 * - DbWeight: 3 Reads, 3 Writes658 * 1174 * - Reads: Vesting Storage, Balances Locks, Target Account, [Sender Account]659 * * from: owner of item1175 * - Writes: Vesting Storage, Balances Locks, Target Account, [Sender Account]1176 * # </weight>1177 **/660 **/1178 vestedTransfer: AugmentedSubmittable<(target: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, schedule: PalletVestingVestingInfo | { locked?: any; perBlock?: any; startingBlock?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, PalletVestingVestingInfo]>;661 burnFrom: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, from: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr, u32, u128]>;1179 /**662 /**1180 * Unlock any vested funds of a `target` account.663 * Destroys a concrete instance of NFT.1181 * 664 * 1182 * The dispatch origin for this call must be _Signed_.665 * # Permissions1183 * 666 * 1184 * - `target`: The account whose vested funds should be unlocked. Must have funds still667 * * Collection Owner.668 * * Collection Admin.1185 * locked under this pallet.669 * * Current NFT Owner.1186 * 670 * 1187 * Emits either `VestingCompleted` or `VestingUpdated`.671 * # Arguments1188 * 672 * 1189 * # <weight>673 * * collection_id: ID of the collection.1190 * - `O(1)`.1191 * - DbWeight: 3 Reads, 3 Writes674 * 1192 * - Reads: Vesting Storage, Balances Locks, Target Account675 * * item_id: ID of NFT to burn.1193 * - Writes: Vesting Storage, Balances Locks, Target Account1194 * # </weight>1195 **/676 **/1196 vestOther: AugmentedSubmittable<(target: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;677 burnItem: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, u32, u128]>;678 /**679 * Change the owner of the collection.680 * 681 * # Permissions682 * 683 * * Collection Owner.684 * 685 * # Arguments686 * 687 * * collection_id.688 * 689 * * new_owner.690 **/691 changeCollectionOwner: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newOwner: AccountId32 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, AccountId32]>;692 /**693 * # Permissions694 * 695 * * Sponsor.696 * 697 * # Arguments698 * 699 * * collection_id.700 **/701 confirmSponsorship: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;702 /**703 * This method creates a Collection of NFTs. Each Token may have multiple properties encoded as an array of bytes of certain length. The initial owner of the collection is set to the address that signed the transaction and can be changed later.704 * 705 * # Permissions706 * 707 * * Anyone.708 * 709 * # Arguments710 * 711 * * collection_name: UTF-16 string with collection name (limit 64 characters), will be stored as zero-terminated.712 * 713 * * collection_description: UTF-16 string with collection description (limit 256 characters), will be stored as zero-terminated.714 * 715 * * token_prefix: UTF-8 string with token prefix.716 * 717 * * mode: [CollectionMode] collection type and type dependent data.718 **/719 createCollection: AugmentedSubmittable<(collectionName: Vec<u16> | (u16 | AnyNumber | Uint8Array)[], collectionDescription: Vec<u16> | (u16 | AnyNumber | Uint8Array)[], tokenPrefix: Bytes | string | Uint8Array, mode: UpDataStructsCollectionMode | { NFT: any } | { Fungible: any } | { ReFungible: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Vec<u16>, Vec<u16>, Bytes, UpDataStructsCollectionMode]>;720 /**721 * This method creates a concrete instance of NFT Collection created with CreateCollection method.722 * 723 * # Permissions724 * 725 * * Collection Owner.726 * * Collection Admin.727 * * Anyone if728 * * Allow List is enabled, and729 * * Address is added to allow list, and730 * * MintPermission is enabled (see SetMintPermission method)731 * 732 * # Arguments733 * 734 * * collection_id: ID of the collection.735 * 736 * * owner: Address, initial owner of the NFT.737 * 738 * * data: Token data to store on chain.739 **/740 createItem: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, owner: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, data: UpDataStructsCreateItemData | { NFT: any } | { Fungible: any } | { ReFungible: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr, UpDataStructsCreateItemData]>;741 /**742 * This method creates multiple items in a collection created with CreateCollection method.743 * 744 * # Permissions745 * 746 * * Collection Owner.747 * * Collection Admin.748 * * Anyone if749 * * Allow List is enabled, and750 * * Address is added to allow list, and751 * * MintPermission is enabled (see SetMintPermission method)752 * 753 * # Arguments754 * 755 * * collection_id: ID of the collection.756 * 757 * * itemsData: Array items properties. Each property is an array of bytes itself, see [create_item].758 * 759 * * owner: Address, initial owner of the NFT.760 **/761 createMultipleItems: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, owner: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, itemsData: Vec<UpDataStructsCreateItemData> | (UpDataStructsCreateItemData | { NFT: any } | { Fungible: any } | { ReFungible: any } | string | Uint8Array)[]) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr, Vec<UpDataStructsCreateItemData>]>;762 /**763 * **DANGEROUS**: Destroys collection and all NFTs within this collection. Users irrecoverably lose their assets and may lose real money.764 * 765 * # Permissions766 * 767 * * Collection Owner.768 * 769 * # Arguments770 * 771 * * collection_id: collection to destroy.772 **/773 destroyCollection: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;774 /**775 * Remove admin address of the Collection. An admin address can remove itself. List of admins may become empty, in which case only Collection Owner will be able to add an Admin.776 * 777 * # Permissions778 * 779 * * Collection Owner.780 * * Collection Admin.781 * 782 * # Arguments783 * 784 * * collection_id: ID of the Collection to remove admin for.785 * 786 * * account_id: Address of admin to remove.787 **/788 removeCollectionAdmin: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, accountId: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;789 /**790 * Switch back to pay-per-own-transaction model.791 * 792 * # Permissions793 * 794 * * Collection owner.795 * 796 * # Arguments797 * 798 * * collection_id.799 **/800 removeCollectionSponsor: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;801 /**802 * Remove an address from allow list.803 * 804 * # Permissions805 * 806 * * Collection Owner807 * * Collection Admin808 * 809 * # Arguments810 * 811 * * collection_id.812 * 813 * * address.814 **/815 removeFromAllowList: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, address: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, PalletCommonAccountBasicCrossAccountIdRepr]>;816 setCollectionLimits: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newLimit: UpDataStructsCollectionLimits | { accountTokenOwnershipLimit?: any; sponsoredDataSize?: any; sponsoredDataRateLimit?: any; tokenLimit?: any; sponsorTransferTimeout?: any; sponsorApproveTimeout?: any; ownerCanTransfer?: any; ownerCanDestroy?: any; transfersEnabled?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, UpDataStructsCollectionLimits]>;817 /**818 * # Permissions819 * 820 * * Collection Owner821 * 822 * # Arguments823 * 824 * * collection_id.825 * 826 * * new_sponsor.827 **/828 setCollectionSponsor: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, newSponsor: AccountId32 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, AccountId32]>;829 /**830 * Set const on-chain data schema.831 * 832 * # Permissions833 * 834 * * Collection Owner835 * * Collection Admin836 * 837 * # Arguments838 * 839 * * collection_id.840 * 841 * * schema: String representing the const on-chain data schema.842 **/843 setConstOnChainSchema: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, schema: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Bytes]>;844 /**845 * Set meta_update_permission value for particular collection846 * 847 * # Permissions848 * 849 * * Collection Owner.850 * 851 * # Arguments852 * 853 * * collection_id: ID of the collection.854 * 855 * * value: New flag value.856 **/857 setMetaUpdatePermissionFlag: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, value: UpDataStructsMetaUpdatePermission | 'ItemOwner' | 'Admin' | 'None' | number | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, UpDataStructsMetaUpdatePermission]>;858 /**859 * Allows Anyone to create tokens if:860 * * Allow List is enabled, and861 * * Address is added to allow list, and862 * * This method was called with True parameter863 * 864 * # Permissions865 * * Collection Owner866 * 867 * # Arguments868 * 869 * * collection_id.870 * 871 * * mint_permission: Boolean parameter. If True, allows minting to Anyone with conditions above.872 **/873 setMintPermission: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, mintPermission: bool | boolean | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, bool]>;874 /**875 * Set off-chain data schema.876 * 877 * # Permissions878 * 879 * * Collection Owner880 * * Collection Admin881 * 882 * # Arguments883 * 884 * * collection_id.885 * 886 * * schema: String representing the offchain data schema.887 **/888 setOffchainSchema: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, schema: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Bytes]>;889 /**890 * Toggle between normal and allow list access for the methods with access for `Anyone`.891 * 892 * # Permissions893 * 894 * * Collection Owner.895 * 896 * # Arguments897 * 898 * * collection_id.899 * 900 * * mode: [AccessMode]901 **/902 setPublicAccessMode: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, mode: UpDataStructsAccessMode | 'Normal' | 'AllowList' | number | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, UpDataStructsAccessMode]>;903 /**904 * Set schema standard905 * ImageURL906 * Unique907 * 908 * # Permissions909 * 910 * * Collection Owner911 * * Collection Admin912 * 913 * # Arguments914 * 915 * * collection_id.916 * 917 * * schema: SchemaVersion: enum918 **/919 setSchemaVersion: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, version: UpDataStructsSchemaVersion | 'ImageURL' | 'Unique' | number | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, UpDataStructsSchemaVersion]>;920 /**921 * Set transfers_enabled value for particular collection922 * 923 * # Permissions924 * 925 * * Collection Owner.926 * 927 * # Arguments928 * 929 * * collection_id: ID of the collection.930 * 931 * * value: New flag value.932 **/933 setTransfersEnabledFlag: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, value: bool | boolean | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, bool]>;934 /**935 * Set off-chain data schema.936 * 937 * # Permissions938 * 939 * * Collection Owner940 * * Collection Admin941 * 942 * # Arguments943 * 944 * * collection_id.945 * 946 * * schema: String representing the offchain data schema.947 **/948 setVariableMetaData: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, data: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, u32, Bytes]>;949 /**950 * Set variable on-chain data schema.951 * 952 * # Permissions953 * 954 * * Collection Owner955 * * Collection Admin956 * 957 * # Arguments958 * 959 * * collection_id.960 * 961 * * schema: String representing the variable on-chain data schema.962 **/963 setVariableOnChainSchema: AugmentedSubmittable<(collectionId: u32 | AnyNumber | Uint8Array, schema: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32, Bytes]>;964 /**965 * Change ownership of the token.966 * 967 * # Permissions968 * 969 * * Collection Owner970 * * Collection Admin971 * * Current NFT owner972 * 973 * # Arguments974 * 975 * * recipient: Address of token recipient.976 * 977 * * collection_id.978 * 979 * * item_id: ID of the item980 * * Non-Fungible Mode: Required.981 * * Fungible Mode: Ignored.982 * * Re-Fungible Mode: Required.983 * 984 * * value: Amount to transfer.985 * * Non-Fungible Mode: Ignored986 * * Fungible Mode: Must specify transferred amount987 * * Re-Fungible Mode: Must specify transferred portion (between 0 and 1)988 **/989 transfer: AugmentedSubmittable<(recipient: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletCommonAccountBasicCrossAccountIdRepr, u32, u32, u128]>;990 /**991 * Change ownership of a NFT on behalf of the owner. See Approve method for additional information. After this method executes, the approval is removed so that the approved address will not be able to transfer this NFT again from this owner.992 * 993 * # Permissions994 * * Collection Owner995 * * Collection Admin996 * * Current NFT owner997 * * Address approved by current NFT owner998 * 999 * # Arguments1000 * 1001 * * from: Address that owns token.1002 * 1003 * * recipient: Address of token recipient.1004 * 1005 * * collection_id.1006 * 1007 * * item_id: ID of the item.1008 * 1009 * * value: Amount to transfer.1010 **/1011 transferFrom: AugmentedSubmittable<(from: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, recipient: PalletCommonAccountBasicCrossAccountIdRepr | { Substrate: any } | { Ethereum: any } | string | Uint8Array, collectionId: u32 | AnyNumber | Uint8Array, itemId: u32 | AnyNumber | Uint8Array, value: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletCommonAccountBasicCrossAccountIdRepr, PalletCommonAccountBasicCrossAccountIdRepr, u32, u32, u128]>;1012 /**1013 * Generic tx1014 **/1015 [key: string]: SubmittableExtrinsicFunction<ApiType>;1016 };1017 vesting: {1018 claim: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;1019 claimFor: AugmentedSubmittable<(dest: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress]>;1020 updateVestingSchedules: AugmentedSubmittable<(who: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, vestingSchedules: Vec<OrmlVestingVestingSchedule> | (OrmlVestingVestingSchedule | { start?: any; period?: any; periodCount?: any; perPeriod?: any } | string | Uint8Array)[]) => SubmittableExtrinsic<ApiType>, [MultiAddress, Vec<OrmlVestingVestingSchedule>]>;1021 vestedTransfer: AugmentedSubmittable<(dest: MultiAddress | { Id: any } | { Index: any } | { Raw: any } | { Address32: any } | { Address20: any } | string | Uint8Array, schedule: OrmlVestingVestingSchedule | { start?: any; period?: any; periodCount?: any; perPeriod?: any } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, OrmlVestingVestingSchedule]>;1197 /**1022 /**1198 * Generic tx1023 * Generic tx1199 **/1024 **/tests/src/interfaces/augment-types.tsdiffbeforeafterboth--- a/tests/src/interfaces/augment-types.ts
+++ b/tests/src/interfaces/augment-types.ts
@@ -2,8 +2,8 @@
/* eslint-disable */
import type { EthereumBlock, EthereumLog, EthereumReceipt, EthereumTransactionLegacyTransaction, EvmCoreErrorExitReason, FpRpcTransactionStatus } from './ethereum';
-import type { NftDataStructsAccessMode, NftDataStructsCollection, NftDataStructsCollectionId, NftDataStructsCollectionLimits, NftDataStructsCollectionMode, NftDataStructsCollectionStats, NftDataStructsCreateItemData, NftDataStructsMetaUpdatePermission, NftDataStructsSchemaVersion, NftDataStructsSponsorshipState, NftDataStructsTokenId, PalletCommonAccountBasicCrossAccountIdRepr, PalletNonfungibleItemData, PalletRefungibleItemData, PalletUnqSchedulerCallSpec, PalletUnqSchedulerReleases, PalletUnqSchedulerScheduledV2 } from './nft';
import type { CumulusPalletDmpQueueConfigData, CumulusPalletDmpQueuePageIndexData, CumulusPalletParachainSystemRelayStateSnapshotMessagingStateSnapshot, CumulusPalletXcmpQueueInboundStatus, CumulusPalletXcmpQueueOutboundStatus, CumulusPalletXcmpQueueQueueConfigData, CumulusPrimitivesParachainInherentParachainInherentData, PolkadotParachainPrimitivesXcmpMessageFormat, PolkadotPrimitivesV1AbridgedHostConfiguration, PolkadotPrimitivesV1PersistedValidationData } from './polkadot';
+import type { PalletCommonAccountBasicCrossAccountIdRepr, PalletNonfungibleItemData, PalletRefungibleItemData, PalletUnqSchedulerCallSpec, PalletUnqSchedulerReleases, PalletUnqSchedulerScheduledV2, UpDataStructsAccessMode, UpDataStructsCollection, UpDataStructsCollectionId, UpDataStructsCollectionLimits, UpDataStructsCollectionMode, UpDataStructsCollectionStats, UpDataStructsCreateItemData, UpDataStructsMetaUpdatePermission, UpDataStructsSchemaVersion, UpDataStructsSponsorshipState, UpDataStructsTokenId } from './unique';
import type { BitVec, Bool, Bytes, Data, I128, I16, I256, I32, I64, I8, Json, Null, Raw, StorageKey, Text, Type, U128, U16, U256, U32, U64, U8, USize, bool, i128, i16, i256, i32, i64, i8, u128, u16, u256, u32, u64, u8, usize } from '@polkadot/types';
import type { AssetApproval, AssetApprovalKey, AssetBalance, AssetDestroyWitness, AssetDetails, AssetMetadata, TAssetBalance, TAssetDepositBalance } from '@polkadot/types/interfaces/assets';
import type { BlockAttestations, IncludedBlocks, MoreAttestations } from '@polkadot/types/interfaces/attestations';
@@ -622,17 +622,6 @@
NextAuthority: NextAuthority;
NextConfigDescriptor: NextConfigDescriptor;
NextConfigDescriptorV1: NextConfigDescriptorV1;
- NftDataStructsAccessMode: NftDataStructsAccessMode;
- NftDataStructsCollection: NftDataStructsCollection;
- NftDataStructsCollectionId: NftDataStructsCollectionId;
- NftDataStructsCollectionLimits: NftDataStructsCollectionLimits;
- NftDataStructsCollectionMode: NftDataStructsCollectionMode;
- NftDataStructsCollectionStats: NftDataStructsCollectionStats;
- NftDataStructsCreateItemData: NftDataStructsCreateItemData;
- NftDataStructsMetaUpdatePermission: NftDataStructsMetaUpdatePermission;
- NftDataStructsSchemaVersion: NftDataStructsSchemaVersion;
- NftDataStructsSponsorshipState: NftDataStructsSponsorshipState;
- NftDataStructsTokenId: NftDataStructsTokenId;
NodeRole: NodeRole;
Nominations: Nominations;
NominatorIndex: NominatorIndex;
@@ -1026,6 +1015,17 @@
UnlockChunk: UnlockChunk;
UnrewardedRelayer: UnrewardedRelayer;
UnrewardedRelayersState: UnrewardedRelayersState;
+ UpDataStructsAccessMode: UpDataStructsAccessMode;
+ UpDataStructsCollection: UpDataStructsCollection;
+ UpDataStructsCollectionId: UpDataStructsCollectionId;
+ UpDataStructsCollectionLimits: UpDataStructsCollectionLimits;
+ UpDataStructsCollectionMode: UpDataStructsCollectionMode;
+ UpDataStructsCollectionStats: UpDataStructsCollectionStats;
+ UpDataStructsCreateItemData: UpDataStructsCreateItemData;
+ UpDataStructsMetaUpdatePermission: UpDataStructsMetaUpdatePermission;
+ UpDataStructsSchemaVersion: UpDataStructsSchemaVersion;
+ UpDataStructsSponsorshipState: UpDataStructsSponsorshipState;
+ UpDataStructsTokenId: UpDataStructsTokenId;
UpgradeGoAhead: UpgradeGoAhead;
UpgradeRestriction: UpgradeRestriction;
UpwardMessage: UpwardMessage;
tests/src/interfaces/definitions.tsdiffbeforeafterboth--- a/tests/src/interfaces/definitions.ts
+++ b/tests/src/interfaces/definitions.ts
@@ -1,3 +1,3 @@
-export {default as nft} from './nft/definitions';
+export {default as unique} from './unique/definitions';
export {default as ethereum} from './ethereum/definitions';
export {default as polkadot} from './polkadot/definitions';
tests/src/interfaces/nft/definitions.tsdiffbeforeafterboth--- a/tests/src/interfaces/nft/definitions.ts
+++ /dev/null
@@ -1,110 +0,0 @@
-function mkDummy(name: string) {
- return {
- ['dummy' + name]: 'u32',
- };
-}
-
-type RpcParam = {
- name: string;
- type: string;
- isOptional?: true;
-};
-
-const CROSS_ACCOUNT_ID_TYPE = 'PalletCommonAccountBasicCrossAccountIdRepr';
-const TOKEN_ID_TYPE = 'NftDataStructsTokenId';
-
-const collectionParam = {name: 'collection', type: 'NftDataStructsCollectionId'};
-const tokenParam = {name: 'tokenId', type: TOKEN_ID_TYPE};
-const crossAccountParam = (name = 'account') => ({name, type: CROSS_ACCOUNT_ID_TYPE});
-const atParam = {name: 'at', type: 'Hash', isOptional: true};
-
-const fun = (description: string, params: RpcParam[], type: string) => ({
- description,
- params: [...params, atParam],
- type,
-});
-
-export default {
- rpc: {
- adminlist: fun('Get admin list', [collectionParam], 'Vec<PalletCommonAccountBasicCrossAccountIdRepr>'),
- allowlist: fun('Get allowlist', [collectionParam], 'Vec<PalletCommonAccountBasicCrossAccountIdRepr>'),
-
- accountTokens: fun('Get tokens owned by account', [collectionParam, crossAccountParam()], 'Vec<NftDataStructsTokenId>'),
- collectionTokens: fun('Get tokens contained in collection', [collectionParam], 'Vec<NftDataStructsTokenId>'),
-
- lastTokenId: fun('Get last token id', [collectionParam], TOKEN_ID_TYPE),
- accountBalance: fun('Get amount of different user tokens', [collectionParam, crossAccountParam()], 'u32'),
- balance: fun('Get amount of specific account token', [collectionParam, crossAccountParam(), tokenParam], 'u128'),
- allowance: fun('Get allowed amount', [collectionParam, crossAccountParam('sender'), crossAccountParam('spender'), tokenParam], 'u128'),
- tokenOwner: fun('Get token owner', [collectionParam, tokenParam], CROSS_ACCOUNT_ID_TYPE),
- constMetadata: fun('Get token constant metadata', [collectionParam, tokenParam], 'Vec<u8>'),
- variableMetadata: fun('Get token variable metadata', [collectionParam, tokenParam], 'Vec<u8>'),
- tokenExists: fun('Check if token exists', [collectionParam, tokenParam], 'bool'),
- collectionById: fun('Get collection by specified id', [collectionParam], 'Option<NftDataStructsCollection>'),
- collectionStats: fun('Get collection stats', [], 'NftDataStructsCollectionStats'),
- allowed: fun('Check if user is allowed to use collection', [collectionParam, crossAccountParam()], 'bool'),
- },
- types: {
- PalletCommonAccountBasicCrossAccountIdRepr: {
- _enum: {
- Substrate: 'AccountId',
- Ethereum: 'H160',
- },
- },
- NftDataStructsCollection: {
- owner: 'AccountId',
- mode: 'NftDataStructsCollectionMode',
- access: 'NftDataStructsAccessMode',
- name: 'Vec<u16>',
- description: 'Vec<u16>',
- tokenPrefix: 'Vec<u8>',
- mintMode: 'bool',
- offchainSchema: 'Vec<u8>',
- schemaVersion: 'NftDataStructsSchemaVersion',
- sponsorship: 'NftDataStructsSponsorshipState',
- limits: 'NftDataStructsCollectionLimits',
- variableOnChainSchema: 'Vec<u8>',
- constOnChainSchema: 'Vec<u8>',
- metaUpdatePermission: 'NftDataStructsMetaUpdatePermission',
- },
- NftDataStructsCollectionStats: {
- created: 'u32',
- destroyed: 'u32',
- alive: 'u32',
- },
- NftDataStructsCollectionId: 'u32',
- NftDataStructsTokenId: 'u32',
- PalletNonfungibleItemData: mkDummy('NftItemData'),
- PalletRefungibleItemData: mkDummy('RftItemData'),
- NftDataStructsCollectionMode: mkDummy('CollectionMode'),
- NftDataStructsCreateItemData: mkDummy('CreateItemData'),
- NftDataStructsCollectionLimits: {
- accountTokenOwnershipLimit: 'Option<u32>',
- sponsoredDataSize: 'Option<u32>',
- sponsoredDataRateLimit: 'Option<u32>',
- tokenLimit: 'Option<u32>',
- sponsorTransferTimeout: 'Option<u32>',
- ownerCanTransfer: 'Option<bool>',
- ownerCanDestroy: 'Option<bool>',
- transfersEnabled: 'Option<bool>',
- },
- NftDataStructsMetaUpdatePermission: {
- _enum: ['ItemOwner', 'Admin', 'None'],
- },
- NftDataStructsSponsorshipState: {
- _enum: {
- Disabled: null,
- Unconfirmed: 'AccountId',
- Confirmed: 'AccountId',
- },
- },
- NftDataStructsAccessMode: {
- _enum: ['Normal', 'AllowList'],
- },
- NftDataStructsSchemaVersion: mkDummy('SchemaVersion'),
-
- PalletUnqSchedulerScheduledV2: mkDummy('ScheduledV2'),
- PalletUnqSchedulerCallSpec: mkDummy('CallSpec'),
- PalletUnqSchedulerReleases: mkDummy('Releases'),
- },
-};
tests/src/interfaces/nft/index.tsdiffbeforeafterboth--- a/tests/src/interfaces/nft/index.ts
+++ /dev/null
@@ -1,4 +0,0 @@
-// Auto-generated via `yarn polkadot-types-from-defs`, do not edit
-/* eslint-disable */
-
-export * from './types';
tests/src/interfaces/nft/types.tsdiffbeforeafterboth--- a/tests/src/interfaces/nft/types.ts
+++ /dev/null
@@ -1,120 +0,0 @@
-// Auto-generated via `yarn polkadot-types-from-defs`, do not edit
-/* eslint-disable */
-
-import type { Bytes, Enum, Option, Struct, Vec, bool, u16, u32 } from '@polkadot/types';
-import type { AccountId, H160 } from '@polkadot/types/interfaces/runtime';
-
-/** @name NftDataStructsAccessMode */
-export interface NftDataStructsAccessMode extends Enum {
- readonly isNormal: boolean;
- readonly isAllowList: boolean;
-}
-
-/** @name NftDataStructsCollection */
-export interface NftDataStructsCollection extends Struct {
- readonly owner: AccountId;
- readonly mode: NftDataStructsCollectionMode;
- readonly access: NftDataStructsAccessMode;
- readonly name: Vec<u16>;
- readonly description: Vec<u16>;
- readonly tokenPrefix: Bytes;
- readonly mintMode: bool;
- readonly offchainSchema: Bytes;
- readonly schemaVersion: NftDataStructsSchemaVersion;
- readonly sponsorship: NftDataStructsSponsorshipState;
- readonly limits: NftDataStructsCollectionLimits;
- readonly variableOnChainSchema: Bytes;
- readonly constOnChainSchema: Bytes;
- readonly metaUpdatePermission: NftDataStructsMetaUpdatePermission;
-}
-
-/** @name NftDataStructsCollectionId */
-export interface NftDataStructsCollectionId extends u32 {}
-
-/** @name NftDataStructsCollectionLimits */
-export interface NftDataStructsCollectionLimits extends Struct {
- readonly accountTokenOwnershipLimit: Option<u32>;
- readonly sponsoredDataSize: Option<u32>;
- readonly sponsoredDataRateLimit: Option<u32>;
- readonly tokenLimit: Option<u32>;
- readonly sponsorTransferTimeout: Option<u32>;
- readonly ownerCanTransfer: Option<bool>;
- readonly ownerCanDestroy: Option<bool>;
- readonly transfersEnabled: Option<bool>;
-}
-
-/** @name NftDataStructsCollectionMode */
-export interface NftDataStructsCollectionMode extends Struct {
- readonly dummyCollectionMode: u32;
-}
-
-/** @name NftDataStructsCollectionStats */
-export interface NftDataStructsCollectionStats extends Struct {
- readonly created: u32;
- readonly destroyed: u32;
- readonly alive: u32;
-}
-
-/** @name NftDataStructsCreateItemData */
-export interface NftDataStructsCreateItemData extends Struct {
- readonly dummyCreateItemData: u32;
-}
-
-/** @name NftDataStructsMetaUpdatePermission */
-export interface NftDataStructsMetaUpdatePermission extends Enum {
- readonly isItemOwner: boolean;
- readonly isAdmin: boolean;
- readonly isNone: boolean;
-}
-
-/** @name NftDataStructsSchemaVersion */
-export interface NftDataStructsSchemaVersion extends Struct {
- readonly dummySchemaVersion: u32;
-}
-
-/** @name NftDataStructsSponsorshipState */
-export interface NftDataStructsSponsorshipState extends Enum {
- readonly isDisabled: boolean;
- readonly isUnconfirmed: boolean;
- readonly asUnconfirmed: AccountId;
- readonly isConfirmed: boolean;
- readonly asConfirmed: AccountId;
-}
-
-/** @name NftDataStructsTokenId */
-export interface NftDataStructsTokenId extends u32 {}
-
-/** @name PalletCommonAccountBasicCrossAccountIdRepr */
-export interface PalletCommonAccountBasicCrossAccountIdRepr extends Enum {
- readonly isSubstrate: boolean;
- readonly asSubstrate: AccountId;
- readonly isEthereum: boolean;
- readonly asEthereum: H160;
-}
-
-/** @name PalletNonfungibleItemData */
-export interface PalletNonfungibleItemData extends Struct {
- readonly dummyNftItemData: u32;
-}
-
-/** @name PalletRefungibleItemData */
-export interface PalletRefungibleItemData extends Struct {
- readonly dummyRftItemData: u32;
-}
-
-/** @name PalletUnqSchedulerCallSpec */
-export interface PalletUnqSchedulerCallSpec extends Struct {
- readonly dummyCallSpec: u32;
-}
-
-/** @name PalletUnqSchedulerReleases */
-export interface PalletUnqSchedulerReleases extends Struct {
- readonly dummyReleases: u32;
-}
-
-/** @name PalletUnqSchedulerScheduledV2 */
-export interface PalletUnqSchedulerScheduledV2 extends Struct {
- readonly dummyScheduledV2: u32;
-}
-
-export type PHANTOM_NFT = 'nft';
tests/src/interfaces/types.tsdiffbeforeafterboth--- a/tests/src/interfaces/types.ts
+++ b/tests/src/interfaces/types.ts
@@ -1,6 +1,6 @@
// Auto-generated via `yarn polkadot-types-from-defs`, do not edit
/* eslint-disable */
-export * from './nft/types';
+export * from './unique/types';
export * from './ethereum/types';
export * from './polkadot/types';
tests/src/interfaces/unique/definitions.tsdiffbeforeafterboth--- /dev/null
+++ b/tests/src/interfaces/unique/definitions.ts
@@ -0,0 +1,110 @@
+function mkDummy(name: string) {
+ return {
+ ['dummy' + name]: 'u32',
+ };
+}
+
+type RpcParam = {
+ name: string;
+ type: string;
+ isOptional?: true;
+};
+
+const CROSS_ACCOUNT_ID_TYPE = 'PalletCommonAccountBasicCrossAccountIdRepr';
+const TOKEN_ID_TYPE = 'UpDataStructsTokenId';
+
+const collectionParam = {name: 'collection', type: 'UpDataStructsCollectionId'};
+const tokenParam = {name: 'tokenId', type: TOKEN_ID_TYPE};
+const crossAccountParam = (name = 'account') => ({name, type: CROSS_ACCOUNT_ID_TYPE});
+const atParam = {name: 'at', type: 'Hash', isOptional: true};
+
+const fun = (description: string, params: RpcParam[], type: string) => ({
+ description,
+ params: [...params, atParam],
+ type,
+});
+
+export default {
+ rpc: {
+ adminlist: fun('Get admin list', [collectionParam], 'Vec<PalletCommonAccountBasicCrossAccountIdRepr>'),
+ allowlist: fun('Get allowlist', [collectionParam], 'Vec<PalletCommonAccountBasicCrossAccountIdRepr>'),
+
+ accountTokens: fun('Get tokens owned by account', [collectionParam, crossAccountParam()], 'Vec<UpDataStructsTokenId>'),
+ collectionTokens: fun('Get tokens contained in collection', [collectionParam], 'Vec<UpDataStructsTokenId>'),
+
+ lastTokenId: fun('Get last token id', [collectionParam], TOKEN_ID_TYPE),
+ accountBalance: fun('Get amount of different user tokens', [collectionParam, crossAccountParam()], 'u32'),
+ balance: fun('Get amount of specific account token', [collectionParam, crossAccountParam(), tokenParam], 'u128'),
+ allowance: fun('Get allowed amount', [collectionParam, crossAccountParam('sender'), crossAccountParam('spender'), tokenParam], 'u128'),
+ tokenOwner: fun('Get token owner', [collectionParam, tokenParam], CROSS_ACCOUNT_ID_TYPE),
+ constMetadata: fun('Get token constant metadata', [collectionParam, tokenParam], 'Vec<u8>'),
+ variableMetadata: fun('Get token variable metadata', [collectionParam, tokenParam], 'Vec<u8>'),
+ tokenExists: fun('Check if token exists', [collectionParam, tokenParam], 'bool'),
+ collectionById: fun('Get collection by specified id', [collectionParam], 'Option<UpDataStructsCollection>'),
+ collectionStats: fun('Get collection stats', [], 'UpDataStructsCollectionStats'),
+ allowed: fun('Check if user is allowed to use collection', [collectionParam, crossAccountParam()], 'bool'),
+ },
+ types: {
+ PalletCommonAccountBasicCrossAccountIdRepr: {
+ _enum: {
+ Substrate: 'AccountId',
+ Ethereum: 'H160',
+ },
+ },
+ UpDataStructsCollection: {
+ owner: 'AccountId',
+ mode: 'UpDataStructsCollectionMode',
+ access: 'UpDataStructsAccessMode',
+ name: 'Vec<u16>',
+ description: 'Vec<u16>',
+ tokenPrefix: 'Vec<u8>',
+ mintMode: 'bool',
+ offchainSchema: 'Vec<u8>',
+ schemaVersion: 'UpDataStructsSchemaVersion',
+ sponsorship: 'UpDataStructsSponsorshipState',
+ limits: 'UpDataStructsCollectionLimits',
+ variableOnChainSchema: 'Vec<u8>',
+ constOnChainSchema: 'Vec<u8>',
+ metaUpdatePermission: 'UpDataStructsMetaUpdatePermission',
+ },
+ UpDataStructsCollectionStats: {
+ created: 'u32',
+ destroyed: 'u32',
+ alive: 'u32',
+ },
+ UpDataStructsCollectionId: 'u32',
+ UpDataStructsTokenId: 'u32',
+ PalletNonfungibleItemData: mkDummy('NftItemData'),
+ PalletRefungibleItemData: mkDummy('RftItemData'),
+ UpDataStructsCollectionMode: mkDummy('CollectionMode'),
+ UpDataStructsCreateItemData: mkDummy('CreateItemData'),
+ UpDataStructsCollectionLimits: {
+ accountTokenOwnershipLimit: 'Option<u32>',
+ sponsoredDataSize: 'Option<u32>',
+ sponsoredDataRateLimit: 'Option<u32>',
+ tokenLimit: 'Option<u32>',
+ sponsorTransferTimeout: 'Option<u32>',
+ ownerCanTransfer: 'Option<bool>',
+ ownerCanDestroy: 'Option<bool>',
+ transfersEnabled: 'Option<bool>',
+ },
+ UpDataStructsMetaUpdatePermission: {
+ _enum: ['ItemOwner', 'Admin', 'None'],
+ },
+ UpDataStructsSponsorshipState: {
+ _enum: {
+ Disabled: null,
+ Unconfirmed: 'AccountId',
+ Confirmed: 'AccountId',
+ },
+ },
+ UpDataStructsAccessMode: {
+ _enum: ['Normal', 'AllowList'],
+ },
+ UpDataStructsSchemaVersion: mkDummy('SchemaVersion'),
+
+ PalletUnqSchedulerScheduledV2: mkDummy('ScheduledV2'),
+ PalletUnqSchedulerCallSpec: mkDummy('CallSpec'),
+ PalletUnqSchedulerReleases: mkDummy('Releases'),
+ },
+};
tests/src/interfaces/unique/index.tsdiffbeforeafterboth--- /dev/null
+++ b/tests/src/interfaces/unique/index.ts
@@ -0,0 +1,4 @@
+// Auto-generated via `yarn polkadot-types-from-defs`, do not edit
+/* eslint-disable */
+
+export * from './types';
tests/src/interfaces/unique/types.tsdiffbeforeafterboth--- /dev/null
+++ b/tests/src/interfaces/unique/types.ts
@@ -0,0 +1,120 @@
+// Auto-generated via `yarn polkadot-types-from-defs`, do not edit
+/* eslint-disable */
+
+import type { Bytes, Enum, Option, Struct, Vec, bool, u16, u32 } from '@polkadot/types';
+import type { AccountId, H160 } from '@polkadot/types/interfaces/runtime';
+
+/** @name PalletCommonAccountBasicCrossAccountIdRepr */
+export interface PalletCommonAccountBasicCrossAccountIdRepr extends Enum {
+ readonly isSubstrate: boolean;
+ readonly asSubstrate: AccountId;
+ readonly isEthereum: boolean;
+ readonly asEthereum: H160;
+}
+
+/** @name PalletNonfungibleItemData */
+export interface PalletNonfungibleItemData extends Struct {
+ readonly dummyNftItemData: u32;
+}
+
+/** @name PalletRefungibleItemData */
+export interface PalletRefungibleItemData extends Struct {
+ readonly dummyRftItemData: u32;
+}
+
+/** @name PalletUnqSchedulerCallSpec */
+export interface PalletUnqSchedulerCallSpec extends Struct {
+ readonly dummyCallSpec: u32;
+}
+
+/** @name PalletUnqSchedulerReleases */
+export interface PalletUnqSchedulerReleases extends Struct {
+ readonly dummyReleases: u32;
+}
+
+/** @name PalletUnqSchedulerScheduledV2 */
+export interface PalletUnqSchedulerScheduledV2 extends Struct {
+ readonly dummyScheduledV2: u32;
+}
+
+/** @name UpDataStructsAccessMode */
+export interface UpDataStructsAccessMode extends Enum {
+ readonly isNormal: boolean;
+ readonly isAllowList: boolean;
+}
+
+/** @name UpDataStructsCollection */
+export interface UpDataStructsCollection extends Struct {
+ readonly owner: AccountId;
+ readonly mode: UpDataStructsCollectionMode;
+ readonly access: UpDataStructsAccessMode;
+ readonly name: Vec<u16>;
+ readonly description: Vec<u16>;
+ readonly tokenPrefix: Bytes;
+ readonly mintMode: bool;
+ readonly offchainSchema: Bytes;
+ readonly schemaVersion: UpDataStructsSchemaVersion;
+ readonly sponsorship: UpDataStructsSponsorshipState;
+ readonly limits: UpDataStructsCollectionLimits;
+ readonly variableOnChainSchema: Bytes;
+ readonly constOnChainSchema: Bytes;
+ readonly metaUpdatePermission: UpDataStructsMetaUpdatePermission;
+}
+
+/** @name UpDataStructsCollectionId */
+export interface UpDataStructsCollectionId extends u32 {}
+
+/** @name UpDataStructsCollectionLimits */
+export interface UpDataStructsCollectionLimits extends Struct {
+ readonly accountTokenOwnershipLimit: Option<u32>;
+ readonly sponsoredDataSize: Option<u32>;
+ readonly sponsoredDataRateLimit: Option<u32>;
+ readonly tokenLimit: Option<u32>;
+ readonly sponsorTransferTimeout: Option<u32>;
+ readonly ownerCanTransfer: Option<bool>;
+ readonly ownerCanDestroy: Option<bool>;
+ readonly transfersEnabled: Option<bool>;
+}
+
+/** @name UpDataStructsCollectionMode */
+export interface UpDataStructsCollectionMode extends Struct {
+ readonly dummyCollectionMode: u32;
+}
+
+/** @name UpDataStructsCollectionStats */
+export interface UpDataStructsCollectionStats extends Struct {
+ readonly created: u32;
+ readonly destroyed: u32;
+ readonly alive: u32;
+}
+
+/** @name UpDataStructsCreateItemData */
+export interface UpDataStructsCreateItemData extends Struct {
+ readonly dummyCreateItemData: u32;
+}
+
+/** @name UpDataStructsMetaUpdatePermission */
+export interface UpDataStructsMetaUpdatePermission extends Enum {
+ readonly isItemOwner: boolean;
+ readonly isAdmin: boolean;
+ readonly isNone: boolean;
+}
+
+/** @name UpDataStructsSchemaVersion */
+export interface UpDataStructsSchemaVersion extends Struct {
+ readonly dummySchemaVersion: u32;
+}
+
+/** @name UpDataStructsSponsorshipState */
+export interface UpDataStructsSponsorshipState extends Enum {
+ readonly isDisabled: boolean;
+ readonly isUnconfirmed: boolean;
+ readonly asUnconfirmed: AccountId;
+ readonly isConfirmed: boolean;
+ readonly asConfirmed: AccountId;
+}
+
+/** @name UpDataStructsTokenId */
+export interface UpDataStructsTokenId extends u32 {}
+
+export type PHANTOM_UNIQUE = 'unique';
tests/src/util/helpers.tsdiffbeforeafterboth--- a/tests/src/util/helpers.ts
+++ b/tests/src/util/helpers.ts
@@ -11,7 +11,7 @@
import chai from 'chai';
import chaiAsPromised from 'chai-as-promised';
import {alicesPublicKey} from '../accounts';
-import {NftDataStructsCollection} from '../interfaces';
+import {UpDataStructsCollection} from '../interfaces';
import privateKey from '../substrate/privateKey';
import {default as usingApi, submitTransactionAsync, submitTransactionExpectFailAsync} from '../substrate/substrate-api';
import {hexToStr, strToUTF16, utf16ToStr} from './util';
@@ -105,7 +105,7 @@
}
interface IGetMessage {
- checkMsgNftMethod: string;
+ checkMsgUnqMethod: string;
checkMsgTrsMethod: string;
checkMsgSysMethod: string;
}
@@ -133,13 +133,13 @@
variableData: number[];
}
-export function nftEventMessage(events: EventRecord[]): IGetMessage {
- let checkMsgNftMethod = '';
+export function uniqueEventMessage(events: EventRecord[]): IGetMessage {
+ let checkMsgUnqMethod = '';
let checkMsgTrsMethod = '';
let checkMsgSysMethod = '';
events.forEach(({event: {method, section}}) => {
if (section === 'common') {
- checkMsgNftMethod = method;
+ checkMsgUnqMethod = method;
} else if (section === 'treasury') {
checkMsgTrsMethod = method;
} else if (section === 'system') {
@@ -147,7 +147,7 @@
} else { return null; }
});
const result: IGetMessage = {
- checkMsgNftMethod,
+ checkMsgUnqMethod,
checkMsgTrsMethod,
checkMsgSysMethod,
};
@@ -716,8 +716,8 @@
tokenId: number, owner: IKeyringPair, approved: CrossAccountId | string, amount: number | bigint = 1,
) {
await usingApi(async (api: ApiPromise) => {
- const approveNftTx = api.tx.unique.approve(normalizeAccountId(approved), collectionId, tokenId, amount);
- const events = await submitTransactionAsync(owner, approveNftTx);
+ const approveUniqueTx = api.tx.unique.approve(normalizeAccountId(approved), collectionId, tokenId, amount);
+ const events = await submitTransactionAsync(owner, approveUniqueTx);
const result = getGenericResult(events);
expect(result.success).to.be.true;
@@ -730,8 +730,8 @@
tokenId: number, admin: IKeyringPair, owner: CrossAccountId | string, approved: CrossAccountId | string, amount: number | bigint = 1,
) {
await usingApi(async (api: ApiPromise) => {
- const approveNftTx = api.tx.unique.approve(normalizeAccountId(approved), collectionId, tokenId, amount);
- const events = await submitTransactionAsync(admin, approveNftTx);
+ const approveUniqueTx = api.tx.unique.approve(normalizeAccountId(approved), collectionId, tokenId, amount);
+ const events = await submitTransactionAsync(admin, approveUniqueTx);
const result = getGenericResult(events);
expect(result.success).to.be.true;
@@ -920,8 +920,8 @@
tokenId: number, owner: IKeyringPair, approved: IKeyringPair, amount: number | bigint = 1,
) {
await usingApi(async (api: ApiPromise) => {
- const approveNftTx = api.tx.unique.approve(normalizeAccountId(approved.address), collectionId, tokenId, amount);
- const events = await expect(submitTransactionExpectFailAsync(owner, approveNftTx)).to.be.rejected;
+ const approveUniqueTx = api.tx.unique.approve(normalizeAccountId(approved.address), collectionId, tokenId, amount);
+ const events = await expect(submitTransactionExpectFailAsync(owner, approveUniqueTx)).to.be.rejected;
const result = getCreateCollectionResult(events);
// tslint:disable-next-line:no-unused-expression
expect(result.success).to.be.false;
@@ -1212,7 +1212,7 @@
}
export const getDetailedCollectionInfo = async (api: ApiPromise, collectionId: number)
- : Promise<NftDataStructsCollection | null> => {
+ : Promise<UpDataStructsCollection | null> => {
return (await api.rpc.unique.collectionById(collectionId)).unwrapOr(null);
};
@@ -1221,7 +1221,7 @@
return (await api.rpc.unique.collectionStats()).created.toNumber();
};
-export async function queryCollectionExpectSuccess(api: ApiPromise, collectionId: number): Promise<NftDataStructsCollection> {
+export async function queryCollectionExpectSuccess(api: ApiPromise, collectionId: number): Promise<UpDataStructsCollection> {
return (await api.rpc.unique.collectionById(collectionId)).unwrap();
}