---
title: "Get price ratio"
method: GET
path: "/ratio/{tokenA}/{tokenB}"
tags: ["Prices"]
---

# Get price ratio

`GET /ratio/{tokenA}/{tokenB}`

## Request

- Base URL: `https://api.tradecraft.fi/v1`
- URL: `https://api.tradecraft.fi/v1/ratio/{tokenA}/{tokenB}`
- Auth: none declared

Returns the current price ratio of token B in terms of token A. Note that token A and token B do not always correlate to the first and second tokens in the pool name.

## Path parameters

- `tokenA` 'CC' | 'USDCx' | 'CBTC' | 'cETH' | 'HANDL' | 'EDELx' | 'SBC', required
- `tokenB` 'CC' | 'USDCx' | 'CBTC' | 'cETH' | 'HANDL' | 'EDELx' | 'SBC', required

## Response `200`

Price ratio

- RatioResponse
  - `price_of_b_in_a` number, double, required: The price of token B expressed in token A (tokenB_holdings / tokenA_holdings).

## Other responses

- `400`: AMM not found

---

[API](https://skmtc.dev/tradecraft/apis/tradecraft-amm-http-api.md) - [All operations](https://skmtc.dev/tradecraft/apis/tradecraft-amm-http-api/llms.txt) - [OpenAPI document](https://skmtc.dev/tradecraft/apis/tradecraft-amm-http-api/revisions/d640e54c230b?raw)
