Skip to content

Commit 43de976

Browse files
authored
Merge pull request #47 from PiotrNap/patch-6
Update staking.mdx
2 parents 64852f9 + fdd7008 commit 43de976

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

apps/docs/content/docs/apis/txbuilder/staking.mdx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: "Transactions for delegating ADA and managing stakepools"
44
icon: ArrowsPointingInIcon
55
---
66

7-
In the code snippet, you will find `txBuilder`, which is an instance of `MeshTxBuilder`, a powerful low-level APIs that allows you to build transactions. Learn how to initialize MeshTxBuilder.
7+
In the code snippet, you will find `txBuilder`, which is an instance of `MeshTxBuilder`, with powerful low-level APIs that allow you to build transactions. Here's how to initialize **MeshTxBuilder**.
88

99
```tsx
1010
const txBuilder = new MeshTxBuilder({
@@ -15,15 +15,15 @@ const txBuilder = new MeshTxBuilder({
1515

1616
## Register Stake Address
1717

18-
Same as Transaction, with `MeshTxBuilder` you have to register a stake address before delegate to stakepools. Here's the 2 APIs you need:
18+
Same as Transaction, with `MeshTxBuilder`, you have to register a stake address before delegating to stakepools. Here are the 2 APIs you need:
1919

2020
```tsx
2121
txBuilder
2222
.registerStakeCertificate(rewardAddress)
2323
.delegateStakeCertificate(rewardAddress, poolIdHash)
2424
```
2525

26-
Since we need to provide the deserilized hash of pool id, we can use the following util to get it:
26+
Since we need to provide the deserialize hash of pool ID, we can use the following util to get it:
2727

2828
```tsx
2929
const poolIdHash = deserializePoolId(
@@ -34,7 +34,7 @@ const poolIdHash = deserializePoolId(
3434
<Card>
3535
### Register Stake Address [!toc]
3636

37-
Register a stake address before delegate to stakepools.
37+
Register a stake address before delegating to a stakepool.
3838

3939
**Pool ID**
4040
`pool107k26e3wrqxwghju2py40ngngx2qcu48ppeg7lk0cm35jl2aenx`
@@ -70,7 +70,7 @@ const poolIdHash = deserializePoolId(
7070

7171
## Delegate Stake
7272

73-
Delegation with `MeshTxBuilder` is exactly the same as first delegate, but without registering stake key, so only one API is needed:
73+
Stake delegation with `MeshTxBuilder` is the same as the first delegate, but without registering the stake key, so only one API call is needed:
7474

7575
```tsx
7676
txBuilder
@@ -115,7 +115,7 @@ txBuilder
115115

116116
## Withdraw Rewards
117117

118-
Withdrawal with `MeshTxBuilder` comes with only one API, to specify the reward address and the amount to withdraw.
118+
Use MeshTxBuilder’s withdrawal method to specify the reward address and amount.
119119

120120
- rewardAddress (string) - the reward address to withdraw from
121121
- lovelace (number) - the amount to withdraw in Lovelace
@@ -161,7 +161,7 @@ txBuilder
161161

162162
## Deregister Stake
163163

164-
Deregister a stake address. The function accepts the following parameters:
164+
To deregister a stake address with MeshTxBuilder, use the following method:
165165

166166
- rewardAddress (string) - the bech32 reward address to deregister
167167

@@ -204,7 +204,7 @@ txBuilder
204204

205205
## Script Withdrawal - Supporting Withdraw Zero
206206

207-
Withdrawal from script is supported by `MeshTxBuilder` with this set of APIs:
207+
Withdrawal from a script is supported by `MeshTxBuilder` with this set of APIs:
208208

209209
```tsx
210210
txBuilder
@@ -216,7 +216,7 @@ txBuilder
216216

217217
**Withdraw Zero**
218218

219-
With that capability, it supports a Cardano technique - withdraw zero - which is a technique to trigger withdrawal script validation without actually withdrawing any value. This is a technique to help boost script ExUnits performance especially comes to validating multiple script inputs. In order to perform withdraw zero, 2 steps are involved:
219+
This is a technique commonly used on Cardano to prove control of a stake key without actually withdrawing any rewards from its withdrawal account. To perform a "withdraw zero", you have to follow these steps:
220220

221221
- Register script stake key
222222

@@ -302,4 +302,4 @@ txBuilder
302302
const signedTx = await wallet.signTx(unsignedTx, true);
303303
const txHash = await wallet.submitTx(signedTx);
304304
```
305-
</Card>
305+
</Card>

0 commit comments

Comments
 (0)