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

Added the expected prefund token type to account create output #2328

Merged
merged 6 commits into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
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
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Cast

#### Changed
- `account create` outputs hint about the type of the tokens required to prefund a newly created account with before deployment

## [0.27.0] - 2024-07-24

### Forge
Expand Down
2 changes: 1 addition & 1 deletion crates/sncast/src/starknet_commands/account/create.rs
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ pub async fn create(
"--add-profile flag was not set. No profile added to snfoundry.toml".to_string()
},
message: if account_json["deployed"] == json!(false) {
"Account successfully created. Prefund generated address with at least <max_fee> tokens. It is good to send more in the case of higher demand.".to_string()
"Account successfully created. Prefund generated address with at least <max_fee> STRK tokens or an equivalent amount of ETH tokens. It is good to send more in the case of higher demand.".to_string()
} else {
"Account already deployed".to_string()
},
Expand Down
2 changes: 1 addition & 1 deletion crates/sncast/tests/e2e/account/create.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ pub async fn test_happy_case(account_type: &str) {
add_profile: --add-profile flag was not set. No profile added to snfoundry.toml
address: 0x[..]
max_fee: [..]
message: Account successfully created. Prefund generated address with at least <max_fee> tokens. It is good to send more in the case of higher demand.
message: Account successfully created. Prefund generated address with at least <max_fee> STRK tokens or an equivalent amount of ETH tokens. It is good to send more in the case of higher demand.
"},
);

Expand Down
5 changes: 4 additions & 1 deletion docs/src/starknet/account.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,12 @@ Do the following to start interacting with the Starknet:


- prefund generated address with tokens


To deploy an account in the next step, you need to prefund it with either STRK or ETH tokens (read more about them [here](https://docs.starknet.io/architecture-and-concepts/economics-of-starknet/)).
You can do it both by sending tokens from another starknet account or by bridging them with [StarkGate](https://starkgate.starknet.io/).

>💡 **Info**
> When deploying on a Sepolia test network, you can also fund your account with artificial tokens via the [Starknet Faucet](https://starknet-faucet.vercel.app)

- deploy account with the `sncast account deploy` command

Expand Down
Loading