From ffdd43592ec9b8f70978f8215ee62d68e4f532a6 Mon Sep 17 00:00:00 2001 From: enrique Date: Wed, 28 Aug 2024 16:01:26 +0200 Subject: [PATCH 1/4] feat: support peaq --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index a22e967..42c5ab7 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "ncli": "./dist/src/index.js" }, "dependencies": { - "@nevermined-io/sdk": "3.0.12", + "@nevermined-io/sdk": "3.0.29", "log4js": "^6.9.1", "chalk": "^4.1.2", "cross-fetch": "~3.1.5", From 40bd3777a576085da00649db619b13a585b5a71d Mon Sep 17 00:00:00 2001 From: enrique Date: Wed, 28 Aug 2024 16:18:43 +0200 Subject: [PATCH 2/4] feat: add peaq network --- resources/networks.json | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/resources/networks.json b/resources/networks.json index 8b77cd6..3dd90de 100644 --- a/resources/networks.json +++ b/resources/networks.json @@ -220,5 +220,30 @@ "gasMultiplier": 0, "gasPriceMultiplier": 0, "externalNetwork": true + }, + "appPeaq": { + "envDescription": "The Peaq network production environment where users can interact with Nevermined protocol.", + "envUrl": "https://peaq.nevermined.app/", + "envName": "Peaq", + "isProduction": true, + "nvm": { + "chainId": 3338, + "appUrl": "https://peaq.nevermined.app", + "web3ProviderUri": "https://evm.peaq.network", + "marketplaceUri": "https://marketplace-api.peaq.nevermined.app", + "graphHttpUri": "", + "neverminedNodeUri": "http://node.peaq.nevermined.app", + "neverminedNodeAddress": "0x824dbcE5E9C96C5b8ce2A35a25a5ab87eD1D00b1", + "verbose": true + }, + "nativeToken": "PEAQ", + "networkName": "peaq-mainnet", + "contractsVersion": "3.5.7", + "tagName": "public", + "etherscanUrl": "https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fmpfn1.peaq.network#/explorer", + "erc20TokenAddress": "0x0000000000000000000000000000000000000000", + "gasMultiplier": 0, + "gasPriceMultiplier": 0, + "externalNetwork": true } } From 2049b7b2232881e55da5f8e25972458dacaf7bd9 Mon Sep 17 00:00:00 2001 From: enrique Date: Wed, 28 Aug 2024 16:24:01 +0200 Subject: [PATCH 3/4] feat: update to pass credits/time nft contract address as parameter --- src/commands/app/registerAgent.ts | 6 +++++- src/commands/app/registerFiles.ts | 3 ++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/commands/app/registerAgent.ts b/src/commands/app/registerAgent.ts index 15f0a66..162cdcb 100644 --- a/src/commands/app/registerAgent.ts +++ b/src/commands/app/registerAgent.ts @@ -100,12 +100,16 @@ export const registerAgent = async ( costInCredits, // default cost in credits for every succesful query to the agent costInCredits, // min amount of credits to be consumed maxCostInCredits, // max amount of credits to be consumed + argv.nftAddress || nvmApp.sdk.keeper.nftUpgradeable.address ) } else { ddo = await nvmApp.registerServiceAsset( agentMetadata, argv.subscriptionDid, - costInCredits + costInCredits, + undefined, + undefined, + argv.nftAddress || nvmApp.sdk.keeper.nftUpgradeable.address ) } diff --git a/src/commands/app/registerFiles.ts b/src/commands/app/registerFiles.ts index 477b930..94a54c3 100644 --- a/src/commands/app/registerFiles.ts +++ b/src/commands/app/registerFiles.ts @@ -57,7 +57,8 @@ export const registerFiles = async ( const ddo = await nvmApp.registerFileAsset( filesMetadata, argv.subscriptionDid, - costInCredits + costInCredits, + argv.nftAddress || nvmApp.sdk.keeper.nftUpgradeable.address ) const assetUrl = `${config.nvm.appUrl}/en/file/${ddo.shortId()}` From 7518983329fa6c65b1a40cb12fb0c7f3d2213591 Mon Sep 17 00:00:00 2001 From: enrique Date: Wed, 28 Aug 2024 16:35:15 +0200 Subject: [PATCH 4/4] feat: bumpversion --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 42c5ab7..4fcbce5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@nevermined-io/cli", - "version": "2.2.0", + "version": "2.2.1", "main": "index.js", "repository": "git@github.com:nevermined-io/cli.git", "author": "Nevermined",