From d19c507eb294b121f2d46400e58c51dbf8ee64b1 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Sat, 8 Aug 2020 17:25:13 +0300 Subject: [PATCH 01/12] api-examples --- api-examples/README.md | 48 ++ api-examples/package.json | 25 + api-examples/scripts/example.js | 32 + api-examples/scripts/export-data-directory.js | 48 ++ api-examples/scripts/index.js | 10 + api-examples/scripts/inject-data-objects.js | 65 ++ api-examples/scripts/list-data-directory.js | 29 + api-examples/src/get-code.ts | 21 + api-examples/src/script.ts | 54 ++ api-examples/src/status.ts | 60 ++ api-examples/src/tohex.ts | 33 + api-examples/tsconfig.json | 17 + package.json | 3 +- yarn.lock | 650 ++++++++++++------ 14 files changed, 887 insertions(+), 208 deletions(-) create mode 100644 api-examples/README.md create mode 100644 api-examples/package.json create mode 100644 api-examples/scripts/example.js create mode 100644 api-examples/scripts/export-data-directory.js create mode 100644 api-examples/scripts/index.js create mode 100644 api-examples/scripts/inject-data-objects.js create mode 100644 api-examples/scripts/list-data-directory.js create mode 100644 api-examples/src/get-code.ts create mode 100644 api-examples/src/script.ts create mode 100644 api-examples/src/status.ts create mode 100644 api-examples/src/tohex.ts create mode 100644 api-examples/tsconfig.json diff --git a/api-examples/README.md b/api-examples/README.md new file mode 100644 index 0000000000..16d1f2c55d --- /dev/null +++ b/api-examples/README.md @@ -0,0 +1,48 @@ +# Joystream API Examples + +Repo with examples on how to use the @joystream/types package along with @polkadot/api to communicate with a joystream full node. + + +## Examples + +``` +yarn && yarn build +yarn run status +``` + +## Example code + +```javascript +import { registerJoystreamTypes } from '@joystream/types'; +import { ApiPromise, WsProvider } from '@polkadot/api'; + +async function main () { + // Initialise the provider to connect to the local node + const provider = new WsProvider('ws://127.0.0.1:9944'); + + // Register types before creating the API + registerJoystreamTypes(); + + // Create the API and wait until ready + const api = await ApiPromise.create({ provider }); + + // Retrieve the chain & node information information via rpc calls + const [chain, nodeName, nodeVersion] = await Promise.all([ + api.rpc.system.chain(), + api.rpc.system.name(), + api.rpc.system.version() + ]); + + console.log(`Chain ${chain} using ${nodeName} v${nodeVersion}`); +} + +main(); +``` + +### Scripts + +You can run scripts that are found in the [./scripts/](./scripts) folder: + +```sh +yarn script example +``` diff --git a/api-examples/package.json b/api-examples/package.json new file mode 100644 index 0000000000..d1388baf5d --- /dev/null +++ b/api-examples/package.json @@ -0,0 +1,25 @@ +{ + "name": "api-examples", + "private": true, + "version": "0.1.0", + "license": "GPL-3.0-only", + "scripts": { + "status": "ts-node src/status", + "script": "ts-node src/script" + }, + "dependencies": { + "@joystream/types": "^0.13.0", + "@polkadot/api": "^1.26.1", + "@polkadot/types": "^1.26.1", + "@polkadot/keyring": "^3.0.1", + "@polkadot/util": "^3.0.1", + "@polkadot/util-crypto": "^3.0.1", + "@types/bn.js": "^4.11.5", + "bn.js": "^4.11.8" + }, + "devDependencies": { + "@polkadot/ts": "^0.1.56", + "typescript": "^3.9.7", + "ts-node": "^8.6.2" + } +} diff --git a/api-examples/scripts/example.js b/api-examples/scripts/example.js new file mode 100644 index 0000000000..d583cb5222 --- /dev/null +++ b/api-examples/scripts/example.js @@ -0,0 +1,32 @@ +/* global api, hashing, keyring, types, util, window, joy */ + +// run this script with: +// yarn script example +// +// or copy and paste the code into the pioneer javascript toolbox at: +// https://testnet.joystream.org/#/js +// +// Example works on nicaea release+ + +const script = async ({ api, hashing, keyring, types, util, joy }) => { + // Retrieve the chain & node information information via rpc calls + const [chain, nodeName, nodeVersion, runtimeVersion] = await Promise.all([ + api.rpc.system.chain(), + api.rpc.system.name(), + api.rpc.system.version(), + api.runtimeVersion, + ]); + + console.log(`Chain: ${chain}`) + console.log(`Software: ${nodeName} v${nodeVersion}`) + console.log(`Runtime specVersion: ${runtimeVersion.specVersion}`) +} + +if (typeof module === 'undefined') { + // Pioneer js-toolbox + // Available globals [api, hashing, keyring, types, util] + script({ api, hashing, keyring, types, util, joy }) +} else { + // Node + module.exports = script +} diff --git a/api-examples/scripts/export-data-directory.js b/api-examples/scripts/export-data-directory.js new file mode 100644 index 0000000000..31911ca148 --- /dev/null +++ b/api-examples/scripts/export-data-directory.js @@ -0,0 +1,48 @@ +/* global api, hashing, keyring, types, util */ + +// run this script with: +// yarn script exportDataDirectory +// +// or copy and paste the code into the pioneer javascript toolbox at: +// https://testnet.joystream.org/#/js + +const script = async ({ api, hashing, keyring, types, util }) => { + const runtimeSpecVersion = api.runtimeVersion.specVersion + + const ownerAccountToMemberId = async (accountId) => { + const memberIds = await api.query.members.memberIdsByRootAccountId(accountId) + return memberIds[0] || null + } + + const ids = await api.query.dataDirectory.knownContentIds() + + // When a BTreeMap is constructed for injection the node will fail to decode + // it if its not sorted. + ids.sort() + + let transformed = await Promise.all(ids.map(async (id) => { + let obj = await api.query.dataDirectory.dataObjectByContentId(id) + if (obj.isNone) { return null } + obj = obj.unwrap() + + return [id, { + owner: runtimeSpecVersion <= 15 ? await ownerAccountToMemberId(obj.owner) : obj.owner, + added_at: obj.added_at, + type_id: obj.type_id, + size: obj.size_in_bytes, + liaison: runtimeSpecVersion <= 15 ? new types.u64(0) : obj.liaison, + liaison_judgement: obj.liaison_judgement, + ipfs_content_id: obj.ipfs_content_id }] + })) + + console.log(JSON.stringify(transformed)) + console.error(`Exported ${transformed.length} objects`) +} + +if (typeof module === 'undefined') { + // Pioneer js-toolbox + script({ api, hashing, keyring, types, util }) +} else { + // Node + module.exports = script +} diff --git a/api-examples/scripts/index.js b/api-examples/scripts/index.js new file mode 100644 index 0000000000..13b09f8ee2 --- /dev/null +++ b/api-examples/scripts/index.js @@ -0,0 +1,10 @@ +const typesVersion = require('@joystream/types/package.json') + +const exportedScripts = {} + +exportedScripts.example = require('./example.js') +exportedScripts.exportDataDirectory = require('./export-data-directory.js') +exportedScripts.injectDataObjects = require('./inject-data-objects.js') +exportedScripts.listDataDirectory = require('./list-data-directory.js') + +module.exports = exportedScripts diff --git a/api-examples/scripts/inject-data-objects.js b/api-examples/scripts/inject-data-objects.js new file mode 100644 index 0000000000..0a724f8d02 --- /dev/null +++ b/api-examples/scripts/inject-data-objects.js @@ -0,0 +1,65 @@ +/* global api, hashing, keyring, types, util, window */ + +const { isJSDocTypeExpression } = require("typescript") + +// run this script with: +// yarn script injectDataObjects +// +// or copy and paste the code into the pioneer javascript toolbox at: +// https://testnet.joystream.org/#/js +// +// requires nicaea release+ + +const script = async ({ api, keyring, types, joy }) => { + // map must be sorted or we get BadProof error when transaction is submitted and decoded by + // the node. Make sure they are exported in sorted order + // As of July-22-2020 + let exported = ` + [["0x024d7e659d98d537e11f584a411a109f823be28c2e33d5fd5bc83705459442d9",{"owner":442,"added_at":{"block":1128903,"time":1591306668000},"type_id":1,"size":219008840,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmc5fAfRUXnHHtXo2dzKG4qMxQU8rz49meRapvmBsGF5cA"}],["0x03d7010faa563d11cad338c43bbac73e3d54369a96385f934a71e454fa307052",{"owner":447,"added_at":{"block":1466693,"time":1593339768000},"type_id":1,"size":288963385,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQDyQFmF3qZ8r1h2Rumd6M1wgykGZTq3h2Zti2UHX91aT"}],["0x05a5d2bc33fcc1d3aff27166a648c86db7e62563bcbe787ec8f9caa58320fc57",{"owner":438,"added_at":{"block":1055902,"time":1590867516000},"type_id":1,"size":427343853,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmT9SqacYty5bdtAtp9DPTiifcX6UDtZbsgZYs29Zt2RGj"}],["0x090721ad1260d7e3a595aa7c006c63142f78d61dc9b98aa02b2f950e368c137e",{"owner":447,"added_at":{"block":1466438,"time":1593338238000},"type_id":1,"size":310674005,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmawgrC6XHUxH461tWjzSRqneZpt9ehP7ApkkxeTKAXFm5"}],["0x09bb6467ed9702401fe14096bfd24f2326b06b97a8147a213bb472560ea7d9fe",{"owner":309,"added_at":{"block":219866,"time":1585804332000},"type_id":1,"size":388639347,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTbQLFvs6JQpKwHWVV3UdqFxPs8AycXh4pXmAQJfFG5Hv"}],["0x09eeedb5ce5a84a2a03e1e90fcdaad069e2ea4aa48dd2821c31d44b0a13b073e",{"owner":8,"added_at":{"block":835705,"time":1589541222000},"type_id":1,"size":97107,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVjycZ8xJPUtfL46xhgPnZBrX4Zou5Husa99PGH2pxWuG"}],["0x0aed8adce29955d23975b2ab605c1cd78c42ce9aa8e3d5de89b7e4e9f140b092",{"owner":442,"added_at":{"block":1092335,"time":1591086528000},"type_id":1,"size":89227056,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNqqmoAb8pRCkfsHiEzcxQ7P4DfcbUAgvG6d4Vcn2tANt"}],["0x11766a6bf64bcfb8264dbecb326d75b6f37efdc178037c0dc9e96118088a1e79",{"owner":350,"added_at":{"block":1040723,"time":1590776238006},"type_id":1,"size":108038112,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWVsNMZtR1hEKmk6omV8kDgLMAxYwovd48UePdRFKCkMb"}],["0x11bcfb731670560b4a7f182df74f321c2004724d756a05f57ac3d4968eeea427",{"owner":350,"added_at":{"block":1041073,"time":1590778338000},"type_id":1,"size":76625829,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmdzd86ZgMu7u7A74PXNL3jAsj4LydLEkejckSHDxnGDwn"}],["0x1569df4aa068b69fe2b88fcd04a9a1939eaec11a45e15068f2d357d29124735b",{"owner":350,"added_at":{"block":952596,"time":1590245130000},"type_id":1,"size":83605504,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWMQgA13brwFkWojPAQY8Jt48fxp8GpuDsAUfMGh2RuCE"}],["0x1630bbc4eb9cc803dfb7e6f445baff6938cf3e86cbcce6a4308375bd9bcb17b8",{"owner":442,"added_at":{"block":1129261,"time":1591308834000},"type_id":1,"size":290289463,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTcMFK8PEdK9ayv825GT8AP6RfKQq4eYSnnDqY61XWGGi"}],["0x19de0fdc6ef77c6afb52ee1e1f6f5a70557442725852385d34a1537857d78793",{"owner":350,"added_at":{"block":1040903,"time":1590777318000},"type_id":1,"size":8388608,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZofxmdtoUYiDRM2LopoBgoaf8QuSdRWDS4mxMSkgw6Qb"}],["0x230546c3c70f0e892adf19be590e8aace2a091f6a6bf6e9e4e84ceccf8f84c57",{"owner":336,"added_at":{"block":1135451,"time":1591346100000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x24949a52872f06ef61ff3a453e14ffdd358518a434e20f46819620c7d8fd788c",{"owner":6,"added_at":{"block":30261,"time":1584641082000},"type_id":1,"size":11703644,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbbK8TSs4YKo25uaTQDN16GWcUpGkTay6hF2jL4aLyy4z"}],["0x28deb34402e47352adea11da480711b04190e3e2d4cd6fe6cbc2fc1823d4076a",{"owner":432,"added_at":{"block":1213031,"time":1591813500000},"type_id":1,"size":22071878,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZcrf8VHgg78NwG7zgwYgBB4kHo5DM3GmPNdjDBe971rk"}],["0x2a191bdf05d03a11ba557241dd0d94e820144c1da7aa37bf4c75cc7207af4c88",{"owner":442,"added_at":{"block":1124157,"time":1591278024000},"type_id":1,"size":239017927,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVpASwjCBiMQm2uHoamxA51pqBuFDzXmV5oKAsWN7xzqV"}],["0x2b88e65e69fa58f983e5db6ce282783d320bda37faf730db959f841bf1777834",{"owner":447,"added_at":{"block":1466836,"time":1593340626000},"type_id":1,"size":67518865,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXsFsAaoSxzEtBtzRZ8f59NicapmV98PEReMVGtycumaV"}],["0x309c38c4216d23dc59d8f2747d6c7a3fca4f31e68f6cbe5d22afb704f22edecf",{"owner":447,"added_at":{"block":1367174,"time":1592740608000},"type_id":1,"size":355856562,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmeSnJjdUocf4pSifABZByHvNUbDjRCfS45bYHmQFq9GRx"}],["0x30e517661b82e1c774a659cd2d7ed5c33be6ac0eba95a74596c05ff912829f4c",{"owner":442,"added_at":{"block":1128414,"time":1591303674000},"type_id":1,"size":219008840,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmc5fAfRUXnHHtXo2dzKG4qMxQU8rz49meRapvmBsGF5cA"}],["0x31a7436a29d8daa4fa7a20a038b26614964584846ea92f3e5f5af543be59a900",{"owner":442,"added_at":{"block":1121633,"time":1591262862000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}],["0x32c8a93d73e14981ad910e6dfb19c83212fbeccbbc773cf3b35e33ac29ee6dbe",{"owner":442,"added_at":{"block":1129511,"time":1591310376000},"type_id":1,"size":381032453,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXv5w8M34dLSN31KoEsbsVHtqpi7yYgxxEdSzvS5ArN5T"}],["0x339d6574987cd3802c89efce1d93a606367ac5154d4e91c749ede761a918e4c5",{"owner":442,"added_at":{"block":1098823,"time":1591125474000},"type_id":1,"size":61109974,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPXxuMcEvZstbaHEy8CqCramJ8ZJRq2faNut8igmvRaDA"}],["0x36ac61276f1ffb56f65f54d47595457b669f6afec86b800dd7fbf76423c8df9a",{"owner":335,"added_at":{"block":281214,"time":1586187438000},"type_id":1,"size":486671229,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQUPSGGt9zQEUHHgvLsUrKWBGRbJZwLDgN9Ds1zGgHa3Q"}],["0x3b3318f4949850d00e0bb53abc60b17bba6918b56f1848f3c04bc8e32ec62a01",{"owner":442,"added_at":{"block":1128625,"time":1591304952000},"type_id":1,"size":476300317,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmY3BVExv59DY24A6kLvmayBNgGKudhdaKcCbTvLj8BXyh"}],["0x3d9d6721a05e68875a598c3b754e28ab466fad2e5d2bec5190019f8eb86a9fbd",{"owner":447,"added_at":{"block":1367042,"time":1592739816000},"type_id":1,"size":464135764,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTPjGsmJMq66rHtQMtUu1UiEnTRght9NW7PuuvPGnNPrV"}],["0x4202b8da5f8b18d2ebe74eeb333f00ed22326cea14fad0c5db14521bb90cef4b",{"owner":442,"added_at":{"block":1129332,"time":1591309266000},"type_id":1,"size":296289584,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVP9m885U84WjFqTH5Z7r17hrtwK1VJ9fbfriMw11Zmhi"}],["0x42e4b57bb3bc6c7c72f7e1e1c3dba164f301799ebc62f52d94ff110afbc58daf",{"owner":442,"added_at":{"block":1129185,"time":1591308366000},"type_id":1,"size":228968517,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmW1ogMZu3Pp6W9empkK3SxceqcoKHas7rg3iybYoUA1mc"}],["0x44792a5aa5b3753afa1158c47f9975b3e7abbbbb213d1e91f024c3e1f688c68a",{"owner":9,"added_at":{"block":1137835,"time":1591360464000},"type_id":1,"size":183564493,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZExcmZdfyLh1en5ozAejPaN76QTPAH61HCqRjgnzFq65"}],["0x4800d425fa2591edb2b936b4f3078570ee3740c2434a99a3f96e85afd37bcaa5",{"owner":442,"added_at":{"block":1129061,"time":1591307622000},"type_id":1,"size":323491639,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmf86Wu4uHrnNUAFeM8CSyUprCfrwrKE1Ejg8AJGqe5GHv"}],["0x48495b3033d497e76298e9301db064d1d36d1b845154e0d4baa06c150a9bbe4d",{"owner":442,"added_at":{"block":1129821,"time":1591312236000},"type_id":1,"size":16788182,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSmEiRfh2x2CnksELXXfd5pNfFHh7uzAvx57dCu42JZYB"}],["0x4964c7e73f4129f5f541b4ac2713b8d10922cd2249fa2577978a775389455f6c",{"owner":442,"added_at":{"block":1130032,"time":1591313502000},"type_id":1,"size":41396854,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNsERXvLpqKFWzc18zBVwj2XzQtPq3uGjRhdJuEjdCpBa"}],["0x4d37449528ca4e54b3a56d51ee0bd3dae289dfda0d683c8d52bf60f804b24474",{"owner":350,"added_at":{"block":1040719,"time":1590776214000},"type_id":1,"size":116963310,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmevuPnBLNzbcqCnAjEf38GCPyFFWDWAjVEXpiVxMFggcM"}],["0x4e5b77b2b26542c352bc9d67f2826739f7947a8dfe8780c0da7ef5a578325c16",{"owner":442,"added_at":{"block":1126921,"time":1591294632000},"type_id":1,"size":454042427,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTrvQUtZgjjzQUivzrBYPZH4ZmUfSGDMy7kjgBLvJu8cL"}],["0x4f88cb65b21c9960bfbb29941258643a41d279f85e7e9d3e361dfb007d2082ad",{"owner":448,"added_at":{"block":1426221,"time":1593096558000},"type_id":1,"size":512691061,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTBtR7zRCu9QVnKR16Rh68KPgENWsm1miLe8rWxx3s3Rd"}],["0x5339a2ad58454d0f2f56fe19a402555197cf0cef6090d38be5991cfd7560a29f",{"owner":448,"added_at":{"block":1426315,"time":1593097122000},"type_id":1,"size":48401831,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWZKK2tduQHWh9WdekCzezogikZ2N17Vkjx59EqKKLMhj"}],["0x5487981d021b38d574aa1585b80dbca4e0a06356f654a9fb388813dc73a45afc",{"owner":442,"added_at":{"block":1126059,"time":1591289454000},"type_id":1,"size":228190053,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmaV45bM5unHC2eavW2wrXcPkk1eteXFM5ohKdxact37yi"}],["0x555112d6f5c0668b2b6a6e1fc4140dd9678cf3ede7d8167ac3281d8707fa510a",{"owner":350,"added_at":{"block":1040822,"time":1590776832000},"type_id":1,"size":115602785,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmeXbHshnx8MrAMSn8BwPv3VgW9HhyneuyjXVhJQp7AEzr"}],["0x558d4f1851d7a031aa77e02a47edcbf3769fbfb15d91356359c7f0920d362204",{"owner":438,"added_at":{"block":1067485,"time":1590937188000},"type_id":1,"size":466914342,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQPFijUtKGY2h7TLMoKS43kCTvbNtBJt5zhkWB2eXNcFv"}],["0x567126390559878911908d9014d16970ca3a8fbfafb73ca58ea2266e4df92cda",{"owner":447,"added_at":{"block":1466727,"time":1593339972000},"type_id":1,"size":175136347,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmcsnrCbWBdw1NbqgHb2NpEKpGg1jmZQScAiYkocxVxJKT"}],["0x57fbba6e14080b7603a37d2f72661a0e50e8bfc75d2016751a0fac2e0e0c5ce8",{"owner":442,"added_at":{"block":1129257,"time":1591308810000},"type_id":1,"size":377630545,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdLgMHn8uKS3bZM7VzV7BKxGK9RB5mpwfZpkUM9WNDkGS"}],["0x5c0d046280e9656772ec5e716c2849c6ac97a27d7e7f5a81f536614d6f26f401",{"owner":442,"added_at":{"block":1092298,"time":1591086306000},"type_id":1,"size":103571823,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbPwLcE31iuUeFaiPQGnrTPWEQpjRFSTrxf5GErNGVrLR"}],["0x627e905c3f1cd963bd6c00d61a742b88ce753139c7a245ed7c5afcbacd0fa79e",{"owner":350,"added_at":{"block":978132,"time":1590398916000},"type_id":1,"size":14055552,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXCoAJrffVv4Wo9cpwYmRD1Wan1p1Ae8q9ayFgwNBXZn3"}],["0x6860c305bdb1b50bb16cac8722a661d22180f9a7aabf26c65e07c1c7391c0a9d",{"owner":442,"added_at":{"block":1111030,"time":1591198980000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}],["0x690f17fcf72ef1411d446671abe79a54cd636f5fd861ec7edec1734c76cd76cb",{"owner":442,"added_at":{"block":1081934,"time":1591024050000},"type_id":1,"size":77047118,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQ8CMEaCgLtGTW9mfHDtScJev4EpX8fsaSjDohKvvHHZr"}],["0x6b37a30969e1179425bf6aa8981beb7f8eeb9db38da5e939749fc50032908cac",{"owner":442,"added_at":{"block":1110501,"time":1591195764000},"type_id":1,"size":143177220,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmcnCxnLXZVrkGGKMRt5dQqbp3nsbCWdMgCw8oTWhJJnqV"}],["0x6b581bb1fa3f25bf0fe52d08cc2cfce9d84371154556b9ebe9ad4778e42b24f0",{"owner":309,"added_at":{"block":10882,"time":1584522906000},"type_id":1,"size":357059329,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP4Q9bD1iJomLk5cmWseATeYiQpTf2mTajvrsH5wCAnGv"}],["0x6bd69751fecccf320548f4b577b13c0e23a59f826f8a408c5a7ec11f03328ce2",{"owner":442,"added_at":{"block":1082012,"time":1591024518000},"type_id":1,"size":42754567,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmagdA7Zf9Hprj2ZrYEBM2WU1WtZhjh5TMtDgCKV2mov3e"}],["0x6c16eda9fd31abbd626c155fa85990f5061e87d4b024599d9446e0a2363f6549",{"owner":336,"added_at":{"block":819861,"time":1589445528000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x6cb1958d0fe6cc59eec2722574175b0dabe7d431795b7bc5e80290fcfedf25e5",{"owner":442,"added_at":{"block":1121846,"time":1591264140000},"type_id":1,"size":214382445,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbgqP1W2wmnf7qWmdoo5FKxyEbygoudcSekYmJorUyhdL"}],["0x6db58a7fe253876c2aea44a3093c6db043b34cc1a16f0ab396b039c410042929",{"owner":442,"added_at":{"block":1110793,"time":1591197534000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}],["0x6f8767696e9e07a4691126eeb5cf790950ff82e32daff1d8be13d9aa5c5cd8d5",{"owner":336,"added_at":{"block":821397,"time":1589454804000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x71e3020c5f4181dfb646bf2a1a1da38a536fc2cafcfaffce989093d247ef6515",{"owner":309,"added_at":{"block":4059,"time":1584481830000},"type_id":1,"size":297638125,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXTJ8JS2L4DLmYSZcjLR9KZtqCKTwTmTT4JcenPwHYzsC"}],["0x73b14241a22c374a2b27161a2e259705459ce1cbee979b4f27a910c6befa5873",{"owner":442,"added_at":{"block":1126289,"time":1591290834000},"type_id":1,"size":303724484,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUkjHiHdSG5kARgZQrCWZeyMVKBfxpT4m1DPEk3LMsRSV"}],["0x76318fc316171d4197e71a06e18df41f5ebc7a1b4b98be15a1f6d4721eca67b6",{"owner":9,"added_at":{"block":10800,"time":1584522414000},"type_id":1,"size":102256050,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmW8j5XdoKewAzJJvq72iRhXK4nKfRzB5eQXGFjnJTGgqS"}],["0x774d61799ad74137d18b0eab532bcdea6b82c8bd1b6a646d861b95d7b8c6ddbe",{"owner":448,"added_at":{"block":1425677,"time":1593093288000},"type_id":1,"size":383882912,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVDxMygHdBYdaYtf3g7ZigyCvxusqEwQdcfNbDxwMCndR"}],["0x7a3859e8742d9bf85b5fc0bcbf5fd86aaecf58119f3a33dd1622d43ab8182510",{"owner":350,"added_at":{"block":952082,"time":1590242046000},"type_id":1,"size":85057536,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQ9agG1gMb7U6w4amyENMTHru34AwZhSgPZCzTAbWJ2Mb"}],["0x7c0a51e41fccf3adca2ca7fdb4492ddd80a3c8716ac04ae408a0a839778405ec",{"owner":336,"added_at":{"block":938132,"time":1590158118000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x7da45cb1e508b802d7eed7f2f07fc8ebea803266027a204ddc219626acbe005f",{"owner":2,"added_at":{"block":1812377,"time":1595417754000},"type_id":1,"size":125787601,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUmeRNYYBWQtju26msXXsxfTytBbKmwTpPdR4z5Vk8L3U"}],["0x7e496ba7bbb89262263a2e9978bff5f151c1045222245c2434b9c3411c68373f",{"owner":309,"added_at":{"block":250877,"time":1585994772000},"type_id":1,"size":415862058,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXMjGjMaUzhADTUkCwMx9zcwCbAHUqhg2fnkRapCfLgbJ"}],["0x7e8798b65aeb97d80f15614f4fbfd1ccc6ea455e450381c8effe67f5af473cd6",{"owner":335,"added_at":{"block":252882,"time":1586007636007},"type_id":1,"size":278383205,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRtgQTyduMCqGTnRUy8b52h53CATVMMfjqxjFC66Td3HS"}],["0x85ab1f59f7268995b96cb5eda25f69aea13ce8c7adb18fc2150cac1accb34e10",{"owner":442,"added_at":{"block":1123966,"time":1591276878000},"type_id":1,"size":185849059,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVP24JciSRNNd3wUELKeWJR1q3dJK2thbKu6Pky2Y4Zf3"}],["0x89a0a48541889c2cb98592e715225facaced548ea7523e089a593409904a66e7",{"owner":447,"added_at":{"block":1466899,"time":1593341004000},"type_id":1,"size":90491542,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmR2WuxrferxegFHCyMoJiByAwzW5n4bt7exwaaMB766qa"}],["0x89c316cf198daf7df103a82bb5ee86116acfb8a6ca84de01a53449f8c5fed3c7",{"owner":442,"added_at":{"block":1110622,"time":1591196496000},"type_id":1,"size":247006015,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVDt1MFxNS8r416RkeEadadzhfFomPby18wcgbCQ9RBxL"}],["0x8ca510b0578ab7e688db30816f783ad78bfe4323cfe045beff1d11244173f547",{"owner":442,"added_at":{"block":1098712,"time":1591124808000},"type_id":1,"size":62038020,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZ63mpsT6tFbr2fx7BxcQRM9p7VDHBVLCtCZQ4Cw68kef"}],["0x8ee1dbbfa90034a258ee8296d794baaf7ffeabf1fa43ed075ddd56ae84a7769d",{"owner":309,"added_at":{"block":295617,"time":1586276886000},"type_id":1,"size":305573424,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZGpGTC8yoUvR7WPmNB5FC8ZJCikrroG6LJU9qtZjzFcr"}],["0x8eebd480e55d8971744d8d35839f5092c2dc5a57d8b96e8c9e1641ed5446df53",{"owner":442,"added_at":{"block":1127271,"time":1591296738000},"type_id":1,"size":296167714,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSdGGSoo7htcyRA93VmGWWv6PezcQFTQ7hzoG7WTz9nat"}],["0x8f32787bcb8ad38be82e9595a44b8adcd5e5271f688dcc61d29f796db5cad19e",{"owner":309,"added_at":{"block":80121,"time":1584946890000},"type_id":1,"size":358383122,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZszxaTJuyLE7bsWimKmA6EnWq7CmCDUunQHPyZ6kyJYM"}],["0x8f7948e5e046024dbec83d4fac4188348e32f3ce3ef8b26561326aad4a1150a5",{"owner":306,"added_at":{"block":399005,"time":1586904192000},"type_id":1,"size":59359868,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPvgMP99gof4RYmcSMEciN3foGmWnMzefUpZAGCCJ8GX8"}],["0x916b6fc96f3d00dd90fccc4618c67178cda61885330c78019fee3d34ffd3e148",{"owner":309,"added_at":{"block":122598,"time":1585207182000},"type_id":1,"size":293299508,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmT21sEqJxDK2LYfZckjyaXWorkNYjuSLKyMrQVt5nnEXX"}],["0x91883d2a207ee1f772f3ec7f48864fd3931500f37bfe8bf0664e3829560a5d5e",{"owner":350,"added_at":{"block":452900,"time":1587232986000},"type_id":1,"size":8808959,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSiDroNEFVwjmnvqguq1Ke6EF77JixsUg1negSWsZtfrt"}],["0x91ae12a19f8ba2461e53d8c0de653c64330996c3e2b93234d8f5db6caae5ba10",{"owner":442,"added_at":{"block":1128145,"time":1591301982000},"type_id":1,"size":296167714,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSdGGSoo7htcyRA93VmGWWv6PezcQFTQ7hzoG7WTz9nat"}],["0x98a2cae0e026c32ef02ac9513d7160a78dc9b3e587b6d55fada211ce811611df",{"owner":447,"added_at":{"block":1466522,"time":1593338742000},"type_id":1,"size":406931374,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdUmdJLFH3SxSUaW46VuN47wo888hFSGt9RP7dBZKHJFe"}],["0x990889a2b149410e4d3576ec5af732843cd38552238d021c614a811e32ac997e",{"owner":442,"added_at":{"block":1128091,"time":1591301658000},"type_id":1,"size":466729213,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmfLASmYcoZwKzqemWDH55XLMvSqobb2prZA6xmq6T23Cc"}],["0x9d75a21ff370cb8b1e74e88d58b5e11a928ac1c48f6b7098e1d25e6df4ca2eee",{"owner":350,"added_at":{"block":1040980,"time":1590777780000},"type_id":1,"size":104637904,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNjmKwksF2WabmA4NyLiyk7h5LZpiRqryQV87JzL4M26x"}],["0x9ed8ded941839a77e2ac1ba931d5a3f22bf142794c3b4297d1d65bac92f9d739",{"owner":442,"added_at":{"block":1125491,"time":1591286034000},"type_id":1,"size":377595483,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmcrf9hMvWqzoAEWH2fnAr1k21jmd1hjvKiTp7BNCJDY73"}],["0x9edacefe7b92331829e93653e5e6c470a73dd6d5eb9e8bb3e6504ad97c6b19b2",{"owner":442,"added_at":{"block":1110425,"time":1591195296000},"type_id":1,"size":211637438,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRmJPWavbxRboXoUvVSkgcL8vCQdxpdtifdyLuuzqSNDA"}],["0xa25d85c5e547dbfbe85edf476b7a3fcecaff3e7a1a156a0ff1c9ace0089bca43",{"owner":442,"added_at":{"block":1128755,"time":1591305780000},"type_id":1,"size":487027735,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmX1uCVbqhjxrVa6ZNp2q9XCaMrTTBEZVUjmq4xdPRjGQG"}],["0xa45878ab69b49ed57ffefaa524548c5c69d05661202f01073c94ea14185f7f5c",{"owner":9,"added_at":{"block":53411,"time":1584783462000},"type_id":1,"size":211387424,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdpygXdKmjgCQNB7wGN7wzhGHD8gnFAsuiU77TTFCbpFy"}],["0xa575d1ee097acdc99989b4d8c0f4ee56bf472e793f5c36ab552ce18ca68109fc",{"owner":442,"added_at":{"block":1127098,"time":1591295694000},"type_id":1,"size":478905799,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXEbCMrBBr56o3Hyu1PUf35kW6UWmN2jaHFJAZMJKTew2"}],["0xab2a6a80321c2b4409c2804af9ac1fe1a8434419d6be1266e3df1207e2470ec4",{"owner":442,"added_at":{"block":1092258,"time":1591086066000},"type_id":1,"size":96442249,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP7fZ4ERh7JzHqVxveE2ZPv7mX46Lh8iAQk7KiMtVEo2g"}],["0xab4109dcfac767e9b557cef22ce726cc2a9af0fd58749e7dff7b9a431e130561",{"owner":448,"added_at":{"block":1426376,"time":1593097488000},"type_id":1,"size":48401831,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWZKK2tduQHWh9WdekCzezogikZ2N17Vkjx59EqKKLMhj"}],["0xac3480f720c1c24c7aafcb13c707be44badcf646690ff7bdbede011b28636d7b",{"owner":430,"added_at":{"block":962539,"time":1590304926000},"type_id":1,"size":145386199,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmeg2CZPpFhWwU2f2dcC8RQsmS9xuiUFbox6twFFvY2b16"}],["0xac9b568a6b7fb3403ba12eb15326740ccbfc1487766e62a1df239867a779f755",{"owner":309,"added_at":{"block":385966,"time":1586825580000},"type_id":1,"size":355621626,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPtSKii2xQ57DUNeHCxrGnuGtrSFHGBZzcvJauyb62Zo3"}],["0xadf8a4933f69fe51a9b16cd4310389ba8efadc8bed078c30f61752f5ba4ca625",{"owner":442,"added_at":{"block":1129663,"time":1591311288000},"type_id":1,"size":285552738,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPu36d9TJorVTLog9MQcXFsuhLYwjvy4o4n45VRj3NZeg"}],["0xb52a6681e9bc13208bc4a9c1238b142b83eb793c8e63aa95628dc31e5d134c50",{"owner":309,"added_at":{"block":178824,"time":1585551600000},"type_id":1,"size":415473786,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbruxNcR2AnCaW6UQU5gGXUZH78kePhcw8d8PTz56rVBb"}],["0xb5e6aa0602d416581017f69bd1f4f4a6d81122ac6d1d6a1e1572b5ac6ecda230",{"owner":438,"added_at":{"block":1066911,"time":1590933744000},"type_id":1,"size":466914342,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQPFijUtKGY2h7TLMoKS43kCTvbNtBJt5zhkWB2eXNcFv"}],["0xb73cfa311d157640033d60611d87ffd9232a0e6ef0b80e0302ac90879b2619c0",{"owner":442,"added_at":{"block":1129388,"time":1591309626000},"type_id":1,"size":178952334,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUbULJeFkgUTBAzChSPigpN6D9VeikkHLvijtrE1AskBu"}],["0xb75caf11de2bef62de71b1a13be82194451fcab7109dba53c0f7a4adf084cd75",{"owner":140,"added_at":{"block":308380,"time":1586355066000},"type_id":1,"size":30770348,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVuLj5TrBBwuVTNoW5eRXrf7xsmsCXrKR469hfv81kihR"}],["0xb7c6803a781aaf175846cf4a3d9bf61303be3cb86e2e4f357ca6d08dacbc55ec",{"owner":336,"added_at":{"block":820868,"time":1589451630000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xb964415073fa910b2e9ade2edb161ba32183502986543a1020c19c03af4126b7",{"owner":442,"added_at":{"block":1129456,"time":1591310046000},"type_id":1,"size":274204288,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPVfNCnVrbCxGxhR1BZrrjcv9WH8zwEKXXznGSDZT8XfZ"}],["0xbb904988c4888a74248f2d18d664d95e9bd9b6392c8a709064c8d54a0cf2b1ef",{"owner":309,"added_at":{"block":23619,"time":1584600726000},"type_id":1,"size":317341899,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUtsmwDF8HrrNXKKTfWYzXFznt5rCEbUe8Q2gGJ6ZTiab"}],["0xbc10f23b830d39018dc8f60f2434d7db3d14262364b3d4e8617a9e8b9ada50a7",{"owner":442,"added_at":{"block":1126767,"time":1591293708000},"type_id":1,"size":256241998,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmYPfooy3YLKxsLfScbmZWNJy4VyAcK5WkfqwjdsWzL7GG"}],["0xbf6c9db08a2f0dd7b5b3966a8f8d8ab312c2965d25867a1ab7463ffc6fece928",{"owner":441,"added_at":{"block":1114794,"time":1591221714000},"type_id":1,"size":55708471,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbfXW6JafVg9dUesazR2wkJq59cCw6eSo8TLUY5Q1rYzQ"}],["0xc17cc1f1a2723bfdc468d624b4b223c0fd31376877e88b7515ec35dec29e7ae2",{"owner":7,"added_at":{"block":1594924,"time":1594110738000},"type_id":1,"size":513795950,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSbdvdc46qE4k8HftqoDW942Ay777RSfhQ6PcGfbkyA5f"}],["0xc2609ab0d956d2daea48f45c678c742b7bdc35d7b03abae4b3c5895a9e1523f8",{"owner":350,"added_at":{"block":1040904,"time":1590777324000},"type_id":1,"size":109999676,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qma2HgfkVZNXiNQwUNZSCr6k4Vvnebc8XVJyw3tEF8EMNi"}],["0xc2924d93aa476e303ecb8c76cc9473a608cdbfb1d40722d8557d0a37764345a9",{"owner":442,"added_at":{"block":1099325,"time":1591128486000},"type_id":1,"size":214961405,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmT138QMCCzJxMhYnFZcvLf8Cs1Joptoy9wtoUqMFWsZQr"}],["0xc4a1e8f7c0d7ec4f0616083c5bcf1dbf1277560910dfeb5417dea3764a64390f",{"owner":336,"added_at":{"block":1136287,"time":1591351116000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xc6649ad85ef2722b6088f37b83c79e0181f372d27a80169e2d70e9e382f1c110",{"owner":442,"added_at":{"block":1126872,"time":1591294338000},"type_id":1,"size":323293926,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdB7mitLeNQ6WZkwBQXVZtd7jDNU713XAfsgDmijt49A3"}],["0xc87a2a87b0cd125a2fbc222f3855caaa1fdbe2149f55c8670b3ddaeb873f309b",{"owner":311,"added_at":{"block":40871,"time":1584705954001},"type_id":1,"size":23677745,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVfnwL5bbv7veTYwS13zUny7Qt22cGei7HCBiunmM64xm"}],["0xc9b3f0c761e8c26a9e75f70628fcebf838fb85771c07874abef3ac83852deaa8",{"owner":309,"added_at":{"block":10038,"time":1584517812000},"type_id":1,"size":53550842,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmcZmcm6xQY3wmiB8mf4aLKe2XzqeEedvWZoszBEKGpfpG"}],["0xc9dd0359955ae104e36a2267a3e0f42fc95d408658f05b78671e43c1133bd549",{"owner":309,"added_at":{"block":40542,"time":1584703902000},"type_id":1,"size":101120291,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5Xg7JLyt6aKZy9AEriP9S6N2D4BL3kA3viWu3M39U79"}],["0xca99d0df631f2f57ceaf7d96954086fc93182fde0c98bef764def13377fba8dd",{"owner":442,"added_at":{"block":1121678,"time":1591263132000},"type_id":1,"size":320771545,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUgaKnr5H5KFvUeddmcQb37pBH5y7fF3ALavTFh5UaGmK"}],["0xcbb5df475a3bacac3435067d597fa27c1eb723bfdd713a94cdb3b8a48b9278f9",{"owner":442,"added_at":{"block":1129080,"time":1591307736000},"type_id":1,"size":402651528,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbMePgwenk4swC5qYBUCVDa116CavRJFg3XZkbr2WDttx"}],["0xcc2cc5ff13676cf96bd31b2e40dc7fc06b1be2072646ac7e9f30147ae3606c1f",{"owner":442,"added_at":{"block":1127163,"time":1591296084000},"type_id":1,"size":277538135,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmR8GkpSW6BCw3idWrQdSeitcdQSt55XaTja2TzLeBezwp"}],["0xccd2906754b6e3dd4ead4987488aaf9d5f869ede35005176e88c28109064953a",{"owner":442,"added_at":{"block":1129364,"time":1591309464000},"type_id":1,"size":351058986,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQEhoPJ1RR2opA4h99FhMJWEvNVwn4aijZpBzyk3iTtLC"}],["0xcd48e94fe4caa413352e548452a921abf2bb8b72a8bf1e966bf16bcae2b3c6ee",{"owner":442,"added_at":{"block":1098883,"time":1591125834043},"type_id":1,"size":61507811,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmV4zNzSWQVJWjDriAFLeevwHQvyTpw1HGcqPbg4DNheBz"}],["0xcde4eefdbb74b50ec27cc0737a3ff40e5199eb3ce4a3df0250af6fc2b72a0fa4",{"owner":8,"added_at":{"block":940641,"time":1590173256000},"type_id":1,"size":80328,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmY8bC5GWvkhS7W5den8p2Lh2WpvVV4De7KzikYgHTK6nT"}],["0xd080a437811cb52706e66961d50552f930e4874579bf7d57967a37bbeba5db19",{"owner":336,"added_at":{"block":1135332,"time":1591345386000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xd1652d0a713a94886774f4ab17544806d2a4e6a5cdb0fc3ec15b2560f28af032",{"owner":442,"added_at":{"block":1129765,"time":1591311900000},"type_id":1,"size":308527570,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRsKoz7nNuoxMpHR5NqoTgzMyxgsnkiSsbuXcL7LdHV2h"}],["0xd3087b8fd18d5a4ec73ce24149216a5d1658e82f1ddeadd6b9525675bb34e340",{"owner":441,"added_at":{"block":1080090,"time":1591012986000},"type_id":1,"size":19727184,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVh9K2yDuvvgbC1g9Rh5pP4jJZTRWXjkaFw1vdPvLrdut"}],["0xd7ec06e442bba27dcfa2c834964f37126d470a3dd1b0374567a18af239474e50",{"owner":442,"added_at":{"block":1127347,"time":1591297194000},"type_id":1,"size":457868208,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVu6FrVaP8jLZiCG6VecKaUNuCB24FHdEj7MjSJABvey9"}],["0xd97b44423c45fe5396963b57ed44f6a91a839160bad3e554bf08ef19fb583127",{"owner":447,"added_at":{"block":1466620,"time":1593339330000},"type_id":1,"size":200420923,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmYS4JAwG45SvDEC5AM9Hzv1dfzPoXoBq1N9aTbT3bEs86"}],["0xdb8f0622b7fc638933b13a15260a09501d01ffc6a23624bd36317b0805d963b7",{"owner":350,"added_at":{"block":1041080,"time":1590778380000},"type_id":1,"size":99136786,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWLgJN8o8YK361jTxCCf96mbubgMCmMfNx5nEYDcF5hs3"}],["0xdffda551959482486ce30e7739e2eb3b8006b27faba8ed656fc643b2c5f26851",{"owner":449,"added_at":{"block":1683972,"time":1594646064000},"type_id":1,"size":1675105,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRwHXmuqS2rdfqnZdcUGbB3bM5UM6jkvdghgSr9coJ2A4"}],["0xe0be443d0d8967f35d02bb9dd7a4d01a3d31b57115ca31ba5174647a58e62d00",{"owner":447,"added_at":{"block":1466594,"time":1593339174000},"type_id":1,"size":125974946,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qma2ZYN1UkF9TRaJxqGuN5Ksg1Mg5rxbQAmQ46PDSipd3M"}],["0xe24cda3dc434513e9cad5888d8466f0ecad2924db10c9788fb56cbc811cb2ec5",{"owner":442,"added_at":{"block":1125805,"time":1591287930000},"type_id":1,"size":233980798,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPcFojVSw9E1UTwLCk53sG9cyM8wo2ZAHTt9bV3o5PcnT"}],["0xe44c4c26e4804a54d3fc3766ae6da16fe3f25ccaaa9a95d3c122fbc0af74dc2a",{"owner":447,"added_at":{"block":1466769,"time":1593340224000},"type_id":1,"size":59703371,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNw2pRA32PGTxVeq7ktaM9ttUHkj5P3is3QLqamLCJ7Bk"}],["0xe6b072d81f0ca33716ddf332e9460ba177650a25dff7e3126e23a7278cffd335",{"owner":350,"added_at":{"block":1040949,"time":1590777594000},"type_id":1,"size":134414330,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmajAfBPnymCpDKPhywX7abeT9kMfFiYsDX9kAvJ3FRcpv"}],["0xe7547e765c44a27cf3ff6e367f5ae3db931927adea06736e95d33bb93fc19ec8",{"owner":442,"added_at":{"block":1128936,"time":1591306872000},"type_id":1,"size":483398954,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWAnhLsrVUAExgNDoNCREuXFUfnn9tJ4tqVm3cyKSuJjC"}],["0xe7ffa7b44f4641b0cc9ed9c0d6d9d42972d745df451bb635dd25d46ff2844172",{"owner":336,"added_at":{"block":421500,"time":1587043908000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xe8208ac9f0280e6db102b0d9f1e2d82fecbfe0ab99dcda32bf465cdd04ead0a4",{"owner":442,"added_at":{"block":1129630,"time":1591311090000},"type_id":1,"size":491998570,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWPaYEBopBh2i4RYumohbTXdYYYMMtNTNPAdEhzejU5Ad"}],["0xe84290c050e44d103806bcfb37441adb7808c7044d80b01dd1c3402be643513d",{"owner":309,"added_at":{"block":9919,"time":1584517098000},"type_id":1,"size":337713518,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPdYHJGDZ5ucEzC8hmmmjUvtzEdKPEnUe4biwpfjahMmJ"}],["0xecc2c164f4d78b61cda6c9f7e414aa2fb4a102356f0e46d14f4a625c5e7afdd5",{"owner":309,"added_at":{"block":41276,"time":1584708432000},"type_id":1,"size":428470328,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXcaiCAejKga3CYoKqLPKaoxFYemdwCjme2n3PLUwZLvz"}],["0xef41f0a04d3a2d1f29e741fd40abba35ce6d095da54202e49cb77be0404d2bc1",{"owner":447,"added_at":{"block":1466867,"time":1593340812000},"type_id":1,"size":60474460,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRdHAkcv1ijiooTEBfzstosGxpKNJP55Hrkj5ooBaLCy6"}],["0xf0c3624748e1b33f55c2b2c65055af4ecb6458a072690bd3fedf0fc3c9dda1fb",{"owner":442,"added_at":{"block":1129493,"time":1591310268000},"type_id":1,"size":466951798,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmc7wwKSPBB73MPPEPDnkvphp2uywBAPEoDTjSZN6hZWgP"}],["0xf2af183bfdd67f74e7c190fe330b436d45dc6f1f3af540ca3f5f008c2f9ba027",{"owner":442,"added_at":{"block":1081980,"time":1591024326000},"type_id":1,"size":77047118,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQ8CMEaCgLtGTW9mfHDtScJev4EpX8fsaSjDohKvvHHZr"}],["0xf3f0a37a878828f8461d269fcf188a47ae97378d58822a1e249ee105c304deab",{"owner":442,"added_at":{"block":1127682,"time":1591299204001},"type_id":1,"size":457868208,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVu6FrVaP8jLZiCG6VecKaUNuCB24FHdEj7MjSJABvey9"}],["0xf9a250565c9d46659ea8be801f324dbeae0584fe80088a61fb2a1fdfb5e25586",{"owner":442,"added_at":{"block":1110733,"time":1591197168000},"type_id":1,"size":247006015,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVDt1MFxNS8r416RkeEadadzhfFomPby18wcgbCQ9RBxL"}],["0xfbe7ea222bdacdeb93082bfec4044f02debe9131488aca1440318b7d1f158b9c",{"owner":336,"added_at":{"block":1135064,"time":1591343772000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xfeef3d37a69ff35e4087736f06c9ee0c487ab4dd53e0c73fca12bb3cc1ed7f02",{"owner":442,"added_at":{"block":1126970,"time":1591294926000},"type_id":1,"size":440201919,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmadjBxxPasDupmedSKcxDJSYenuYMym6eqHRVdBpYcjbv"}],["0xff6e55a2e0b3332fae51ff7e32975a7d7ab5bce3f0bd1850ae00e08dac0fa751",{"owner":442,"added_at":{"block":1129846,"time":1591312386000},"type_id":1,"size":46196651,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdCvapqKfoVAjNvpsnzecBug9y9LBikgyDYbUsKktuaRs"}],["0xffcb7d08e62559cb6624c2cd82cdccba811423d2b43522cef254a2312571fa77",{"owner":442,"added_at":{"block":1110975,"time":1591198638000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}]] + ` + const parsed = JSON.parse(exported) + + const sudoAddress = (await api.query.sudo.key()).toString() + let sudo + if (typeof window === 'undefined'){ + // In node, get the keyPair if the keyring was provided + sudo = keyring.getPair(sudoAddress) + } else { + // Pioneer: let the UI Signer handle it + sudo = sudoAddress + } + + let nonce = (await api.query.system.account(sudoAddress)).nonce + const max = api.consts.dataDirectory.maxObjectsPerInjection.toNumber() + + const preInjectionIds = await api.query.dataDirectory.knownContentIds() + console.log(`Before injection there are ${preInjectionIds.length} known object ids`) + + // split injection into batches of max objects + while(parsed.length) { + const batch = parsed.splice(0, max) + const objectsMap = api.createType('DataObjectsMap') // new joy.media.DataObjectsMap(api.registry) + batch.forEach(([id, object]) => { + objectsMap.set( + api.createType('ContentId', id), + api.createType('DataObject', object) + ) + }) + + const injectTx = api.tx.dataDirectory.injectDataObjects(objectsMap) + const sudoTx = api.tx.sudo.sudo(injectTx) + console.log(`injecting ${batch.length} objects`) + const signed = sudoTx.sign(sudo, {nonce}) + await signed.send() + console.log(`nonce: ${nonce.toNumber()}, tx hash: ${signed.hash}`) + nonce = nonce.addn(1) + } +} + +if (typeof module === 'undefined') { + // Pioneer js-toolbox + script({ api, hashing, keyring, types, util }) +} else { + // Node + module.exports = script +} diff --git a/api-examples/scripts/list-data-directory.js b/api-examples/scripts/list-data-directory.js new file mode 100644 index 0000000000..0a7dd52ac2 --- /dev/null +++ b/api-examples/scripts/list-data-directory.js @@ -0,0 +1,29 @@ +/* global api, hashing, keyring, types, util */ + +// run this script with: +// yarn script listDataDirectory +// +// or copy and paste the code into the pioneer javascript toolbox at: +// https://testnet.joystream.org/#/js +// requires nicaea release+ + +const script = async ({ api, joy }) => { + const ids = await api.query.dataDirectory.knownContentIds() + + await Promise.all(ids.map(async (id) => { + let obj = await api.query.dataDirectory.dataObjectByContentId(id) + if (obj.isNone) { return } + obj = obj.unwrap() + console.log(`contentId: ${new joy.media.ContentId(id).encode()}, ipfs: ${obj.ipfs_content_id}`) + })) + + console.error(`Data Directory contains ${ids.length} objects`) +} + +if (typeof module === 'undefined') { + // Pioneer js-toolbox + script({ api, hashing, keyring, types, util, joy }) +} else { + // Node + module.exports = script +} diff --git a/api-examples/src/get-code.ts b/api-examples/src/get-code.ts new file mode 100644 index 0000000000..47bf6bb443 --- /dev/null +++ b/api-examples/src/get-code.ts @@ -0,0 +1,21 @@ +import { ApiPromise, WsProvider } from '@polkadot/api'; +import { types } from '@joystream/types' + +async function main () { + const provider = new WsProvider('ws://127.0.0.1:9944'); + + const api = await ApiPromise.create({ provider, types }) + + let current_block_hash = await api.rpc.chain.getBlockHash(); + + console.log('getting code as of block hash', current_block_hash.toString()) + + const substrateWasm = await api.query.substrate.code.at(current_block_hash.toString()); + // const substrateWasm = await api.rpc.state.getStorage('0x'+Buffer.from(':code').toString('hex'), current_block_hash); + + console.log(substrateWasm.toHex()); + + api.disconnect(); +} + +main() diff --git a/api-examples/src/script.ts b/api-examples/src/script.ts new file mode 100644 index 0000000000..8f99a0bb25 --- /dev/null +++ b/api-examples/src/script.ts @@ -0,0 +1,54 @@ +// @ts-check + +import { ApiPromise, WsProvider } from '@polkadot/api' +import * as types from '@polkadot/types' +import * as util from '@polkadot/util' +import { types as joyTypes } from '@joystream/types' +import * as joy from '@joystream/types' +import * as hashing from '@polkadot/util-crypto' +import { Keyring } from '@polkadot/keyring' + +const scripts = require('../scripts') + +async function main () { + + + const scriptArg = process.argv[2] + const script = scripts[scriptArg] + + if (!scriptArg || !script) { + console.error('Please specify valid script name.') + console.error('Available scripts:', Object.keys(scripts)) + return + } + + const provider = new WsProvider('ws://127.0.0.1:9944') + + const api = await ApiPromise.create({ provider, types: joyTypes }) + + // We don't pass a custom signer to the api so we must use a keyPair + // when calling signAndSend on transactions + const keyring = new Keyring() + + // Optional last argument is a SURI for account to use for signing transactions + const suri = process.argv[3] + if (suri) { + keyring.addFromUri(suri, undefined, 'sr25519') + } + + // Add development well known keys to keyring + if ((await api.rpc.system.chain()).toString() === 'Development') { + keyring.addFromUri('//Alice', undefined, 'sr25519') + keyring.addFromUri('//Bob', undefined, 'sr25519') + } + + try { + await script({ api, types, util, hashing, keyring, joy }) + } catch (err) { + console.error(err) + } + + api.disconnect(); +} + +main() diff --git a/api-examples/src/status.ts b/api-examples/src/status.ts new file mode 100644 index 0000000000..abfb224e01 --- /dev/null +++ b/api-examples/src/status.ts @@ -0,0 +1,60 @@ +// @ts-check + +import { ApiPromise, WsProvider } from '@polkadot/api'; +import { types } from '@joystream/types' +import { Seat } from '@joystream/types/council'; +// import { SubscriptionResult, QueryableStorageFunction } from '@polkadot/api/promise/types'; +// import { GenericAccountId } from '@polkadot/types'; +import { ValidatorId } from '@polkadot/types/interfaces'; + +// import BN from 'bn.js'; +const BN = require('bn.js'); + +async function main () { + // Initialise the provider to connect to the local node + const provider = new WsProvider('ws://127.0.0.1:9944'); + + // Create the API and wait until ready + const api = await ApiPromise.create({ provider, types }) + + // Retrieve the chain & node information information via rpc calls + const [chain, nodeName, nodeVersion] = await Promise.all([ + api.rpc.system.chain(), + api.rpc.system.name(), + api.rpc.system.version() + ]); + + console.log(`Chain ${chain} using ${nodeName} v${nodeVersion}`); + + let council = await api.query.council.activeCouncil() as unknown as Seat[]; + let validators = await api.query.session.validators() as unknown as ValidatorId[]; + let version = await api.rpc.state.getRuntimeVersion() as any; + + console.log(`Runtime Version: ${version.authoringVersion}.${version.specVersion}.${version.implVersion}`); + + // let council: QueryableStorageFunction = (await api.query.council.activeCouncil()) as unknown as Seat[] + // let council = (await api.query.council.activeCouncil()) as unknown as Seat[]; + + // number of council members + console.log('Council size:', council.length) + + console.log('Validator count:', validators.length); + + if (validators && validators.length > 0) { + // Retrieve the free balances for all validators + const validatorBalances = await Promise.all( + validators.map(authorityId => api.query.balances.account(authorityId)) + ); + + let totalValidatorBalances = + validatorBalances.reduce((total, value) => total.add(value.free), new BN(0)) + + // TODO: to get the staked amounts we need to read the account lock information. + + console.log('Total Validator Free Balance:', totalValidatorBalances.toString()); + } + + api.disconnect(); +} + +main() diff --git a/api-examples/src/tohex.ts b/api-examples/src/tohex.ts new file mode 100644 index 0000000000..f04ac89ea5 --- /dev/null +++ b/api-examples/src/tohex.ts @@ -0,0 +1,33 @@ +import { ApiPromise, WsProvider } from '@polkadot/api'; +import { CuratorApplicationId } from '@joystream/types/content-working-group'; +import { BTreeSet } from '@polkadot/types'; +import { types } from '@joystream/types' + +async function main() { + const provider = new WsProvider('ws://127.0.0.1:9944'); + const api = await ApiPromise.create({ provider, types }) + + let wgId = [1, 2] + + let set = new BTreeSet(api.registry, CuratorApplicationId, []); + + wgId.forEach((id) => { + set.add(new CuratorApplicationId(api.registry, id)) + }) + + /* + Replace the integers inside the bracket in: + let wgId:number[] = [1, 2]; + With the "WG ID"s of the curators you wish to hire, in ascending order. + + To hire "WG ID" 18 21 and 16: + let wgId:number[] = [16, 18, 21]; + */ + + console.log('copy/paste the output below to hire curator applicant(s) with WG IDs:', wgId ) + console.log(set.toHex()) + + api.disconnect() +} + +main() \ No newline at end of file diff --git a/api-examples/tsconfig.json b/api-examples/tsconfig.json new file mode 100644 index 0000000000..0735d6c692 --- /dev/null +++ b/api-examples/tsconfig.json @@ -0,0 +1,17 @@ +{ + "compilerOptions": { + "declaration": true, + "importHelpers": true, + "module": "commonjs", + "outDir": "lib", + "rootDir": "src", + "strict": true, + "target": "es2017", + "esModuleInterop": true, + "types" : [ "node" ], + "noUnusedLocals": true + }, + "include": [ + "src/**/*" + ] +} diff --git a/package.json b/package.json index d6dfd2a6e2..04e0b8030c 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,8 @@ "storage-node", "storage-node/packages/*", "devops/eslint-config", - "devops/prettier-config" + "devops/prettier-config", + "api-examples" ], "resolutions": { "@polkadot/api": "^1.26.1", diff --git a/yarn.lock b/yarn.lock index da03e8d36c..1abd8789c1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,10 @@ # yarn lockfile v1 +"@alexandria/types@link:types": + version "0.0.0" + uid "" + "@babel/cli@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.7.4.tgz#38804334c8db40209f88c69a5c90998e60cca18b" @@ -79,6 +83,28 @@ semver "^5.4.1" source-map "^0.5.0" +"@babel/core@^7.11.0": + version "7.11.1" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.11.1.tgz#2c55b604e73a40dc21b0e52650b11c65cf276643" + integrity sha512-XqF7F6FWQdKGGWAzGELL+aCO1p+lRY5Tj5/tbT3St1G8NaH70jhhDIKknIZaDans0OQBG5wRAldROLHSt44BgQ== + dependencies: + "@babel/code-frame" "^7.10.4" + "@babel/generator" "^7.11.0" + "@babel/helper-module-transforms" "^7.11.0" + "@babel/helpers" "^7.10.4" + "@babel/parser" "^7.11.1" + "@babel/template" "^7.10.4" + "@babel/traverse" "^7.11.0" + "@babel/types" "^7.11.0" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.1" + json5 "^2.1.2" + lodash "^4.17.19" + resolve "^1.3.2" + semver "^5.4.1" + source-map "^0.5.0" + "@babel/core@^7.5.5": version "7.10.1" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.10.1.tgz#2a0ad0ea693601820defebad2140206503d89af3" @@ -121,6 +147,15 @@ lodash "^4.17.13" source-map "^0.5.0" +"@babel/generator@^7.11.0": + version "7.11.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.11.0.tgz#4b90c78d8c12825024568cbe83ee6c9af193585c" + integrity sha512-fEm3Uzw7Mc9Xi//qU20cBKatTfs2aOtKqmvy/Vm7RkJEGFQ4xc9myCfbXxqK//ZS8MR/ciOHw6meGASJuKmDfQ== + dependencies: + "@babel/types" "^7.11.0" + jsesc "^2.5.1" + source-map "^0.5.0" + "@babel/generator@^7.4.0", "@babel/generator@^7.6.0", "@babel/generator@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.7.4.tgz#db651e2840ca9aa66f327dcec1dc5f5fa9611369" @@ -286,6 +321,13 @@ dependencies: "@babel/types" "^7.10.1" +"@babel/helper-member-expression-to-functions@^7.10.4": + version "7.11.0" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.11.0.tgz#ae69c83d84ee82f4b42f96e2a09410935a8f26df" + integrity sha512-JbFlKHFntRV5qKw3YC0CvQnDZ4XMwgzzBbld7Ly4Mj4cbFy3KywcR8NtNctRToMWJOVvLINJv525Gd6wwVEx/Q== + dependencies: + "@babel/types" "^7.11.0" + "@babel/helper-member-expression-to-functions@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.7.4.tgz#356438e2569df7321a8326644d4b790d2122cb74" @@ -307,6 +349,13 @@ dependencies: "@babel/types" "^7.10.1" +"@babel/helper-module-imports@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.10.4.tgz#4c5c54be04bd31670a7382797d75b9fa2e5b5620" + integrity sha512-nEQJHqYavI217oD9+s5MUBzk6x1IlvoS9WTPfgG43CbMEeStE0v+r+TucWdx8KFGowPGvyOkDT9+7DHedIDnVw== + dependencies: + "@babel/types" "^7.10.4" + "@babel/helper-module-transforms@^7.10.1": version "7.10.1" resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.10.1.tgz#24e2f08ee6832c60b157bb0936c86bef7210c622" @@ -320,6 +369,19 @@ "@babel/types" "^7.10.1" lodash "^4.17.13" +"@babel/helper-module-transforms@^7.11.0": + version "7.11.0" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.11.0.tgz#b16f250229e47211abdd84b34b64737c2ab2d359" + integrity sha512-02EVu8COMuTRO1TAzdMtpBPbe6aQ1w/8fePD2YgQmxZU4gpNWaL9gK3Jp7dxlkUlUCJOTaSeA+Hrm1BRQwqIhg== + dependencies: + "@babel/helper-module-imports" "^7.10.4" + "@babel/helper-replace-supers" "^7.10.4" + "@babel/helper-simple-access" "^7.10.4" + "@babel/helper-split-export-declaration" "^7.11.0" + "@babel/template" "^7.10.4" + "@babel/types" "^7.11.0" + lodash "^4.17.19" + "@babel/helper-module-transforms@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.7.4.tgz#8d7cdb1e1f8ea3d8c38b067345924ac4f8e0879a" @@ -339,6 +401,13 @@ dependencies: "@babel/types" "^7.10.1" +"@babel/helper-optimise-call-expression@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.10.4.tgz#50dc96413d594f995a77905905b05893cd779673" + integrity sha512-n3UGKY4VXwXThEiKrgRAoVPBMqeoPgHVqiHZOanAJCG9nQUL2pLRQirUzl0ioKclHGpGqRgIOkgcIJaIWLpygg== + dependencies: + "@babel/types" "^7.10.4" + "@babel/helper-optimise-call-expression@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.7.4.tgz#034af31370d2995242aa4df402c3b7794b2dcdf2" @@ -384,6 +453,16 @@ "@babel/traverse" "^7.10.1" "@babel/types" "^7.10.1" +"@babel/helper-replace-supers@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.10.4.tgz#d585cd9388ea06e6031e4cd44b6713cbead9e6cf" + integrity sha512-sPxZfFXocEymYTdVK1UNmFPBN+Hv5mJkLPsYWwGBxZAxaWfFu+xqp7b6qWD0yjNuNL2VKc6L5M18tOXUP7NU0A== + dependencies: + "@babel/helper-member-expression-to-functions" "^7.10.4" + "@babel/helper-optimise-call-expression" "^7.10.4" + "@babel/traverse" "^7.10.4" + "@babel/types" "^7.10.4" + "@babel/helper-replace-supers@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.7.4.tgz#3c881a6a6a7571275a72d82e6107126ec9e2cdd2" @@ -402,6 +481,14 @@ "@babel/template" "^7.10.1" "@babel/types" "^7.10.1" +"@babel/helper-simple-access@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.10.4.tgz#0f5ccda2945277a2a7a2d3a821e15395edcf3461" + integrity sha512-0fMy72ej/VEvF8ULmX6yb5MtHG4uH4Dbd6I/aHDb/JVg0bbivwt9Wg+h3uMvX+QSFtwr5MeItvazbrc4jtRAXw== + dependencies: + "@babel/template" "^7.10.4" + "@babel/types" "^7.10.4" + "@babel/helper-simple-access@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.7.4.tgz#a169a0adb1b5f418cfc19f22586b2ebf58a9a294" @@ -424,6 +511,13 @@ dependencies: "@babel/types" "^7.10.4" +"@babel/helper-split-export-declaration@^7.11.0": + version "7.11.0" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.11.0.tgz#f8a491244acf6a676158ac42072911ba83ad099f" + integrity sha512-74Vejvp6mHkGE+m+k5vHY93FX2cAtrw1zXrZXRlG4l410Nm9PxfEiVTn1PjDPV5SnmieiueY4AFg2xqhNFuuZg== + dependencies: + "@babel/types" "^7.11.0" + "@babel/helper-split-export-declaration@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.7.4.tgz#57292af60443c4a3622cf74040ddc28e68336fd8" @@ -460,6 +554,15 @@ "@babel/traverse" "^7.10.1" "@babel/types" "^7.10.1" +"@babel/helpers@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.10.4.tgz#2abeb0d721aff7c0a97376b9e1f6f65d7a475044" + integrity sha512-L2gX/XeUONeEbI78dXSrJzGdz4GQ+ZTA/aazfUsFaWjSe95kiCuOZ5HsXvkiw3iwF+mFHSRUfJU8t6YavocdXA== + dependencies: + "@babel/template" "^7.10.4" + "@babel/traverse" "^7.10.4" + "@babel/types" "^7.10.4" + "@babel/helpers@^7.6.0", "@babel/helpers@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.7.4.tgz#62c215b9e6c712dadc15a9a0dcab76c92a940302" @@ -511,6 +614,11 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.10.4.tgz#9eedf27e1998d87739fb5028a5120557c06a1a64" integrity sha512-8jHII4hf+YVDsskTF6WuMB3X4Eh+PsUkC2ljq22so5rHvH+T8BzyL94VOdyFLNR8tBSVXOTbNHOKpR4TfRxVtA== +"@babel/parser@^7.11.0", "@babel/parser@^7.11.1": + version "7.11.2" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.11.2.tgz#0882ab8a455df3065ea2dcb4c753b2460a24bead" + integrity sha512-Vuj/+7vLo6l1Vi7uuO+1ngCDNeVmNbTngcJFKCR/oEtz8tKz0CJxZEGmPt9KcIloZhOZ3Zit6xbpXT2MDlS9Vw== + "@babel/plugin-proposal-async-generator-functions@^7.2.0", "@babel/plugin-proposal-async-generator-functions@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.7.4.tgz#0351c5ac0a9e927845fffd5b82af476947b7ce6d" @@ -1292,6 +1400,17 @@ "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-typescript" "^7.7.4" +"@babel/register@^7.10.5": + version "7.10.5" + resolved "https://registry.yarnpkg.com/@babel/register/-/register-7.10.5.tgz#354f3574895f1307f79efe37a51525e52fd38d89" + integrity sha512-eYHdLv43nyvmPn9bfNfrcC4+iYNwdQ8Pxk1MFJuU/U5LpSYl/PH4dFMazCYZDFVi8ueG3shvO+AQfLrxpYulQw== + dependencies: + find-cache-dir "^2.0.0" + lodash "^4.17.19" + make-dir "^2.1.0" + pirates "^4.0.0" + source-map-support "^0.5.16" + "@babel/register@^7.7.4": version "7.7.4" resolved "https://registry.yarnpkg.com/@babel/register/-/register-7.7.4.tgz#45a4956471a9df3b012b747f5781cc084ee8f128" @@ -1340,6 +1459,13 @@ dependencies: regenerator-runtime "^0.13.2" +"@babel/runtime@^7.10.5", "@babel/runtime@^7.11.0": + version "7.11.2" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.11.2.tgz#f549c13c754cc40b87644b9fa9f09a6a95fe0736" + integrity sha512-TeWkU52so0mPtDcaCTxNBI/IHiz0pZgr8VEFqXFtZWpYD08ZB6FaSwVAS8MKRQAP3bYKiVjwysOJgMFY28o6Tw== + dependencies: + regenerator-runtime "^0.13.4" + "@babel/template@^7.10.1": version "7.10.1" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.10.1.tgz#e167154a94cb5f14b28dc58f5356d2162f539811" @@ -1397,6 +1523,21 @@ globals "^11.1.0" lodash "^4.17.13" +"@babel/traverse@^7.10.4", "@babel/traverse@^7.11.0": + version "7.11.0" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.11.0.tgz#9b996ce1b98f53f7c3e4175115605d56ed07dd24" + integrity sha512-ZB2V+LskoWKNpMq6E5UUCrjtDUh5IOTAyIl0dTjIEoXum/iKWkoIEKIRDnUucO6f+2FzNkE0oD4RLKoPIufDtg== + dependencies: + "@babel/code-frame" "^7.10.4" + "@babel/generator" "^7.11.0" + "@babel/helper-function-name" "^7.10.4" + "@babel/helper-split-export-declaration" "^7.11.0" + "@babel/parser" "^7.11.0" + "@babel/types" "^7.11.0" + debug "^4.1.0" + globals "^11.1.0" + lodash "^4.17.19" + "@babel/traverse@^7.7.0": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.10.4.tgz#e642e5395a3b09cc95c8e74a27432b484b697818" @@ -1439,6 +1580,15 @@ lodash "^4.17.13" to-fast-properties "^2.0.0" +"@babel/types@^7.11.0": + version "7.11.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.11.0.tgz#2ae6bf1ba9ae8c3c43824e5861269871b206e90d" + integrity sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA== + dependencies: + "@babel/helper-validator-identifier" "^7.10.4" + lodash "^4.17.19" + to-fast-properties "^2.0.0" + "@cnakazawa/watch@^1.0.3": version "1.0.3" resolved "https://registry.yarnpkg.com/@cnakazawa/watch/-/watch-1.0.3.tgz#099139eaec7ebf07a27c1786a3ff64f39464d2ef" @@ -1828,8 +1978,10 @@ "@types/istanbul-reports" "^1.1.1" "@types/yargs" "^13.0.0" -"@joystream/types@link:types": +"@joystream/types@^0.12.0", "@nicaea/types@npm:@joystream/types@^0.12.0": version "0.12.0" + resolved "https://registry.yarnpkg.com/@joystream/types/-/types-0.12.0.tgz#4033967ae2ac111f894fb4100e414f7cdbe95611" + integrity sha512-pHHYTbIa6V1C4k9aj+M6Fkwa2I2Br+4x7cuvREmrVh21GHjGuzoIwB74MfqFajdSTDQDZbjdixcYDES6uo3sUg== dependencies: "@polkadot/keyring" "^1.7.0-beta.5" "@polkadot/types" "^0.96.1" @@ -1839,6 +1991,18 @@ lodash "^4.17.15" moment "^2.24.0" +"@joystream/types@link:types": + version "0.13.0" + dependencies: + "@polkadot/api" "^1.26.1" + "@polkadot/keyring" "^3.0.1" + "@polkadot/types" "^1.26.1" + "@types/lodash" "^4.14.157" + "@types/vfile" "^4.0.0" + ajv "^6.11.0" + lodash "^4.17.15" + moment "^2.24.0" + "@ledgerhq/devices@^4.78.0": version "4.78.0" resolved "https://registry.yarnpkg.com/@ledgerhq/devices/-/devices-4.78.0.tgz#149b572f0616096e2bd5eb14ce14d0061c432be6" @@ -2584,10 +2748,6 @@ call-me-maybe "^1.0.1" glob-to-regexp "^0.3.0" -"@nicaea/types@link:types": - version "0.0.0" - uid "" - "@nodelib/fs.scandir@2.1.3": version "2.1.3" resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.3.tgz#3a582bdb53804c6ba6d146579c46e52130cf4a3b" @@ -2868,46 +3028,53 @@ dependencies: "@types/node" ">= 8" -"@polkadot/api-contract@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/api-contract/-/api-contract-0.96.1.tgz#d43c80059caaf0014c353d0c6544d39a1b6926a3" - integrity sha512-nvIY70YiIbsBBP/48NeFJTc6DCGp9H5Rw+c9hR8J3hZYzbe8qMwpuTS+gHePxwJt/wMFdW8yMP7QS/1tN0JDsA== - dependencies: - "@babel/runtime" "^7.7.1" - "@polkadot/types" "^0.96.1" - -"@polkadot/api-derive@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/api-derive/-/api-derive-0.96.1.tgz#dc49db7293b585c4bde5e334c134127821a0ebed" - integrity sha512-PGWdUvlD2acUKOgaJcYWuMTfSuQKUpwgwjer5SomHLFn4ZPOz8iDa7mYtrgmxQctRv1zsuck2X01uhxdEdtJZw== - dependencies: - "@babel/runtime" "^7.7.1" - "@polkadot/api" "^0.96.1" - "@polkadot/types" "^0.96.1" - -"@polkadot/api-metadata@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/api-metadata/-/api-metadata-0.96.1.tgz#5aaf7b78a72049cca9cbde5b078f26a330ab515c" - integrity sha512-I9F3twpSCgx4ny25a3moGrhf2vHKFnjooO3W9NaAxIj/us4q4Gqo4+czQajqt8vaJqrNMq/PE7lzVz1NhYDrZQ== - dependencies: - "@babel/runtime" "^7.7.1" - "@polkadot/types" "^0.96.1" - "@polkadot/util" "^1.7.0-beta.5" - "@polkadot/util-crypto" "^1.7.0-beta.5" - -"@polkadot/api@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/api/-/api-0.96.1.tgz#708b7f487091e6ffafac16c71074d1366f8f122f" - integrity sha512-FeYyMfJL0NACJBIuG7C7mp7f9J/WOGUERF/hUP3RlIz4Ld2X0vRjEoOgiG0VIS89I4K31XaNmSjIchH244WtHg== - dependencies: - "@babel/runtime" "^7.7.1" - "@polkadot/api-derive" "^0.96.1" - "@polkadot/api-metadata" "^0.96.1" - "@polkadot/keyring" "^1.7.0-beta.5" - "@polkadot/rpc-core" "^0.96.1" - "@polkadot/rpc-provider" "^0.96.1" - "@polkadot/types" "^0.96.1" - "@polkadot/util-crypto" "^1.7.0-beta.5" +"@polkadot/api-contract@^0.96.1", "@polkadot/api-contract@^1.26.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/api-contract/-/api-contract-1.27.1.tgz#52b45b7de8ce35b0d278f4c37eafdcd0b0b7b8c7" + integrity sha512-4Md0LXysEctONz38u7TG9EEFHL2rd9s25nzskGOuFm3FoLomFrvUHGsheIr0zM6wDg8yScRh9zvdkc8EvG4sWQ== + dependencies: + "@babel/runtime" "^7.11.0" + "@polkadot/api" "1.27.1" + "@polkadot/rpc-core" "1.27.1" + "@polkadot/types" "1.27.1" + "@polkadot/util" "^3.0.1" + bn.js "^5.1.2" + rxjs "^6.6.2" + +"@polkadot/api-derive@1.27.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/api-derive/-/api-derive-1.27.1.tgz#5001f19cb29ea4d7924412950b41e46fcca45d81" + integrity sha512-WPZEZ9THeYOkkGzDDsCGSTrWJuWu6qegmWLo52pqD7enmP3dADDoKqPzszHVbEAfc+wYtc5Ye4EogUAiK30iMg== + dependencies: + "@babel/runtime" "^7.11.0" + "@polkadot/api" "1.27.1" + "@polkadot/rpc-core" "1.27.1" + "@polkadot/rpc-provider" "1.27.1" + "@polkadot/types" "1.27.1" + "@polkadot/util" "^3.0.1" + "@polkadot/util-crypto" "^3.0.1" + bn.js "^5.1.2" + memoizee "^0.4.14" + rxjs "^6.6.2" + +"@polkadot/api@1.27.1", "@polkadot/api@^0.96.1", "@polkadot/api@^1.26.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/api/-/api-1.27.1.tgz#dcd3ae5d8699ea5555369b9594888eb1008dd7fe" + integrity sha512-ANMLmNR1PfXLoQ7Ysep9sM/2U3oh3fjFI+9P4Yy9Pv+XMvCROaGAcvxoG+hHfWFz6OAT7ABwyiocV93PuOpAww== + dependencies: + "@babel/runtime" "^7.11.0" + "@polkadot/api-derive" "1.27.1" + "@polkadot/keyring" "^3.0.1" + "@polkadot/metadata" "1.27.1" + "@polkadot/rpc-core" "1.27.1" + "@polkadot/rpc-provider" "1.27.1" + "@polkadot/types" "1.27.1" + "@polkadot/types-known" "1.27.1" + "@polkadot/util" "^3.0.1" + "@polkadot/util-crypto" "^3.0.1" + bn.js "^5.1.2" + eventemitter3 "^4.0.4" + rxjs "^6.6.2" "@polkadot/dev-react@^0.32.0-beta.13": version "0.32.0-beta.15" @@ -3010,21 +3177,26 @@ dependencies: "@babel/runtime" "^7.7.4" -"@polkadot/jsonrpc@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/jsonrpc/-/jsonrpc-0.96.1.tgz#78ae3565169d2bd3cb46abbcb67d4768fb0f6154" - integrity sha512-UHpcUGIvkG4dJ5gUhDyfJ1xfr/VcBlJ5lIlGamGsnNacMuIVmmEsftgxtPlJLWHuoA1EBEHY4cbPSv9CUJ0IFw== +"@polkadot/keyring@^1.7.0-beta.5", "@polkadot/keyring@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@polkadot/keyring/-/keyring-3.0.1.tgz#3944079697c15b2af81e1f57b1c4aeab703a4fef" + integrity sha512-vAHSBnisiDYHsBbEzAgIpuwQp3vIDN2uWQ/1wAE2BrKzXCBQM7RrF3LRcLFySk0xzQoDs7AP1TlPoakxJ/C/Qw== dependencies: - "@babel/runtime" "^7.7.1" + "@babel/runtime" "^7.10.5" + "@polkadot/util" "3.0.1" + "@polkadot/util-crypto" "3.0.1" -"@polkadot/keyring@^1.7.0-beta.5": - version "1.7.1" - resolved "https://registry.yarnpkg.com/@polkadot/keyring/-/keyring-1.7.1.tgz#53a3dd87e547aaee0a877e4fc5fdfc4757e60a0d" - integrity sha512-CWCnU0zsaot0QvEiasKfhCiVlZCIVKOQGPzXiVE9JSjoqTQQJ0BEdaEfM4x0/bFFvvsn/8RcjLPpxBPSfe2eOg== +"@polkadot/metadata@1.27.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/metadata/-/metadata-1.27.1.tgz#40b8e26f9eee30df5b6790aaab406dae1e6d3152" + integrity sha512-jOsWvpGNFkV3NGSGVTzyir0PKinxoa97CYEQj8tJTU7iHDPnSs5R/BEmI0+1hg4ZM/47n+YU8d0lLktD6wbMOA== dependencies: - "@babel/runtime" "^7.7.4" - "@polkadot/util" "^1.7.1" - "@polkadot/util-crypto" "^1.7.1" + "@babel/runtime" "^7.11.0" + "@polkadot/types" "1.27.1" + "@polkadot/types-known" "1.27.1" + "@polkadot/util" "^3.0.1" + "@polkadot/util-crypto" "^3.0.1" + bn.js "^5.1.2" "@polkadot/react-identicon@^0.47.0-beta.3": version "0.47.1" @@ -3051,30 +3223,33 @@ qrcode-generator "^1.4.4" react-qr-reader "^2.2.1" -"@polkadot/rpc-core@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/rpc-core/-/rpc-core-0.96.1.tgz#8da81d3a690fc4e9b2ccc65761166b4830c5d1a3" - integrity sha512-ygSaJpz/QPEq1p35wYRzONuP2PCtkAJ9eS8swQqUIezTo2ZPUOyBhmnJ3nxj11R8YnQClq4Id0QdsJmH1ClYgw== - dependencies: - "@babel/runtime" "^7.7.1" - "@polkadot/jsonrpc" "^0.96.1" - "@polkadot/rpc-provider" "^0.96.1" - "@polkadot/types" "^0.96.1" - "@polkadot/util" "^1.7.0-beta.5" - rxjs "^6.5.3" - -"@polkadot/rpc-provider@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/rpc-provider/-/rpc-provider-0.96.1.tgz#4936f1876484e3388b6d4b31ee51a7f8946638ad" - integrity sha512-cUhp8FMCYHrXrBTbxZrok/hPIgtOXEUhIXn5/zrffg1Qpbzju/y/bXx7c1Kxl1JF7Bg0vSBRZEGJTn/x0irWRQ== +"@polkadot/rpc-core@1.27.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/rpc-core/-/rpc-core-1.27.1.tgz#afe7d1890c779eaf2bec9bb1336b5ba2ff1ba15b" + integrity sha512-HxLHHdV3bDqTltsEedCRGiZeTGmeahnk6OEGyysFOW3PFIrygwwuYa0Mo10lS93dwy9xZw4oE3h9qZqox2mGmQ== dependencies: - "@babel/runtime" "^7.7.1" - "@polkadot/api-metadata" "^0.96.1" - "@polkadot/util" "^1.7.0-beta.5" - "@polkadot/util-crypto" "^1.7.0-beta.5" - eventemitter3 "^4.0.0" + "@babel/runtime" "^7.11.0" + "@polkadot/metadata" "1.27.1" + "@polkadot/rpc-provider" "1.27.1" + "@polkadot/types" "1.27.1" + "@polkadot/util" "^3.0.1" + memoizee "^0.4.14" + rxjs "^6.6.2" + +"@polkadot/rpc-provider@1.27.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/rpc-provider/-/rpc-provider-1.27.1.tgz#c0307a9e9c658f4072ad94ac6e98e2bd78bb1ee6" + integrity sha512-12lpsmHNYLZ3p0X0h643U+sw+WE/kzVB9Q0Y0RA9Recq794cBGiEgK/nmVjT5hrTEk+2+qdtu+CqficWt2FeQw== + dependencies: + "@babel/runtime" "^7.11.0" + "@polkadot/metadata" "1.27.1" + "@polkadot/types" "1.27.1" + "@polkadot/util" "^3.0.1" + "@polkadot/util-crypto" "^3.0.1" + bn.js "^5.1.2" + eventemitter3 "^4.0.4" isomorphic-fetch "^2.2.1" - websocket "^1.0.30" + websocket "^1.0.31" "@polkadot/ts@^0.1.56": version "0.1.91" @@ -3097,16 +3272,46 @@ dependencies: "@types/chrome" "^0.0.114" -"@polkadot/types@^0.96.1": - version "0.96.1" - resolved "https://registry.yarnpkg.com/@polkadot/types/-/types-0.96.1.tgz#84a7123db0ae2922217a0b830a59acb9d83f176f" - integrity sha512-b8AZBNmMjB0+34Oxue3AYc0gIjDHYCdVGtDpel0omHkLMcEquSvrCniLm+p7g4cfArICiZPFmS9In/OWWdRUVA== - dependencies: - "@babel/runtime" "^7.7.1" - "@polkadot/util" "^1.7.0-beta.5" - "@polkadot/util-crypto" "^1.7.0-beta.5" - "@types/memoizee" "^0.4.3" +"@polkadot/typegen@^1.26.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/typegen/-/typegen-1.27.1.tgz#e092f54f686d16af11a9e1bde7b9f4bb70413eb8" + integrity sha512-Yhj8suhErKV/E5WRaQ9iAIzu3ihHSMk3Ncm/viyA7dMCmtvlEpiSqLeWuA/yrSQ/wHwwyiwnNyjZ7VbptGx1yw== + dependencies: + "@babel/core" "^7.11.0" + "@babel/register" "^7.10.5" + "@babel/runtime" "^7.11.0" + "@polkadot/api" "1.27.1" + "@polkadot/metadata" "1.27.1" + "@polkadot/rpc-provider" "1.27.1" + "@polkadot/types" "1.27.1" + "@polkadot/util" "^3.0.1" + handlebars "^4.7.6" + websocket "^1.0.31" + yargs "^15.4.1" + +"@polkadot/types-known@1.27.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/types-known/-/types-known-1.27.1.tgz#d6c48c7b075cd0a9772fcc5df8d98f77b0da35f3" + integrity sha512-9HzHJXznuuG0EQPR3XN931smIzA5usOP2D4Te/uyjiqHgXGUv1EU/vPYaacYYRrjLNdytNcF3HbW97fxu+fC6w== + dependencies: + "@babel/runtime" "^7.11.0" + "@polkadot/types" "1.27.1" + "@polkadot/util" "^3.0.1" + bn.js "^5.1.2" + +"@polkadot/types@1.27.1", "@polkadot/types@^0.96.1", "@polkadot/types@^1.26.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@polkadot/types/-/types-1.27.1.tgz#243f796178f9308a8e58f13fa13d0f3ed1fd2bc8" + integrity sha512-6sX+0/cBUEd/Pt6Y4JSjUI44nqH6qyuRcs6bte2OsEsm06XTEMoIqICPHoOS36Sd/ux7IA/gTZgEj39C9mJWBQ== + dependencies: + "@babel/runtime" "^7.11.0" + "@polkadot/metadata" "1.27.1" + "@polkadot/util" "^3.0.1" + "@polkadot/util-crypto" "^3.0.1" + "@types/bn.js" "^4.11.6" + bn.js "^5.1.2" memoizee "^0.4.14" + rxjs "^6.6.2" "@polkadot/ui-assets@^0.47.0-beta.3": version "0.47.1" @@ -3152,45 +3357,41 @@ "@types/color" "^3.0.0" color "^3.1.2" -"@polkadot/util-crypto@^1.7.0-beta.5", "@polkadot/util-crypto@^1.7.1": - version "1.7.1" - resolved "https://registry.yarnpkg.com/@polkadot/util-crypto/-/util-crypto-1.7.1.tgz#6cb1ed1f7ecbea3b41100231830817e7fd116dc6" - integrity sha512-g0JCciJLJXbkc/Q+2QuJgCgS0Xfl7tO97ALdsI00bgSDA7zlh2zhjpx03Ve47hMndmn7K8ClIGrj4nxHx/95Tw== +"@polkadot/util-crypto@3.0.1", "@polkadot/util-crypto@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@polkadot/util-crypto/-/util-crypto-3.0.1.tgz#800746a39a00e5aa7dc7b901bbde0f5e3e0be60b" + integrity sha512-4G5kzNfqa/nQGuTtoFsy3DESApc8BTgTHbAvLwSkxzM3j8YsvC5ayJ3AFYvM2UT2PDwXmrFx4cwRnYsYZvhC9A== dependencies: - "@babel/runtime" "^7.7.4" - "@polkadot/util" "^1.7.1" - "@polkadot/wasm-crypto" "^0.14.1" - "@types/bip39" "^2.4.2" - "@types/bs58" "^4.0.0" - "@types/pbkdf2" "^3.0.0" - "@types/secp256k1" "^3.5.0" - "@types/xxhashjs" "^0.2.1" - base-x "3.0.5" - bip39 "^2.5.0" + "@babel/runtime" "^7.10.5" + "@polkadot/util" "3.0.1" + "@polkadot/wasm-crypto" "^1.2.1" + base-x "^3.0.8" + bip39 "^3.0.2" blakejs "^1.1.0" - bs58 "^4.0.1" + bn.js "^5.1.2" + elliptic "^6.5.3" js-sha3 "^0.8.0" - secp256k1 "^3.7.0" - tweetnacl "^1.0.1" + pbkdf2 "^3.1.1" + scryptsy "^2.1.0" + tweetnacl "^1.0.3" xxhashjs "^0.2.2" -"@polkadot/util@^1.7.0-beta.5", "@polkadot/util@^1.7.1": - version "1.7.1" - resolved "https://registry.yarnpkg.com/@polkadot/util/-/util-1.7.1.tgz#cb262fa5a441097c0c093532f70d0b7e0503fbb1" - integrity sha512-tWvh+vYDIiXDIWgAGd9zyJWlDKxQ5KYTKZ9uTlLxfuy1qXEdVOjlX9Qz5+FACU2742e8tTvtvM9KfK05VK5X/A== +"@polkadot/util@3.0.1", "@polkadot/util@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@polkadot/util/-/util-3.0.1.tgz#f7ed9d81d745136aa6d6ad57277ee05c88f32784" + integrity sha512-WvH+seT03YQ+6dWJqo285uYHsDvMEGzgYQILEclzQo8xExeCYLIX6GptpW0vGycVxdZmmCdDmUFbcQSRsFawYA== dependencies: - "@babel/runtime" "^7.7.4" - "@types/bn.js" "^4.11.5" - bn.js "^4.11.8" + "@babel/runtime" "^7.10.5" + "@types/bn.js" "^4.11.6" + bn.js "^5.1.2" camelcase "^5.3.1" - chalk "^3.0.0" + chalk "^4.1.0" ip-regex "^4.1.0" - moment "^2.24.0" -"@polkadot/wasm-crypto@^0.14.1": - version "0.14.1" - resolved "https://registry.yarnpkg.com/@polkadot/wasm-crypto/-/wasm-crypto-0.14.1.tgz#f4923bba22d7c68a4be3575ba27790947b212633" - integrity sha512-Xng7L2Z8TNZa/5g6pot4O06Jf0ohQRZdvfl8eQL+E/L2mcqJYC1IjkMxJBSBuQEV7hisWzh9mHOy5WCcgPk29Q== +"@polkadot/wasm-crypto@^1.2.1": + version "1.2.1" + resolved "https://registry.yarnpkg.com/@polkadot/wasm-crypto/-/wasm-crypto-1.2.1.tgz#2189702447acd28d763886359576c87562241767" + integrity sha512-nckIoZBV4nBZdeKwFwH5t7skS7L7GO5EFUl5B1F6uCjUfdNpDz3DtqbYQHcLdCZNmG4TDLg6w/1J+rkl2SiUZw== "@reach/router@^1.2.1": version "1.2.1" @@ -3786,13 +3987,6 @@ dependencies: "@babel/types" "^7.3.0" -"@types/bip39@^2.4.2": - version "2.4.2" - resolved "https://registry.yarnpkg.com/@types/bip39/-/bip39-2.4.2.tgz#f5d6617212be496bb998d3969f657f77a10c5287" - integrity sha512-Vo9lqOIRq8uoIzEVrV87ZvcIM0PN9t0K3oYZ/CS61fIYKCBdOIM7mlWzXuRvSXrDtVa1uUO2w1cdfufxTC0bzg== - dependencies: - "@types/node" "*" - "@types/bn.js@^4.11.5": version "4.11.5" resolved "https://registry.yarnpkg.com/@types/bn.js/-/bn.js-4.11.5.tgz#40e36197433f78f807524ec623afcf0169ac81dc" @@ -3800,12 +3994,12 @@ dependencies: "@types/node" "*" -"@types/bs58@^4.0.0": - version "4.0.1" - resolved "https://registry.yarnpkg.com/@types/bs58/-/bs58-4.0.1.tgz#3d51222aab067786d3bc3740a84a7f5a0effaa37" - integrity sha512-yfAgiWgVLjFCmRv8zAcOIHywYATEwiTVccTLnRp6UxTNavT55M9d/uhK3T03St/+8/z/wW+CRjGKUNmEqoHHCA== +"@types/bn.js@^4.11.6": + version "4.11.6" + resolved "https://registry.yarnpkg.com/@types/bn.js/-/bn.js-4.11.6.tgz#c306c70d9358aaea33cd4eda092a742b9505967c" + integrity sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg== dependencies: - base-x "^3.0.6" + "@types/node" "*" "@types/chai@*", "@types/chai@^4.2.11": version "4.2.11" @@ -4010,11 +4204,6 @@ resolved "https://registry.yarnpkg.com/@types/marked/-/marked-0.7.2.tgz#1393f076773b55cc7078c0fbeb86a497c69db97e" integrity sha512-A3EDyNaq6OCcpaOia2HQ/tu2QYt8DKuj4ExP21VU3cU3HTo2FLslvbqa2T1vux910RHvuSVqpwKnnykSFcRWOA== -"@types/memoizee@^0.4.3": - version "0.4.3" - resolved "https://registry.yarnpkg.com/@types/memoizee/-/memoizee-0.4.3.tgz#f48270d19327c1709620132cf54d598650f98492" - integrity sha512-N6QT0c9ZbEKl33n1wyoTxZs4cpN+YXjs0Aqy5Qim8ipd9PBNIPqOh/p5Pixc4601tqr5GErsdxUbfqviDfubNw== - "@types/mime-types@^2.1.0": version "2.1.0" resolved "https://registry.yarnpkg.com/@types/mime-types/-/mime-types-2.1.0.tgz#9ca52cda363f699c69466c2a6ccdaad913ea7a73" @@ -4059,6 +4248,11 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-12.12.14.tgz#1c1d6e3c75dba466e0326948d56e8bd72a1903d2" integrity sha512-u/SJDyXwuihpwjXy7hOOghagLEV1KdAST6syfnOk6QZAMzZuWZqXy5aYYZbh8Jdpd4escVFP0MvftHNDb9pruA== +"@types/node@11.11.6": + version "11.11.6" + resolved "https://registry.yarnpkg.com/@types/node/-/node-11.11.6.tgz#df929d1bb2eee5afdda598a41930fe50b43eaa6a" + integrity sha512-Exw4yUWMBXM3X+8oqzJNRqZSwUAaS4+7NdvHqQuFi/d+synz++xmX3QIf+BFqneW8N31R8Ky+sikfZUXq07ggQ== + "@types/node@^10.17.18": version "10.17.24" resolved "https://registry.yarnpkg.com/@types/node/-/node-10.17.24.tgz#c57511e3a19c4b5e9692bb2995c40a3a52167944" @@ -4074,13 +4268,6 @@ resolved "https://registry.yarnpkg.com/@types/parse-json/-/parse-json-4.0.0.tgz#2f8bb441434d163b35fb8ffdccd7138927ffb8c0" integrity sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA== -"@types/pbkdf2@^3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@types/pbkdf2/-/pbkdf2-3.0.0.tgz#5d9ca5f12a78a08cc89ad72883ad4a30af359229" - integrity sha512-6J6MHaAlBJC/eVMy9jOwj9oHaprfutukfW/Dyt0NEnpQ/6HN6YQrpvLwzWdWDeWZIdenjGHlbYDzyEODO5Z+2Q== - dependencies: - "@types/node" "*" - "@types/prettier@^1.16.1": version "1.19.0" resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-1.19.0.tgz#a2502fb7ce9b6626fdbfc2e2a496f472de1bdd05" @@ -4234,13 +4421,6 @@ resolved "https://registry.yarnpkg.com/@types/retry/-/retry-0.12.0.tgz#2b35eccfcee7d38cd72ad99232fbd58bffb3c84d" integrity sha512-wWKOClTTiizcZhXnPY4wikVAwmdYHp8q6DmC+EJUzAMsycb7HB32Kh9RN4+0gExjmPmZSAQjgURXIGATPegAvA== -"@types/secp256k1@^3.5.0": - version "3.5.0" - resolved "https://registry.yarnpkg.com/@types/secp256k1/-/secp256k1-3.5.0.tgz#0f3baf16b07488c6da2633a63b4160bcf8d0fd5b" - integrity sha512-ZE39QhkIaNK6xbKIp1VLN5O36r97LuslLmRnjAcT0sVDxcfvrk3zqp/VnIfmGza7J6jDxR8dIai3hsCxPYglPA== - dependencies: - "@types/node" "*" - "@types/sinon@*": version "9.0.4" resolved "https://registry.yarnpkg.com/@types/sinon/-/sinon-9.0.4.tgz#e934f904606632287a6e7f7ab0ce3f08a0dad4b1" @@ -4344,13 +4524,6 @@ resolved "https://registry.yarnpkg.com/@types/webpack-env/-/webpack-env-1.14.1.tgz#0d8a53f308f017c53a5ddc3d07f4d6fa76b790d7" integrity sha512-0Ki9jAAhKDSuLDXOIMADg54Hu60SuBTEsWaJGGy5cV+SSUQ63J2a+RrYYGrErzz39fXzTibhKrAQJAb8M7PNcA== -"@types/xxhashjs@^0.2.1": - version "0.2.1" - resolved "https://registry.yarnpkg.com/@types/xxhashjs/-/xxhashjs-0.2.1.tgz#6cd06b2eca5228765ff45960cf2c2a557ddf109a" - integrity sha512-Akm13wkwsQylVnBokl/aiKLtSxndSjfgTjdvmSxXNehYy4NymwdfdJHwGhpV54wcYfmOByOp3ak8AGdUlvp0sA== - dependencies: - "@types/node" "*" - "@types/yargs-parser@*": version "13.1.0" resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-13.1.0.tgz#c563aa192f39350a1d18da36c5a8da382bbd8228" @@ -6134,14 +6307,7 @@ base-x@3.0.4: dependencies: safe-buffer "^5.0.1" -base-x@3.0.5: - version "3.0.5" - resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.5.tgz#d3ada59afed05b921ab581ec3112e6444ba0795a" - integrity sha512-C3picSgzPSLE+jW3tcBzJoGwitOtazb5B+5YmAxZm2ybmTi9LNgAtDO/jjVEBZwHoXmDBZ9m/IELj3elJVRBcA== - dependencies: - safe-buffer "^5.0.1" - -base-x@^3.0.2, base-x@^3.0.6: +base-x@^3.0.2: version "3.0.7" resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.7.tgz#1c5a7fafe8f66b4114063e8da102799d4e7c408f" integrity sha512-zAKJGuQPihXW22fkrfOclUUZXM2g92z5GzlSMHxhO6r6Qj+Nm0ccaGNBzDZojzwOMkpjAv4J0fOv1U4go+a4iw== @@ -6247,16 +6413,15 @@ bindings@^1.2.1, bindings@^1.4.0, bindings@^1.5.0: dependencies: file-uri-to-path "1.0.0" -bip39@^2.5.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/bip39/-/bip39-2.6.0.tgz#9e3a720b42ec8b3fbe4038f1e445317b6a99321c" - integrity sha512-RrnQRG2EgEoqO24ea+Q/fftuPUZLmrEM3qNhhGsA3PbaXaCW791LTzPuVyx/VprXQcTbPJ3K3UeTna8ZnVl2sg== +bip39@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/bip39/-/bip39-3.0.2.tgz#2baf42ff3071fc9ddd5103de92e8f80d9257ee32" + integrity sha512-J4E1r2N0tUylTKt07ibXvhpT2c5pyAFgvuA5q1H9uDy6dEGpjV8jmymh3MTYJDLCNbIVClSB9FbND49I6N24MQ== dependencies: + "@types/node" "11.11.6" create-hash "^1.1.0" pbkdf2 "^3.0.9" randombytes "^2.0.1" - safe-buffer "^5.0.1" - unorm "^1.3.3" bip66@^1.1.5: version "1.1.5" @@ -6311,6 +6476,11 @@ bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.11.8, bn.js@^4.4.0: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f" integrity sha512-ItfYfPLkWHUjckQCk8xC+LwxgK8NYcXywGigJgSwOP8Y2iyWT4f2vsZnoOXTTbo+o5yXmIUJ4gn5538SO5S3gA== +bn.js@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.1.2.tgz#c9686902d3c9a27729f43ab10f9d79c2004da7b0" + integrity sha512-40rZaf3bUNKTVYu9sIeeEGOg7g14Yvnj9kH7b50EiwX0Q7A6umbvfI5tvHaOERH0XigqKkfLkFQxzb4e6CIXnA== + body-parser@1.19.0, body-parser@^1.19.0: version "1.19.0" resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.19.0.tgz#96b2709e57c9c4e09a6fd66a8fd979844f69f08a" @@ -6955,6 +7125,14 @@ chalk@^4.0.0: ansi-styles "^4.1.0" supports-color "^7.1.0" +chalk@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.0.tgz#4e14870a618d9e2edd97dd8345fd9d9dc315646a" + integrity sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + character-entities-html4@^1.0.0: version "1.1.3" resolved "https://registry.yarnpkg.com/character-entities-html4/-/character-entities-html4-1.1.3.tgz#5ce6e01618e47048ac22f34f7f39db5c6fd679ef" @@ -7360,6 +7538,15 @@ cliui@^5.0.0: strip-ansi "^5.2.0" wrap-ansi "^5.1.0" +cliui@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-6.0.0.tgz#511d702c0c4e41ca156d7d0e96021f23e13225b1" + integrity sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.0" + wrap-ansi "^6.2.0" + clone-buffer@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" @@ -9253,7 +9440,7 @@ element-resize-detector@^1.1.15: dependencies: batch-processor "^1.0.0" -elliptic@^6.0.0, elliptic@^6.4.1: +elliptic@^6.0.0: version "6.5.2" resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.2.tgz#05c5678d7173c049d8ca433552224a495d0e3762" integrity sha512-f4x70okzZbIQl/NSRLkI/+tteV/9WqL98zx+SQ69KbXxmVrmjwsNUPn/gYJJ0sHvEak24cZgHIPegRePAtA/xw== @@ -9266,7 +9453,7 @@ elliptic@^6.0.0, elliptic@^6.4.1: minimalistic-assert "^1.0.0" minimalistic-crypto-utils "^1.0.0" -elliptic@^6.5.2: +elliptic@^6.5.2, elliptic@^6.5.3: version "6.5.3" resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.3.tgz#cb59eb2efdaf73a0bd78ccd7015a62ad6e0f93d6" integrity sha512-IMqzv5wNQf+E6aHeIqATs0tOLeOTwj1QKbRcS3jBbYkl5oLAserA8yJTT7/VyHUYG91PRmPyeQDObKLPpeS4dw== @@ -10201,6 +10388,11 @@ eventemitter3@^4.0.0: resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.0.tgz#d65176163887ee59f386d64c82610b696a4a74eb" integrity sha512-qerSRB0p+UDEssxTtm6EDKcE7W4OaoisfIMl4CngyEhjpYglocpNg6UEqCvemdGhosAsg4sO2dXJOdyBifPGCg== +eventemitter3@^4.0.4: + version "4.0.4" + resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.4.tgz#b5463ace635a083d018bdc7c917b4c5f10a85384" + integrity sha512-rlaVLnVxtxvoyLsQQFBx53YmXHDxRIzzTLbdfxqi4yocpSjAxXwkU0cScM5JgSKMqEhrZpnvQ2D9gjylR0AimQ== + events-to-array@^1.0.1: version "1.1.2" resolved "https://registry.yarnpkg.com/events-to-array/-/events-to-array-1.1.2.tgz#2d41f563e1fe400ed4962fe1a4d5c6a7539df7f6" @@ -11821,6 +12013,18 @@ handlebars@^4.1.2, handlebars@^4.4.0, handlebars@^4.5.3: optionalDependencies: uglify-js "^3.1.4" +handlebars@^4.7.6: + version "4.7.6" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.6.tgz#d4c05c1baf90e9945f77aa68a7a219aa4a7df74e" + integrity sha512-1f2BACcBfiwAfStCKZNrUCgqNZkGsAT7UM3kkYtXuLo0KnaVfjKOyf7PRzB6++aK9STyT1Pd2ZCPe3EGOXleXA== + dependencies: + minimist "^1.2.5" + neo-async "^2.6.0" + source-map "^0.6.1" + wordwrap "^1.0.0" + optionalDependencies: + uglify-js "^3.1.4" + har-schema@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" @@ -15120,6 +15324,11 @@ lodash@^4.0.0, lodash@^4.0.1, lodash@^4.15.0, lodash@^4.17.10, lodash@^4.17.11, resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== +lodash@^4.17.19: + version "4.17.19" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.19.tgz#e48ddedbe30b3321783c5b4301fbd353bc1e4a4b" + integrity sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ== + log-driver@^1.2.7: version "1.2.7" resolved "https://registry.yarnpkg.com/log-driver/-/log-driver-1.2.7.tgz#63b95021f0702fedfa2c9bb0a24e7797d71871d8" @@ -17667,6 +17876,17 @@ pbkdf2@^3.0.3, pbkdf2@^3.0.9: safe-buffer "^5.0.1" sha.js "^2.4.8" +pbkdf2@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/pbkdf2/-/pbkdf2-3.1.1.tgz#cb8724b0fada984596856d1a6ebafd3584654b94" + integrity sha512-4Ejy1OPxi9f2tt1rRV7Go7zmfDQ+ZectEQz3VGUQhgq62HtIRPDyG/JtnwIxs6x3uNMwo2V7q1fMvKjb+Tnpqg== + dependencies: + create-hash "^1.1.2" + create-hmac "^1.1.4" + ripemd160 "^2.0.1" + safe-buffer "^5.0.1" + sha.js "^2.4.8" + peer-id@~0.12.2: version "0.12.5" resolved "https://registry.yarnpkg.com/peer-id/-/peer-id-0.12.5.tgz#b22a1edc5b4aaaa2bb830b265ba69429823e5179" @@ -20080,6 +20300,11 @@ regenerator-runtime@^0.13.2: resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.3.tgz#7cf6a77d8f5c6f60eb73c5fc1955b2ceb01e6bf5" integrity sha512-naKIZz2GQ8JWh///G7L3X6LaQUAMp2lvb1rvwwsURe/VXwD6VMfr+/1NuNw3ag8v2kY1aQ/go5SNn79O9JU7yw== +regenerator-runtime@^0.13.4: + version "0.13.7" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz#cac2dacc8a1ea675feaabaeb8ae833898ae46f55" + integrity sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew== + regenerator-transform@^0.14.0: version "0.14.1" resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.1.tgz#3b2fce4e1ab7732c08f665dfdb314749c7ddd2fb" @@ -20614,6 +20839,13 @@ rxjs@^6.4.0, rxjs@^6.5.3: dependencies: tslib "^1.9.0" +rxjs@^6.6.2: + version "6.6.2" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.6.2.tgz#8096a7ac03f2cc4fe5860ef6e572810d9e01c0d2" + integrity sha512-BHdBMVoWC2sL26w//BCu3YzKT4s2jip/WhwsGEDmeKYBhKDZeYezVUnHatYB7L85v5xs0BAQmg6BEYJEKxBabg== + dependencies: + tslib "^1.9.0" + safe-buffer@5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" @@ -20722,6 +20954,11 @@ schema-utils@^2.0.0, schema-utils@^2.0.1, schema-utils@^2.1.0, schema-utils@^2.5 ajv "^6.10.2" ajv-keywords "^3.4.1" +scryptsy@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/scryptsy/-/scryptsy-2.1.0.tgz#8d1e8d0c025b58fdd25b6fa9a0dc905ee8faa790" + integrity sha512-1CdSqHQowJBnMAFyPEBRfqag/YP9OF394FV+4YREIJX4ljD7OxvQRDayyoyyCk+senRjSkP6VnUNQmVQqB6g7w== + scss-tokenizer@^0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/scss-tokenizer/-/scss-tokenizer-0.2.3.tgz#8eb06db9a9723333824d3f5530641149847ce5d1" @@ -20749,20 +20986,6 @@ secp256k1@^3.6.2: nan "^2.14.0" safe-buffer "^5.1.2" -secp256k1@^3.7.0: - version "3.7.1" - resolved "https://registry.yarnpkg.com/secp256k1/-/secp256k1-3.7.1.tgz#12e473e0e9a7c2f2d4d4818e722ad0e14cc1e2f1" - integrity sha512-1cf8sbnRreXrQFdH6qsg2H71Xw91fCCS9Yp021GnUNJzWJS/py96fS4lHbnTnouLp08Xj6jBoBB6V78Tdbdu5g== - dependencies: - bindings "^1.5.0" - bip66 "^1.1.5" - bn.js "^4.11.8" - create-hash "^1.2.0" - drbg.js "^1.0.1" - elliptic "^6.4.1" - nan "^2.14.0" - safe-buffer "^5.1.2" - section-matter@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/section-matter/-/section-matter-1.0.0.tgz#e9041953506780ec01d59f292a19c7b850b84167" @@ -22756,7 +22979,7 @@ ts-log@^2.1.4: resolved "https://registry.yarnpkg.com/ts-log/-/ts-log-2.1.4.tgz#063c5ad1cbab5d49d258d18015963489fb6fb59a" integrity sha512-P1EJSoyV+N3bR/IWFeAqXzKPZwHpnLY6j7j58mAvewHRipo+BQM2Y1f9Y9BjEQznKwgqqZm7H8iuixmssU7tYQ== -ts-node@^8.5.2: +ts-node@^8.5.2, ts-node@^8.6.2: version "8.10.2" resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-8.10.2.tgz#eee03764633b1234ddd37f8db9ec10b75ec7fb8d" integrity sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA== @@ -22841,16 +23064,11 @@ tweetnacl@^0.14.3, tweetnacl@~0.14.0: resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= -tweetnacl@^1.0.0: +tweetnacl@^1.0.0, tweetnacl@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.3.tgz#ac0af71680458d8a6378d0d0d050ab1407d35596" integrity sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw== -tweetnacl@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.1.tgz#2594d42da73cd036bd0d2a54683dd35a6b55ca17" - integrity sha512-kcoMoKTPYnoeS50tzoqjPY3Uv9axeuuFAZY9M/9zFnhoVvRfxz9K29IMPD7jGmt2c8SW7i3gT9WqDl2+nV7p4A== - type-check@~0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" @@ -22975,10 +23193,10 @@ typescript-formatter@^7.2.2: commandpost "^1.0.0" editorconfig "^0.15.0" -typescript@3.7.2, typescript@3.7.x, typescript@^3.0.3, typescript@^3.6.4, typescript@^3.7.2, typescript@^3.8.3, typescript@^3.9.6: - version "3.7.2" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.7.2.tgz#27e489b95fa5909445e9fef5ee48d81697ad18fb" - integrity sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ== +typescript@3.7.2, typescript@3.7.x, typescript@^3.0.3, typescript@^3.6.4, typescript@^3.7.2, typescript@^3.8.3, typescript@^3.9.6, typescript@^3.9.7: + version "3.9.7" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.9.7.tgz#98d600a5ebdc38f40cb277522f12dc800e9e25fa" + integrity sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw== u2f-api@0.2.7: version "0.2.7" @@ -23227,11 +23445,6 @@ universalify@^1.0.0: resolved "https://registry.yarnpkg.com/universalify/-/universalify-1.0.0.tgz#b61a1da173e8435b2fe3c67d29b9adf8594bd16d" integrity sha512-rb6X1W158d7pRQBg5gkR8uPaSfiids68LTJQYOtEUhoJUWBdaQHsuT/EUduxXYxcrt4r5PJ4fuHW1MHT6p0qug== -unorm@^1.3.3: - version "1.6.0" - resolved "https://registry.yarnpkg.com/unorm/-/unorm-1.6.0.tgz#029b289661fba714f1a9af439eb51d9b16c205af" - integrity sha512-b2/KCUlYZUeA7JFUuRJZPUtr4gZvBh7tavtv4fvk4+KV9pfGiR6CQAQAWl49ZpR3ts2dk4FYkP7EIgDJoiOLDA== - unpipe@1.0.0, unpipe@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec" @@ -23991,12 +24204,13 @@ websocket-extensions@>=0.1.1: resolved "https://registry.yarnpkg.com/websocket-extensions/-/websocket-extensions-0.1.3.tgz#5d2ff22977003ec687a4b87073dfbbac146ccf29" integrity sha512-nqHUnMXmBzT0w570r2JpJxfiSD1IzoI+HGVdd3aZ0yNi3ngvQ4jv1dtHt5VGxfI2yj5yqImPhOK4vmIh2xMbGg== -websocket@^1.0.30: - version "1.0.30" - resolved "https://registry.yarnpkg.com/websocket/-/websocket-1.0.30.tgz#91d3bd00c3d43e916f0cf962f8f8c451bb0b2373" - integrity sha512-aO6klgaTdSMkhfl5VVJzD5fm+Srhh5jLYbS15+OiI1sN6h/RU/XW6WN9J1uVIpUKNmsTvT3Hs35XAFjn9NMfOw== +websocket@^1.0.31: + version "1.0.31" + resolved "https://registry.yarnpkg.com/websocket/-/websocket-1.0.31.tgz#e5d0f16c3340ed87670e489ecae6144c79358730" + integrity sha512-VAouplvGKPiKFDTeCCO65vYHsyay8DqoBSlzIO3fayrfOgU94lQN5a1uWVnFrMLceTJw/+fQXR5PGbUVRaHshQ== dependencies: debug "^2.2.0" + es5-ext "^0.10.50" nan "^2.14.0" typedarray-to-buffer "^3.1.5" yaeti "^0.0.6" @@ -24103,6 +24317,11 @@ word-wrap@~1.2.3: resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== +wordwrap@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" + integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= + wordwrap@~0.0.2: version "0.0.3" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" @@ -24421,7 +24640,7 @@ yargs-parser@^15.0.0: camelcase "^5.0.0" decamelize "^1.2.0" -yargs-parser@^18.1.3: +yargs-parser@^18.1.2, yargs-parser@^18.1.3: version "18.1.3" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-18.1.3.tgz#be68c4975c6b2abf469236b0c870362fab09a7b0" integrity sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ== @@ -24570,6 +24789,23 @@ yargs@^14.2.0, yargs@^14.2.2: y18n "^4.0.0" yargs-parser "^15.0.0" +yargs@^15.4.1: + version "15.4.1" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-15.4.1.tgz#0d87a16de01aee9d8bec2bfbf74f67851730f4f8" + integrity sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A== + dependencies: + cliui "^6.0.0" + decamelize "^1.2.0" + find-up "^4.1.0" + get-caller-file "^2.0.1" + require-directory "^2.1.1" + require-main-filename "^2.0.0" + set-blocking "^2.0.0" + string-width "^4.2.0" + which-module "^2.0.0" + y18n "^4.0.0" + yargs-parser "^18.1.2" + yargs@^7.0.0: version "7.1.0" resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.0.tgz#6ba318eb16961727f5d284f8ea003e8d6154d0c8" From 711be6e414445fdfd78c99d422e8e940057fed2c Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Sat, 8 Aug 2020 18:03:46 +0300 Subject: [PATCH 02/12] apply prettier formatting --- api-examples/src/get-code.ts | 14 ++++++------ api-examples/src/script.ts | 6 ++---- api-examples/src/status.ts | 41 ++++++++++++++++++------------------ api-examples/src/tohex.ts | 38 ++++++++++++++++----------------- 4 files changed, 48 insertions(+), 51 deletions(-) diff --git a/api-examples/src/get-code.ts b/api-examples/src/get-code.ts index 47bf6bb443..c24fd4dcfe 100644 --- a/api-examples/src/get-code.ts +++ b/api-examples/src/get-code.ts @@ -1,21 +1,21 @@ -import { ApiPromise, WsProvider } from '@polkadot/api'; +import { ApiPromise, WsProvider } from '@polkadot/api' import { types } from '@joystream/types' -async function main () { - const provider = new WsProvider('ws://127.0.0.1:9944'); +async function main() { + const provider = new WsProvider('ws://127.0.0.1:9944') const api = await ApiPromise.create({ provider, types }) - let current_block_hash = await api.rpc.chain.getBlockHash(); + let current_block_hash = await api.rpc.chain.getBlockHash() console.log('getting code as of block hash', current_block_hash.toString()) - const substrateWasm = await api.query.substrate.code.at(current_block_hash.toString()); + const substrateWasm = await api.query.substrate.code.at(current_block_hash.toString()) // const substrateWasm = await api.rpc.state.getStorage('0x'+Buffer.from(':code').toString('hex'), current_block_hash); - console.log(substrateWasm.toHex()); + console.log(substrateWasm.toHex()) - api.disconnect(); + api.disconnect() } main() diff --git a/api-examples/src/script.ts b/api-examples/src/script.ts index 8f99a0bb25..285b11ea9f 100644 --- a/api-examples/src/script.ts +++ b/api-examples/src/script.ts @@ -10,9 +10,7 @@ import { Keyring } from '@polkadot/keyring' const scripts = require('../scripts') -async function main () { - - +async function main() { const scriptArg = process.argv[2] const script = scripts[scriptArg] @@ -48,7 +46,7 @@ async function main () { console.error(err) } - api.disconnect(); + api.disconnect() } main() diff --git a/api-examples/src/status.ts b/api-examples/src/status.ts index abfb224e01..8514582847 100644 --- a/api-examples/src/status.ts +++ b/api-examples/src/status.ts @@ -1,18 +1,18 @@ // @ts-check -import { ApiPromise, WsProvider } from '@polkadot/api'; +import { ApiPromise, WsProvider } from '@polkadot/api' import { types } from '@joystream/types' -import { Seat } from '@joystream/types/council'; +import { Seat } from '@joystream/types/council' // import { SubscriptionResult, QueryableStorageFunction } from '@polkadot/api/promise/types'; // import { GenericAccountId } from '@polkadot/types'; -import { ValidatorId } from '@polkadot/types/interfaces'; +import { ValidatorId } from '@polkadot/types/interfaces' // import BN from 'bn.js'; -const BN = require('bn.js'); +const BN = require('bn.js') -async function main () { +async function main() { // Initialise the provider to connect to the local node - const provider = new WsProvider('ws://127.0.0.1:9944'); + const provider = new WsProvider('ws://127.0.0.1:9944') // Create the API and wait until ready const api = await ApiPromise.create({ provider, types }) @@ -21,16 +21,16 @@ async function main () { const [chain, nodeName, nodeVersion] = await Promise.all([ api.rpc.system.chain(), api.rpc.system.name(), - api.rpc.system.version() - ]); + api.rpc.system.version(), + ]) - console.log(`Chain ${chain} using ${nodeName} v${nodeVersion}`); + console.log(`Chain ${chain} using ${nodeName} v${nodeVersion}`) - let council = await api.query.council.activeCouncil() as unknown as Seat[]; - let validators = await api.query.session.validators() as unknown as ValidatorId[]; - let version = await api.rpc.state.getRuntimeVersion() as any; + let council = ((await api.query.council.activeCouncil()) as unknown) as Seat[] + let validators = ((await api.query.session.validators()) as unknown) as ValidatorId[] + let version = (await api.rpc.state.getRuntimeVersion()) as any - console.log(`Runtime Version: ${version.authoringVersion}.${version.specVersion}.${version.implVersion}`); + console.log(`Runtime Version: ${version.authoringVersion}.${version.specVersion}.${version.implVersion}`) // let council: QueryableStorageFunction = (await api.query.council.activeCouncil()) as unknown as Seat[] // let council = (await api.query.council.activeCouncil()) as unknown as Seat[]; @@ -38,23 +38,22 @@ async function main () { // number of council members console.log('Council size:', council.length) - console.log('Validator count:', validators.length); + console.log('Validator count:', validators.length) if (validators && validators.length > 0) { // Retrieve the free balances for all validators const validatorBalances = await Promise.all( - validators.map(authorityId => api.query.balances.account(authorityId)) - ); + validators.map((authorityId) => api.query.balances.account(authorityId)) + ) - let totalValidatorBalances = - validatorBalances.reduce((total, value) => total.add(value.free), new BN(0)) + let totalValidatorBalances = validatorBalances.reduce((total, value) => total.add(value.free), new BN(0)) // TODO: to get the staked amounts we need to read the account lock information. - - console.log('Total Validator Free Balance:', totalValidatorBalances.toString()); + + console.log('Total Validator Free Balance:', totalValidatorBalances.toString()) } - api.disconnect(); + api.disconnect() } main() diff --git a/api-examples/src/tohex.ts b/api-examples/src/tohex.ts index f04ac89ea5..1e6273a392 100644 --- a/api-examples/src/tohex.ts +++ b/api-examples/src/tohex.ts @@ -1,21 +1,21 @@ -import { ApiPromise, WsProvider } from '@polkadot/api'; -import { CuratorApplicationId } from '@joystream/types/content-working-group'; -import { BTreeSet } from '@polkadot/types'; +import { ApiPromise, WsProvider } from '@polkadot/api' +import { CuratorApplicationId } from '@joystream/types/content-working-group' +import { BTreeSet } from '@polkadot/types' import { types } from '@joystream/types' async function main() { - const provider = new WsProvider('ws://127.0.0.1:9944'); - const api = await ApiPromise.create({ provider, types }) - - let wgId = [1, 2] - - let set = new BTreeSet(api.registry, CuratorApplicationId, []); - - wgId.forEach((id) => { - set.add(new CuratorApplicationId(api.registry, id)) - }) - - /* + const provider = new WsProvider('ws://127.0.0.1:9944') + const api = await ApiPromise.create({ provider, types }) + + let wgId = [1, 2] + + let set = new BTreeSet(api.registry, CuratorApplicationId, []) + + wgId.forEach((id) => { + set.add(new CuratorApplicationId(api.registry, id)) + }) + + /* Replace the integers inside the bracket in: let wgId:number[] = [1, 2]; With the "WG ID"s of the curators you wish to hire, in ascending order. @@ -24,10 +24,10 @@ async function main() { let wgId:number[] = [16, 18, 21]; */ - console.log('copy/paste the output below to hire curator applicant(s) with WG IDs:', wgId ) - console.log(set.toHex()) + console.log('copy/paste the output below to hire curator applicant(s) with WG IDs:', wgId) + console.log(set.toHex()) - api.disconnect() + api.disconnect() } -main() \ No newline at end of file +main() From 4236c3a420f5341a02f65db3c22373976d417359 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Sat, 8 Aug 2020 18:19:50 +0300 Subject: [PATCH 03/12] formatting --- api-examples/README.md | 21 ++++++----- api-examples/scripts/example.js | 4 +-- api-examples/scripts/export-data-directory.js | 36 +++++++++++-------- api-examples/scripts/inject-data-objects.js | 13 +++---- api-examples/scripts/list-data-directory.js | 16 +++++---- api-examples/tsconfig.json | 12 ++++--- 6 files changed, 56 insertions(+), 46 deletions(-) diff --git a/api-examples/README.md b/api-examples/README.md index 16d1f2c55d..436d971704 100644 --- a/api-examples/README.md +++ b/api-examples/README.md @@ -2,7 +2,6 @@ Repo with examples on how to use the @joystream/types package along with @polkadot/api to communicate with a joystream full node. - ## Examples ``` @@ -13,30 +12,30 @@ yarn run status ## Example code ```javascript -import { registerJoystreamTypes } from '@joystream/types'; -import { ApiPromise, WsProvider } from '@polkadot/api'; +import { registerJoystreamTypes } from '@joystream/types' +import { ApiPromise, WsProvider } from '@polkadot/api' -async function main () { +async function main() { // Initialise the provider to connect to the local node - const provider = new WsProvider('ws://127.0.0.1:9944'); + const provider = new WsProvider('ws://127.0.0.1:9944') // Register types before creating the API - registerJoystreamTypes(); + registerJoystreamTypes() // Create the API and wait until ready - const api = await ApiPromise.create({ provider }); + const api = await ApiPromise.create({ provider }) // Retrieve the chain & node information information via rpc calls const [chain, nodeName, nodeVersion] = await Promise.all([ api.rpc.system.chain(), api.rpc.system.name(), - api.rpc.system.version() - ]); + api.rpc.system.version(), + ]) - console.log(`Chain ${chain} using ${nodeName} v${nodeVersion}`); + console.log(`Chain ${chain} using ${nodeName} v${nodeVersion}`) } -main(); +main() ``` ### Scripts diff --git a/api-examples/scripts/example.js b/api-examples/scripts/example.js index d583cb5222..283f62f182 100644 --- a/api-examples/scripts/example.js +++ b/api-examples/scripts/example.js @@ -5,7 +5,7 @@ // // or copy and paste the code into the pioneer javascript toolbox at: // https://testnet.joystream.org/#/js -// +// // Example works on nicaea release+ const script = async ({ api, hashing, keyring, types, util, joy }) => { @@ -15,7 +15,7 @@ const script = async ({ api, hashing, keyring, types, util, joy }) => { api.rpc.system.name(), api.rpc.system.version(), api.runtimeVersion, - ]); + ]) console.log(`Chain: ${chain}`) console.log(`Software: ${nodeName} v${nodeVersion}`) diff --git a/api-examples/scripts/export-data-directory.js b/api-examples/scripts/export-data-directory.js index 31911ca148..9bfdd3fa0b 100644 --- a/api-examples/scripts/export-data-directory.js +++ b/api-examples/scripts/export-data-directory.js @@ -20,20 +20,28 @@ const script = async ({ api, hashing, keyring, types, util }) => { // it if its not sorted. ids.sort() - let transformed = await Promise.all(ids.map(async (id) => { - let obj = await api.query.dataDirectory.dataObjectByContentId(id) - if (obj.isNone) { return null } - obj = obj.unwrap() - - return [id, { - owner: runtimeSpecVersion <= 15 ? await ownerAccountToMemberId(obj.owner) : obj.owner, - added_at: obj.added_at, - type_id: obj.type_id, - size: obj.size_in_bytes, - liaison: runtimeSpecVersion <= 15 ? new types.u64(0) : obj.liaison, - liaison_judgement: obj.liaison_judgement, - ipfs_content_id: obj.ipfs_content_id }] - })) + let transformed = await Promise.all( + ids.map(async (id) => { + let obj = await api.query.dataDirectory.dataObjectByContentId(id) + if (obj.isNone) { + return null + } + obj = obj.unwrap() + + return [ + id, + { + owner: runtimeSpecVersion <= 15 ? await ownerAccountToMemberId(obj.owner) : obj.owner, + added_at: obj.added_at, + type_id: obj.type_id, + size: obj.size_in_bytes, + liaison: runtimeSpecVersion <= 15 ? new types.u64(0) : obj.liaison, + liaison_judgement: obj.liaison_judgement, + ipfs_content_id: obj.ipfs_content_id, + }, + ] + }) + ) console.log(JSON.stringify(transformed)) console.error(`Exported ${transformed.length} objects`) diff --git a/api-examples/scripts/inject-data-objects.js b/api-examples/scripts/inject-data-objects.js index 0a724f8d02..408cf84fcf 100644 --- a/api-examples/scripts/inject-data-objects.js +++ b/api-examples/scripts/inject-data-objects.js @@ -1,6 +1,6 @@ /* global api, hashing, keyring, types, util, window */ -const { isJSDocTypeExpression } = require("typescript") +const { isJSDocTypeExpression } = require('typescript') // run this script with: // yarn script injectDataObjects @@ -21,7 +21,7 @@ const script = async ({ api, keyring, types, joy }) => { const sudoAddress = (await api.query.sudo.key()).toString() let sudo - if (typeof window === 'undefined'){ + if (typeof window === 'undefined') { // In node, get the keyPair if the keyring was provided sudo = keyring.getPair(sudoAddress) } else { @@ -36,20 +36,17 @@ const script = async ({ api, keyring, types, joy }) => { console.log(`Before injection there are ${preInjectionIds.length} known object ids`) // split injection into batches of max objects - while(parsed.length) { + while (parsed.length) { const batch = parsed.splice(0, max) const objectsMap = api.createType('DataObjectsMap') // new joy.media.DataObjectsMap(api.registry) batch.forEach(([id, object]) => { - objectsMap.set( - api.createType('ContentId', id), - api.createType('DataObject', object) - ) + objectsMap.set(api.createType('ContentId', id), api.createType('DataObject', object)) }) const injectTx = api.tx.dataDirectory.injectDataObjects(objectsMap) const sudoTx = api.tx.sudo.sudo(injectTx) console.log(`injecting ${batch.length} objects`) - const signed = sudoTx.sign(sudo, {nonce}) + const signed = sudoTx.sign(sudo, { nonce }) await signed.send() console.log(`nonce: ${nonce.toNumber()}, tx hash: ${signed.hash}`) nonce = nonce.addn(1) diff --git a/api-examples/scripts/list-data-directory.js b/api-examples/scripts/list-data-directory.js index 0a7dd52ac2..631ab8fc32 100644 --- a/api-examples/scripts/list-data-directory.js +++ b/api-examples/scripts/list-data-directory.js @@ -10,12 +10,16 @@ const script = async ({ api, joy }) => { const ids = await api.query.dataDirectory.knownContentIds() - await Promise.all(ids.map(async (id) => { - let obj = await api.query.dataDirectory.dataObjectByContentId(id) - if (obj.isNone) { return } - obj = obj.unwrap() - console.log(`contentId: ${new joy.media.ContentId(id).encode()}, ipfs: ${obj.ipfs_content_id}`) - })) + await Promise.all( + ids.map(async (id) => { + let obj = await api.query.dataDirectory.dataObjectByContentId(id) + if (obj.isNone) { + return + } + obj = obj.unwrap() + console.log(`contentId: ${new joy.media.ContentId(id).encode()}, ipfs: ${obj.ipfs_content_id}`) + }) + ) console.error(`Data Directory contains ${ids.length} objects`) } diff --git a/api-examples/tsconfig.json b/api-examples/tsconfig.json index 0735d6c692..19d0fec61c 100644 --- a/api-examples/tsconfig.json +++ b/api-examples/tsconfig.json @@ -8,10 +8,12 @@ "strict": true, "target": "es2017", "esModuleInterop": true, - "types" : [ "node" ], - "noUnusedLocals": true + "types": ["node"], + "noUnusedLocals": true, + "baseUrl": "./", + "paths": { + "@polkadot/types/augment": ["../types/src/definitions/augment-types.ts"] + } }, - "include": [ - "src/**/*" - ] + "include": ["src/**/*"] } From bfa03059c42effaf6cfe846b10270f52d1302239 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Mon, 10 Aug 2020 13:24:30 +0300 Subject: [PATCH 04/12] api-examples: transferTest script --- api-examples/scripts/index.js | 1 + api-examples/scripts/transfer.js | 35 ++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 api-examples/scripts/transfer.js diff --git a/api-examples/scripts/index.js b/api-examples/scripts/index.js index 13b09f8ee2..fb9b017240 100644 --- a/api-examples/scripts/index.js +++ b/api-examples/scripts/index.js @@ -6,5 +6,6 @@ exportedScripts.example = require('./example.js') exportedScripts.exportDataDirectory = require('./export-data-directory.js') exportedScripts.injectDataObjects = require('./inject-data-objects.js') exportedScripts.listDataDirectory = require('./list-data-directory.js') +exportedScripts.testTransfer = require('./transfer.js') module.exports = exportedScripts diff --git a/api-examples/scripts/transfer.js b/api-examples/scripts/transfer.js new file mode 100644 index 0000000000..329e89368b --- /dev/null +++ b/api-examples/scripts/transfer.js @@ -0,0 +1,35 @@ +/* global api, hashing, keyring, types, util, window */ + +// run this script with: +// yarn script injectDataObjects +// +// or copy and paste the code into the pioneer javascript toolbox at: +// https://testnet.joystream.org/#/js +// +// requires nicaea release+ + +const script = async ({ api, keyring, types, joy }) => { + const sudoAddress = (await api.query.sudo.key()).toString() + let sudo + if (typeof window === 'undefined') { + // In node, get the keyPair if the keyring was provided + sudo = keyring.getPair(sudoAddress) + } else { + // Pioneer: let the UI Signer handle it + sudo = sudoAddress + } + + const nonce = (await api.query.system.account(sudoAddress)).nonce + + const transfer = api.tx.balances.transfer(sudoAddress, 100) + console.log(transfer) + await transfer.signAndSend(sudo) +} + +if (typeof module === 'undefined') { + // Pioneer js-toolbox + script({ api, hashing, keyring, types, util }) +} else { + // Node + module.exports = script +} From 9dd1cab6c3a3690cee37b8da62cca22a00a5a3dc Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Wed, 12 Aug 2020 08:44:00 +0300 Subject: [PATCH 05/12] polkadot-api types, correctly reigster Address and LookupSource to match alexandria runtime --- types/src/index.ts | 3 +++ yarn.lock | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/types/src/index.ts b/types/src/index.ts index e5c9eace5c..574ddcc704 100644 --- a/types/src/index.ts +++ b/types/src/index.ts @@ -53,4 +53,7 @@ export const types: RegistryTypes = { ...discovery, ...media, ...proposals, + // https://polkadot.js.org/api/start/FAQ.html#the-node-returns-a-could-not-convert-error-on-send + 'Address': 'AccountId', + 'LookupSource': 'AccountId', } diff --git a/yarn.lock b/yarn.lock index d3920c80a7..5c8b9610a0 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3058,7 +3058,7 @@ memoizee "^0.4.14" rxjs "^6.6.0" -"@polkadot/api@1.26.1", "@polkadot/api@^0.96.1": +"@polkadot/api@1.26.1", "@polkadot/api@^0.96.1", "@polkadot/api@^1.26.1": version "1.26.1" resolved "https://registry.yarnpkg.com/@polkadot/api/-/api-1.26.1.tgz#215268489c10b1a65429c6ce451c8d65bd3ad843" integrity sha512-al8nmLgIU1EKo0oROEgw1mqUvrHJu4gKYBwnFONaEOxHSxBgBSSgNy1MWKNntAQYDKA4ETCj4pz7ZpMXTx2SDA== @@ -3300,7 +3300,7 @@ "@polkadot/util" "^3.0.1" bn.js "^5.1.2" -"@polkadot/types@1.26.1", "@polkadot/types@^0.96.1": +"@polkadot/types@1.26.1", "@polkadot/types@^0.96.1", "@polkadot/types@^1.26.1": version "1.26.1" resolved "https://registry.yarnpkg.com/@polkadot/types/-/types-1.26.1.tgz#e58a823da22bd526b298f7d42384bf59b8994fad" integrity sha512-mrA3+qYyDvfOIOMkY8lg2ziCYpwOl3N1LUxKdiyBDtKM7Dl8ZWQ0nLUCDW5MhbzDlThmYjE4feBRA+2eBShfyA== From ba05fb59c87806815cbb19d399e09a3e927ced53 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Wed, 12 Aug 2020 09:04:21 +0300 Subject: [PATCH 06/12] api-examples: some code cleanup --- api-examples/scripts/transfer.js | 5 +---- api-examples/src/script.ts | 3 +-- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/api-examples/scripts/transfer.js b/api-examples/scripts/transfer.js index 329e89368b..d709ed2d97 100644 --- a/api-examples/scripts/transfer.js +++ b/api-examples/scripts/transfer.js @@ -8,7 +8,7 @@ // // requires nicaea release+ -const script = async ({ api, keyring, types, joy }) => { +const script = async ({ api, keyring }) => { const sudoAddress = (await api.query.sudo.key()).toString() let sudo if (typeof window === 'undefined') { @@ -19,10 +19,7 @@ const script = async ({ api, keyring, types, joy }) => { sudo = sudoAddress } - const nonce = (await api.query.system.account(sudoAddress)).nonce - const transfer = api.tx.balances.transfer(sudoAddress, 100) - console.log(transfer) await transfer.signAndSend(sudo) } diff --git a/api-examples/src/script.ts b/api-examples/src/script.ts index 285b11ea9f..4f6db5177e 100644 --- a/api-examples/src/script.ts +++ b/api-examples/src/script.ts @@ -3,8 +3,7 @@ import { ApiPromise, WsProvider } from '@polkadot/api' import * as types from '@polkadot/types' import * as util from '@polkadot/util' -import { types as joyTypes } from '@joystream/types' -import * as joy from '@joystream/types' +import joy, { types as joyTypes } from '@joystream/types' import * as hashing from '@polkadot/util-crypto' import { Keyring } from '@polkadot/keyring' From 7081f0f62bff7fa2fcd86efcc18cc8d64320cf2d Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Wed, 12 Aug 2020 11:13:25 +0300 Subject: [PATCH 07/12] move api-examples to utils/ folder --- package.json | 2 +- {api-examples => utils/api-examples}/README.md | 0 {api-examples => utils/api-examples}/package.json | 0 {api-examples => utils/api-examples}/scripts/example.js | 0 .../api-examples}/scripts/export-data-directory.js | 0 {api-examples => utils/api-examples}/scripts/index.js | 0 .../api-examples}/scripts/inject-data-objects.js | 0 .../api-examples}/scripts/list-data-directory.js | 0 {api-examples => utils/api-examples}/scripts/transfer.js | 0 {api-examples => utils/api-examples}/src/get-code.ts | 0 {api-examples => utils/api-examples}/src/script.ts | 0 {api-examples => utils/api-examples}/src/status.ts | 0 {api-examples => utils/api-examples}/src/tohex.ts | 0 {api-examples => utils/api-examples}/tsconfig.json | 0 14 files changed, 1 insertion(+), 1 deletion(-) rename {api-examples => utils/api-examples}/README.md (100%) rename {api-examples => utils/api-examples}/package.json (100%) rename {api-examples => utils/api-examples}/scripts/example.js (100%) rename {api-examples => utils/api-examples}/scripts/export-data-directory.js (100%) rename {api-examples => utils/api-examples}/scripts/index.js (100%) rename {api-examples => utils/api-examples}/scripts/inject-data-objects.js (100%) rename {api-examples => utils/api-examples}/scripts/list-data-directory.js (100%) rename {api-examples => utils/api-examples}/scripts/transfer.js (100%) rename {api-examples => utils/api-examples}/src/get-code.ts (100%) rename {api-examples => utils/api-examples}/src/script.ts (100%) rename {api-examples => utils/api-examples}/src/status.ts (100%) rename {api-examples => utils/api-examples}/src/tohex.ts (100%) rename {api-examples => utils/api-examples}/tsconfig.json (100%) diff --git a/package.json b/package.json index d978f603b2..135257eece 100644 --- a/package.json +++ b/package.json @@ -21,7 +21,7 @@ "storage-node/packages/*", "devops/eslint-config", "devops/prettier-config", - "api-examples" + "utils/api-examples" ], "resolutions": { "@polkadot/api": "1.26.1", diff --git a/api-examples/README.md b/utils/api-examples/README.md similarity index 100% rename from api-examples/README.md rename to utils/api-examples/README.md diff --git a/api-examples/package.json b/utils/api-examples/package.json similarity index 100% rename from api-examples/package.json rename to utils/api-examples/package.json diff --git a/api-examples/scripts/example.js b/utils/api-examples/scripts/example.js similarity index 100% rename from api-examples/scripts/example.js rename to utils/api-examples/scripts/example.js diff --git a/api-examples/scripts/export-data-directory.js b/utils/api-examples/scripts/export-data-directory.js similarity index 100% rename from api-examples/scripts/export-data-directory.js rename to utils/api-examples/scripts/export-data-directory.js diff --git a/api-examples/scripts/index.js b/utils/api-examples/scripts/index.js similarity index 100% rename from api-examples/scripts/index.js rename to utils/api-examples/scripts/index.js diff --git a/api-examples/scripts/inject-data-objects.js b/utils/api-examples/scripts/inject-data-objects.js similarity index 100% rename from api-examples/scripts/inject-data-objects.js rename to utils/api-examples/scripts/inject-data-objects.js diff --git a/api-examples/scripts/list-data-directory.js b/utils/api-examples/scripts/list-data-directory.js similarity index 100% rename from api-examples/scripts/list-data-directory.js rename to utils/api-examples/scripts/list-data-directory.js diff --git a/api-examples/scripts/transfer.js b/utils/api-examples/scripts/transfer.js similarity index 100% rename from api-examples/scripts/transfer.js rename to utils/api-examples/scripts/transfer.js diff --git a/api-examples/src/get-code.ts b/utils/api-examples/src/get-code.ts similarity index 100% rename from api-examples/src/get-code.ts rename to utils/api-examples/src/get-code.ts diff --git a/api-examples/src/script.ts b/utils/api-examples/src/script.ts similarity index 100% rename from api-examples/src/script.ts rename to utils/api-examples/src/script.ts diff --git a/api-examples/src/status.ts b/utils/api-examples/src/status.ts similarity index 100% rename from api-examples/src/status.ts rename to utils/api-examples/src/status.ts diff --git a/api-examples/src/tohex.ts b/utils/api-examples/src/tohex.ts similarity index 100% rename from api-examples/src/tohex.ts rename to utils/api-examples/src/tohex.ts diff --git a/api-examples/tsconfig.json b/utils/api-examples/tsconfig.json similarity index 100% rename from api-examples/tsconfig.json rename to utils/api-examples/tsconfig.json From 16687b62db7f5079fc3f52157299e9fb8cf115d4 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Wed, 12 Aug 2020 11:14:38 +0300 Subject: [PATCH 08/12] api-examples: fix path to augment-types --- utils/api-examples/tsconfig.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/api-examples/tsconfig.json b/utils/api-examples/tsconfig.json index 19d0fec61c..45be35edff 100644 --- a/utils/api-examples/tsconfig.json +++ b/utils/api-examples/tsconfig.json @@ -12,7 +12,7 @@ "noUnusedLocals": true, "baseUrl": "./", "paths": { - "@polkadot/types/augment": ["../types/src/definitions/augment-types.ts"] + "@polkadot/types/augment": ["../../types/src/definitions/augment-types.ts"] } }, "include": ["src/**/*"] From 9e28c05cf27621bc60bf2c719e8d52dde65f5b74 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Fri, 14 Aug 2020 08:52:43 +0300 Subject: [PATCH 09/12] api-examples: linter fixes --- utils/api-examples/README.md | 11 +++++------ utils/api-examples/scripts/example.js | 2 +- utils/api-examples/scripts/export-data-directory.js | 4 ++-- utils/api-examples/scripts/index.js | 2 -- utils/api-examples/scripts/inject-data-objects.js | 6 ++---- utils/api-examples/scripts/list-data-directory.js | 2 +- utils/api-examples/scripts/transfer.js | 3 +-- utils/api-examples/src/get-code.ts | 7 +++---- utils/api-examples/src/script.ts | 1 + utils/api-examples/src/status.ts | 13 +++++-------- utils/api-examples/src/tohex.ts | 5 +++-- 11 files changed, 24 insertions(+), 32 deletions(-) diff --git a/utils/api-examples/README.md b/utils/api-examples/README.md index 436d971704..766ea3c681 100644 --- a/utils/api-examples/README.md +++ b/utils/api-examples/README.md @@ -5,25 +5,24 @@ Repo with examples on how to use the @joystream/types package along with @polkad ## Examples ``` -yarn && yarn build +yarn yarn run status ``` ## Example code ```javascript -import { registerJoystreamTypes } from '@joystream/types' +import { types } from '@joystream/types' import { ApiPromise, WsProvider } from '@polkadot/api' async function main() { // Initialise the provider to connect to the local node const provider = new WsProvider('ws://127.0.0.1:9944') - // Register types before creating the API - registerJoystreamTypes() - // Create the API and wait until ready - const api = await ApiPromise.create({ provider }) + const api = await ApiPromise.create({ provider, types }) + + await api.isReady // Retrieve the chain & node information information via rpc calls const [chain, nodeName, nodeVersion] = await Promise.all([ diff --git a/utils/api-examples/scripts/example.js b/utils/api-examples/scripts/example.js index 283f62f182..d2e4036444 100644 --- a/utils/api-examples/scripts/example.js +++ b/utils/api-examples/scripts/example.js @@ -1,4 +1,4 @@ -/* global api, hashing, keyring, types, util, window, joy */ +/* global api, hashing, keyring, types, util, joy */ // run this script with: // yarn script example diff --git a/utils/api-examples/scripts/export-data-directory.js b/utils/api-examples/scripts/export-data-directory.js index 9bfdd3fa0b..3a27581ae4 100644 --- a/utils/api-examples/scripts/export-data-directory.js +++ b/utils/api-examples/scripts/export-data-directory.js @@ -20,7 +20,7 @@ const script = async ({ api, hashing, keyring, types, util }) => { // it if its not sorted. ids.sort() - let transformed = await Promise.all( + const transformed = await Promise.all( ids.map(async (id) => { let obj = await api.query.dataDirectory.dataObjectByContentId(id) if (obj.isNone) { @@ -35,7 +35,7 @@ const script = async ({ api, hashing, keyring, types, util }) => { added_at: obj.added_at, type_id: obj.type_id, size: obj.size_in_bytes, - liaison: runtimeSpecVersion <= 15 ? new types.u64(0) : obj.liaison, + liaison: runtimeSpecVersion <= 15 ? api.createType('u64', 0) : obj.liaison, liaison_judgement: obj.liaison_judgement, ipfs_content_id: obj.ipfs_content_id, }, diff --git a/utils/api-examples/scripts/index.js b/utils/api-examples/scripts/index.js index fb9b017240..eaedc4eff7 100644 --- a/utils/api-examples/scripts/index.js +++ b/utils/api-examples/scripts/index.js @@ -1,5 +1,3 @@ -const typesVersion = require('@joystream/types/package.json') - const exportedScripts = {} exportedScripts.example = require('./example.js') diff --git a/utils/api-examples/scripts/inject-data-objects.js b/utils/api-examples/scripts/inject-data-objects.js index 408cf84fcf..e86beeba71 100644 --- a/utils/api-examples/scripts/inject-data-objects.js +++ b/utils/api-examples/scripts/inject-data-objects.js @@ -1,7 +1,5 @@ /* global api, hashing, keyring, types, util, window */ -const { isJSDocTypeExpression } = require('typescript') - // run this script with: // yarn script injectDataObjects // @@ -10,11 +8,11 @@ const { isJSDocTypeExpression } = require('typescript') // // requires nicaea release+ -const script = async ({ api, keyring, types, joy }) => { +const script = async ({ api, keyring }) => { // map must be sorted or we get BadProof error when transaction is submitted and decoded by // the node. Make sure they are exported in sorted order // As of July-22-2020 - let exported = ` + const exported = ` [["0x024d7e659d98d537e11f584a411a109f823be28c2e33d5fd5bc83705459442d9",{"owner":442,"added_at":{"block":1128903,"time":1591306668000},"type_id":1,"size":219008840,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmc5fAfRUXnHHtXo2dzKG4qMxQU8rz49meRapvmBsGF5cA"}],["0x03d7010faa563d11cad338c43bbac73e3d54369a96385f934a71e454fa307052",{"owner":447,"added_at":{"block":1466693,"time":1593339768000},"type_id":1,"size":288963385,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQDyQFmF3qZ8r1h2Rumd6M1wgykGZTq3h2Zti2UHX91aT"}],["0x05a5d2bc33fcc1d3aff27166a648c86db7e62563bcbe787ec8f9caa58320fc57",{"owner":438,"added_at":{"block":1055902,"time":1590867516000},"type_id":1,"size":427343853,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmT9SqacYty5bdtAtp9DPTiifcX6UDtZbsgZYs29Zt2RGj"}],["0x090721ad1260d7e3a595aa7c006c63142f78d61dc9b98aa02b2f950e368c137e",{"owner":447,"added_at":{"block":1466438,"time":1593338238000},"type_id":1,"size":310674005,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmawgrC6XHUxH461tWjzSRqneZpt9ehP7ApkkxeTKAXFm5"}],["0x09bb6467ed9702401fe14096bfd24f2326b06b97a8147a213bb472560ea7d9fe",{"owner":309,"added_at":{"block":219866,"time":1585804332000},"type_id":1,"size":388639347,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTbQLFvs6JQpKwHWVV3UdqFxPs8AycXh4pXmAQJfFG5Hv"}],["0x09eeedb5ce5a84a2a03e1e90fcdaad069e2ea4aa48dd2821c31d44b0a13b073e",{"owner":8,"added_at":{"block":835705,"time":1589541222000},"type_id":1,"size":97107,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVjycZ8xJPUtfL46xhgPnZBrX4Zou5Husa99PGH2pxWuG"}],["0x0aed8adce29955d23975b2ab605c1cd78c42ce9aa8e3d5de89b7e4e9f140b092",{"owner":442,"added_at":{"block":1092335,"time":1591086528000},"type_id":1,"size":89227056,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNqqmoAb8pRCkfsHiEzcxQ7P4DfcbUAgvG6d4Vcn2tANt"}],["0x11766a6bf64bcfb8264dbecb326d75b6f37efdc178037c0dc9e96118088a1e79",{"owner":350,"added_at":{"block":1040723,"time":1590776238006},"type_id":1,"size":108038112,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWVsNMZtR1hEKmk6omV8kDgLMAxYwovd48UePdRFKCkMb"}],["0x11bcfb731670560b4a7f182df74f321c2004724d756a05f57ac3d4968eeea427",{"owner":350,"added_at":{"block":1041073,"time":1590778338000},"type_id":1,"size":76625829,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmdzd86ZgMu7u7A74PXNL3jAsj4LydLEkejckSHDxnGDwn"}],["0x1569df4aa068b69fe2b88fcd04a9a1939eaec11a45e15068f2d357d29124735b",{"owner":350,"added_at":{"block":952596,"time":1590245130000},"type_id":1,"size":83605504,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWMQgA13brwFkWojPAQY8Jt48fxp8GpuDsAUfMGh2RuCE"}],["0x1630bbc4eb9cc803dfb7e6f445baff6938cf3e86cbcce6a4308375bd9bcb17b8",{"owner":442,"added_at":{"block":1129261,"time":1591308834000},"type_id":1,"size":290289463,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTcMFK8PEdK9ayv825GT8AP6RfKQq4eYSnnDqY61XWGGi"}],["0x19de0fdc6ef77c6afb52ee1e1f6f5a70557442725852385d34a1537857d78793",{"owner":350,"added_at":{"block":1040903,"time":1590777318000},"type_id":1,"size":8388608,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZofxmdtoUYiDRM2LopoBgoaf8QuSdRWDS4mxMSkgw6Qb"}],["0x230546c3c70f0e892adf19be590e8aace2a091f6a6bf6e9e4e84ceccf8f84c57",{"owner":336,"added_at":{"block":1135451,"time":1591346100000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x24949a52872f06ef61ff3a453e14ffdd358518a434e20f46819620c7d8fd788c",{"owner":6,"added_at":{"block":30261,"time":1584641082000},"type_id":1,"size":11703644,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbbK8TSs4YKo25uaTQDN16GWcUpGkTay6hF2jL4aLyy4z"}],["0x28deb34402e47352adea11da480711b04190e3e2d4cd6fe6cbc2fc1823d4076a",{"owner":432,"added_at":{"block":1213031,"time":1591813500000},"type_id":1,"size":22071878,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZcrf8VHgg78NwG7zgwYgBB4kHo5DM3GmPNdjDBe971rk"}],["0x2a191bdf05d03a11ba557241dd0d94e820144c1da7aa37bf4c75cc7207af4c88",{"owner":442,"added_at":{"block":1124157,"time":1591278024000},"type_id":1,"size":239017927,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVpASwjCBiMQm2uHoamxA51pqBuFDzXmV5oKAsWN7xzqV"}],["0x2b88e65e69fa58f983e5db6ce282783d320bda37faf730db959f841bf1777834",{"owner":447,"added_at":{"block":1466836,"time":1593340626000},"type_id":1,"size":67518865,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXsFsAaoSxzEtBtzRZ8f59NicapmV98PEReMVGtycumaV"}],["0x309c38c4216d23dc59d8f2747d6c7a3fca4f31e68f6cbe5d22afb704f22edecf",{"owner":447,"added_at":{"block":1367174,"time":1592740608000},"type_id":1,"size":355856562,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmeSnJjdUocf4pSifABZByHvNUbDjRCfS45bYHmQFq9GRx"}],["0x30e517661b82e1c774a659cd2d7ed5c33be6ac0eba95a74596c05ff912829f4c",{"owner":442,"added_at":{"block":1128414,"time":1591303674000},"type_id":1,"size":219008840,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmc5fAfRUXnHHtXo2dzKG4qMxQU8rz49meRapvmBsGF5cA"}],["0x31a7436a29d8daa4fa7a20a038b26614964584846ea92f3e5f5af543be59a900",{"owner":442,"added_at":{"block":1121633,"time":1591262862000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}],["0x32c8a93d73e14981ad910e6dfb19c83212fbeccbbc773cf3b35e33ac29ee6dbe",{"owner":442,"added_at":{"block":1129511,"time":1591310376000},"type_id":1,"size":381032453,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXv5w8M34dLSN31KoEsbsVHtqpi7yYgxxEdSzvS5ArN5T"}],["0x339d6574987cd3802c89efce1d93a606367ac5154d4e91c749ede761a918e4c5",{"owner":442,"added_at":{"block":1098823,"time":1591125474000},"type_id":1,"size":61109974,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPXxuMcEvZstbaHEy8CqCramJ8ZJRq2faNut8igmvRaDA"}],["0x36ac61276f1ffb56f65f54d47595457b669f6afec86b800dd7fbf76423c8df9a",{"owner":335,"added_at":{"block":281214,"time":1586187438000},"type_id":1,"size":486671229,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQUPSGGt9zQEUHHgvLsUrKWBGRbJZwLDgN9Ds1zGgHa3Q"}],["0x3b3318f4949850d00e0bb53abc60b17bba6918b56f1848f3c04bc8e32ec62a01",{"owner":442,"added_at":{"block":1128625,"time":1591304952000},"type_id":1,"size":476300317,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmY3BVExv59DY24A6kLvmayBNgGKudhdaKcCbTvLj8BXyh"}],["0x3d9d6721a05e68875a598c3b754e28ab466fad2e5d2bec5190019f8eb86a9fbd",{"owner":447,"added_at":{"block":1367042,"time":1592739816000},"type_id":1,"size":464135764,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTPjGsmJMq66rHtQMtUu1UiEnTRght9NW7PuuvPGnNPrV"}],["0x4202b8da5f8b18d2ebe74eeb333f00ed22326cea14fad0c5db14521bb90cef4b",{"owner":442,"added_at":{"block":1129332,"time":1591309266000},"type_id":1,"size":296289584,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVP9m885U84WjFqTH5Z7r17hrtwK1VJ9fbfriMw11Zmhi"}],["0x42e4b57bb3bc6c7c72f7e1e1c3dba164f301799ebc62f52d94ff110afbc58daf",{"owner":442,"added_at":{"block":1129185,"time":1591308366000},"type_id":1,"size":228968517,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmW1ogMZu3Pp6W9empkK3SxceqcoKHas7rg3iybYoUA1mc"}],["0x44792a5aa5b3753afa1158c47f9975b3e7abbbbb213d1e91f024c3e1f688c68a",{"owner":9,"added_at":{"block":1137835,"time":1591360464000},"type_id":1,"size":183564493,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZExcmZdfyLh1en5ozAejPaN76QTPAH61HCqRjgnzFq65"}],["0x4800d425fa2591edb2b936b4f3078570ee3740c2434a99a3f96e85afd37bcaa5",{"owner":442,"added_at":{"block":1129061,"time":1591307622000},"type_id":1,"size":323491639,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmf86Wu4uHrnNUAFeM8CSyUprCfrwrKE1Ejg8AJGqe5GHv"}],["0x48495b3033d497e76298e9301db064d1d36d1b845154e0d4baa06c150a9bbe4d",{"owner":442,"added_at":{"block":1129821,"time":1591312236000},"type_id":1,"size":16788182,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSmEiRfh2x2CnksELXXfd5pNfFHh7uzAvx57dCu42JZYB"}],["0x4964c7e73f4129f5f541b4ac2713b8d10922cd2249fa2577978a775389455f6c",{"owner":442,"added_at":{"block":1130032,"time":1591313502000},"type_id":1,"size":41396854,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNsERXvLpqKFWzc18zBVwj2XzQtPq3uGjRhdJuEjdCpBa"}],["0x4d37449528ca4e54b3a56d51ee0bd3dae289dfda0d683c8d52bf60f804b24474",{"owner":350,"added_at":{"block":1040719,"time":1590776214000},"type_id":1,"size":116963310,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmevuPnBLNzbcqCnAjEf38GCPyFFWDWAjVEXpiVxMFggcM"}],["0x4e5b77b2b26542c352bc9d67f2826739f7947a8dfe8780c0da7ef5a578325c16",{"owner":442,"added_at":{"block":1126921,"time":1591294632000},"type_id":1,"size":454042427,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTrvQUtZgjjzQUivzrBYPZH4ZmUfSGDMy7kjgBLvJu8cL"}],["0x4f88cb65b21c9960bfbb29941258643a41d279f85e7e9d3e361dfb007d2082ad",{"owner":448,"added_at":{"block":1426221,"time":1593096558000},"type_id":1,"size":512691061,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmTBtR7zRCu9QVnKR16Rh68KPgENWsm1miLe8rWxx3s3Rd"}],["0x5339a2ad58454d0f2f56fe19a402555197cf0cef6090d38be5991cfd7560a29f",{"owner":448,"added_at":{"block":1426315,"time":1593097122000},"type_id":1,"size":48401831,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWZKK2tduQHWh9WdekCzezogikZ2N17Vkjx59EqKKLMhj"}],["0x5487981d021b38d574aa1585b80dbca4e0a06356f654a9fb388813dc73a45afc",{"owner":442,"added_at":{"block":1126059,"time":1591289454000},"type_id":1,"size":228190053,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmaV45bM5unHC2eavW2wrXcPkk1eteXFM5ohKdxact37yi"}],["0x555112d6f5c0668b2b6a6e1fc4140dd9678cf3ede7d8167ac3281d8707fa510a",{"owner":350,"added_at":{"block":1040822,"time":1590776832000},"type_id":1,"size":115602785,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmeXbHshnx8MrAMSn8BwPv3VgW9HhyneuyjXVhJQp7AEzr"}],["0x558d4f1851d7a031aa77e02a47edcbf3769fbfb15d91356359c7f0920d362204",{"owner":438,"added_at":{"block":1067485,"time":1590937188000},"type_id":1,"size":466914342,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQPFijUtKGY2h7TLMoKS43kCTvbNtBJt5zhkWB2eXNcFv"}],["0x567126390559878911908d9014d16970ca3a8fbfafb73ca58ea2266e4df92cda",{"owner":447,"added_at":{"block":1466727,"time":1593339972000},"type_id":1,"size":175136347,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmcsnrCbWBdw1NbqgHb2NpEKpGg1jmZQScAiYkocxVxJKT"}],["0x57fbba6e14080b7603a37d2f72661a0e50e8bfc75d2016751a0fac2e0e0c5ce8",{"owner":442,"added_at":{"block":1129257,"time":1591308810000},"type_id":1,"size":377630545,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdLgMHn8uKS3bZM7VzV7BKxGK9RB5mpwfZpkUM9WNDkGS"}],["0x5c0d046280e9656772ec5e716c2849c6ac97a27d7e7f5a81f536614d6f26f401",{"owner":442,"added_at":{"block":1092298,"time":1591086306000},"type_id":1,"size":103571823,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbPwLcE31iuUeFaiPQGnrTPWEQpjRFSTrxf5GErNGVrLR"}],["0x627e905c3f1cd963bd6c00d61a742b88ce753139c7a245ed7c5afcbacd0fa79e",{"owner":350,"added_at":{"block":978132,"time":1590398916000},"type_id":1,"size":14055552,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXCoAJrffVv4Wo9cpwYmRD1Wan1p1Ae8q9ayFgwNBXZn3"}],["0x6860c305bdb1b50bb16cac8722a661d22180f9a7aabf26c65e07c1c7391c0a9d",{"owner":442,"added_at":{"block":1111030,"time":1591198980000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}],["0x690f17fcf72ef1411d446671abe79a54cd636f5fd861ec7edec1734c76cd76cb",{"owner":442,"added_at":{"block":1081934,"time":1591024050000},"type_id":1,"size":77047118,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQ8CMEaCgLtGTW9mfHDtScJev4EpX8fsaSjDohKvvHHZr"}],["0x6b37a30969e1179425bf6aa8981beb7f8eeb9db38da5e939749fc50032908cac",{"owner":442,"added_at":{"block":1110501,"time":1591195764000},"type_id":1,"size":143177220,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmcnCxnLXZVrkGGKMRt5dQqbp3nsbCWdMgCw8oTWhJJnqV"}],["0x6b581bb1fa3f25bf0fe52d08cc2cfce9d84371154556b9ebe9ad4778e42b24f0",{"owner":309,"added_at":{"block":10882,"time":1584522906000},"type_id":1,"size":357059329,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP4Q9bD1iJomLk5cmWseATeYiQpTf2mTajvrsH5wCAnGv"}],["0x6bd69751fecccf320548f4b577b13c0e23a59f826f8a408c5a7ec11f03328ce2",{"owner":442,"added_at":{"block":1082012,"time":1591024518000},"type_id":1,"size":42754567,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmagdA7Zf9Hprj2ZrYEBM2WU1WtZhjh5TMtDgCKV2mov3e"}],["0x6c16eda9fd31abbd626c155fa85990f5061e87d4b024599d9446e0a2363f6549",{"owner":336,"added_at":{"block":819861,"time":1589445528000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x6cb1958d0fe6cc59eec2722574175b0dabe7d431795b7bc5e80290fcfedf25e5",{"owner":442,"added_at":{"block":1121846,"time":1591264140000},"type_id":1,"size":214382445,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbgqP1W2wmnf7qWmdoo5FKxyEbygoudcSekYmJorUyhdL"}],["0x6db58a7fe253876c2aea44a3093c6db043b34cc1a16f0ab396b039c410042929",{"owner":442,"added_at":{"block":1110793,"time":1591197534000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}],["0x6f8767696e9e07a4691126eeb5cf790950ff82e32daff1d8be13d9aa5c5cd8d5",{"owner":336,"added_at":{"block":821397,"time":1589454804000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x71e3020c5f4181dfb646bf2a1a1da38a536fc2cafcfaffce989093d247ef6515",{"owner":309,"added_at":{"block":4059,"time":1584481830000},"type_id":1,"size":297638125,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXTJ8JS2L4DLmYSZcjLR9KZtqCKTwTmTT4JcenPwHYzsC"}],["0x73b14241a22c374a2b27161a2e259705459ce1cbee979b4f27a910c6befa5873",{"owner":442,"added_at":{"block":1126289,"time":1591290834000},"type_id":1,"size":303724484,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUkjHiHdSG5kARgZQrCWZeyMVKBfxpT4m1DPEk3LMsRSV"}],["0x76318fc316171d4197e71a06e18df41f5ebc7a1b4b98be15a1f6d4721eca67b6",{"owner":9,"added_at":{"block":10800,"time":1584522414000},"type_id":1,"size":102256050,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmW8j5XdoKewAzJJvq72iRhXK4nKfRzB5eQXGFjnJTGgqS"}],["0x774d61799ad74137d18b0eab532bcdea6b82c8bd1b6a646d861b95d7b8c6ddbe",{"owner":448,"added_at":{"block":1425677,"time":1593093288000},"type_id":1,"size":383882912,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVDxMygHdBYdaYtf3g7ZigyCvxusqEwQdcfNbDxwMCndR"}],["0x7a3859e8742d9bf85b5fc0bcbf5fd86aaecf58119f3a33dd1622d43ab8182510",{"owner":350,"added_at":{"block":952082,"time":1590242046000},"type_id":1,"size":85057536,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQ9agG1gMb7U6w4amyENMTHru34AwZhSgPZCzTAbWJ2Mb"}],["0x7c0a51e41fccf3adca2ca7fdb4492ddd80a3c8716ac04ae408a0a839778405ec",{"owner":336,"added_at":{"block":938132,"time":1590158118000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0x7da45cb1e508b802d7eed7f2f07fc8ebea803266027a204ddc219626acbe005f",{"owner":2,"added_at":{"block":1812377,"time":1595417754000},"type_id":1,"size":125787601,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUmeRNYYBWQtju26msXXsxfTytBbKmwTpPdR4z5Vk8L3U"}],["0x7e496ba7bbb89262263a2e9978bff5f151c1045222245c2434b9c3411c68373f",{"owner":309,"added_at":{"block":250877,"time":1585994772000},"type_id":1,"size":415862058,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXMjGjMaUzhADTUkCwMx9zcwCbAHUqhg2fnkRapCfLgbJ"}],["0x7e8798b65aeb97d80f15614f4fbfd1ccc6ea455e450381c8effe67f5af473cd6",{"owner":335,"added_at":{"block":252882,"time":1586007636007},"type_id":1,"size":278383205,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRtgQTyduMCqGTnRUy8b52h53CATVMMfjqxjFC66Td3HS"}],["0x85ab1f59f7268995b96cb5eda25f69aea13ce8c7adb18fc2150cac1accb34e10",{"owner":442,"added_at":{"block":1123966,"time":1591276878000},"type_id":1,"size":185849059,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVP24JciSRNNd3wUELKeWJR1q3dJK2thbKu6Pky2Y4Zf3"}],["0x89a0a48541889c2cb98592e715225facaced548ea7523e089a593409904a66e7",{"owner":447,"added_at":{"block":1466899,"time":1593341004000},"type_id":1,"size":90491542,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmR2WuxrferxegFHCyMoJiByAwzW5n4bt7exwaaMB766qa"}],["0x89c316cf198daf7df103a82bb5ee86116acfb8a6ca84de01a53449f8c5fed3c7",{"owner":442,"added_at":{"block":1110622,"time":1591196496000},"type_id":1,"size":247006015,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVDt1MFxNS8r416RkeEadadzhfFomPby18wcgbCQ9RBxL"}],["0x8ca510b0578ab7e688db30816f783ad78bfe4323cfe045beff1d11244173f547",{"owner":442,"added_at":{"block":1098712,"time":1591124808000},"type_id":1,"size":62038020,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZ63mpsT6tFbr2fx7BxcQRM9p7VDHBVLCtCZQ4Cw68kef"}],["0x8ee1dbbfa90034a258ee8296d794baaf7ffeabf1fa43ed075ddd56ae84a7769d",{"owner":309,"added_at":{"block":295617,"time":1586276886000},"type_id":1,"size":305573424,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZGpGTC8yoUvR7WPmNB5FC8ZJCikrroG6LJU9qtZjzFcr"}],["0x8eebd480e55d8971744d8d35839f5092c2dc5a57d8b96e8c9e1641ed5446df53",{"owner":442,"added_at":{"block":1127271,"time":1591296738000},"type_id":1,"size":296167714,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSdGGSoo7htcyRA93VmGWWv6PezcQFTQ7hzoG7WTz9nat"}],["0x8f32787bcb8ad38be82e9595a44b8adcd5e5271f688dcc61d29f796db5cad19e",{"owner":309,"added_at":{"block":80121,"time":1584946890000},"type_id":1,"size":358383122,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmZszxaTJuyLE7bsWimKmA6EnWq7CmCDUunQHPyZ6kyJYM"}],["0x8f7948e5e046024dbec83d4fac4188348e32f3ce3ef8b26561326aad4a1150a5",{"owner":306,"added_at":{"block":399005,"time":1586904192000},"type_id":1,"size":59359868,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPvgMP99gof4RYmcSMEciN3foGmWnMzefUpZAGCCJ8GX8"}],["0x916b6fc96f3d00dd90fccc4618c67178cda61885330c78019fee3d34ffd3e148",{"owner":309,"added_at":{"block":122598,"time":1585207182000},"type_id":1,"size":293299508,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmT21sEqJxDK2LYfZckjyaXWorkNYjuSLKyMrQVt5nnEXX"}],["0x91883d2a207ee1f772f3ec7f48864fd3931500f37bfe8bf0664e3829560a5d5e",{"owner":350,"added_at":{"block":452900,"time":1587232986000},"type_id":1,"size":8808959,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSiDroNEFVwjmnvqguq1Ke6EF77JixsUg1negSWsZtfrt"}],["0x91ae12a19f8ba2461e53d8c0de653c64330996c3e2b93234d8f5db6caae5ba10",{"owner":442,"added_at":{"block":1128145,"time":1591301982000},"type_id":1,"size":296167714,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSdGGSoo7htcyRA93VmGWWv6PezcQFTQ7hzoG7WTz9nat"}],["0x98a2cae0e026c32ef02ac9513d7160a78dc9b3e587b6d55fada211ce811611df",{"owner":447,"added_at":{"block":1466522,"time":1593338742000},"type_id":1,"size":406931374,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdUmdJLFH3SxSUaW46VuN47wo888hFSGt9RP7dBZKHJFe"}],["0x990889a2b149410e4d3576ec5af732843cd38552238d021c614a811e32ac997e",{"owner":442,"added_at":{"block":1128091,"time":1591301658000},"type_id":1,"size":466729213,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmfLASmYcoZwKzqemWDH55XLMvSqobb2prZA6xmq6T23Cc"}],["0x9d75a21ff370cb8b1e74e88d58b5e11a928ac1c48f6b7098e1d25e6df4ca2eee",{"owner":350,"added_at":{"block":1040980,"time":1590777780000},"type_id":1,"size":104637904,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNjmKwksF2WabmA4NyLiyk7h5LZpiRqryQV87JzL4M26x"}],["0x9ed8ded941839a77e2ac1ba931d5a3f22bf142794c3b4297d1d65bac92f9d739",{"owner":442,"added_at":{"block":1125491,"time":1591286034000},"type_id":1,"size":377595483,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmcrf9hMvWqzoAEWH2fnAr1k21jmd1hjvKiTp7BNCJDY73"}],["0x9edacefe7b92331829e93653e5e6c470a73dd6d5eb9e8bb3e6504ad97c6b19b2",{"owner":442,"added_at":{"block":1110425,"time":1591195296000},"type_id":1,"size":211637438,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRmJPWavbxRboXoUvVSkgcL8vCQdxpdtifdyLuuzqSNDA"}],["0xa25d85c5e547dbfbe85edf476b7a3fcecaff3e7a1a156a0ff1c9ace0089bca43",{"owner":442,"added_at":{"block":1128755,"time":1591305780000},"type_id":1,"size":487027735,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmX1uCVbqhjxrVa6ZNp2q9XCaMrTTBEZVUjmq4xdPRjGQG"}],["0xa45878ab69b49ed57ffefaa524548c5c69d05661202f01073c94ea14185f7f5c",{"owner":9,"added_at":{"block":53411,"time":1584783462000},"type_id":1,"size":211387424,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdpygXdKmjgCQNB7wGN7wzhGHD8gnFAsuiU77TTFCbpFy"}],["0xa575d1ee097acdc99989b4d8c0f4ee56bf472e793f5c36ab552ce18ca68109fc",{"owner":442,"added_at":{"block":1127098,"time":1591295694000},"type_id":1,"size":478905799,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXEbCMrBBr56o3Hyu1PUf35kW6UWmN2jaHFJAZMJKTew2"}],["0xab2a6a80321c2b4409c2804af9ac1fe1a8434419d6be1266e3df1207e2470ec4",{"owner":442,"added_at":{"block":1092258,"time":1591086066000},"type_id":1,"size":96442249,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP7fZ4ERh7JzHqVxveE2ZPv7mX46Lh8iAQk7KiMtVEo2g"}],["0xab4109dcfac767e9b557cef22ce726cc2a9af0fd58749e7dff7b9a431e130561",{"owner":448,"added_at":{"block":1426376,"time":1593097488000},"type_id":1,"size":48401831,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWZKK2tduQHWh9WdekCzezogikZ2N17Vkjx59EqKKLMhj"}],["0xac3480f720c1c24c7aafcb13c707be44badcf646690ff7bdbede011b28636d7b",{"owner":430,"added_at":{"block":962539,"time":1590304926000},"type_id":1,"size":145386199,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmeg2CZPpFhWwU2f2dcC8RQsmS9xuiUFbox6twFFvY2b16"}],["0xac9b568a6b7fb3403ba12eb15326740ccbfc1487766e62a1df239867a779f755",{"owner":309,"added_at":{"block":385966,"time":1586825580000},"type_id":1,"size":355621626,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPtSKii2xQ57DUNeHCxrGnuGtrSFHGBZzcvJauyb62Zo3"}],["0xadf8a4933f69fe51a9b16cd4310389ba8efadc8bed078c30f61752f5ba4ca625",{"owner":442,"added_at":{"block":1129663,"time":1591311288000},"type_id":1,"size":285552738,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPu36d9TJorVTLog9MQcXFsuhLYwjvy4o4n45VRj3NZeg"}],["0xb52a6681e9bc13208bc4a9c1238b142b83eb793c8e63aa95628dc31e5d134c50",{"owner":309,"added_at":{"block":178824,"time":1585551600000},"type_id":1,"size":415473786,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbruxNcR2AnCaW6UQU5gGXUZH78kePhcw8d8PTz56rVBb"}],["0xb5e6aa0602d416581017f69bd1f4f4a6d81122ac6d1d6a1e1572b5ac6ecda230",{"owner":438,"added_at":{"block":1066911,"time":1590933744000},"type_id":1,"size":466914342,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQPFijUtKGY2h7TLMoKS43kCTvbNtBJt5zhkWB2eXNcFv"}],["0xb73cfa311d157640033d60611d87ffd9232a0e6ef0b80e0302ac90879b2619c0",{"owner":442,"added_at":{"block":1129388,"time":1591309626000},"type_id":1,"size":178952334,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUbULJeFkgUTBAzChSPigpN6D9VeikkHLvijtrE1AskBu"}],["0xb75caf11de2bef62de71b1a13be82194451fcab7109dba53c0f7a4adf084cd75",{"owner":140,"added_at":{"block":308380,"time":1586355066000},"type_id":1,"size":30770348,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVuLj5TrBBwuVTNoW5eRXrf7xsmsCXrKR469hfv81kihR"}],["0xb7c6803a781aaf175846cf4a3d9bf61303be3cb86e2e4f357ca6d08dacbc55ec",{"owner":336,"added_at":{"block":820868,"time":1589451630000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xb964415073fa910b2e9ade2edb161ba32183502986543a1020c19c03af4126b7",{"owner":442,"added_at":{"block":1129456,"time":1591310046000},"type_id":1,"size":274204288,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPVfNCnVrbCxGxhR1BZrrjcv9WH8zwEKXXznGSDZT8XfZ"}],["0xbb904988c4888a74248f2d18d664d95e9bd9b6392c8a709064c8d54a0cf2b1ef",{"owner":309,"added_at":{"block":23619,"time":1584600726000},"type_id":1,"size":317341899,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUtsmwDF8HrrNXKKTfWYzXFznt5rCEbUe8Q2gGJ6ZTiab"}],["0xbc10f23b830d39018dc8f60f2434d7db3d14262364b3d4e8617a9e8b9ada50a7",{"owner":442,"added_at":{"block":1126767,"time":1591293708000},"type_id":1,"size":256241998,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmYPfooy3YLKxsLfScbmZWNJy4VyAcK5WkfqwjdsWzL7GG"}],["0xbf6c9db08a2f0dd7b5b3966a8f8d8ab312c2965d25867a1ab7463ffc6fece928",{"owner":441,"added_at":{"block":1114794,"time":1591221714000},"type_id":1,"size":55708471,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbfXW6JafVg9dUesazR2wkJq59cCw6eSo8TLUY5Q1rYzQ"}],["0xc17cc1f1a2723bfdc468d624b4b223c0fd31376877e88b7515ec35dec29e7ae2",{"owner":7,"added_at":{"block":1594924,"time":1594110738000},"type_id":1,"size":513795950,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmSbdvdc46qE4k8HftqoDW942Ay777RSfhQ6PcGfbkyA5f"}],["0xc2609ab0d956d2daea48f45c678c742b7bdc35d7b03abae4b3c5895a9e1523f8",{"owner":350,"added_at":{"block":1040904,"time":1590777324000},"type_id":1,"size":109999676,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qma2HgfkVZNXiNQwUNZSCr6k4Vvnebc8XVJyw3tEF8EMNi"}],["0xc2924d93aa476e303ecb8c76cc9473a608cdbfb1d40722d8557d0a37764345a9",{"owner":442,"added_at":{"block":1099325,"time":1591128486000},"type_id":1,"size":214961405,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmT138QMCCzJxMhYnFZcvLf8Cs1Joptoy9wtoUqMFWsZQr"}],["0xc4a1e8f7c0d7ec4f0616083c5bcf1dbf1277560910dfeb5417dea3764a64390f",{"owner":336,"added_at":{"block":1136287,"time":1591351116000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xc6649ad85ef2722b6088f37b83c79e0181f372d27a80169e2d70e9e382f1c110",{"owner":442,"added_at":{"block":1126872,"time":1591294338000},"type_id":1,"size":323293926,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdB7mitLeNQ6WZkwBQXVZtd7jDNU713XAfsgDmijt49A3"}],["0xc87a2a87b0cd125a2fbc222f3855caaa1fdbe2149f55c8670b3ddaeb873f309b",{"owner":311,"added_at":{"block":40871,"time":1584705954001},"type_id":1,"size":23677745,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVfnwL5bbv7veTYwS13zUny7Qt22cGei7HCBiunmM64xm"}],["0xc9b3f0c761e8c26a9e75f70628fcebf838fb85771c07874abef3ac83852deaa8",{"owner":309,"added_at":{"block":10038,"time":1584517812000},"type_id":1,"size":53550842,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmcZmcm6xQY3wmiB8mf4aLKe2XzqeEedvWZoszBEKGpfpG"}],["0xc9dd0359955ae104e36a2267a3e0f42fc95d408658f05b78671e43c1133bd549",{"owner":309,"added_at":{"block":40542,"time":1584703902000},"type_id":1,"size":101120291,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5Xg7JLyt6aKZy9AEriP9S6N2D4BL3kA3viWu3M39U79"}],["0xca99d0df631f2f57ceaf7d96954086fc93182fde0c98bef764def13377fba8dd",{"owner":442,"added_at":{"block":1121678,"time":1591263132000},"type_id":1,"size":320771545,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmUgaKnr5H5KFvUeddmcQb37pBH5y7fF3ALavTFh5UaGmK"}],["0xcbb5df475a3bacac3435067d597fa27c1eb723bfdd713a94cdb3b8a48b9278f9",{"owner":442,"added_at":{"block":1129080,"time":1591307736000},"type_id":1,"size":402651528,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmbMePgwenk4swC5qYBUCVDa116CavRJFg3XZkbr2WDttx"}],["0xcc2cc5ff13676cf96bd31b2e40dc7fc06b1be2072646ac7e9f30147ae3606c1f",{"owner":442,"added_at":{"block":1127163,"time":1591296084000},"type_id":1,"size":277538135,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmR8GkpSW6BCw3idWrQdSeitcdQSt55XaTja2TzLeBezwp"}],["0xccd2906754b6e3dd4ead4987488aaf9d5f869ede35005176e88c28109064953a",{"owner":442,"added_at":{"block":1129364,"time":1591309464000},"type_id":1,"size":351058986,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQEhoPJ1RR2opA4h99FhMJWEvNVwn4aijZpBzyk3iTtLC"}],["0xcd48e94fe4caa413352e548452a921abf2bb8b72a8bf1e966bf16bcae2b3c6ee",{"owner":442,"added_at":{"block":1098883,"time":1591125834043},"type_id":1,"size":61507811,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmV4zNzSWQVJWjDriAFLeevwHQvyTpw1HGcqPbg4DNheBz"}],["0xcde4eefdbb74b50ec27cc0737a3ff40e5199eb3ce4a3df0250af6fc2b72a0fa4",{"owner":8,"added_at":{"block":940641,"time":1590173256000},"type_id":1,"size":80328,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmY8bC5GWvkhS7W5den8p2Lh2WpvVV4De7KzikYgHTK6nT"}],["0xd080a437811cb52706e66961d50552f930e4874579bf7d57967a37bbeba5db19",{"owner":336,"added_at":{"block":1135332,"time":1591345386000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xd1652d0a713a94886774f4ab17544806d2a4e6a5cdb0fc3ec15b2560f28af032",{"owner":442,"added_at":{"block":1129765,"time":1591311900000},"type_id":1,"size":308527570,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRsKoz7nNuoxMpHR5NqoTgzMyxgsnkiSsbuXcL7LdHV2h"}],["0xd3087b8fd18d5a4ec73ce24149216a5d1658e82f1ddeadd6b9525675bb34e340",{"owner":441,"added_at":{"block":1080090,"time":1591012986000},"type_id":1,"size":19727184,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVh9K2yDuvvgbC1g9Rh5pP4jJZTRWXjkaFw1vdPvLrdut"}],["0xd7ec06e442bba27dcfa2c834964f37126d470a3dd1b0374567a18af239474e50",{"owner":442,"added_at":{"block":1127347,"time":1591297194000},"type_id":1,"size":457868208,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVu6FrVaP8jLZiCG6VecKaUNuCB24FHdEj7MjSJABvey9"}],["0xd97b44423c45fe5396963b57ed44f6a91a839160bad3e554bf08ef19fb583127",{"owner":447,"added_at":{"block":1466620,"time":1593339330000},"type_id":1,"size":200420923,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmYS4JAwG45SvDEC5AM9Hzv1dfzPoXoBq1N9aTbT3bEs86"}],["0xdb8f0622b7fc638933b13a15260a09501d01ffc6a23624bd36317b0805d963b7",{"owner":350,"added_at":{"block":1041080,"time":1590778380000},"type_id":1,"size":99136786,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWLgJN8o8YK361jTxCCf96mbubgMCmMfNx5nEYDcF5hs3"}],["0xdffda551959482486ce30e7739e2eb3b8006b27faba8ed656fc643b2c5f26851",{"owner":449,"added_at":{"block":1683972,"time":1594646064000},"type_id":1,"size":1675105,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRwHXmuqS2rdfqnZdcUGbB3bM5UM6jkvdghgSr9coJ2A4"}],["0xe0be443d0d8967f35d02bb9dd7a4d01a3d31b57115ca31ba5174647a58e62d00",{"owner":447,"added_at":{"block":1466594,"time":1593339174000},"type_id":1,"size":125974946,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qma2ZYN1UkF9TRaJxqGuN5Ksg1Mg5rxbQAmQ46PDSipd3M"}],["0xe24cda3dc434513e9cad5888d8466f0ecad2924db10c9788fb56cbc811cb2ec5",{"owner":442,"added_at":{"block":1125805,"time":1591287930000},"type_id":1,"size":233980798,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPcFojVSw9E1UTwLCk53sG9cyM8wo2ZAHTt9bV3o5PcnT"}],["0xe44c4c26e4804a54d3fc3766ae6da16fe3f25ccaaa9a95d3c122fbc0af74dc2a",{"owner":447,"added_at":{"block":1466769,"time":1593340224000},"type_id":1,"size":59703371,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmNw2pRA32PGTxVeq7ktaM9ttUHkj5P3is3QLqamLCJ7Bk"}],["0xe6b072d81f0ca33716ddf332e9460ba177650a25dff7e3126e23a7278cffd335",{"owner":350,"added_at":{"block":1040949,"time":1590777594000},"type_id":1,"size":134414330,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmajAfBPnymCpDKPhywX7abeT9kMfFiYsDX9kAvJ3FRcpv"}],["0xe7547e765c44a27cf3ff6e367f5ae3db931927adea06736e95d33bb93fc19ec8",{"owner":442,"added_at":{"block":1128936,"time":1591306872000},"type_id":1,"size":483398954,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWAnhLsrVUAExgNDoNCREuXFUfnn9tJ4tqVm3cyKSuJjC"}],["0xe7ffa7b44f4641b0cc9ed9c0d6d9d42972d745df451bb635dd25d46ff2844172",{"owner":336,"added_at":{"block":421500,"time":1587043908000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xe8208ac9f0280e6db102b0d9f1e2d82fecbfe0ab99dcda32bf465cdd04ead0a4",{"owner":442,"added_at":{"block":1129630,"time":1591311090000},"type_id":1,"size":491998570,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmWPaYEBopBh2i4RYumohbTXdYYYMMtNTNPAdEhzejU5Ad"}],["0xe84290c050e44d103806bcfb37441adb7808c7044d80b01dd1c3402be643513d",{"owner":309,"added_at":{"block":9919,"time":1584517098000},"type_id":1,"size":337713518,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmPdYHJGDZ5ucEzC8hmmmjUvtzEdKPEnUe4biwpfjahMmJ"}],["0xecc2c164f4d78b61cda6c9f7e414aa2fb4a102356f0e46d14f4a625c5e7afdd5",{"owner":309,"added_at":{"block":41276,"time":1584708432000},"type_id":1,"size":428470328,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmXcaiCAejKga3CYoKqLPKaoxFYemdwCjme2n3PLUwZLvz"}],["0xef41f0a04d3a2d1f29e741fd40abba35ce6d095da54202e49cb77be0404d2bc1",{"owner":447,"added_at":{"block":1466867,"time":1593340812000},"type_id":1,"size":60474460,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmRdHAkcv1ijiooTEBfzstosGxpKNJP55Hrkj5ooBaLCy6"}],["0xf0c3624748e1b33f55c2b2c65055af4ecb6458a072690bd3fedf0fc3c9dda1fb",{"owner":442,"added_at":{"block":1129493,"time":1591310268000},"type_id":1,"size":466951798,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"Qmc7wwKSPBB73MPPEPDnkvphp2uywBAPEoDTjSZN6hZWgP"}],["0xf2af183bfdd67f74e7c190fe330b436d45dc6f1f3af540ca3f5f008c2f9ba027",{"owner":442,"added_at":{"block":1081980,"time":1591024326000},"type_id":1,"size":77047118,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmQ8CMEaCgLtGTW9mfHDtScJev4EpX8fsaSjDohKvvHHZr"}],["0xf3f0a37a878828f8461d269fcf188a47ae97378d58822a1e249ee105c304deab",{"owner":442,"added_at":{"block":1127682,"time":1591299204001},"type_id":1,"size":457868208,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVu6FrVaP8jLZiCG6VecKaUNuCB24FHdEj7MjSJABvey9"}],["0xf9a250565c9d46659ea8be801f324dbeae0584fe80088a61fb2a1fdfb5e25586",{"owner":442,"added_at":{"block":1110733,"time":1591197168000},"type_id":1,"size":247006015,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVDt1MFxNS8r416RkeEadadzhfFomPby18wcgbCQ9RBxL"}],["0xfbe7ea222bdacdeb93082bfec4044f02debe9131488aca1440318b7d1f158b9c",{"owner":336,"added_at":{"block":1135064,"time":1591343772000},"type_id":1,"size":36260435,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmVcYit7yaLdxfaANZeawMSrH5teWBM6AhtFszZvuFC2ni"}],["0xfeef3d37a69ff35e4087736f06c9ee0c487ab4dd53e0c73fca12bb3cc1ed7f02",{"owner":442,"added_at":{"block":1126970,"time":1591294926000},"type_id":1,"size":440201919,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmadjBxxPasDupmedSKcxDJSYenuYMym6eqHRVdBpYcjbv"}],["0xff6e55a2e0b3332fae51ff7e32975a7d7ab5bce3f0bd1850ae00e08dac0fa751",{"owner":442,"added_at":{"block":1129846,"time":1591312386000},"type_id":1,"size":46196651,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmdCvapqKfoVAjNvpsnzecBug9y9LBikgyDYbUsKktuaRs"}],["0xffcb7d08e62559cb6624c2cd82cdccba811423d2b43522cef254a2312571fa77",{"owner":442,"added_at":{"block":1110975,"time":1591198638000},"type_id":1,"size":171629454,"liaison":0,"liaison_judgement":1,"ipfs_content_id":"QmP5U82G3zBS7Z2nY3M877knEHjMBqZw5v6Y2z6vpihFaG"}]] ` const parsed = JSON.parse(exported) diff --git a/utils/api-examples/scripts/list-data-directory.js b/utils/api-examples/scripts/list-data-directory.js index 631ab8fc32..336acc10d6 100644 --- a/utils/api-examples/scripts/list-data-directory.js +++ b/utils/api-examples/scripts/list-data-directory.js @@ -1,4 +1,4 @@ -/* global api, hashing, keyring, types, util */ +/* global api, hashing, keyring, types, util, joy */ // run this script with: // yarn script listDataDirectory diff --git a/utils/api-examples/scripts/transfer.js b/utils/api-examples/scripts/transfer.js index d709ed2d97..7dc2cf7422 100644 --- a/utils/api-examples/scripts/transfer.js +++ b/utils/api-examples/scripts/transfer.js @@ -1,12 +1,11 @@ /* global api, hashing, keyring, types, util, window */ // run this script with: -// yarn script injectDataObjects +// yarn script testTransfer // // or copy and paste the code into the pioneer javascript toolbox at: // https://testnet.joystream.org/#/js // -// requires nicaea release+ const script = async ({ api, keyring }) => { const sudoAddress = (await api.query.sudo.key()).toString() diff --git a/utils/api-examples/src/get-code.ts b/utils/api-examples/src/get-code.ts index c24fd4dcfe..6e5a398bba 100644 --- a/utils/api-examples/src/get-code.ts +++ b/utils/api-examples/src/get-code.ts @@ -6,12 +6,11 @@ async function main() { const api = await ApiPromise.create({ provider, types }) - let current_block_hash = await api.rpc.chain.getBlockHash() + const currentBlockHash = await api.rpc.chain.getBlockHash(1) - console.log('getting code as of block hash', current_block_hash.toString()) + console.log('getting code as of block hash', currentBlockHash.toString()) - const substrateWasm = await api.query.substrate.code.at(current_block_hash.toString()) - // const substrateWasm = await api.rpc.state.getStorage('0x'+Buffer.from(':code').toString('hex'), current_block_hash); + const substrateWasm = await api.query.substrate.code.at(currentBlockHash) console.log(substrateWasm.toHex()) diff --git a/utils/api-examples/src/script.ts b/utils/api-examples/src/script.ts index 4f6db5177e..0918bf6a05 100644 --- a/utils/api-examples/src/script.ts +++ b/utils/api-examples/src/script.ts @@ -7,6 +7,7 @@ import joy, { types as joyTypes } from '@joystream/types' import * as hashing from '@polkadot/util-crypto' import { Keyring } from '@polkadot/keyring' +// eslint-disable-next-line @typescript-eslint/no-var-requires const scripts = require('../scripts') async function main() { diff --git a/utils/api-examples/src/status.ts b/utils/api-examples/src/status.ts index 8514582847..e06a077bbd 100644 --- a/utils/api-examples/src/status.ts +++ b/utils/api-examples/src/status.ts @@ -3,12 +3,9 @@ import { ApiPromise, WsProvider } from '@polkadot/api' import { types } from '@joystream/types' import { Seat } from '@joystream/types/council' -// import { SubscriptionResult, QueryableStorageFunction } from '@polkadot/api/promise/types'; -// import { GenericAccountId } from '@polkadot/types'; import { ValidatorId } from '@polkadot/types/interfaces' -// import BN from 'bn.js'; -const BN = require('bn.js') +import BN from 'bn.js' async function main() { // Initialise the provider to connect to the local node @@ -26,9 +23,9 @@ async function main() { console.log(`Chain ${chain} using ${nodeName} v${nodeVersion}`) - let council = ((await api.query.council.activeCouncil()) as unknown) as Seat[] - let validators = ((await api.query.session.validators()) as unknown) as ValidatorId[] - let version = (await api.rpc.state.getRuntimeVersion()) as any + const council = ((await api.query.council.activeCouncil()) as unknown) as Seat[] + const validators = ((await api.query.session.validators()) as unknown) as ValidatorId[] + const version = (await api.rpc.state.getRuntimeVersion()) as any console.log(`Runtime Version: ${version.authoringVersion}.${version.specVersion}.${version.implVersion}`) @@ -46,7 +43,7 @@ async function main() { validators.map((authorityId) => api.query.balances.account(authorityId)) ) - let totalValidatorBalances = validatorBalances.reduce((total, value) => total.add(value.free), new BN(0)) + const totalValidatorBalances = validatorBalances.reduce((total, value) => total.add(value.free), new BN(0)) // TODO: to get the staked amounts we need to read the account lock information. diff --git a/utils/api-examples/src/tohex.ts b/utils/api-examples/src/tohex.ts index 1e6273a392..752b731e15 100644 --- a/utils/api-examples/src/tohex.ts +++ b/utils/api-examples/src/tohex.ts @@ -7,9 +7,10 @@ async function main() { const provider = new WsProvider('ws://127.0.0.1:9944') const api = await ApiPromise.create({ provider, types }) - let wgId = [1, 2] + const wgId = [1, 2] - let set = new BTreeSet(api.registry, CuratorApplicationId, []) + // Is it not possible to create the registry without actually connecting to a node? + const set = new BTreeSet(api.registry, CuratorApplicationId, []) wgId.forEach((id) => { set.add(new CuratorApplicationId(api.registry, id)) From 67f3baf4614c685247fb63a3419b24457c7eafe2 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Mon, 17 Aug 2020 11:19:47 +0300 Subject: [PATCH 10/12] api-examples: fix export data directory script for new runtime --- utils/api-examples/scripts/export-data-directory.js | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/utils/api-examples/scripts/export-data-directory.js b/utils/api-examples/scripts/export-data-directory.js index 3a27581ae4..f65ab74d6f 100644 --- a/utils/api-examples/scripts/export-data-directory.js +++ b/utils/api-examples/scripts/export-data-directory.js @@ -6,14 +6,7 @@ // or copy and paste the code into the pioneer javascript toolbox at: // https://testnet.joystream.org/#/js -const script = async ({ api, hashing, keyring, types, util }) => { - const runtimeSpecVersion = api.runtimeVersion.specVersion - - const ownerAccountToMemberId = async (accountId) => { - const memberIds = await api.query.members.memberIdsByRootAccountId(accountId) - return memberIds[0] || null - } - +const script = async ({ api }) => { const ids = await api.query.dataDirectory.knownContentIds() // When a BTreeMap is constructed for injection the node will fail to decode @@ -31,11 +24,11 @@ const script = async ({ api, hashing, keyring, types, util }) => { return [ id, { - owner: runtimeSpecVersion <= 15 ? await ownerAccountToMemberId(obj.owner) : obj.owner, + owner: obj.owner, added_at: obj.added_at, type_id: obj.type_id, size: obj.size_in_bytes, - liaison: runtimeSpecVersion <= 15 ? api.createType('u64', 0) : obj.liaison, + liaison: obj.liaison, liaison_judgement: obj.liaison_judgement, ipfs_content_id: obj.ipfs_content_id, }, From 0e3362bf730a8cab2f1bcef2448d28d1cccd4b81 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Wed, 19 Aug 2020 12:24:27 +0300 Subject: [PATCH 11/12] api-examples: manually construct type registry when not requiring api --- utils/api-examples/src/tohex.ts | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/utils/api-examples/src/tohex.ts b/utils/api-examples/src/tohex.ts index 752b731e15..f10a36e2f4 100644 --- a/utils/api-examples/src/tohex.ts +++ b/utils/api-examples/src/tohex.ts @@ -1,19 +1,17 @@ -import { ApiPromise, WsProvider } from '@polkadot/api' import { CuratorApplicationId } from '@joystream/types/content-working-group' -import { BTreeSet } from '@polkadot/types' +import { BTreeSet, createType, TypeRegistry } from '@polkadot/types' import { types } from '@joystream/types' async function main() { - const provider = new WsProvider('ws://127.0.0.1:9944') - const api = await ApiPromise.create({ provider, types }) - const wgId = [1, 2] - // Is it not possible to create the registry without actually connecting to a node? - const set = new BTreeSet(api.registry, CuratorApplicationId, []) + const registry = new TypeRegistry() + registry.register(types) + + const set = new BTreeSet(registry, CuratorApplicationId, []) wgId.forEach((id) => { - set.add(new CuratorApplicationId(api.registry, id)) + set.add(createType(registry, 'CuratorApplicationId', id)) }) /* @@ -27,8 +25,6 @@ async function main() { console.log('copy/paste the output below to hire curator applicant(s) with WG IDs:', wgId) console.log(set.toHex()) - - api.disconnect() } main() From 0c3770d82ab211c2ffab6613beb7964780541ac3 Mon Sep 17 00:00:00 2001 From: Mokhtar Naamani Date: Wed, 19 Aug 2020 12:25:27 +0300 Subject: [PATCH 12/12] api-examples: use createType --- utils/api-examples/scripts/list-data-directory.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/api-examples/scripts/list-data-directory.js b/utils/api-examples/scripts/list-data-directory.js index 336acc10d6..ed32e28e9a 100644 --- a/utils/api-examples/scripts/list-data-directory.js +++ b/utils/api-examples/scripts/list-data-directory.js @@ -17,7 +17,7 @@ const script = async ({ api, joy }) => { return } obj = obj.unwrap() - console.log(`contentId: ${new joy.media.ContentId(id).encode()}, ipfs: ${obj.ipfs_content_id}`) + console.log(`contentId: ${api.createType('ContentId', id).encode()}, ipfs: ${obj.ipfs_content_id}`) }) )