0% found this document useful (0 votes)
329 views

solana-cmds-tokens

Uploaded by

2024eb02377
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
329 views

solana-cmds-tokens

Uploaded by

2024eb02377
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 3

compact]

--ws <URL> WebSocket URL for the solana cluster

SUBCOMMANDS:
export-address-labels Export the current address labels
get Get current config settings
help Prints this message or the help of the given
subcommand(s)
import-address-labels Import a list of address labels
set Set a config setting
akshatsipany@Akshats-MacBook-Air ~ % solana get --keypair
solana-config
Solana command-line tool configuration settings

USAGE:
solana config [FLAGS] [OPTIONS] <SUBCOMMAND>

FLAGS:
-h, --help Prints help information
--no-address-labels Do not use address labels in the output
--skip-seed-phrase-validation Skip validation of seed phrases. Use this
if your phrase does not use the BIP39
official English word list
--use-quic Use QUIC when sending transactions.
--use-udp Use UDP when sending transactions.
-V, --version Prints version information
-v, --verbose Show additional information

OPTIONS:
--commitment <COMMITMENT_LEVEL> Return information at the selected
commitment level [possible values:
processed, confirmed, finalized]
-C, --config <FILEPATH> Configuration file to use [default:

/Users/akshatsipany/.config/solana/cli/config.yml]
-u, --url <URL_OR_MONIKER> URL for Solana's JSON RPC or moniker (or
their first letter): [mainnet-beta,
testnet, devnet, localhost]
-k, --keypair <KEYPAIR> Filepath or URL to a keypair
--output <FORMAT> Return information in specified output
format [possible values: json, json-
compact]
--ws <URL> WebSocket URL for the solana cluster

SUBCOMMANDS:
export-address-labels Export the current address labels
get Get current config settings
help Prints this message or the help of the given
subcommand(s)
import-address-labels Import a list of address labels
set Set a config setting
akshatsipany@Akshats-MacBook-Air ~ % clera
zsh: command not found: clera
akshatsipany@Akshats-MacBook-Air ~ % clear

akshatsipany@Akshats-MacBook-Air ~ % solana-keygen new


Error: Refusing to overwrite /Users/akshatsipany/.config/solana/id.json without --
force flag
akshatsipany@Akshats-MacBook-Air ~ % solana-keygen new --force
Generating a new keypair

For added security, enter a BIP39 passphrase

NOTE! This passphrase improves security of the recovery seed phrase NOT the
keypair file itself, which is stored as insecure plain text

BIP39 Passphrase (empty for none):

Wrote new keypair to /Users/akshatsipany/.config/solana/id.json


=============================================================================
pubkey: DG5tghuFQktgXQ1UVeL1QKA9TjrCPQmqCZVCNUEFrUw9
=============================================================================
Save this seed phrase and your BIP39 passphrase to recover your new keypair:
laundry digital obtain predict wool junk oven pistol nose wild produce casual
=============================================================================
akshatsipany@Akshats-MacBook-Air ~ % solana config set --url
https://api.devnet.solana.com
Config File: /Users/akshatsipany/.config/solana/cli/config.yml
RPC URL: https://api.devnet.solana.com
WebSocket URL: wss://api.devnet.solana.com/ (computed)
Keypair Path: /Users/akshatsipany/.config/solana/id.json
Commitment: confirmed
akshatsipany@Akshats-MacBook-Air ~ % solana airdrop 1
Requesting airdrop of 1 SOL
⠁ [0/1] Finalizing transaction
5v21hPDQNSQ2XF8PYKLk8JN1jDYpbdzMT93TtgXKeHngHBW7A97nmrjn2D7TZfyhMY7nL3Gsj9c4Je2uiBG
cb44B ⠙ [0/1]
Finalizing transaction
5v21hPDQNSQ2XF8PYKLk8JN1jDYpbdzMT93TtgXKeHngHBW7A97nmrjn2D7TZfyhMY7nL3Gsj9c4Je2uiBG
cb44B ⠂ [0/1]
Finalizing transaction
5v21hPDQNSQ2XF8PYKLk8JN1jDYpbdzMT93TtgXKeHngHBW7A97nmrjn2D7TZfyhMY7nL3Gsj9c4Je2uiBG
cb44B ^R
⠂ [0/1] Finalizing transaction
5v21hPDQNSQ2XF8PYKLk8JN1jDYpbdzMT93TtgXKeHngHBW7A97nmrjn2D7TZfyhMY7nL3Gsj9c4Je2uiBG
cb44B ^R

