# Solana Integrations

The `SolanaProvider` defined in Tomo Connect SDK contains all the necessary functions to interact with Solana chain. Core functions are:

### Get Wallet Public Key

```javascript
async getPublicKey()
```

### Send SOL

```javascript
async sendSol(to: string, amount: string, mintAddress?: string): Promise<string>
```

### Sign Transaction

```javascript
import { Transaction, VersionedTransaction } from "@solana/web3.js";

async signTransaction<T extends Transaction | VersionedTransaction>(
    transaction: T
): Promise<T>
```

### Sign All Transactions

```javascript
async signAllTransactions<T extends Transaction | VersionedTransaction>(
    transactions: T[]
): Promise<T[]>
```

### Sign and Send Transaction

```javascript
import { 
      Transaction,
      VersionedTransaction,
      SendOptions,
      TransactionSignature
} from "@solana/web3.js";

async signAndSendTransaction<T extends Transaction | VersionedTransaction>(
      transaction: T,
      options?: SendOptions
): Promise<{ signature: TransactionSignature }>
```

### Sign Message

```javascript
async signMessage(message: Uint8Array): Promise<{ signature: Uint8Array }>
```

### Connect

```javascript
async connect(): Promise<void>
```

### Disconnect

```javascript
async disconnect(): Promise<void>
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.tomo.inc/tomo-sdk/tomo-web-sdk/solana-integrations.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
