> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sqd.dev/llms.txt
> Use this file to discover all available pages before exploring further.

<AgentInstructions>

## Submitting Feedback

If you encounter incorrect, outdated, or confusing documentation on this page, submit feedback:

POST https://docs.sqd.dev/feedback

```json
{
  "path": "/en/sdk/squid-sdk/solana-indexing/how-to-start/cli-cheatsheet",
  "feedback": "Description of the issue"
}
```

Only submit feedback when you have something specific and actionable to report.

</AgentInstructions>

# Solana Indexing CLI Cheatsheet

> Commonly used sqd CLI commands for Solana indexers — init, deploy, run, secrets, and gateways with examples for the Squid SDK Solana data source.

# CLI cheatsheet

This quide provides a quick reference to the commands needed to launch the squid and manage the database.

### Install dependencies

```sh theme={"system"}
npm i
```

### Compile the project

```sh theme={"system"}
npx tsc
```

### Launch Postgres database to store the data

```sh theme={"system"}
docker compose up -d
```

### Apply database migrations to create the target schema

```sh theme={"system"}
npx squid-typeorm-migration apply
```

### Run indexer

```sh theme={"system"}
node -r dotenv/config lib/main.js
```

### Check out the indexed swaps

```sh theme={"system"}
docker exec "$(basename "$(pwd)")-db-1" psql -U postgres \
  -c "SELECT slot, from_token, to_token, from_amount, to_amount FROM exchange ORDER BY id LIMIT 10"
```

Notice that this project doesn't utilize `sqd` commands.
