From bfc42356fefdc5efa7eef6c5bf995a85afbd3132 Mon Sep 17 00:00:00 2001 From: biancabuzea200 Date: Mon, 25 Sep 2023 16:52:41 +0200 Subject: [PATCH 1/4] add up_generateLsp23Address docs --- docs/standards/rpc-api.md | 89 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) diff --git a/docs/standards/rpc-api.md b/docs/standards/rpc-api.md index f5da7f2f67..12a49b6955 100644 --- a/docs/standards/rpc-api.md +++ b/docs/standards/rpc-api.md @@ -168,3 +168,92 @@ params: ['0x311611C9A46a192C14Ea993159a0498EDE5578aC']; #### Returns ##### 1. `String` - New controller address, to be added to the profile by the dapp. + +### up_generateLsp23Address {#up_generateLsp23Address} + +To perform the deployment, the dApp needs the salt and the controllerAddress. The controllerAddress will be injected in the dataKeys and dataValues array, then the salt and the encoded dataKeys and dataValues are sent to the relayer to deploy the profile. Previously, the relayer had to do several consecutive transactions in order to deploy a profile. Now, all those transactions are taking place at the smart contract level, so the relayer only creates one transaction. + +##### Parameters + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameTypeDescription
primaryImplementationContractAddressstringUniversal Profile implementation address
secondaryImplementationContractAddressstringKey Manager implementation address
secondaryContractInitializationCalldatastringinitialization calldata for for the Key Manager contract
secondaryContractAddControlledContractAddressbooleanthe my.universalprofile.cloud sets it as true
secondaryContractExtraInitializationParamsstringmy.universalprofile.cloud sets it as '0x'
upPostDeploymentModuleAddressstringaddress of the post deployment module
linkedContractsFactoryAddressstring address of the linkedContractsFactory (LSP23)
dataKeysstring[] data that will be set on a smart contract, e.g: adding controllers, adding LSP3 metadata, or adding default controller permissions
dataValuesstring[] data that will be set on a smart contract, e.g: adding controllers, adding LSP3 metadata, or adding default controller permissions
dataKeysControllerIndexnumber an array index where the controller key is placed
dataValuesControllerIndexnumber array index where the controller value is placed
+ +#### Returns + + + + + + + + + + + + + + + + + +
NameType
saltstring
controllerAddressstring
upAddressupAddress
From b8c73de67392c3b2b7b42399f0ef48cbd3dd1570 Mon Sep 17 00:00:00 2001 From: biancabuzea200 <34369307+biancabuzea200@users.noreply.github.com> Date: Mon, 25 Sep 2023 20:49:33 +0200 Subject: [PATCH 2/4] Update docs/standards/rpc-api.md Co-authored-by: Hugo Masclet --- docs/standards/rpc-api.md | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) diff --git a/docs/standards/rpc-api.md b/docs/standards/rpc-api.md index 12a49b6955..0c3a8036c7 100644 --- a/docs/standards/rpc-api.md +++ b/docs/standards/rpc-api.md @@ -240,20 +240,8 @@ To perform the deployment, the dApp needs the salt and the controllerAddress. Th #### Returns - - - - - - - - - - - - - - - - -
NameType
saltstring
controllerAddressstring
upAddressupAddress
+| Name | Type | +|-------------------|-----------| +| salt | string | +| controllerAddress | string | +| upAddress | upAddress | From 684d45d0aa91f322ae69a682de5c14156c437aad Mon Sep 17 00:00:00 2001 From: biancabuzea200 Date: Mon, 25 Sep 2023 21:06:13 +0200 Subject: [PATCH 3/4] linter fix --- docs/standards/rpc-api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/standards/rpc-api.md b/docs/standards/rpc-api.md index 0c3a8036c7..ab09312ad5 100644 --- a/docs/standards/rpc-api.md +++ b/docs/standards/rpc-api.md @@ -241,7 +241,7 @@ To perform the deployment, the dApp needs the salt and the controllerAddress. Th #### Returns | Name | Type | -|-------------------|-----------| +| ----------------- | --------- | | salt | string | | controllerAddress | string | | upAddress | upAddress | From a74e09150eed1e95e0fd8e6adf2dfdd0b0b07187 Mon Sep 17 00:00:00 2001 From: biancabuzea200 Date: Thu, 28 Sep 2023 11:18:14 +0200 Subject: [PATCH 4/4] add additional context for up_generateLsp23Address --- docs/standards/rpc-api.md | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/docs/standards/rpc-api.md b/docs/standards/rpc-api.md index ab09312ad5..5dc3d36d7e 100644 --- a/docs/standards/rpc-api.md +++ b/docs/standards/rpc-api.md @@ -11,7 +11,7 @@ This page is under active development. ::: -The [LUKSO Extension](../guides/browser-extension/install-browser-extension.md) uses the RPC API methods from the table below. The methods are grouped by category: signing methods, standard methods, and LUKSO-specific methods. +The [LUKSO UP Browser Extension](../guides/browser-extension/install-browser-extension.md) uses the RPC API methods from the table below. The methods are grouped by category: signing methods, standard methods, and LUKSO-specific methods. ## Supported Methods @@ -147,17 +147,17 @@ params: [ #### Returns -##### 1. `String Array` - Array of universal profile addresses the user selected for this relay service +##### 1. `String Array` - Array of Universal Profile addresses the user selected for this relay service It returns an array of Universal Profile addresses. ### up_import {#up_import} -Add a Universal Profile address. +Add a Universal Profile address to the UP Browser Extension. #### Parameters -##### 1. `String` - Universal profile address to add to the extension +##### 1. `String` - Universal Profile address to add to the extension The Universal Profile address to add. @@ -171,7 +171,13 @@ params: ['0x311611C9A46a192C14Ea993159a0498EDE5578aC']; ### up_generateLsp23Address {#up_generateLsp23Address} -To perform the deployment, the dApp needs the salt and the controllerAddress. The controllerAddress will be injected in the dataKeys and dataValues array, then the salt and the encoded dataKeys and dataValues are sent to the relayer to deploy the profile. Previously, the relayer had to do several consecutive transactions in order to deploy a profile. Now, all those transactions are taking place at the smart contract level, so the relayer only creates one transaction. +It allows the creation of a Universal Profile for the UP Browser Extension using the [LSP23 Standard](https://github.com/lukso-network/LIPs/blob/main/LSPs/LSP-23-LinkedContractsFactory.md), which under the hood will wrap many operations/transactions into one, simplifying deployment. + +To perform the deployment of a Universal Profile, the dApp needs the salt and the controllerAddress. The controllerAddress will be injected in the dataKeys and dataValues array, then the salt and the encoded dataKeys and dataValues are sent to the relayer to deploy the profile. Previously, the relayer had to do several consecutive transactions to deploy a profile. Now, all those transactions are taking place at the smart contract level, so the relayer only creates one transaction. + +**up_generateLsp23Address**: should be used for creating a new Universal Profile using the UP Browser Extension + +**up_import**: should be used for adding already existing Universal Profiles to the UP Browser Extension ##### Parameters @@ -240,8 +246,8 @@ To perform the deployment, the dApp needs the salt and the controllerAddress. Th #### Returns -| Name | Type | -| ----------------- | --------- | -| salt | string | -| controllerAddress | string | -| upAddress | upAddress | +| Name | Type | +| ------------------- | --------- | +| `salt` | string | +| `controllerAddress` | string | +| `upAddress` | upAddress |