From 1871ff961bf2d23b77d510d8ac2fbff5ff4155d3 Mon Sep 17 00:00:00 2001 From: Damjan Dimitrov Date: Mon, 22 Apr 2024 13:54:33 +0200 Subject: [PATCH 1/6] New methods on storage module --- .../sdk/src/modules/storage/storage-bucket.ts | 16 ++--- packages/sdk/src/modules/storage/storage.ts | 43 ++++++++++++- packages/sdk/src/tests/nft.test.ts | 16 ++--- packages/sdk/src/tests/storage.test.ts | 64 ++++++++++++++----- packages/sdk/src/types/storage.ts | 39 +++++++++++ 5 files changed, 142 insertions(+), 36 deletions(-) diff --git a/packages/sdk/src/modules/storage/storage-bucket.ts b/packages/sdk/src/modules/storage/storage-bucket.ts index aaeb176..b68ecab 100644 --- a/packages/sdk/src/modules/storage/storage-bucket.ts +++ b/packages/sdk/src/modules/storage/storage-bucket.ts @@ -101,10 +101,7 @@ export class StorageBucket extends ApillonModel { * @returns List of files in the bucket */ async listFiles(params?: IBucketFilesRequest): Promise> { - const url = constructUrlWithQueryParams( - `/storage/buckets/${this.uuid}/files`, - params, - ); + const url = constructUrlWithQueryParams(`${this.API_PREFIX}/files`, params); const data = await ApillonApi.get< IApillonList >(url); @@ -227,10 +224,7 @@ export class StorageBucket extends ApillonModel { * @returns List of IPNS names in the bucket */ async listIpnsNames(params?: IPNSListRequest) { - const url = constructUrlWithQueryParams( - `/storage/buckets/${this.uuid}/ipns`, - params, - ); + const url = constructUrlWithQueryParams(`${this.API_PREFIX}/ipns`, params); const data = await ApillonApi.get< IApillonList >(url); @@ -247,8 +241,10 @@ export class StorageBucket extends ApillonModel { * @returns New IPNS instance */ async createIpns(body: ICreateIpns): Promise { - const url = `/storage/buckets/${this.uuid}/ipns`; - const data = await ApillonApi.post(url, body); + const data = await ApillonApi.post( + `${this.API_PREFIX}/ipns`, + body, + ); return new Ipns(this.uuid, data.ipnsUuid, data); } //#endregion diff --git a/packages/sdk/src/modules/storage/storage.ts b/packages/sdk/src/modules/storage/storage.ts index 73d0bd2..6bcda0c 100644 --- a/packages/sdk/src/modules/storage/storage.ts +++ b/packages/sdk/src/modules/storage/storage.ts @@ -1,3 +1,4 @@ +import { IpfsClusterInfo, StorageInfo } from '../../docs-index'; import { ApillonModule } from '../../lib/apillon'; import { ApillonApi } from '../../lib/apillon-api'; import { constructUrlWithQueryParams } from '../../lib/common'; @@ -8,7 +9,7 @@ export class Storage extends ApillonModule { /** * API url for storage. */ - private API_PREFIX = '/storage/buckets'; + private API_PREFIX = '/storage'; /** * Lists all buckets. @@ -18,7 +19,10 @@ export class Storage extends ApillonModule { public async listBuckets( params?: IApillonPagination, ): Promise> { - const url = constructUrlWithQueryParams(this.API_PREFIX, params); + const url = constructUrlWithQueryParams( + `${this.API_PREFIX}/buckets`, + params, + ); const data = await ApillonApi.get< IApillonList @@ -39,4 +43,39 @@ export class Storage extends ApillonModule { public bucket(uuid: string): StorageBucket { return new StorageBucket(uuid); } + + /** + * Gets overall storage info for a project - available and used storage and bandwidth + * @returns {Promise} + */ + public async getInfo(): Promise { + return await ApillonApi.get(`${this.API_PREFIX}/info`); + } + + /** + * Gets basic data of an IPFS cluster used by the project. + * + * IPFS clusters contain multiple IPFS nodes but expose a single gateway for accessing content via CID or IPNS. + * + * Apillon clusters (gateways) are not publicly accessible + * @note Each project has its own secret for generating tokens to access content on the IPFS gateway. + * @returns {Promise} + */ + public async getIpfsClusterInfo(): Promise { + return await ApillonApi.get( + `${this.API_PREFIX}/ipfs-cluster-info`, + ); + } + + /** + * Apillon IPFS gateways are private and can only be accessible with a token. + * @docs [Generate an IPFS link](https://wiki.apillon.io/build/2-storage-api.html#get-or-generate-link-for-ipfs) + * @param {string} cid The CID or IPNS address of the fie + * @returns {Promise<{ link: string }>} Link where the requested content can be accessed. + */ + public async generateIpfsLink(cid: string): Promise<{ link: string }> { + return await ApillonApi.get<{ link: string }>( + `${this.API_PREFIX}/link-on-ipfs/${cid}`, + ); + } } diff --git a/packages/sdk/src/tests/nft.test.ts b/packages/sdk/src/tests/nft.test.ts index 5b04d60..1aa6ec3 100644 --- a/packages/sdk/src/tests/nft.test.ts +++ b/packages/sdk/src/tests/nft.test.ts @@ -26,17 +26,11 @@ describe('Nft tests', () => { receivingAddress = getMintAddress(); }); - test('list nft collections', async () => { - const { items: collections } = await nft.listCollections(); - expect(collections.length).toBeGreaterThan(0); - expect(collections[0]).toBeInstanceOf(NftCollection); - }); - test('creates a new collection', async () => { const collection = await nft.create({ ...nftData, chain: EvmChain.MOONBASE, - isRevokable: true, + isRevokable: false, isSoulbound: true, }); expect(collection.uuid).toBeDefined(); @@ -45,12 +39,18 @@ describe('Nft tests', () => { expect(collection.name).toEqual('SDK Test'); expect(collection.description).toEqual('Created from SDK tests'); expect(collection.isAutoIncrement).toEqual(true); - expect(collection.isRevokable).toEqual(true); + expect(collection.isRevokable).toEqual(false); expect(collection.isSoulbound).toEqual(true); collectionUuid = collection.uuid; }); + test('list nft collections', async () => { + const { items: collections } = await nft.listCollections(); + expect(collections.length).toBeGreaterThan(0); + expect(collections[0]).toBeInstanceOf(NftCollection); + }); + test('creates a new substrate collection', async () => { const collection = await nft.createSubstrate({ ...nftData, diff --git a/packages/sdk/src/tests/storage.test.ts b/packages/sdk/src/tests/storage.test.ts index 86dd9fc..c9d1abc 100644 --- a/packages/sdk/src/tests/storage.test.ts +++ b/packages/sdk/src/tests/storage.test.ts @@ -15,6 +15,7 @@ describe('Storage tests', () => { // For get and delete tests let directoryUuid: string; let fileUuid: string; + let cid: string; beforeAll(async () => { storage = new Storage(getConfig()); @@ -78,11 +79,6 @@ describe('Storage tests', () => { items.forEach((item) => expect(item.name).toBeTruthy()); }); - test('get file details', async () => { - const file = await storage.bucket(bucketUuid).file(fileUuid).get(); - expect(file.name).toBeTruthy(); - }); - test('upload files from folder', async () => { const uploadDir = resolve(__dirname, './helpers/website/'); @@ -104,18 +100,19 @@ describe('Storage tests', () => { expect(files.length).toBeGreaterThan(0); expect(files.every((f) => !!f.CID)).toBeTruthy(); + cid = files[0].CID; }); test('upload files from folder with ignoreFiles = false', async () => { const uploadDir = resolve(__dirname, './helpers/website/'); - console.time('File upload complete'); - const files = await storage - .bucket(bucketUuid) - .uploadFromFolder(uploadDir, { ignoreFiles: false }); - expect(files.length).toEqual(3); // .gitignore and index.html are not ignored - - console.timeEnd('File upload complete'); + // .gitignore and index.html are not ignored + // and HTML files are not allowed + await expect( + storage + .bucket(bucketUuid) + .uploadFromFolder(uploadDir, { ignoreFiles: false }), + ).rejects.toThrow(); }); test('upload files from buffer', async () => { @@ -140,11 +137,46 @@ describe('Storage tests', () => { console.timeEnd('File upload complete'); }); - test.skip('delete a file', async () => { - await storage.bucket(bucketUuid).file(fileUuid).delete(); + describe.skip('File detail tests', () => { + test('get file details', async () => { + const file = await storage.bucket(bucketUuid).file(fileUuid).get(); + expect(file.name).toBeTruthy(); + }); + + test('delete a file', async () => { + await storage.bucket(bucketUuid).file(fileUuid).delete(); + }); + + test('delete a directory', async () => { + await storage.bucket(bucketUuid).directory(directoryUuid).delete(); + }); }); - test.skip('delete a directory', async () => { - await storage.bucket(bucketUuid).directory(directoryUuid).delete(); + describe('Storage info tests', () => { + test('Get storage info', async () => { + const info = await storage.getInfo(); + expect(info).toBeDefined(); + expect(info.availableStorage).toBeGreaterThan(0); + expect(info.usedStorage).toBeGreaterThanOrEqual(0); + expect(info.usedStorage).toBeLessThan(info.availableStorage); + expect(info.availableBandwidth).toBeGreaterThan(0); + expect(info.usedBandwidth).toBeGreaterThanOrEqual(0); + expect(info.usedBandwidth).toBeLessThan(info.availableBandwidth); + }); + + test('Get IPFS cluster info', async () => { + const ipfsClusterInfo = await storage.getIpfsClusterInfo(); + expect(ipfsClusterInfo).toBeDefined(); + expect(ipfsClusterInfo.secret).toBeDefined(); + expect(ipfsClusterInfo.projectUuid).toBeDefined(); + expect(ipfsClusterInfo.ipfsGateway).toBeDefined(); + expect(ipfsClusterInfo.ipnsGateway).toBeDefined(); + }); + + test('Generate IPFS link', async () => { + const { link } = await storage.generateIpfsLink(cid); + expect(link).toBeDefined(); + expect(link).toContain(cid); + }); }); }); diff --git a/packages/sdk/src/types/storage.ts b/packages/sdk/src/types/storage.ts index 08f4a21..d2552ed 100644 --- a/packages/sdk/src/types/storage.ts +++ b/packages/sdk/src/types/storage.ts @@ -116,3 +116,42 @@ export interface ICreateIpns { */ cid?: string; } + +export interface StorageInfo { + /** + * Available storage space in bytes + */ + availableStorage: number; + /** + * Used storage in bytes. When `usedStorage` reaches available storage, upload to buckets will be blocked (error 40006003) + */ + usedStorage: number; + /** + * Monthly available bandwidth (upload and download) + */ + availableBandwidth: number; + /** + * Bandwidth used in current month. If `usedBandwidth` reaches available bandwidth, requests to the IPFS gateway will be blocked + */ + usedBandwidth: number; +} + +export interface IpfsClusterInfo { + /** + * Secret for this project, which can be used to generate tokens to access content of IPFS gateway + * @docs [Generate an IPFS link](https://wiki.apillon.io/build/2-storage-api.html#get-or-generate-link-for-ipfs) + */ + secret: string; + /** + * Project unique identifier + */ + projectUuid: string; + /** + * Gateway that can used to access content via CIDs. + */ + ipfsGateway: string; + /** + * Gateway that can be used to access content via IPNS name. + */ + ipnsGateway: string; +} From 50543ee247a05a1b0d491af4df7de6799a7c56d7 Mon Sep 17 00:00:00 2001 From: Damjan Dimitrov Date: Tue, 23 Apr 2024 15:02:52 +0200 Subject: [PATCH 2/6] Add project module --- packages/sdk/src/docs-index.ts | 1 + packages/sdk/src/index.ts | 1 + packages/sdk/src/modules/project/project.ts | 20 ++++++++++++++++++++ packages/sdk/src/tests/project.test.ts | 17 +++++++++++++++++ 4 files changed, 39 insertions(+) create mode 100644 packages/sdk/src/modules/project/project.ts create mode 100644 packages/sdk/src/tests/project.test.ts diff --git a/packages/sdk/src/docs-index.ts b/packages/sdk/src/docs-index.ts index 9b761f0..89e2c65 100644 --- a/packages/sdk/src/docs-index.ts +++ b/packages/sdk/src/docs-index.ts @@ -22,3 +22,4 @@ export * from './modules/computing/computing-contract'; export * from './modules/social/social'; export * from './modules/social/social-hub'; export * from './modules/social/social-channel'; +export * from './modules/project/project'; diff --git a/packages/sdk/src/index.ts b/packages/sdk/src/index.ts index a0e8c95..d1dc0bd 100644 --- a/packages/sdk/src/index.ts +++ b/packages/sdk/src/index.ts @@ -12,3 +12,4 @@ export * from './modules/nft/nft'; export * from './modules/identity/identity'; export * from './modules/computing/computing'; export * from './modules/social/social'; +export * from './modules/project/project'; diff --git a/packages/sdk/src/modules/project/project.ts b/packages/sdk/src/modules/project/project.ts new file mode 100644 index 0000000..847af1e --- /dev/null +++ b/packages/sdk/src/modules/project/project.ts @@ -0,0 +1,20 @@ +import { ApillonModule } from '../../lib/apillon'; +import { ApillonApi } from '../../lib/apillon-api'; + +export class Project extends ApillonModule { + /** + * Base API url for project. + */ + private API_PREFIX = '/project'; + + /** + * Get credit balance for your project + * @returns {Promise<{ balance: number }>} The credit balance of your project + */ + public async getCreditBalance(): Promise { + const { balance } = await ApillonApi.get<{ balance: number }>( + `${this.API_PREFIX}/credit`, + ); + return balance; + } +} diff --git a/packages/sdk/src/tests/project.test.ts b/packages/sdk/src/tests/project.test.ts new file mode 100644 index 0000000..c908c5d --- /dev/null +++ b/packages/sdk/src/tests/project.test.ts @@ -0,0 +1,17 @@ +import { getConfig } from './helpers/helper'; +import { Project } from '../modules/project/project'; + +describe('Project Module tests', () => { + let project: Project; + + beforeAll(async () => { + project = new Project(getConfig()); + }); + + describe('Project module tests', () => { + test('Get project credit balance', async () => { + const balance = await project.getCreditBalance(); + expect(balance).toBeGreaterThan(0); + }); + }); +}); From 466fc6fed121a278c952d7837d342ff30f280641 Mon Sep 17 00:00:00 2001 From: Damjan Dimitrov Date: Tue, 23 Apr 2024 15:07:23 +0200 Subject: [PATCH 3/6] Upgrade minor package versions --- package-lock.json | 646 ++++++++++++++++---------------------- package.json | 10 +- packages/cli/package.json | 4 +- packages/sdk/package.json | 12 +- 4 files changed, 283 insertions(+), 389 deletions(-) diff --git a/package-lock.json b/package-lock.json index 6cbc12a..c2e4b2a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,24 +1,24 @@ { "name": "apillon-web3-tools", - "version": "1.2.0", + "version": "3.0.0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "apillon-web3-tools", - "version": "1.2.0", + "version": "3.0.0", "license": "MIT", "workspaces": [ "packages/*" ], "devDependencies": { - "@types/jest": "^29.5.11", + "@types/jest": "^29.5.12", "eslint-config-common": "*", "jest": "29.7.0", "prettier": "latest", "rimraf": "^5.0.5", - "ts-jest": "29.1.1", - "turbo": "latest" + "ts-jest": "29.1.2", + "turbo": "^1.13.2" }, "engines": { "node": ">=16.17.0", @@ -26,9 +26,9 @@ } }, "node_modules/@adraffy/ens-normalize": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.0.tgz", - "integrity": "sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==", + "version": "1.10.1", + "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.1.tgz", + "integrity": "sha512-96Z2IP3mYmF1Xg2cDm8f1gWGf/HUVedQ3FMifV4kG/PQ4yEP51xDtRAEfhVNt5f/uzpNkZHwWQuUcu6D6K+Ekw==", "dev": true }, "node_modules/@ampproject/remapping": { @@ -53,89 +53,18 @@ "link": true }, "node_modules/@babel/code-frame": { - "version": "7.22.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz", - "integrity": "sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==", + "version": "7.24.2", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.2.tgz", + "integrity": "sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==", "dev": true, "dependencies": { - "@babel/highlight": "^7.22.13", - "chalk": "^2.4.2" + "@babel/highlight": "^7.24.2", + "picocolors": "^1.0.0" }, "engines": { "node": ">=6.9.0" } }, - "node_modules/@babel/code-frame/node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "dependencies": { - "color-convert": "^1.9.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/code-frame/node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/code-frame/node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dev": true, - "dependencies": { - "color-name": "1.1.3" - } - }, - "node_modules/@babel/code-frame/node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true - }, - "node_modules/@babel/code-frame/node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true, - "engines": { - "node": ">=0.8.0" - } - }, - "node_modules/@babel/code-frame/node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", - "dev": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/code-frame/node_modules/supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "dependencies": { - "has-flag": "^3.0.0" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/@babel/compat-data": { "version": "7.22.20", "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.22.20.tgz", @@ -185,14 +114,14 @@ } }, "node_modules/@babel/generator": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.0.tgz", - "integrity": "sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==", + "version": "7.24.4", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.24.4.tgz", + "integrity": "sha512-Xd6+v6SnjWVx/nus+y0l1sxMOTOMBkyL4+BIdbALyatQnAe/SRVjANeDPSCYaX+i1iJmuGSKf3Z+E+V/va1Hvw==", "dev": true, "dependencies": { - "@babel/types": "^7.23.0", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", + "@babel/types": "^7.24.0", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", "jsesc": "^2.5.1" }, "engines": { @@ -200,9 +129,9 @@ } }, "node_modules/@babel/generator/node_modules/@jridgewell/trace-mapping": { - "version": "0.3.19", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz", - "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==", + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", @@ -348,9 +277,9 @@ } }, "node_modules/@babel/helper-string-parser": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", - "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.1.tgz", + "integrity": "sha512-2ofRCjnnA9y+wk8b9IAREroeUP02KHp431N2mhKniy2yKIDKpbrHv9eXwm8cBeWQYcJmzv5qKCu65P47eCF7CQ==", "dev": true, "engines": { "node": ">=6.9.0" @@ -389,14 +318,15 @@ } }, "node_modules/@babel/highlight": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz", - "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==", + "version": "7.24.2", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.2.tgz", + "integrity": "sha512-Yac1ao4flkTxTteCDZLEvdxg2fZfz1v8M4QpaGypq/WPDqg3ijHYbDfs+LG5hvzSoqaSZ9/Z9lKSP3CjZjv+pA==", "dev": true, "dependencies": { "@babel/helper-validator-identifier": "^7.22.20", "chalk": "^2.4.2", - "js-tokens": "^4.0.0" + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" }, "engines": { "node": ">=6.9.0" @@ -474,9 +404,9 @@ } }, "node_modules/@babel/parser": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz", - "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==", + "version": "7.24.4", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.24.4.tgz", + "integrity": "sha512-zTvEBcghmeBma9QIGunWevvBAp4/Qu9Bdq+2k0Ot4fVMD6v3dsC9WOcRSKk7tRRyBM/53yKMJko9xOatGQAwSg==", "dev": true, "bin": { "parser": "bin/babel-parser.js" @@ -677,20 +607,20 @@ } }, "node_modules/@babel/traverse": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.0.tgz", - "integrity": "sha512-t/QaEvyIoIkwzpiZ7aoSKK8kObQYeF7T2v+dazAYCb8SXtp58zEVkWW7zAnju8FNKNdr4ScAOEDmMItbyOmEYw==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.24.1.tgz", + "integrity": "sha512-xuU6o9m68KeqZbQuDt2TcKSxUw/mrsvavlEqQ1leZ/B+C9tk6E4sRWy97WaXgvq5E+nU3cXMxv3WKOCanVMCmQ==", "dev": true, "dependencies": { - "@babel/code-frame": "^7.22.13", - "@babel/generator": "^7.23.0", + "@babel/code-frame": "^7.24.1", + "@babel/generator": "^7.24.1", "@babel/helper-environment-visitor": "^7.22.20", "@babel/helper-function-name": "^7.23.0", "@babel/helper-hoist-variables": "^7.22.5", "@babel/helper-split-export-declaration": "^7.22.6", - "@babel/parser": "^7.23.0", - "@babel/types": "^7.23.0", - "debug": "^4.1.0", + "@babel/parser": "^7.24.1", + "@babel/types": "^7.24.0", + "debug": "^4.3.1", "globals": "^11.1.0" }, "engines": { @@ -707,12 +637,12 @@ } }, "node_modules/@babel/types": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz", - "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==", + "version": "7.24.0", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.24.0.tgz", + "integrity": "sha512-+j7a5c253RfKh8iABBhywc8NSfP5LURe7Uh4qpsh6jc+aLJguvmIUBdjSdEMQv2bENrCR5MfRdjGo7vzS/ob7w==", "dev": true, "dependencies": { - "@babel/helper-string-parser": "^7.22.5", + "@babel/helper-string-parser": "^7.23.4", "@babel/helper-validator-identifier": "^7.22.20", "to-fast-properties": "^2.0.0" }, @@ -1363,19 +1293,29 @@ } }, "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz", - "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==", + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dev": true, "dependencies": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" }, "engines": { "node": ">=6.0.0" } }, + "node_modules/@jridgewell/gen-mapping/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, "node_modules/@jridgewell/resolve-uri": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", @@ -1386,9 +1326,9 @@ } }, "node_modules/@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true, "engines": { "node": ">=6.0.0" @@ -1950,9 +1890,9 @@ } }, "node_modules/@types/jest": { - "version": "29.5.11", - "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.11.tgz", - "integrity": "sha512-S2mHmYIVe13vrm6q4kN6fLYYAka15ALQki/vgDC3mIukEOx8WJlv0kQPM+d4w8Gp6u0uSdKND04IlTXBv0rwnQ==", + "version": "29.5.12", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.12.tgz", + "integrity": "sha512-eDC8bTvT/QhYdxJAulQikueigY5AsdBRH2yDKW3yveW7svY3+DzN84/2NUgkw10RTiJbWqZrTtoGVdYlvFJdLw==", "dev": true, "dependencies": { "expect": "^29.0.0", @@ -2339,11 +2279,11 @@ "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" }, "node_modules/axios": { - "version": "1.6.2", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.2.tgz", - "integrity": "sha512-7i24Ri4pmDRfJTR7LDBhsOTtcm+9kjX5WiY1X3wIisx6G9So3pfMkEiU7emUBe46oceVImccTEM3k6C5dbVW8A==", + "version": "1.6.8", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.8.tgz", + "integrity": "sha512-v/ZHtJDU39mDpyBoFVkETcd/uNdxrWRrg3bKpOKzXFA6Bvqopts6ALSMU3y6ijYxbw2B+wPrIv46egTzJXCLGQ==", "dependencies": { - "follow-redirects": "^1.15.0", + "follow-redirects": "^1.15.6", "form-data": "^4.0.0", "proxy-from-env": "^1.1.0" } @@ -3026,15 +2966,15 @@ } }, "node_modules/dotenv": { - "version": "16.3.1", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.3.1.tgz", - "integrity": "sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==", + "version": "16.4.5", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.5.tgz", + "integrity": "sha512-ZmdL2rui+eB2YwhsWzjInR8LldtZHGDoQ1ugH85ppHKwpUHL7j7rN0Ti9NCnGiQbhaZ11FpR+7ao1dNsmduNUg==", "dev": true, "engines": { "node": ">=12" }, "funding": { - "url": "https://github.com/motdotla/dotenv?sponsor=1" + "url": "https://dotenvx.com" } }, "node_modules/eastasianwidth": { @@ -3417,9 +3357,9 @@ } }, "node_modules/ethers": { - "version": "6.9.0", - "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.9.0.tgz", - "integrity": "sha512-pmfNyQzc2mseLe91FnT2vmNaTt8dDzhxZ/xItAV7uGsF4dI4ek2ufMu3rAkgQETL/TIs0GS5A+U05g9QyWnv3Q==", + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.12.0.tgz", + "integrity": "sha512-zL5NlOTjML239gIvtVJuaSk0N9GQLi1Hom3ZWUszE5lDTQE/IVB62mrPkQ2W1bGcZwVGSLaetQbWNQSvI4rGDQ==", "dev": true, "funding": [ { @@ -3432,7 +3372,7 @@ } ], "dependencies": { - "@adraffy/ens-normalize": "1.10.0", + "@adraffy/ens-normalize": "1.10.1", "@noble/curves": "1.2.0", "@noble/hashes": "1.3.2", "@types/node": "18.15.13", @@ -3684,9 +3624,9 @@ "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==" }, "node_modules/follow-redirects": { - "version": "1.15.2", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", - "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==", + "version": "1.15.6", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz", + "integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==", "funding": [ { "type": "individual", @@ -4899,9 +4839,9 @@ } }, "node_modules/jsonc-parser": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.2.0.tgz", - "integrity": "sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w==", + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.2.1.tgz", + "integrity": "sha512-AilxAyFOAcK5wA1+LeaySVBrHsGQvUFCDWXKpZjzaL0PqW+xfBOttn8GNtWKFWqneyMZj41MWF9Kl6iPWLwgOA==", "dev": true }, "node_modules/keccak": { @@ -5177,9 +5117,9 @@ "dev": true }, "node_modules/nodemon": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.0.2.tgz", - "integrity": "sha512-9qIN2LNTrEzpOPBaWHTm4Asy1LxXLSickZStAQ4IZe7zsoIpD/A7LWxhZV3t4Zu352uBcqVnRsDXSMR2Sc3lTA==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.1.0.tgz", + "integrity": "sha512-xqlktYlDMCepBJd43ZQhjWwMw2obW/JRvkrLxq5RCNcuDDX1DbcPT+qT1IlIIdf+DhnWs90JpTMe+Y5KxOchvA==", "dev": true, "dependencies": { "chokidar": "^3.5.2", @@ -5961,9 +5901,9 @@ } }, "node_modules/shiki": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/shiki/-/shiki-0.14.5.tgz", - "integrity": "sha512-1gCAYOcmCFONmErGTrS1fjzJLA7MGZmKzrBNX7apqSwhyITJg2O102uFzXUeBxNnEkDA9vHIKLyeKq0V083vIw==", + "version": "0.14.7", + "resolved": "https://registry.npmjs.org/shiki/-/shiki-0.14.7.tgz", + "integrity": "sha512-dNPAPrxSc87ua2sKJ3H5dQ/6ZaY8RNnaAqK+t0eG7p0Soi2ydiqbGOTaZCqaYvA/uZYfS1LJnemt3Q+mSfcPCg==", "dev": true, "dependencies": { "ansi-sequence-parser": "^1.1.0", @@ -6318,9 +6258,9 @@ } }, "node_modules/ts-jest": { - "version": "29.1.1", - "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.1.1.tgz", - "integrity": "sha512-D6xjnnbP17cC85nliwGiL+tpoKN0StpgE0TeOjXQTU6MVCfsB4v7aW05CgQ/1OywGb0x/oy9hHFnN+sczTiRaA==", + "version": "29.1.2", + "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.1.2.tgz", + "integrity": "sha512-br6GJoH/WUX4pu7FbZXuWGKGNDuU7b8Uj77g/Sp7puZV6EXzuByl6JrECvm0MzVzSTkSHWTihsXt+5XYER5b+g==", "dev": true, "dependencies": { "bs-logger": "0.x", @@ -6336,7 +6276,7 @@ "ts-jest": "cli.js" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^16.10.0 || ^18.0.0 || >=20.0.0" }, "peerDependencies": { "@babel/core": ">=7.0.0-beta.0 <8", @@ -6427,27 +6367,26 @@ } }, "node_modules/turbo": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo/-/turbo-1.8.3.tgz", - "integrity": "sha512-zGrkU1EuNFmkq6iky6LcMqD4h0OLE8XysVFxQWRIZbcTNnf0XAycbsbeEyiJpiWeqb7qtg2bVuY9EYcNoNhVuQ==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo/-/turbo-1.13.2.tgz", + "integrity": "sha512-rX/d9f4MgRT3yK6cERPAkfavIxbpBZowDQpgvkYwGMGDQ0Nvw1nc0NVjruE76GrzXQqoxR1UpnmEP54vBARFHQ==", "dev": true, - "hasInstallScript": true, "bin": { "turbo": "bin/turbo" }, "optionalDependencies": { - "turbo-darwin-64": "1.8.3", - "turbo-darwin-arm64": "1.8.3", - "turbo-linux-64": "1.8.3", - "turbo-linux-arm64": "1.8.3", - "turbo-windows-64": "1.8.3", - "turbo-windows-arm64": "1.8.3" + "turbo-darwin-64": "1.13.2", + "turbo-darwin-arm64": "1.13.2", + "turbo-linux-64": "1.13.2", + "turbo-linux-arm64": "1.13.2", + "turbo-windows-64": "1.13.2", + "turbo-windows-arm64": "1.13.2" } }, "node_modules/turbo-darwin-64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-darwin-64/-/turbo-darwin-64-1.8.3.tgz", - "integrity": "sha512-bLM084Wr17VAAY/EvCWj7+OwYHvI9s/NdsvlqGp8iT5HEYVimcornCHespgJS/yvZDfC+mX9EQkn3V2JmYgGGw==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-darwin-64/-/turbo-darwin-64-1.13.2.tgz", + "integrity": "sha512-CCSuD8CfmtncpohCuIgq7eAzUas0IwSbHfI8/Q3vKObTdXyN8vAo01gwqXjDGpzG9bTEVedD0GmLbD23dR0MLA==", "cpu": [ "x64" ], @@ -6458,9 +6397,9 @@ ] }, "node_modules/turbo-darwin-arm64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-darwin-arm64/-/turbo-darwin-arm64-1.8.3.tgz", - "integrity": "sha512-4oZjXtzakopMK110kue3z/hqu3WLv+eDLZOX1NGdo49gqca9BeD8GbH+sXpAp6tqyeuzpss+PIliVYuyt7LgbA==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-darwin-arm64/-/turbo-darwin-arm64-1.13.2.tgz", + "integrity": "sha512-0HySm06/D2N91rJJ89FbiI/AodmY8B3WDSFTVEpu2+8spUw7hOJ8okWOT0e5iGlyayUP9gr31eOeL3VFZkpfCw==", "cpu": [ "arm64" ], @@ -6471,9 +6410,9 @@ ] }, "node_modules/turbo-linux-64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-linux-64/-/turbo-linux-64-1.8.3.tgz", - "integrity": "sha512-uvX2VKotf5PU14FCxJA5iHItPQno2JWzerMd+g3/h/Asay6dvxvtVjc39MQeGT0H5njSvzVKFkT+3/5q8lgOEg==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-linux-64/-/turbo-linux-64-1.13.2.tgz", + "integrity": "sha512-7HnibgbqZrjn4lcfIouzlPu8ZHSBtURG4c7Bedu7WJUDeZo+RE1crlrQm8wuwO54S0siYqUqo7GNHxu4IXbioQ==", "cpu": [ "x64" ], @@ -6484,9 +6423,9 @@ ] }, "node_modules/turbo-linux-arm64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-linux-arm64/-/turbo-linux-arm64-1.8.3.tgz", - "integrity": "sha512-E1p+oH3XKMaPS4rqWhYsL4j2Pzc0d/9P5KU7Kn1kqVLo2T3iRA7n2KVULEieUNE0nTH+aIJPXYXOpqCI5wFJaA==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-linux-arm64/-/turbo-linux-arm64-1.13.2.tgz", + "integrity": "sha512-sUq4dbpk6SNKg/Hkwn256Vj2AEYSQdG96repio894h5/LEfauIK2QYiC/xxAeW3WBMc6BngmvNyURIg7ltrePg==", "cpu": [ "arm64" ], @@ -6497,9 +6436,9 @@ ] }, "node_modules/turbo-windows-64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-windows-64/-/turbo-windows-64-1.8.3.tgz", - "integrity": "sha512-cnzAytHtoLXd0J7aNzRpZFpL/GTjcBmkvAPlbOdf/Pl1iwS4qzGrudZQ+OM1lmLgLIfBPIavsGHBknTwTNib4A==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-windows-64/-/turbo-windows-64-1.13.2.tgz", + "integrity": "sha512-DqzhcrciWq3dpzllJR2VVIyOhSlXYCo4mNEWl98DJ3FZ08PEzcI3ceudlH6F0t/nIcfSItK1bDP39cs7YoZHEA==", "cpu": [ "x64" ], @@ -6510,9 +6449,9 @@ ] }, "node_modules/turbo-windows-arm64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-windows-arm64/-/turbo-windows-arm64-1.8.3.tgz", - "integrity": "sha512-ulIiItNm2w/zYJdD5/oAzjzNns1IjbpweRzpsE8tLXaWwo6+fnXXkyloUug0IUhcd2k6fJXfoiDZfygqpOVuXg==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-windows-arm64/-/turbo-windows-arm64-1.13.2.tgz", + "integrity": "sha512-WnPMrwfCXxK69CdDfS1/j2DlzcKxSmycgDAqV0XCYpK/812KB0KlvsVAt5PjEbZGXkY88pCJ1BLZHAjF5FcbqA==", "cpu": [ "arm64" ], @@ -6554,15 +6493,15 @@ } }, "node_modules/typedoc": { - "version": "0.25.4", - "resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.25.4.tgz", - "integrity": "sha512-Du9ImmpBCw54bX275yJrxPVnjdIyJO/84co0/L9mwe0R3G4FSR6rQ09AlXVRvZEGMUg09+z/usc8mgygQ1aidA==", + "version": "0.25.13", + "resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.25.13.tgz", + "integrity": "sha512-pQqiwiJ+Z4pigfOnnysObszLiU3mVLWAExSPf+Mu06G/qsc3wzbuM56SZQvONhHLncLUhYzOVkjFFpFfL5AzhQ==", "dev": true, "dependencies": { "lunr": "^2.3.9", "marked": "^4.3.0", "minimatch": "^9.0.3", - "shiki": "^0.14.1" + "shiki": "^0.14.7" }, "bin": { "typedoc": "bin/typedoc" @@ -6571,7 +6510,7 @@ "node": ">= 16" }, "peerDependencies": { - "typescript": "4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x" + "typescript": "4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x || 5.4.x" } }, "node_modules/typescript": { @@ -6707,9 +6646,9 @@ } }, "node_modules/word-wrap": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", - "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==", + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", + "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", "engines": { "node": ">=0.10.0" } @@ -6936,11 +6875,11 @@ }, "packages/cli": { "name": "@apillon/cli", - "version": "1.2.0", + "version": "1.3.0", "license": "MIT", "dependencies": { "@apillon/sdk": "*", - "axios": "^1.6.2", + "axios": "^1.6.8", "chalk": "^4.1.2", "commander": "^11.1.0" }, @@ -6950,7 +6889,7 @@ }, "devDependencies": { "eslint-config-common": "*", - "nodemon": "^3.0.2", + "nodemon": "^3.1.0", "rimraf": "^5.0.5", "ts-node": "^10.9.2", "tsconfig": "*" @@ -6975,24 +6914,24 @@ }, "packages/sdk": { "name": "@apillon/sdk", - "version": "1.2.0", + "version": "3.0.0", "license": "MIT", "dependencies": { "@polkadot/util-crypto": "^12.6.2", - "axios": "^1.6.2", + "axios": "^1.6.8", "ethereumjs-util": "^7.1.5" }, "devDependencies": { "@polkadot/keyring": "^12.6.2", - "@types/jest": "^29.5.11", - "dotenv": "^16.3.1", + "@types/jest": "^29.5.12", + "dotenv": "^16.4.5", "eslint-config-common": "*", - "ethers": "^6.9.0", - "nodemon": "^3.0.2", + "ethers": "^6.12.0", + "nodemon": "^3.1.0", "rimraf": "^5.0.5", "ts-node": "^10.9.2", "tsconfig": "*", - "typedoc": "^0.25.4" + "typedoc": "^0.25.13" } }, "packages/tsconfig": { @@ -7001,9 +6940,9 @@ }, "dependencies": { "@adraffy/ens-normalize": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.0.tgz", - "integrity": "sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==", + "version": "1.10.1", + "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.1.tgz", + "integrity": "sha512-96Z2IP3mYmF1Xg2cDm8f1gWGf/HUVedQ3FMifV4kG/PQ4yEP51xDtRAEfhVNt5f/uzpNkZHwWQuUcu6D6K+Ekw==", "dev": true }, "@ampproject/remapping": { @@ -7020,11 +6959,11 @@ "version": "file:packages/cli", "requires": { "@apillon/sdk": "*", - "axios": "^1.6.2", + "axios": "^1.6.8", "chalk": "^4.1.2", "commander": "^11.1.0", "eslint-config-common": "*", - "nodemon": "^3.0.2", + "nodemon": "^3.1.0", "rimraf": "^5.0.5", "ts-node": "^10.9.2", "tsconfig": "*" @@ -7035,85 +6974,27 @@ "requires": { "@polkadot/keyring": "^12.6.2", "@polkadot/util-crypto": "^12.6.2", - "@types/jest": "^29.5.11", - "axios": "^1.6.2", - "dotenv": "^16.3.1", + "@types/jest": "^29.5.12", + "axios": "^1.6.8", + "dotenv": "^16.4.5", "eslint-config-common": "*", "ethereumjs-util": "^7.1.5", - "ethers": "^6.9.0", - "nodemon": "^3.0.2", + "ethers": "^6.12.0", + "nodemon": "^3.1.0", "rimraf": "^5.0.5", "ts-node": "^10.9.2", "tsconfig": "*", - "typedoc": "^0.25.4" + "typedoc": "^0.25.13" } }, "@babel/code-frame": { - "version": "7.22.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz", - "integrity": "sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==", + "version": "7.24.2", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.2.tgz", + "integrity": "sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==", "dev": true, "requires": { - "@babel/highlight": "^7.22.13", - "chalk": "^2.4.2" - }, - "dependencies": { - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dev": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true - }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true - }, - "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", - "dev": true - }, - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } + "@babel/highlight": "^7.24.2", + "picocolors": "^1.0.0" } }, "@babel/compat-data": { @@ -7154,21 +7035,21 @@ } }, "@babel/generator": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.0.tgz", - "integrity": "sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==", + "version": "7.24.4", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.24.4.tgz", + "integrity": "sha512-Xd6+v6SnjWVx/nus+y0l1sxMOTOMBkyL4+BIdbALyatQnAe/SRVjANeDPSCYaX+i1iJmuGSKf3Z+E+V/va1Hvw==", "dev": true, "requires": { - "@babel/types": "^7.23.0", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", + "@babel/types": "^7.24.0", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", "jsesc": "^2.5.1" }, "dependencies": { "@jridgewell/trace-mapping": { - "version": "0.3.19", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz", - "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==", + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, "requires": { "@jridgewell/resolve-uri": "^3.1.0", @@ -7285,9 +7166,9 @@ } }, "@babel/helper-string-parser": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", - "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.1.tgz", + "integrity": "sha512-2ofRCjnnA9y+wk8b9IAREroeUP02KHp431N2mhKniy2yKIDKpbrHv9eXwm8cBeWQYcJmzv5qKCu65P47eCF7CQ==", "dev": true }, "@babel/helper-validator-identifier": { @@ -7314,14 +7195,15 @@ } }, "@babel/highlight": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz", - "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==", + "version": "7.24.2", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.2.tgz", + "integrity": "sha512-Yac1ao4flkTxTteCDZLEvdxg2fZfz1v8M4QpaGypq/WPDqg3ijHYbDfs+LG5hvzSoqaSZ9/Z9lKSP3CjZjv+pA==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.22.20", "chalk": "^2.4.2", - "js-tokens": "^4.0.0" + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" }, "dependencies": { "ansi-styles": { @@ -7383,9 +7265,9 @@ } }, "@babel/parser": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz", - "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==", + "version": "7.24.4", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.24.4.tgz", + "integrity": "sha512-zTvEBcghmeBma9QIGunWevvBAp4/Qu9Bdq+2k0Ot4fVMD6v3dsC9WOcRSKk7tRRyBM/53yKMJko9xOatGQAwSg==", "dev": true }, "@babel/plugin-syntax-async-generators": { @@ -7526,20 +7408,20 @@ } }, "@babel/traverse": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.0.tgz", - "integrity": "sha512-t/QaEvyIoIkwzpiZ7aoSKK8kObQYeF7T2v+dazAYCb8SXtp58zEVkWW7zAnju8FNKNdr4ScAOEDmMItbyOmEYw==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.24.1.tgz", + "integrity": "sha512-xuU6o9m68KeqZbQuDt2TcKSxUw/mrsvavlEqQ1leZ/B+C9tk6E4sRWy97WaXgvq5E+nU3cXMxv3WKOCanVMCmQ==", "dev": true, "requires": { - "@babel/code-frame": "^7.22.13", - "@babel/generator": "^7.23.0", + "@babel/code-frame": "^7.24.1", + "@babel/generator": "^7.24.1", "@babel/helper-environment-visitor": "^7.22.20", "@babel/helper-function-name": "^7.23.0", "@babel/helper-hoist-variables": "^7.22.5", "@babel/helper-split-export-declaration": "^7.22.6", - "@babel/parser": "^7.23.0", - "@babel/types": "^7.23.0", - "debug": "^4.1.0", + "@babel/parser": "^7.24.1", + "@babel/types": "^7.24.0", + "debug": "^4.3.1", "globals": "^11.1.0" }, "dependencies": { @@ -7552,12 +7434,12 @@ } }, "@babel/types": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz", - "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==", + "version": "7.24.0", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.24.0.tgz", + "integrity": "sha512-+j7a5c253RfKh8iABBhywc8NSfP5LURe7Uh4qpsh6jc+aLJguvmIUBdjSdEMQv2bENrCR5MfRdjGo7vzS/ob7w==", "dev": true, "requires": { - "@babel/helper-string-parser": "^7.22.5", + "@babel/helper-string-parser": "^7.23.4", "@babel/helper-validator-identifier": "^7.22.20", "to-fast-properties": "^2.0.0" } @@ -8073,14 +7955,26 @@ } }, "@jridgewell/gen-mapping": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz", - "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==", + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dev": true, "requires": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" + }, + "dependencies": { + "@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "requires": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + } } }, "@jridgewell/resolve-uri": { @@ -8090,9 +7984,9 @@ "dev": true }, "@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true }, "@jridgewell/sourcemap-codec": { @@ -8571,9 +8465,9 @@ } }, "@types/jest": { - "version": "29.5.11", - "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.11.tgz", - "integrity": "sha512-S2mHmYIVe13vrm6q4kN6fLYYAka15ALQki/vgDC3mIukEOx8WJlv0kQPM+d4w8Gp6u0uSdKND04IlTXBv0rwnQ==", + "version": "29.5.12", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.12.tgz", + "integrity": "sha512-eDC8bTvT/QhYdxJAulQikueigY5AsdBRH2yDKW3yveW7svY3+DzN84/2NUgkw10RTiJbWqZrTtoGVdYlvFJdLw==", "dev": true, "requires": { "expect": "^29.0.0", @@ -8831,11 +8725,11 @@ "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" }, "axios": { - "version": "1.6.2", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.2.tgz", - "integrity": "sha512-7i24Ri4pmDRfJTR7LDBhsOTtcm+9kjX5WiY1X3wIisx6G9So3pfMkEiU7emUBe46oceVImccTEM3k6C5dbVW8A==", + "version": "1.6.8", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.8.tgz", + "integrity": "sha512-v/ZHtJDU39mDpyBoFVkETcd/uNdxrWRrg3bKpOKzXFA6Bvqopts6ALSMU3y6ijYxbw2B+wPrIv46egTzJXCLGQ==", "requires": { - "follow-redirects": "^1.15.0", + "follow-redirects": "^1.15.6", "form-data": "^4.0.0", "proxy-from-env": "^1.1.0" } @@ -9346,9 +9240,9 @@ } }, "dotenv": { - "version": "16.3.1", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.3.1.tgz", - "integrity": "sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==", + "version": "16.4.5", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.5.tgz", + "integrity": "sha512-ZmdL2rui+eB2YwhsWzjInR8LldtZHGDoQ1ugH85ppHKwpUHL7j7rN0Ti9NCnGiQbhaZ11FpR+7ao1dNsmduNUg==", "dev": true }, "eastasianwidth": { @@ -9650,12 +9544,12 @@ } }, "ethers": { - "version": "6.9.0", - "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.9.0.tgz", - "integrity": "sha512-pmfNyQzc2mseLe91FnT2vmNaTt8dDzhxZ/xItAV7uGsF4dI4ek2ufMu3rAkgQETL/TIs0GS5A+U05g9QyWnv3Q==", + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.12.0.tgz", + "integrity": "sha512-zL5NlOTjML239gIvtVJuaSk0N9GQLi1Hom3ZWUszE5lDTQE/IVB62mrPkQ2W1bGcZwVGSLaetQbWNQSvI4rGDQ==", "dev": true, "requires": { - "@adraffy/ens-normalize": "1.10.0", + "@adraffy/ens-normalize": "1.10.1", "@noble/curves": "1.2.0", "@noble/hashes": "1.3.2", "@types/node": "18.15.13", @@ -9864,9 +9758,9 @@ "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==" }, "follow-redirects": { - "version": "1.15.2", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", - "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==" + "version": "1.15.6", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz", + "integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==" }, "foreground-child": { "version": "3.1.1", @@ -10762,9 +10656,9 @@ "dev": true }, "jsonc-parser": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.2.0.tgz", - "integrity": "sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w==", + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.2.1.tgz", + "integrity": "sha512-AilxAyFOAcK5wA1+LeaySVBrHsGQvUFCDWXKpZjzaL0PqW+xfBOttn8GNtWKFWqneyMZj41MWF9Kl6iPWLwgOA==", "dev": true }, "keccak": { @@ -10977,9 +10871,9 @@ "dev": true }, "nodemon": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.0.2.tgz", - "integrity": "sha512-9qIN2LNTrEzpOPBaWHTm4Asy1LxXLSickZStAQ4IZe7zsoIpD/A7LWxhZV3t4Zu352uBcqVnRsDXSMR2Sc3lTA==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.1.0.tgz", + "integrity": "sha512-xqlktYlDMCepBJd43ZQhjWwMw2obW/JRvkrLxq5RCNcuDDX1DbcPT+qT1IlIIdf+DhnWs90JpTMe+Y5KxOchvA==", "dev": true, "requires": { "chokidar": "^3.5.2", @@ -11509,9 +11403,9 @@ "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" }, "shiki": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/shiki/-/shiki-0.14.5.tgz", - "integrity": "sha512-1gCAYOcmCFONmErGTrS1fjzJLA7MGZmKzrBNX7apqSwhyITJg2O102uFzXUeBxNnEkDA9vHIKLyeKq0V083vIw==", + "version": "0.14.7", + "resolved": "https://registry.npmjs.org/shiki/-/shiki-0.14.7.tgz", + "integrity": "sha512-dNPAPrxSc87ua2sKJ3H5dQ/6ZaY8RNnaAqK+t0eG7p0Soi2ydiqbGOTaZCqaYvA/uZYfS1LJnemt3Q+mSfcPCg==", "dev": true, "requires": { "ansi-sequence-parser": "^1.1.0", @@ -11779,9 +11673,9 @@ } }, "ts-jest": { - "version": "29.1.1", - "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.1.1.tgz", - "integrity": "sha512-D6xjnnbP17cC85nliwGiL+tpoKN0StpgE0TeOjXQTU6MVCfsB4v7aW05CgQ/1OywGb0x/oy9hHFnN+sczTiRaA==", + "version": "29.1.2", + "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.1.2.tgz", + "integrity": "sha512-br6GJoH/WUX4pu7FbZXuWGKGNDuU7b8Uj77g/Sp7puZV6EXzuByl6JrECvm0MzVzSTkSHWTihsXt+5XYER5b+g==", "dev": true, "requires": { "bs-logger": "0.x", @@ -11832,58 +11726,58 @@ } }, "turbo": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo/-/turbo-1.8.3.tgz", - "integrity": "sha512-zGrkU1EuNFmkq6iky6LcMqD4h0OLE8XysVFxQWRIZbcTNnf0XAycbsbeEyiJpiWeqb7qtg2bVuY9EYcNoNhVuQ==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo/-/turbo-1.13.2.tgz", + "integrity": "sha512-rX/d9f4MgRT3yK6cERPAkfavIxbpBZowDQpgvkYwGMGDQ0Nvw1nc0NVjruE76GrzXQqoxR1UpnmEP54vBARFHQ==", "dev": true, "requires": { - "turbo-darwin-64": "1.8.3", - "turbo-darwin-arm64": "1.8.3", - "turbo-linux-64": "1.8.3", - "turbo-linux-arm64": "1.8.3", - "turbo-windows-64": "1.8.3", - "turbo-windows-arm64": "1.8.3" + "turbo-darwin-64": "1.13.2", + "turbo-darwin-arm64": "1.13.2", + "turbo-linux-64": "1.13.2", + "turbo-linux-arm64": "1.13.2", + "turbo-windows-64": "1.13.2", + "turbo-windows-arm64": "1.13.2" } }, "turbo-darwin-64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-darwin-64/-/turbo-darwin-64-1.8.3.tgz", - "integrity": "sha512-bLM084Wr17VAAY/EvCWj7+OwYHvI9s/NdsvlqGp8iT5HEYVimcornCHespgJS/yvZDfC+mX9EQkn3V2JmYgGGw==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-darwin-64/-/turbo-darwin-64-1.13.2.tgz", + "integrity": "sha512-CCSuD8CfmtncpohCuIgq7eAzUas0IwSbHfI8/Q3vKObTdXyN8vAo01gwqXjDGpzG9bTEVedD0GmLbD23dR0MLA==", "dev": true, "optional": true }, "turbo-darwin-arm64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-darwin-arm64/-/turbo-darwin-arm64-1.8.3.tgz", - "integrity": "sha512-4oZjXtzakopMK110kue3z/hqu3WLv+eDLZOX1NGdo49gqca9BeD8GbH+sXpAp6tqyeuzpss+PIliVYuyt7LgbA==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-darwin-arm64/-/turbo-darwin-arm64-1.13.2.tgz", + "integrity": "sha512-0HySm06/D2N91rJJ89FbiI/AodmY8B3WDSFTVEpu2+8spUw7hOJ8okWOT0e5iGlyayUP9gr31eOeL3VFZkpfCw==", "dev": true, "optional": true }, "turbo-linux-64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-linux-64/-/turbo-linux-64-1.8.3.tgz", - "integrity": "sha512-uvX2VKotf5PU14FCxJA5iHItPQno2JWzerMd+g3/h/Asay6dvxvtVjc39MQeGT0H5njSvzVKFkT+3/5q8lgOEg==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-linux-64/-/turbo-linux-64-1.13.2.tgz", + "integrity": "sha512-7HnibgbqZrjn4lcfIouzlPu8ZHSBtURG4c7Bedu7WJUDeZo+RE1crlrQm8wuwO54S0siYqUqo7GNHxu4IXbioQ==", "dev": true, "optional": true }, "turbo-linux-arm64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-linux-arm64/-/turbo-linux-arm64-1.8.3.tgz", - "integrity": "sha512-E1p+oH3XKMaPS4rqWhYsL4j2Pzc0d/9P5KU7Kn1kqVLo2T3iRA7n2KVULEieUNE0nTH+aIJPXYXOpqCI5wFJaA==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-linux-arm64/-/turbo-linux-arm64-1.13.2.tgz", + "integrity": "sha512-sUq4dbpk6SNKg/Hkwn256Vj2AEYSQdG96repio894h5/LEfauIK2QYiC/xxAeW3WBMc6BngmvNyURIg7ltrePg==", "dev": true, "optional": true }, "turbo-windows-64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-windows-64/-/turbo-windows-64-1.8.3.tgz", - "integrity": "sha512-cnzAytHtoLXd0J7aNzRpZFpL/GTjcBmkvAPlbOdf/Pl1iwS4qzGrudZQ+OM1lmLgLIfBPIavsGHBknTwTNib4A==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-windows-64/-/turbo-windows-64-1.13.2.tgz", + "integrity": "sha512-DqzhcrciWq3dpzllJR2VVIyOhSlXYCo4mNEWl98DJ3FZ08PEzcI3ceudlH6F0t/nIcfSItK1bDP39cs7YoZHEA==", "dev": true, "optional": true }, "turbo-windows-arm64": { - "version": "1.8.3", - "resolved": "https://registry.npmjs.org/turbo-windows-arm64/-/turbo-windows-arm64-1.8.3.tgz", - "integrity": "sha512-ulIiItNm2w/zYJdD5/oAzjzNns1IjbpweRzpsE8tLXaWwo6+fnXXkyloUug0IUhcd2k6fJXfoiDZfygqpOVuXg==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/turbo-windows-arm64/-/turbo-windows-arm64-1.13.2.tgz", + "integrity": "sha512-WnPMrwfCXxK69CdDfS1/j2DlzcKxSmycgDAqV0XCYpK/812KB0KlvsVAt5PjEbZGXkY88pCJ1BLZHAjF5FcbqA==", "dev": true, "optional": true }, @@ -11907,15 +11801,15 @@ "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==" }, "typedoc": { - "version": "0.25.4", - "resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.25.4.tgz", - "integrity": "sha512-Du9ImmpBCw54bX275yJrxPVnjdIyJO/84co0/L9mwe0R3G4FSR6rQ09AlXVRvZEGMUg09+z/usc8mgygQ1aidA==", + "version": "0.25.13", + "resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.25.13.tgz", + "integrity": "sha512-pQqiwiJ+Z4pigfOnnysObszLiU3mVLWAExSPf+Mu06G/qsc3wzbuM56SZQvONhHLncLUhYzOVkjFFpFfL5AzhQ==", "dev": true, "requires": { "lunr": "^2.3.9", "marked": "^4.3.0", "minimatch": "^9.0.3", - "shiki": "^0.14.1" + "shiki": "^0.14.7" } }, "typescript": { @@ -12017,9 +11911,9 @@ } }, "word-wrap": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", - "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==" + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", + "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==" }, "wrap-ansi": { "version": "8.1.0", diff --git a/package.json b/package.json index 0977766..8bcb59a 100644 --- a/package.json +++ b/package.json @@ -21,13 +21,13 @@ }, "packageManager": "npm@8.4.0", "devDependencies": { + "@types/jest": "^29.5.12", "eslint-config-common": "*", + "jest": "29.7.0", "prettier": "latest", "rimraf": "^5.0.5", - "turbo": "latest", - "jest": "29.7.0", - "ts-jest": "29.1.1", - "@types/jest": "^29.5.11" + "ts-jest": "29.1.2", + "turbo": "latest" }, "jest": { "testTimeout": 1800000, @@ -53,4 +53,4 @@ "preset": "ts-jest", "verbose": true } -} \ No newline at end of file +} diff --git a/packages/cli/package.json b/packages/cli/package.json index eae0042..afb0362 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -47,14 +47,14 @@ ], "devDependencies": { "eslint-config-common": "*", - "nodemon": "^3.0.2", + "nodemon": "^3.1.0", "rimraf": "^5.0.5", "ts-node": "^10.9.2", "tsconfig": "*" }, "dependencies": { "@apillon/sdk": "*", - "axios": "^1.6.2", + "axios": "^1.6.8", "chalk": "^4.1.2", "commander": "^11.1.0" } diff --git a/packages/sdk/package.json b/packages/sdk/package.json index eb7a6b3..891ccee 100644 --- a/packages/sdk/package.json +++ b/packages/sdk/package.json @@ -45,20 +45,20 @@ ], "dependencies": { "@polkadot/util-crypto": "^12.6.2", - "axios": "^1.6.2", + "axios": "^1.6.8", "ethereumjs-util": "^7.1.5" }, "devDependencies": { "@polkadot/keyring": "^12.6.2", - "@types/jest": "^29.5.11", - "dotenv": "^16.3.1", + "@types/jest": "^29.5.12", + "dotenv": "^16.4.5", "eslint-config-common": "*", - "ethers": "^6.9.0", - "nodemon": "^3.0.2", + "ethers": "^6.12.0", + "nodemon": "^3.1.0", "rimraf": "^5.0.5", "ts-node": "^10.9.2", "tsconfig": "*", - "typedoc": "^0.25.4" + "typedoc": "^0.25.13" }, "jest": { "testTimeout": 1800000, From 267a713fbd0196cf5a75287aec6ad38a5f72f0ee Mon Sep 17 00:00:00 2001 From: Damjan Dimitrov Date: Tue, 23 Apr 2024 15:07:46 +0200 Subject: [PATCH 4/6] Upgrade SDK version --- packages/sdk/package.json | 2 +- packages/sdk/src/modules/project/project.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/sdk/package.json b/packages/sdk/package.json index 891ccee..9a67c07 100644 --- a/packages/sdk/package.json +++ b/packages/sdk/package.json @@ -1,7 +1,7 @@ { "name": "@apillon/sdk", "description": "▶◀ Apillon SDK for NodeJS ▶◀", - "version": "3.0.0", + "version": "3.1.0", "author": "Apillon", "license": "MIT", "main": "./dist/index.js", diff --git a/packages/sdk/src/modules/project/project.ts b/packages/sdk/src/modules/project/project.ts index 847af1e..e685cc4 100644 --- a/packages/sdk/src/modules/project/project.ts +++ b/packages/sdk/src/modules/project/project.ts @@ -9,7 +9,7 @@ export class Project extends ApillonModule { /** * Get credit balance for your project - * @returns {Promise<{ balance: number }>} The credit balance of your project + * @returns {Promise} The credit balance of your project */ public async getCreditBalance(): Promise { const { balance } = await ApillonApi.get<{ balance: number }>( From 508cf3d3193fb11ff7e753854bf961c0075c0cfe Mon Sep 17 00:00:00 2001 From: Damjan Dimitrov Date: Thu, 25 Apr 2024 09:09:45 +0200 Subject: [PATCH 5/6] Decouple CID variable in storage tests --- packages/sdk/src/tests/storage.test.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/sdk/src/tests/storage.test.ts b/packages/sdk/src/tests/storage.test.ts index c9d1abc..551e2df 100644 --- a/packages/sdk/src/tests/storage.test.ts +++ b/packages/sdk/src/tests/storage.test.ts @@ -15,7 +15,6 @@ describe('Storage tests', () => { // For get and delete tests let directoryUuid: string; let fileUuid: string; - let cid: string; beforeAll(async () => { storage = new Storage(getConfig()); @@ -100,7 +99,6 @@ describe('Storage tests', () => { expect(files.length).toBeGreaterThan(0); expect(files.every((f) => !!f.CID)).toBeTruthy(); - cid = files[0].CID; }); test('upload files from folder with ignoreFiles = false', async () => { @@ -174,6 +172,7 @@ describe('Storage tests', () => { }); test('Generate IPFS link', async () => { + const cid = 'bafybeigjhyc2tpvqfqsuvf3byo4e4a4v6spi6jk4qqvvtlpca6rsaf2cqi'; const { link } = await storage.generateIpfsLink(cid); expect(link).toBeDefined(); expect(link).toContain(cid); From 286464122cfba1604c1d87c28fd6aa506c2803be Mon Sep 17 00:00:00 2001 From: Damjan Dimitrov Date: Tue, 7 May 2024 12:55:13 +0200 Subject: [PATCH 6/6] Update generateIpfsLink method, add docs --- packages/sdk/README.md | 4 ++++ packages/sdk/src/modules/storage/storage.ts | 7 ++++--- packages/sdk/src/tests/storage.test.ts | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/packages/sdk/README.md b/packages/sdk/README.md index 47e1901..0588dce 100644 --- a/packages/sdk/README.md +++ b/packages/sdk/README.md @@ -175,6 +175,10 @@ await bucket.listObjects({ // list all files in a bucket no matter if they are in a folder or not await bucket.listFiles({ fileStatus: FileStatus.UPLOADED }); +// generate an IPFS link for a CID +const cid = 'bafybeigjhyc2tpvqfqsuvf3byo4e4a4v6spi6jk4qqvvtlpca6rsaf2cqi'; +const link = await storage.generateIpfsLink(cid); + // gets a specific file in a bucket directly through uuid const file = await bucket.file('2195521d-15cc-4f6e-abf2-13866f9c6e03').get(); diff --git a/packages/sdk/src/modules/storage/storage.ts b/packages/sdk/src/modules/storage/storage.ts index 6bcda0c..8a21bf5 100644 --- a/packages/sdk/src/modules/storage/storage.ts +++ b/packages/sdk/src/modules/storage/storage.ts @@ -71,11 +71,12 @@ export class Storage extends ApillonModule { * Apillon IPFS gateways are private and can only be accessible with a token. * @docs [Generate an IPFS link](https://wiki.apillon.io/build/2-storage-api.html#get-or-generate-link-for-ipfs) * @param {string} cid The CID or IPNS address of the fie - * @returns {Promise<{ link: string }>} Link where the requested content can be accessed. + * @returns {Promise} The IPFS link where the requested content can be accessed. */ - public async generateIpfsLink(cid: string): Promise<{ link: string }> { - return await ApillonApi.get<{ link: string }>( + public async generateIpfsLink(cid: string): Promise { + const { link } = await ApillonApi.get<{ link: string }>( `${this.API_PREFIX}/link-on-ipfs/${cid}`, ); + return link; } } diff --git a/packages/sdk/src/tests/storage.test.ts b/packages/sdk/src/tests/storage.test.ts index 551e2df..e334935 100644 --- a/packages/sdk/src/tests/storage.test.ts +++ b/packages/sdk/src/tests/storage.test.ts @@ -173,7 +173,7 @@ describe('Storage tests', () => { test('Generate IPFS link', async () => { const cid = 'bafybeigjhyc2tpvqfqsuvf3byo4e4a4v6spi6jk4qqvvtlpca6rsaf2cqi'; - const { link } = await storage.generateIpfsLink(cid); + const link = await storage.generateIpfsLink(cid); expect(link).toBeDefined(); expect(link).toContain(cid); });