Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
sgc-code committed Jun 27, 2024
1 parent 6992b48 commit 5d28fc5
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ As the fee should be larger than the claiming transaction cost, there might be a
Deposits follow the flow described in the first 3 steps above.
For more details please see the `deposit` function at [Deposit example](./lib/deposit.ts)

Claiming can be done in two ways:

## Claiming

Claiming can be done in two ways:
Expand All @@ -29,15 +27,15 @@ The recipient uses the private key to craft a transaction to claim the gift. The

Edge cases:

- Insufficient `fee_amount`: Alternative options are external claiming or cancellation (see below)
- Dust: `fee+amount” will usually be higher than the actual fee and there will be some amount left in the contract. The owner can collect this amount later
- Insufficient `fee_amount`: Alternative options are "external claiming", waiting for transaction price to go down, or canceling the gift (see below)
- Dust: `fee_amount” will usually be higher than the actual fee and there will be some amount left in the contract. The protocol owner can collect the dust later
- If the internal claim transaction fails for any reason, the account won't allow to submit another transaction. But the gift can be cancelled or claimed using the external method.

For more details about how to trigger it please see the `claimInternal` function at [Claim Internal Example](./lib/claim.ts)

### External claim

If for some reason the funds deposited to pay for the claim transaction are not enough. Or if someone prefers to subsidize. It is also possible for someone else to pay for the claim fees.
It is also possible for someone else to pay for the claim fees. This can be useful if the funds deposited to pay for the claim transaction are not enough, or in someone wants to subsidize the claim

The receiver can use the private key sign a message containing the address receiving the address (and optionally some address that will receive the dust). Using this signature, anybody can execute a transaction to perform the claim. To do so, they should call `claim_external` on the escrow account (through the `execute_action` entrypoint)

Expand Down

0 comments on commit 5d28fc5

Please sign in to comment.