From 22388b5084002b7ee662c76976d5340185d55038 Mon Sep 17 00:00:00 2001 From: Prashant Bajpai <34747455+prashantasdeveloper@users.noreply.github.com> Date: Wed, 7 Feb 2024 17:31:49 +0530 Subject: [PATCH] feat: add examples related to confidential assets --- package.json | 21 ++- src/common/client.ts | 10 +- src/examples/addCAVenueFiltering.ts | 59 +++++++++ src/examples/addConfidentialTransaction.ts | 58 +++++++++ src/examples/affirmConfidentialTransaction.ts | 63 +++++++++ src/examples/confidentialAssetDetails.ts | 41 ++++++ .../confidentialTransactionDetails.ts | 48 +++++++ .../createAndMintConfidentialAsset.ts | 59 +++++++++ src/examples/createConfidentialAccount.ts | 31 +++++ src/examples/createConfidentialVenue.ts | 54 ++++++++ .../executeConfidentialTransaction.ts | 37 ++++++ tsconfig.json | 5 +- webpack.config.dev.js | 73 +++++++++++ yarn.lock | 122 +++--------------- 14 files changed, 573 insertions(+), 108 deletions(-) create mode 100644 src/examples/addCAVenueFiltering.ts create mode 100644 src/examples/addConfidentialTransaction.ts create mode 100644 src/examples/affirmConfidentialTransaction.ts create mode 100644 src/examples/confidentialAssetDetails.ts create mode 100644 src/examples/confidentialTransactionDetails.ts create mode 100644 src/examples/createAndMintConfidentialAsset.ts create mode 100644 src/examples/createConfidentialAccount.ts create mode 100644 src/examples/createConfidentialVenue.ts create mode 100644 src/examples/executeConfidentialTransaction.ts create mode 100644 webpack.config.dev.js diff --git a/package.json b/package.json index 5137353..3749024 100644 --- a/package.json +++ b/package.json @@ -28,6 +28,7 @@ "@typescript-eslint/eslint-plugin": "6.5.0", "@typescript-eslint/parser": "6.5.0", "cross-env": "^7.0.3", + "@zerollup/ts-transform-paths": "^1.7.11", "cz-conventional-changelog": "^3.0.2", "eslint": "^8.48.0", "eslint-config-prettier": "^9.0.0", @@ -53,10 +54,28 @@ }, "dependencies": { "@polymeshassociation/local-signing-manager": "^3.1.0", - "@polymeshassociation/polymesh-sdk": "23.0.0", + "@polymeshassociation/polymesh-sdk": "24.0.0-confidential-assets.1", "bluebird": "^3.7.2", "dotenv": "^16.0.3" }, + "resolutions": { + "@polkadot/keyring": "12.4.2", + "@polkadot/api-augment": "10.9.1", + "@polkadot/api-base": "10.9.1", + "@polkadot/api-derive": "10.9.1", + "@polkadot/rpc-augment": "10.9.1", + "@polkadot/rpc-core": "10.9.1", + "@polkadot/rpc-provider": "10.9.1", + "@polkadot/types": "10.9.1", + "@polkadot/types-augment": "10.9.1", + "@polkadot/types-codec": "10.9.1", + "@polkadot/types-create": "10.9.1", + "@polkadot/types-known": "10.9.1", + "@polkadot/util": "12.4.2", + "@polkadot/networks": "12.4.2", + "@polkadot/util-crypto": "12.4.2", + "@polkadot/x-bigint": "12.4.2" + }, "config": { "commitizen": { "path": "./node_modules/cz-conventional-changelog" diff --git a/src/common/client.ts b/src/common/client.ts index 2475ca8..e388106 100644 --- a/src/common/client.ts +++ b/src/common/client.ts @@ -15,11 +15,11 @@ export async function getClient(mnemonic?: string): Promise { api = await Polymesh.connect({ /* eslint-disable @typescript-eslint/no-non-null-assertion */ nodeUrl: process.env.POLYMESH_NODE_URL!, - middlewareV2: { - link: process.env.MIDDLEWARE_LINK!, - key: process.env.MIDDLEWARE_KEY!, - /* eslint-enable @typescript-eslint/no-non-null-assertion */ - }, + // middlewareV2: { + // link: process.env.MIDDLEWARE_LINK!, + // key: process.env.MIDDLEWARE_KEY!, + // /* eslint-enable @typescript-eslint/no-non-null-assertion */ + // }, signingManager: localSigningManager, }); } diff --git a/src/examples/addCAVenueFiltering.ts b/src/examples/addCAVenueFiltering.ts new file mode 100644 index 0000000..f98b254 --- /dev/null +++ b/src/examples/addCAVenueFiltering.ts @@ -0,0 +1,59 @@ +import { BigNumber } from '@polymeshassociation/polymesh-sdk'; +import { ConfidentialAsset } from '@polymeshassociation/polymesh-sdk/types'; + +import { getClient } from '~/common/client'; +import { toHumanObject } from '~/common/utils'; + +/** + * Retrieves all relevant info about a venue filtering for an asset + */ +export async function getVenueFiltering(asset: ConfidentialAsset) { + console.log('\n----------------------------------------------------------------------\n'); + console.log('\n💡 Fetching venue filtering details : '); + + const venueFilteringDetails = await asset.getVenueFilteringDetails(); + + console.log( + `\nℹ️ Venue Filtering details - ${JSON.stringify(toHumanObject(venueFilteringDetails))}` + ); +} + +/* + This script showcases how to get a confidential asset instance with its ID and get all the relevant info about it +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const account = process.argv[2]; + const assetId = process.argv[3]; + const allowedVenue = process.argv[4]; + if (!account || !process.env[account]) { + throw new Error('Please specify the account to be used to create the venue'); + } + if (!assetId || !allowedVenue) { + throw new Error('Please specify asset ID and allowed Venue'); + } + const api = await getClient(process.env[account]); + + const signingIdentity = await api.getSigningIdentity(); + if (!signingIdentity) { + throw new Error(`Account information not found for ${account}`); + } + console.log( + `\n💡 Enabling venue filtering for asset ID - ${assetId} and allowing venue - ${allowedVenue}` + ); + + const asset = await api.confidentialAssets.getConfidentialAsset({ id: assetId }); + + const setFilteringTx = await asset.setVenueFiltering({ + enabled: true, + allowedVenues: [new BigNumber(allowedVenue)], + }); + + await setFilteringTx.run(); + + console.log(`\n✅ Venue filtering has been set for asset ID - ${asset.toHuman()}`); + + await getVenueFiltering(asset); + + await api.disconnect(); +})(); diff --git a/src/examples/addConfidentialTransaction.ts b/src/examples/addConfidentialTransaction.ts new file mode 100644 index 0000000..46181a8 --- /dev/null +++ b/src/examples/addConfidentialTransaction.ts @@ -0,0 +1,58 @@ +import { BigNumber } from '@polymeshassociation/polymesh-sdk'; + +import { getClient } from '~/common/client'; +import { getTransactionDetails } from '~/examples/confidentialTransactionDetails'; + +/* + This script showcases how to get a confidential asset instance with its ID and get all the relevant info about it +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const account = process.argv[2]; + const sender = process.argv[3]; + const receiver = process.argv[4]; + const mediator = process.argv[5]; + const venueId = process.argv[6]; + const assetId = process.argv[7]; + if (!account || !process.env[account]) { + throw new Error('Please specify the account to be used to create the venue'); + } + if (!sender || !receiver || !mediator || !venueId) { + throw new Error('Please specify all the transaction details'); + } + + const api = await getClient(process.env[account]); + + const signingIdentity = await api.getSigningIdentity(); + if (!signingIdentity) { + throw new Error(`Account information not found for ${account}`); + } + + console.log( + `\n💡 Creating a new confidential transaction using ${account} DID - ${signingIdentity.did}` + ); + + const venue = await api.confidentialSettlements.getVenue({ id: new BigNumber(venueId) }); + + const addTransactionTx = await venue.addTransaction({ + legs: [ + { + sender, + receiver, + auditors: [], + mediators: [mediator], + assets: [assetId], + }, + ], + }); + + const createdTransaction = await addTransactionTx.run(); + + console.log( + `\n✅ New confidential transaction created with ID - ${createdTransaction.toHuman()}` + ); + + await getTransactionDetails(createdTransaction); + + await api.disconnect(); +})(); diff --git a/src/examples/affirmConfidentialTransaction.ts b/src/examples/affirmConfidentialTransaction.ts new file mode 100644 index 0000000..48d9e0a --- /dev/null +++ b/src/examples/affirmConfidentialTransaction.ts @@ -0,0 +1,63 @@ +import { BigNumber } from '@polymeshassociation/polymesh-sdk'; +import { + AffirmConfidentialTransactionParams, + ConfidentialAffirmParty, +} from '@polymeshassociation/polymesh-sdk/types'; + +import { getClient } from '~/common/client'; + +/* + This script showcases affirming of confidential transaction +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const account = process.argv[2]; + const transactionId = process.argv[3]; + const legId = process.argv[4]; + const party = process.argv[5] as ConfidentialAffirmParty; + const assetId = process.argv[6]; + const proof = process.argv[7]; + + if (!account) { + throw new Error('Please specify both account and public key for creating confidential account'); + } + const api = await getClient(process.env[account]); + + const signingIdentity = await api.getSigningIdentity(); + if (!signingIdentity) { + throw new Error(`Account information not found for ${account}`); + } + + console.log(`\n💡 Affirming transaction ${transactionId} for ${party}`); + + const transaction = await api.confidentialSettlements.getTransaction({ + id: new BigNumber(transactionId), + }); + + let params: AffirmConfidentialTransactionParams; + if (party === ConfidentialAffirmParty.Sender) { + params = { + legId: new BigNumber(legId), + party, + proofs: [ + { + asset: assetId, + proof, + }, + ], + }; + } else { + params = { + legId: new BigNumber(legId), + party, + }; + } + const affirmTx = await transaction.affirmLeg(params); + + await affirmTx.run(); + + console.log(`\n✅ Transaction ${transactionId} is now affirmed by ${party}`); + + // await getTransactionDetails(transaction); + await api.disconnect(); +})(); diff --git a/src/examples/confidentialAssetDetails.ts b/src/examples/confidentialAssetDetails.ts new file mode 100644 index 0000000..9f10590 --- /dev/null +++ b/src/examples/confidentialAssetDetails.ts @@ -0,0 +1,41 @@ +import { ConfidentialAsset } from '@polymeshassociation/polymesh-sdk/types'; + +import { getClient } from '~/common/client'; +import { toHumanObject } from '~/common/utils'; + +/** + * Retrieves all relevant info about a confidential asset + */ +export async function getConfidentialAssetDetails(asset: ConfidentialAsset) { + console.log('\n----------------------------------------------------------------------\n'); + console.log('\n💡 Getting all the information about asset ID : ', asset.toHuman()); + + const [exists, details, auditorInfo, venueFilteringDetails] = await Promise.all([ + asset.exists(), + asset.details(), + asset.getAuditors(), + asset.getVenueFilteringDetails(), + ]); + + console.log('\nℹ️ Exists - ', exists); + console.log('\nℹ️ Details - ', toHumanObject(details)); + console.log('\nℹ️ Auditors - ', toHumanObject(auditorInfo)); + console.log('\nℹ️ Venue filtering details - ', toHumanObject(venueFilteringDetails)); +} +/* + This script showcases how to get a confidential asset instance with its ID and get all the relevant info about it +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const assetId = process.argv[2]; + if (!assetId) { + throw new Error('Please specify asset ID to fetch the details'); + } + const api = await getClient(); + + const asset = await api.confidentialAssets.getConfidentialAsset({ id: assetId }); + + await getConfidentialAssetDetails(asset); + + await api.disconnect(); +})(); diff --git a/src/examples/confidentialTransactionDetails.ts b/src/examples/confidentialTransactionDetails.ts new file mode 100644 index 0000000..47c8c24 --- /dev/null +++ b/src/examples/confidentialTransactionDetails.ts @@ -0,0 +1,48 @@ +import { BigNumber } from '@polymeshassociation/polymesh-sdk'; +import { ConfidentialTransaction } from '@polymeshassociation/polymesh-sdk/types'; + +import { getClient } from '~/common/client'; +import { toHumanObject } from '~/common/utils'; + +/** + * Retrieves all relevant info about a confidential transaction + */ +export async function getTransactionDetails(transaction: ConfidentialTransaction) { + console.log('\n----------------------------------------------------------------------\n'); + console.log('\n💡 Getting info about confidential transaction : ', transaction.toHuman()); + + const [exists, details, legs, involvedParties, legStates, pendingAffirmCount] = await Promise.all( + [ + transaction.exists(), + transaction.details(), + transaction.getLegs(), + transaction.getInvolvedParties(), + transaction.getLegStates(), + transaction.getPendingAffirmsCount(), + ] + ); + + console.log('\nℹ️ Exists - ', exists); + console.log('\nℹ️ Details - ', toHumanObject(details)); + console.log('\nℹ️ Legs - ', toHumanObject(legs)); + console.log('\nℹ️ Involved Parties - ', toHumanObject(involvedParties)); + console.log('\nℹ️ Leg states - ', toHumanObject(legStates)); + console.log('\nℹ️ Pending Affirmations - ', toHumanObject(pendingAffirmCount)); +} +/* + This script showcases how to get a confidential asset instance with its ID and get all the relevant info about it +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const id = process.argv[2]; + if (!id) { + throw new Error('Please specify asset ID to fetch the details'); + } + const api = await getClient(); + + const transaction = await api.confidentialSettlements.getTransaction({ id: new BigNumber(id) }); + + await getTransactionDetails(transaction); + + await api.disconnect(); +})(); diff --git a/src/examples/createAndMintConfidentialAsset.ts b/src/examples/createAndMintConfidentialAsset.ts new file mode 100644 index 0000000..3a63a07 --- /dev/null +++ b/src/examples/createAndMintConfidentialAsset.ts @@ -0,0 +1,59 @@ +import { BigNumber } from '@polymeshassociation/polymesh-sdk'; + +import { getClient } from '~/common/client'; +import { getConfidentialAssetDetails } from '~/examples/confidentialAssetDetails'; + +/* + This script showcases Confidential Asset related functionality. It: + - it will create a new asset + - mint into given account +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const account = process.argv[2]; + const ticker = process.argv[3]; + const auditor = process.argv[4]; + const owner = process.argv[5]; + if (!account || !ticker || !auditor) { + throw new Error('Please specify the account, ticker, auditor for creating confidential asset'); + } + const api = await getClient(process.env[account]); + + const signingIdentity = await api.getSigningIdentity(); + if (!signingIdentity) { + throw new Error(`Account information not found for ${account}`); + } + console.log( + `\n💡 Creating a new confidential asset with ticker ${ticker} for ${account} DID - ${signingIdentity.did}` + ); + + const createTx = await api.confidentialAssets.createConfidentialAsset({ + ticker, + data: 'Some Random Data', + auditors: [auditor], + }); + + const createdConfidentialAsset = await createTx.run(); + + console.log(`\n✅ New confidential asset created with ID - ${createdConfidentialAsset.id}`); + + await getConfidentialAssetDetails(createdConfidentialAsset); + + console.log('\n----------------------------------------------------------------------\n'); + + console.log('\n💡 Minting some assets : '); + + const amount = new BigNumber(10000); + const issueTx = await createdConfidentialAsset.issue({ + account: owner, + amount, + }); + + await issueTx.run(); + + console.log( + `\n✅ Minted a total of ${amount.toString()} assets with ID - ${createdConfidentialAsset.id}` + ); + + await api.disconnect(); +})(); diff --git a/src/examples/createConfidentialAccount.ts b/src/examples/createConfidentialAccount.ts new file mode 100644 index 0000000..d361f40 --- /dev/null +++ b/src/examples/createConfidentialAccount.ts @@ -0,0 +1,31 @@ +import { getClient } from '~/common/client'; + +/* + This script showcases Confidential Account related functionality. It: + - it will add a public key to a given account +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const account = process.argv[2]; + const publicKey = process.argv[3]; + if (!account || !publicKey) { + throw new Error('Please specify both account and public key for creating confidential account'); + } + const api = await getClient(process.env[account]); + + const signingIdentity = await api.getSigningIdentity(); + if (!signingIdentity) { + throw new Error(`Account information not found for ${account}`); + } + console.log(`\n💡 Adding a public key - ${publicKey} to ${account} DID - ${signingIdentity.did}`); + + const createTx = await api.confidentialAccounts.createConfidentialAccount({ publicKey }); + + const createdConfidentialAccount = await createTx.run(); + + console.log( + `\n✅ New confidential account created with key ${createdConfidentialAccount.publicKey}` + ); + + await api.disconnect(); +})(); diff --git a/src/examples/createConfidentialVenue.ts b/src/examples/createConfidentialVenue.ts new file mode 100644 index 0000000..0f09092 --- /dev/null +++ b/src/examples/createConfidentialVenue.ts @@ -0,0 +1,54 @@ +import { ConfidentialVenue } from '@polymeshassociation/polymesh-sdk/types'; + +import { getClient } from '~/common/client'; +import { toHumanObject } from '~/common/utils'; + +/** + * Retrieves all relevant info about a confidential venue + */ +export async function getVenueDetails(venue: ConfidentialVenue) { + console.log('\n----------------------------------------------------------------------\n'); + console.log('\n💡 Getting all the information about the newly created venue : '); + + const [exists, creator, transactions] = await Promise.all([ + venue.exists(), + venue.creator(), + venue.getTransactions(), + ]); + + console.log('\nℹ️ Exists - ', exists); + console.log('\nℹ️ Creator - ', creator.toHuman()); + console.log('\nℹ️ Transactions - ', toHumanObject(transactions)); +} + +/* + This script showcases how to get a confidential asset instance with its ID and get all the relevant info about it +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const account = process.argv[2]; + if (!account || !process.env[account]) { + throw new Error('Please specify the account to be used to create the venue'); + } + const api = await getClient(process.env[account]); + + const signingIdentity = await api.getSigningIdentity(); + if (!signingIdentity) { + throw new Error(`Account information not found for ${account}`); + } + console.log( + `\n💡 Creating a new confidential venue using ${account} DID - ${signingIdentity.did}` + ); + + const createVenueTx = await api.confidentialSettlements.createVenue(); + + const createdConfidentialVenue = await createVenueTx.run(); + + console.log( + `\n✅ New confidential venue created with ID - ${createdConfidentialVenue.toHuman()}` + ); + + await getVenueDetails(createdConfidentialVenue); + + await api.disconnect(); +})(); diff --git a/src/examples/executeConfidentialTransaction.ts b/src/examples/executeConfidentialTransaction.ts new file mode 100644 index 0000000..7408af0 --- /dev/null +++ b/src/examples/executeConfidentialTransaction.ts @@ -0,0 +1,37 @@ +import { BigNumber } from '@polymeshassociation/polymesh-sdk'; + +import { getClient } from '~/common/client'; + +/* + This script showcases affirming of confidential transaction +*/ +(async (): Promise => { + console.log('Connecting to the node...\n'); + const account = process.argv[2]; + const transactionId = process.argv[3]; + + if (!account) { + throw new Error('Please specify both account and public key for creating confidential account'); + } + const api = await getClient(process.env[account]); + + const signingIdentity = await api.getSigningIdentity(); + if (!signingIdentity) { + throw new Error(`Account information not found for ${account}`); + } + + console.log(`\n💡 Executing transaction ${transactionId}`); + + const transaction = await api.confidentialSettlements.getTransaction({ + id: new BigNumber(transactionId), + }); + + const executeTx = await transaction.execute(); + + await executeTx.run(); + + console.log(`\n✅ Transaction ${transactionId} is now executed`); + + // await getTransactionDetails(transaction); + await api.disconnect(); +})(); diff --git a/tsconfig.json b/tsconfig.json index 2f04fb9..dac0551 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -12,6 +12,9 @@ "exclude": ["*"] } ], + "useUnknownInCatchVariables": false, + "noImplicitOverride": true, + "moduleResolution": "node", "target": "es6", "module": "commonjs", "declaration": true, @@ -19,8 +22,8 @@ "sourceMap": true, "strict": true, "esModuleInterop": true, - "skipLibCheck": true, "resolveJsonModule": true, + "skipLibCheck": true, "lib": ["es2017", "dom"], "typeRoots": ["./node_modules/@types", "./src/typings"] }, diff --git a/webpack.config.dev.js b/webpack.config.dev.js new file mode 100644 index 0000000..125c999 --- /dev/null +++ b/webpack.config.dev.js @@ -0,0 +1,73 @@ +/* eslint-disable */ +const path = require('path'); +const fs = require('fs'); +const HtmlWebpackPlugin = require('html-webpack-plugin'); +const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin'); +const CaseSensitivePathsPlugin = require('case-sensitive-paths-webpack-plugin'); + +const SANDBOX_FILE_NAME = 'sandbox.ts'; + +const sandboxFilePath = path.resolve(`./${SANDBOX_FILE_NAME}`); +const webpack = require('webpack'); + +if (!fs.existsSync(sandboxFilePath)) { + fs.writeFileSync( + sandboxFilePath, + "import { Polymesh } from './src/Polymesh';\r\n\r\n/**\r\n * Polymesh SDK connection\r\n */\r\nasync function run(): Promise {\r\n await Polymesh.connect({\r\n nodeUrl: 'ws://78.47.38.110:9944',\r\n });\r\n}\r\n\r\nrun();" + ); +} + +const devConfig = { + devtool: 'cheap-module-source-map', + entry: ['babel-polyfill', path.resolve(__dirname, SANDBOX_FILE_NAME)], + mode: 'development', + module: { + rules: [ + { + test: /\.ts$/, + loader: 'ts-loader', + options: { + configFile: 'tsconfig.dev.json', + }, + }, + ], + }, + + devServer: { + // This is not written to the disk, but has to be named anyways + static: path.join(__dirname, 'dist'), + // Opens the browser when the watcher starts + open: true, + // No need for compression on development + compress: false, + port: process.env.PORT || 9000, + }, + plugins: [ + new HtmlWebpackPlugin({ + title: 'Polymesh SDK - Sandbox', + }), + new CaseSensitivePathsPlugin(), + // Work around for Buffer is undefined: + // https://github.com/webpack/changelog-v5/issues/10 + new webpack.ProvidePlugin({ + Buffer: ['buffer', 'Buffer'], + }), + ], + output: { + pathinfo: true, + filename: 'devServer.js', + path: path.resolve(__dirname, 'dist'), + publicPath: '/', + }, + resolve: { + extensions: ['.ts', '.js'], + plugins: [new TsconfigPathsPlugin()], + fallback: { + crypto: require.resolve('crypto-browserify'), + stream: require.resolve('stream-browserify'), + assert: require.resolve('assert/'), + }, + }, +}; + +module.exports = devConfig; diff --git a/yarn.lock b/yarn.lock index 0976b2a..7e5b497 100644 --- a/yarn.lock +++ b/yarn.lock @@ -901,23 +901,11 @@ dependencies: "@noble/hashes" "1.3.1" -"@noble/curves@^1.2.0": - version "1.2.0" - resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.2.0.tgz#92d7e12e4e49b23105a2555c6984d41733d65c35" - integrity sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw== - dependencies: - "@noble/hashes" "1.3.2" - "@noble/hashes@1.3.1": version "1.3.1" resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.1.tgz#8831ef002114670c603c458ab8b11328406953a9" integrity sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA== -"@noble/hashes@1.3.2", "@noble/hashes@^1.3.2": - version "1.3.2" - resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.2.tgz#6f26dbc8fbc7205873ce3cee2f690eba0d421b39" - integrity sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ== - "@nodelib/fs.scandir@2.1.5": version "2.1.5" resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" @@ -1300,16 +1288,16 @@ rxjs "^7.8.1" tslib "^2.5.3" -"@polkadot/keyring@^12.3.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/keyring/-/keyring-12.5.1.tgz#2f38504aa915f54bbd265f3793a6be55010eb1f5" - integrity sha512-u6b+Q7wI6WY/vwmJS9uUHy/5hKZ226nTlVNmxjkj9GvrRsQvUSwS94163yHPJwiZJiIv5xK5m0rwCMyoYu+wjA== +"@polkadot/keyring@12.4.2", "@polkadot/keyring@^12.3.1": + version "12.4.2" + resolved "https://registry.yarnpkg.com/@polkadot/keyring/-/keyring-12.4.2.tgz#ff66c531ff29c1c9cb7c0f8411930bc18c76e2d3" + integrity sha512-VH91feSL6GiVVLcJ6V8h6jIAuq62bfvhM75AMcjTFol6MDqFl25jdjkHfZ2bQhig330LIhLw89nKdYr2/OfwjA== dependencies: - "@polkadot/util" "12.5.1" - "@polkadot/util-crypto" "12.5.1" + "@polkadot/util" "12.4.2" + "@polkadot/util-crypto" "12.4.2" tslib "^2.6.2" -"@polkadot/networks@12.4.2": +"@polkadot/networks@12.4.2", "@polkadot/networks@^12.3.1": version "12.4.2" resolved "https://registry.yarnpkg.com/@polkadot/networks/-/networks-12.4.2.tgz#6b3dcbdd016beb0ea585009fd61b048b99b17d1c" integrity sha512-dd7vss+86kpOyy/C+DuCWChGfhwHBHtrzJ9ArbbpY75qc8SqdP90lj/c13ZCHr5I1l+coy31gyyMj5i6ja1Dpg== @@ -1318,15 +1306,6 @@ "@substrate/ss58-registry" "^1.43.0" tslib "^2.6.2" -"@polkadot/networks@12.5.1", "@polkadot/networks@^12.3.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/networks/-/networks-12.5.1.tgz#685c69d24d78a64f4e750609af22678d57fe1192" - integrity sha512-PP6UUdzz6iHHZH4q96cUEhTcydHj16+61sqeaYEJSF6Q9iY+5WVWQ26+rdjmre/EBdrMQkSS/CKy73mO5z/JkQ== - dependencies: - "@polkadot/util" "12.5.1" - "@substrate/ss58-registry" "^1.43.0" - tslib "^2.6.2" - "@polkadot/rpc-augment@10.9.1": version "10.9.1" resolved "https://registry.yarnpkg.com/@polkadot/rpc-augment/-/rpc-augment-10.9.1.tgz#214ec3ee145d20caa61ea204041a3aadb89c6b0f" @@ -1432,7 +1411,7 @@ rxjs "^7.8.1" tslib "^2.5.3" -"@polkadot/util-crypto@12.4.2": +"@polkadot/util-crypto@12.4.2", "@polkadot/util-crypto@^12.3.1": version "12.4.2" resolved "https://registry.yarnpkg.com/@polkadot/util-crypto/-/util-crypto-12.4.2.tgz#e19258dab5f2d4fe49f2d074d36d33a445e50b74" integrity sha512-JP7OrEKYx35P3wWc2Iu9F6BfYMIkywXik908zQqPxwoQhr8uDLP1Qoyu9Sws+hE97Yz1O4jBVvryS2le0yusog== @@ -1448,23 +1427,7 @@ "@scure/base" "1.1.1" tslib "^2.6.2" -"@polkadot/util-crypto@12.5.1", "@polkadot/util-crypto@^12.3.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/util-crypto/-/util-crypto-12.5.1.tgz#1753b23abfb9d72db950399ef65b0cbe5bef9f2f" - integrity sha512-Y8ORbMcsM/VOqSG3DgqutRGQ8XXK+X9M3C8oOEI2Tji65ZsXbh9Yh+ryPLM0oBp/9vqOXjkLgZJbbVuQceOw0A== - dependencies: - "@noble/curves" "^1.2.0" - "@noble/hashes" "^1.3.2" - "@polkadot/networks" "12.5.1" - "@polkadot/util" "12.5.1" - "@polkadot/wasm-crypto" "^7.2.2" - "@polkadot/wasm-util" "^7.2.2" - "@polkadot/x-bigint" "12.5.1" - "@polkadot/x-randomvalues" "12.5.1" - "@scure/base" "^1.1.3" - tslib "^2.6.2" - -"@polkadot/util@12.4.2": +"@polkadot/util@12.4.2", "@polkadot/util@^12.3.1": version "12.4.2" resolved "https://registry.yarnpkg.com/@polkadot/util/-/util-12.4.2.tgz#65759f4b366c2a787fd21abacab8cf8ab1aebbf9" integrity sha512-NcTCbnIzMb/3TvJNEbaiu/9EvYIBuzDwZfqQ4hzL0GAptkF8aDkKMDCfQ/j3FI38rR+VTPQHNky9fvWglGKGRw== @@ -1477,19 +1440,6 @@ bn.js "^5.2.1" tslib "^2.6.2" -"@polkadot/util@12.5.1", "@polkadot/util@^12.3.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/util/-/util-12.5.1.tgz#f4e7415600b013d3b69527aa88904acf085be3f5" - integrity sha512-fDBZL7D4/baMG09Qowseo884m3QBzErGkRWNBId1UjWR99kyex+cIY9fOSzmuQxo6nLdJlLHw1Nz2caN3+Bq0A== - dependencies: - "@polkadot/x-bigint" "12.5.1" - "@polkadot/x-global" "12.5.1" - "@polkadot/x-textdecoder" "12.5.1" - "@polkadot/x-textencoder" "12.5.1" - "@types/bn.js" "^5.1.1" - bn.js "^5.2.1" - tslib "^2.6.2" - "@polkadot/wasm-bridge@7.2.2": version "7.2.2" resolved "https://registry.yarnpkg.com/@polkadot/wasm-bridge/-/wasm-bridge-7.2.2.tgz#957b82b17927fe080729e8930b5b5c554f77b8df" @@ -1543,7 +1493,7 @@ dependencies: tslib "^2.6.1" -"@polkadot/x-bigint@12.4.2": +"@polkadot/x-bigint@12.4.2", "@polkadot/x-bigint@^12.3.1": version "12.4.2" resolved "https://registry.yarnpkg.com/@polkadot/x-bigint/-/x-bigint-12.4.2.tgz#a63c9c926443231206726103d06c117ac2248de8" integrity sha512-VRbkhdIf7CyWiUSyHemYi2fFWjBetUGyqpzsIHEclmzvqhKPfs7Kd2ZRdoXKU5QM56eD0sV2pyJxL34dv36/rw== @@ -1551,14 +1501,6 @@ "@polkadot/x-global" "12.4.2" tslib "^2.6.2" -"@polkadot/x-bigint@12.5.1", "@polkadot/x-bigint@^12.3.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/x-bigint/-/x-bigint-12.5.1.tgz#0a6a3a34fae51468e7b02b42e0ff0747fd88a80a" - integrity sha512-Fw39eoN9v0sqxSzfSC5awaDVdzojIiE7d1hRSQgVSrES+8whWvtbYMR0qwbVhTuW7DvogHmye41P9xKMlXZysg== - dependencies: - "@polkadot/x-global" "12.5.1" - tslib "^2.6.2" - "@polkadot/x-fetch@^12.3.1": version "12.5.1" resolved "https://registry.yarnpkg.com/@polkadot/x-fetch/-/x-fetch-12.5.1.tgz#41532d1324cef56a28c31490ac81062d487b16fb" @@ -1590,14 +1532,6 @@ "@polkadot/x-global" "12.4.2" tslib "^2.6.2" -"@polkadot/x-randomvalues@12.5.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/x-randomvalues/-/x-randomvalues-12.5.1.tgz#b30c6fa8749f5776f1d8a78b6edddb9b0f9c2853" - integrity sha512-UsMb1d+77EPNjW78BpHjZLIm4TaIpfqq89OhZP/6gDIoS2V9iE/AK3jOWKm1G7Y2F8XIoX1qzQpuMakjfagFoQ== - dependencies: - "@polkadot/x-global" "12.5.1" - tslib "^2.6.2" - "@polkadot/x-textdecoder@12.4.2": version "12.4.2" resolved "https://registry.yarnpkg.com/@polkadot/x-textdecoder/-/x-textdecoder-12.4.2.tgz#fea941decbe32d24aa3f951a511bf576dc104826" @@ -1606,14 +1540,6 @@ "@polkadot/x-global" "12.4.2" tslib "^2.6.2" -"@polkadot/x-textdecoder@12.5.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/x-textdecoder/-/x-textdecoder-12.5.1.tgz#8d89d2b5efbffb2550a48f8afb4a834e1d8d4f6e" - integrity sha512-j2YZGWfwhMC8nHW3BXq10fAPY02ObLL/qoTjCMJ1Cmc/OGq18Ep7k9cXXbjFAq3wf3tUUewt/u/hStKCk3IvfQ== - dependencies: - "@polkadot/x-global" "12.5.1" - tslib "^2.6.2" - "@polkadot/x-textencoder@12.4.2": version "12.4.2" resolved "https://registry.yarnpkg.com/@polkadot/x-textencoder/-/x-textencoder-12.4.2.tgz#a717fe2701ade5648600ff3a34d4d1224d916ee3" @@ -1622,14 +1548,6 @@ "@polkadot/x-global" "12.4.2" tslib "^2.6.2" -"@polkadot/x-textencoder@12.5.1": - version "12.5.1" - resolved "https://registry.yarnpkg.com/@polkadot/x-textencoder/-/x-textencoder-12.5.1.tgz#9104e37a60068df2fbf57c81a7ce48669430c76c" - integrity sha512-1JNNpOGb4wD+c7zFuOqjibl49LPnHNr4rj4s3WflLUIZvOMY6euoDuN3ISjQSHCLlVSoH0sOCWA3qXZU4bCTDQ== - dependencies: - "@polkadot/x-global" "12.5.1" - tslib "^2.6.2" - "@polkadot/x-ws@^12.3.1": version "12.5.1" resolved "https://registry.yarnpkg.com/@polkadot/x-ws/-/x-ws-12.5.1.tgz#ff9fc78ef701e18d765443779ab95296a406138c" @@ -1646,10 +1564,10 @@ dependencies: "@polymeshassociation/signing-manager-types" "^3.2.0" -"@polymeshassociation/polymesh-sdk@23.0.0": - version "23.0.0" - resolved "https://registry.yarnpkg.com/@polymeshassociation/polymesh-sdk/-/polymesh-sdk-23.0.0.tgz#1d73ac26d6117b9cf9543e7705695992cefd4305" - integrity sha512-rq6fnRN9gLMGrG8hz+gvtDJFloYKw8WlgoXzDZxeVSiGgGg3YSVWRge8WzfeTotHumS2qbfkWJK2HgFU6V5foA== +"@polymeshassociation/polymesh-sdk@24.0.0-confidential-assets.1": + version "24.0.0-confidential-assets.1" + resolved "https://registry.yarnpkg.com/@polymeshassociation/polymesh-sdk/-/polymesh-sdk-24.0.0-confidential-assets.1.tgz#7f9a75033b406d0836c9728a41b7926c1e5b8f53" + integrity sha512-b7y3P+/sbwk3F861PnNL0ej3wegFmzh2KrZI4uWVOUdqTf+ymXA5BKp0LxDJUuFbH4Cmo0MRz2cxn91szRmmXA== dependencies: "@apollo/client" "^3.8.1" "@polkadot/api" "10.9.1" @@ -1698,11 +1616,6 @@ resolved "https://registry.yarnpkg.com/@scure/base/-/base-1.1.1.tgz#ebb651ee52ff84f420097055f4bf46cfba403938" integrity sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== -"@scure/base@^1.1.3": - version "1.1.3" - resolved "https://registry.yarnpkg.com/@scure/base/-/base-1.1.3.tgz#8584115565228290a6c6c4961973e0903bb3df2f" - integrity sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q== - "@semantic-release/commit-analyzer@^9.0.2": version "9.0.2" resolved "https://registry.yarnpkg.com/@semantic-release/commit-analyzer/-/commit-analyzer-9.0.2.tgz#a78e54f9834193b55f1073fa6258eecc9a545e03" @@ -2191,6 +2104,13 @@ dependencies: resolve "^1.12.0" +"@zerollup/ts-transform-paths@^1.7.11": + version "1.7.18" + resolved "https://registry.yarnpkg.com/@zerollup/ts-transform-paths/-/ts-transform-paths-1.7.18.tgz#72f705c66690879e51d53c73dc76c4e2518a8c50" + integrity sha512-YPVUxvWQVzRx1OBN0Pmkd58+R9FcfUJuwTaPUSoi5rKxuXMtxevTXdfi0w5mEaIH8b0DfL+wg0wFDHiJE+S2zA== + dependencies: + "@zerollup/ts-helpers" "^1.7.18" + JSONStream@^1.0.4, JSONStream@^1.3.5: version "1.3.5" resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.3.5.tgz#3208c1f08d3a4d99261ab64f92302bc15e111ca0"