Signature:
5v21hPDQNSQ2XF8PYKLk8JN1jDYpbdzMT93TtgXKeHngHBW7A97nmrjn2D7TZfyhMY7nL3Gsj9c4Je2uiBG
cb44B

1 SOL
akshatsipany@Akshats-MacBook-Air ~ % solana balance
1 SOL
akshatsipany@Akshats-MacBook-Air ~ % spl-token create-token
Creating token 3jARp9HxoMfvoKGgL2pyWsCEgBr2G91PpKpprJ9LSZBF under program
TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA

Address: 3jARp9HxoMfvoKGgL2pyWsCEgBr2G91PpKpprJ9LSZBF
Decimals: 9

Signature:
4zNnm1tbZTgGdQjsMxdZELSv8EKhJQWkVMw3ApqQmCGJrY3JLxpBsHA7Zu9aFwNpN2XbdSkK9A5UgHFzcza
1nLXj

akshatsipany@Akshats-MacBook-Air ~ % spl-token supply


3jARp9HxoMfvoKGgL2pyWsCEgBr2G91PpKpprJ9LSZBF
0
akshatsipany@Akshats-MacBook-Air ~ % spl-token create-account
3jARp9HxoMfvoKGgL2pyWsCEgBr2G91PpKpprJ9LSZBF
Creating account 21myCewRz8vfU5v6c7D9L7KLcnh5S7hvQeEmtW8qUZSr

Signature:
1aRcEUWMQsV9CCCMWgKZkXsh3dNmL5RufhJmq4p4xyD3Vn7kjDq9KwcW73epeq98EpzLnZE8WzUMsNuudUj
BiKX

akshatsipany@Akshats-MacBook-Air ~ % solana address


DG5tghuFQktgXQ1UVeL1QKA9TjrCPQmqCZVCNUEFrUw9
akshatsipany@Akshats-MacBook-Air ~ % spl-token mint
3jARp9HxoMfvoKGgL2pyWsCEgBr2G91PpKpprJ9LSZBF 100
Minting 100 tokens
Token: 3jARp9HxoMfvoKGgL2pyWsCEgBr2G91PpKpprJ9LSZBF
Recipient: 21myCewRz8vfU5v6c7D9L7KLcnh5S7hvQeEmtW8qUZSr

Signature:
3g51dUpnnE4rgv9oe3pfwGUzmMJD5gWWWyrTptghUJM1a7SGPc5Z38oSbwDqu7uv9n17FrgBjeusySscnsR
6p7j4

akshatsipany@Akshats-MacBook-Air ~ % cat ~/.config/solana/id.json


[95,48,141,246,44,95,59,154,213,49,27,77,19,91,63,146,121,109,170,103,233,187,127,9
4,191,105,170,88,93,189,204,231,182,41,124,83,173,76,196,46,153,172,193,16,142,234,
207,145,122,22,156,226,118,152,85,35,18,98,126,212,45,186,64,248]%
akshatsipany@Akshats-MacBook-Air ~ % solana airdrop 10000
Requesting airdrop of 10000 SOL
Error: airdrop request failed. This can happen when the rate limit is reached.
akshatsipany@Akshats-MacBook-Air ~ % solana airdrop 20
Requesting airdrop of 20 SOL
Error: airdrop request failed. This can happen when the rate limit is reached.
akshatsipany@Akshats-MacBook-Air ~ % solana config get
Config File: /Users/akshatsipany/.config/solana/cli/config.yml
RPC URL: https://api.devnet.solana.com
WebSocket URL: wss://api.devnet.solana.com/ (computed)
Keypair Path: /Users/akshatsipany/.config/solana/id.json
Commitment: confirmed
akshatsipany@Akshats-MacBook-Air ~ % solana airdrop 1
Requesting airdrop of 1 SOL
Error: airdrop request failed. This can happen when the rate limit is reached.
akshatsipany@Akshats-MacBook-Air ~ %

You might also like