> For the complete documentation index, see [llms.txt](https://docs.cielo.finance/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cielo.finance/api-reference/trading/solana-trading.md).

# Solana Trading

Swap quotes on Solana.

## Get Solana Swap Quote (v2)

> Fetches a quote for buying or selling tokens on Solana. For buy: swaps the chosen collateral (SOL or USDC) for the specified token. For sell: swaps the specified token for the chosen collateral (SOL or USDC).\
> Plans Included = Builder, Architect, Enterprise Cost per request = 5 credits.<br>

```json
{"openapi":"3.0.0","info":{"title":"Cielo Public API","version":"1.0"},"tags":[{"name":"Solana Trading","description":"Swap quotes on Solana."}],"servers":[{"url":"https://api.cielo.finance","description":"Endpoint"}],"security":[{"api_key":[]}],"components":{"securitySchemes":{"api_key":{"type":"apiKey","in":"header","name":"X-API-KEY"}},"schemas":{"ErrorResponse":{"type":"object","description":"This object represents a response structure typically used to convey the outcome of a request. It primarily consists of a status indicator and a message, which together provide essential feedback about the request's processing. The status reflects the overall result of the request (such as success, error, etc.), while the message gives a more detailed explanation or the nature of the response, especially useful in cases of errors or exceptions.\n","properties":{"status":{"$ref":"#/components/schemas/ResponseStatus","description":"A reference to the response status object. This status is a key indicator of whether the request was processed successfully or resulted in an error."},"data":{"type":"object","description":"A flexible object intended to hold the actual data payload of the response. The structure of this object can vary depending on the specific endpoint and the nature of the response."},"message":{"type":"string","description":"A descriptive message providing additional details about the response. In case of an error, this message typically contains information useful for understanding the error's cause or nature."}},"required":["status","message"]},"ResponseStatus":{"type":"string","enum":["ok","error","pending"]}}},"paths":{"/api/trading/solana/v2/quote":{"get":{"tags":["Solana Trading"],"summary":"Get Solana Swap Quote (v2)","description":"Fetches a quote for buying or selling tokens on Solana. For buy: swaps the chosen collateral (SOL or USDC) for the specified token. For sell: swaps the specified token for the chosen collateral (SOL or USDC).\nPlans Included = Builder, Architect, Enterprise Cost per request = 5 credits.\n","operationId":"getSolanaQuoteV2","parameters":[{"name":"type","in":"query","description":"Trade type.","required":true,"schema":{"type":"string","enum":["buy","sell"]}},{"name":"mint","in":"query","description":"Token mint address to buy or sell.","required":true,"schema":{"type":"string"}},{"name":"collateral","in":"query","description":"Trading collateral asset. \"sol\" (default) trades against WSOL; \"usdc\" trades against the canonical Solana USDC mint (EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v). Determines the decimals used for the amount field.\n","required":false,"schema":{"type":"string","enum":["sol","usdc"],"default":"sol"}},{"name":"amount","in":"query","description":"Human-readable amount in the chosen collateral on buy (1.5 SOL or 1.5 USDC), or in token units on sell. Converted server-side to collateral base units (lamports for SOL, micro-USDC for USDC).\n","required":false,"schema":{"type":"number"}},{"name":"amount_raw","in":"query","description":"Raw amount in collateral base units (lamports for SOL, micro-USDC for USDC, or token's smallest unit on sell). Overrides amount if provided.\n","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Quote retrieved successfully","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}}}
```
