# Sei

Source: https://developers.bitgo.com/docs/sei

## Sei

Sei can be accessed with the following coin types:

| Environment        | Coin Type | Faucet                                                                                                                           |
| :------------------| :---------| :--------------------------------------------------------------------------------------------------------------------------------|
| Sei Production     | sei       |                                                                                                                                  |
| Sei Testnet        | tsei      | <a href="https://atlantic-2.app.sei.io/faucet" target="_blank" rel="noreferrer">https://atlantic-2.app.sei.io/faucet</a>                        |

### Explorer
<a href="https://www.mintscan.io/osmosis/" target="_blank" rel="noreferrer">https://www.mintscan.io/osmosis/</a>


### Generating wallets

To create a Sei wallet using BitGoJS:

```javascript
bitgo
  .coin('tsei')
  .wallets()
  .generateWallet({
    label: 'My Test Wallet',
    passphrase: 'secretpassphrase1a5df8380e0e30',
  })
  .then(function (wallet) {
    // print the new wallet
    console.dir(wallet);
  });
```

To create a Sei wallet using the platform API:

```shell
LABEL="My Test Wallet"
PASSPHRASE="secretpassphrase1a5df8380e0e30"

curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-d "{ \"label\": \"$LABEL\", \"passphrase\": \"$PASSPHRASE\" }" \
http://$BITGO_EXPRESS_HOST/api/v2/tsei/wallet/generate
```

### Creating addresses

```javascript
bitgo
  .coin('tsei')
  .wallets()
  .getWallet({ id: '585c51a5df8380e0e3082e46' })
  .then(function (wallet) {
    return wallet.createAddress();
  })
  .then(function (newAddress) {
    // print new address details
    console.dir(newAddress);
  });
```
```shell
WALLET=585c51a5df8380e0e3082e46

curl -X POST \
-H "Authorization: Bearer $ACCESS_TOKEN" \
https://app.bitgo-test.com/api/v2/tsei/wallet/$WALLET/address
```

### Staking
- Sei supports staking. Sei uses a delegated proof-of-stake (DPoS) consensus mechanism. Sei holders can stake their tokens to validators.
- Validators participate in consensus to produce new blocks and validate transactions.
- By staking Sei, holders can earn rewards.

### Balances
The base unit of Sei is `usei` (microsei).
- 1 sei = 1,000,000 usei
- 1 usei = 0.000001 sei

To check the balance of a wallet:

```javascript
const address = yield walletInstance.getAddress({ address: 'sei1fsjz3adpv3v4zlu6dwn4qm8n98r8ard2jma7eu' });
const bal = address.balance;
return bal;
```

### Tokens
Sei does not support tokens transactions.

### Consolidation
BitGo supports memo based addresses. Therefore, consolidation is not required.

### Fee rate
The default gas fee is 1.75 sei
