mirror of
https://github.com/XRPLF/xrpl-dev-portal.git
synced 2025-12-06 17:27:57 +00:00
Apply suggestions from @oeggert review
Co-authored-by: oeggert <117319296+oeggert@users.noreply.github.com>
This commit is contained in:
@@ -4,7 +4,7 @@ These code samples demonstrate how to delegate permissions to another account an
|
||||
|
||||
## Usage
|
||||
|
||||
1. First, install dependencies.
|
||||
1. Install dependencies.
|
||||
|
||||
```sh
|
||||
npm i
|
||||
@@ -26,9 +26,9 @@ These code samples demonstrate how to delegate permissions to another account an
|
||||
|
||||
If it runs successfully, it should output several things including "Delegate successfully set." followed by an [account_objects API method](https://xrpl.org/docs/references/http-websocket-apis/public-api-methods/account-methods/account_objects) response showing the delegate permissions.
|
||||
|
||||
Take note of the `account` address in this output. That's the address of the delegating account.
|
||||
Take note of the `account` address in this output. That's the address of the delegator.
|
||||
|
||||
5. Run `use-delegate-permissions.js` and provide both the delegating account's address (from the previous step's output) and the delegate's secret key (from the devnet faucet earlier).
|
||||
5. Run `use-delegate-permissions.js` and provide both the delegator's address (from the previous step's output) and the delegate's secret key (from the devnet faucet earlier).
|
||||
|
||||
If it runs successfully, it should output various things ending in the following:
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ async function main() {
|
||||
const delegate_address = "r9GAKojMTyexqvy8DXFWYq63Mod5k5wnkT"
|
||||
const delegateset = {
|
||||
"TransactionType": "DelegateSet",
|
||||
"Account": wallet.address,
|
||||
"Account": wallet.address, // Delegator address
|
||||
"Authorize": delegate_address,
|
||||
"Permissions": [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user