Skip to content

Update multisig README with clearer instructions #373

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

Merged
merged 1 commit into from
May 2, 2025
Merged
Changes from all 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
34 changes: 26 additions & 8 deletions multisig_1_of_n_account/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,17 +105,26 @@ cd contract
stellar network use testnet
```

### Create a Testnet Account to Deploy with
### Create a Testnet Account to Deploy with and pay Tx fees

```
stellar keys generate --fund me
stellar keys use me
stellar keys generate --fund feepayer
stellar keys use feepayer
```

### Deploy the contract account
### Build the contract

```
stellar contract build --out-dir out/
```

### Deploy the contract account

Deploy the contract, including a list of signers that will be permitted to
authorize / sign for the contract account. The signers should be the hex encoded
32-byte ed25519 public keys discussed at the top of this document.

```
stellar contract deploy \
--alias admin \
--wasm out/soroban_multisig_1_of_n_account_contract.wasm \
Expand All @@ -128,6 +137,8 @@ stellar contract deploy \

### Deploy asset

Create an account that'll be the issuer of the asset. Deploy the asset contract.

```
stellar keys generate --fund issuer
stellar contract asset deploy \
Expand All @@ -143,6 +154,11 @@ stellar contract alias ls

### Set admin

Set the admin of the asset contract to the contract account deployed in a
previous step. The default admin for the asset contract is the issuer, and
setting the admin will change which address can authorize operations like
minting.

```
stellar contract invoke --source issuer --id asset -- \
set_admin \
Expand All @@ -168,16 +184,18 @@ stellar contract invoke --id asset --build-only -- \
--secret-key 0000000000000000000000000000000000000000000000000000000000000001 \
--signature-expiration-ledger 2296800 \
| stellar tx simulate \
| stellar tx sign --sign-with-key me \
| stellar tx sign --sign-with-key feepayer \
| stellar tx send
```

Note: The 'me' key is signing the transaction to pay the fee, and the admin
signature produced by the `sign-auth-ed25519` plugin is what is authorizing the
mint. The issuer key is not involved in the mint at all.
Note: The 'feepayer' key is signing the transaction to pay the fee, and the
admin signature produced by the `sign-auth-ed25519` plugin is what is
authorizing the mint. The issuer key is not involved in the mint at all.

### View Balance

Verify that the mint did take place by viewing the balance of the recipient.

```
stellar contract invoke --id asset -- \
balance \
Expand Down