# Guide

To make the most of SolanaPortal’s API for token swaps, you first need to understand the basic components and tools used in the Solana blockchain. This guide will introduce these key concepts, helping you build a solid foundation before diving into swaps.

### Key Concepts

#### Wallets

A wallet is where you store your cryptocurrencies and tokens on the blockchain. To use SolanaPortal, you’ll need access to a Solana-compatible wallet that supports private keys for signing transactions.\
Popular wallets include:

* **Phantom**: A user-friendly browser extension wallet.
* **Solflare**: A versatile wallet available on browsers and mobile devices.

{% hint style="danger" %}
**Warning**: Always keep your private key secure and never share it. You’ll need your wallet’s private key to sign swaps using the SolanaPortal API.
{% endhint %}

#### Mint Address

A **mint address** is a unique identifier for a token on the Solana blockchain. Each token, including **SOL**, **USDC**, and other tokens, has its own mint address. You’ll need the mint address of the token you want to trade.\
For example:

* SOL:     `So11111111111111111111111111111111111111112`
* USDC:  `EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v`

#### Private Keys

Your wallet’s private key is required to authenticate and sign transactions on the Solana blockchain. Without the private key, you cannot initiate or complete swaps.

* Use libraries like **bs58** in Node.js or **solana-py** in Python to decode and use your private key programmatically.

#### API Basics

SolanaPortal provides two key endpoints for swapping:

1. **Single Swap Endpoint**:

   ```arduino
   https://api.solanaportal.io/api/trading
   ```

   Use this for individual swaps using jito or bloxroute.
2. **Jito Bundle Endpoint**:

   ```arduino
   https://api.solanaportal.io/api/jito-bundle
   ```

   Use this to execute multiple swaps in a single transaction.


---

# 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.solanaportal.io/getting-started/key-insights.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.
