Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add up_generateLsp23Address docs #644

Merged
merged 5 commits into from
Sep 28, 2023
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 77 additions & 0 deletions docs/standards/rpc-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,3 +168,80 @@ 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.
biancabuzea200 marked this conversation as resolved.
Show resolved Hide resolved

##### Parameters

<table>
<tr>
<td>Name</td>
<td>Type</td>
<td>Description</td>
</tr>
<tr>
<td>primaryImplementationContractAddress</td>
<td>string</td>
<td>Universal Profile implementation address</td>
</tr>
<tr>
<td>secondaryImplementationContractAddress</td>
<td>string</td>
<td>Key Manager implementation address</td>
</tr>
<tr>
<td>secondaryContractInitializationCalldata</td>
<td>string</td>
<td>initialization calldata for for the Key Manager contract</td>
</tr>
<tr>
<td>secondaryContractAddControlledContractAddress</td>
<td>boolean</td>
<td>the my.universalprofile.cloud sets it as true</td>
</tr>
<tr>
<td>secondaryContractExtraInitializationParams</td>
<td>string</td>
<td>my.universalprofile.cloud sets it as '0x'</td>
</tr>
<tr>
<td>upPostDeploymentModuleAddress</td>
<td>string</td>
<td>address of the post deployment module</td>
</tr>
<tr>
<td>linkedContractsFactoryAddress</td>
<td>string</td>
<td> address of the linkedContractsFactory (LSP23)</td>
</tr>
<tr>
<td>dataKeys</td>
<td>string[]</td>
<td> data that will be set on a smart contract, e.g: adding controllers, adding LSP3 metadata, or adding default controller permissions</td>
</tr>
<tr>
<td>dataValues</td>
<td>string[]</td>
<td> data that will be set on a smart contract, e.g: adding controllers, adding LSP3 metadata, or adding default controller permissions</td>
</tr>
<tr>
<td>dataKeysControllerIndex</td>
<td>number</td>
<td> an array index where the controller key is placed</td>
</tr>
<tr>
<td>dataValuesControllerIndex</td>
<td>number</td>
<td> array index where the controller value is placed</td>
</tr>
</table>

#### Returns

| Name | Type |
| ----------------- | --------- |
| salt | string |
| controllerAddress | string |
| upAddress | upAddress |