You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Added new log files to .gitignore to prevent unnecessary tracking.
- Updated links and fixed formatting in various documentation files, including coinpath and examples.
- Improved clarity in filtering sections across multiple schema documents by adding new lines for better readability.
- Corrected minor typographical errors in documentation headings and links.
Copy file name to clipboardExpand all lines: docs/Examples/dexTrades/dex-trading-data-api.md
+8-5Lines changed: 8 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,9 +18,12 @@ In the case of Buy/Sell Currency, we look into only 1 side of the swap.
18
18
However, in the case of Base/Quote Currency, we look at both sides of the swap.
19
19
20
20
For example - Let's say there are 3 trades.
21
-
1 - A <-> B
22
-
2 - B <-> C
23
-
3 - C <-> A
21
+
22
+
```
23
+
1 - A < - > B
24
+
2 - B < - > C
25
+
3 - C < - > A
26
+
```
24
27
25
28
Now when you query, give me all trades where sellCurrency is B, and we will give only 1st trade (Swap). However, if you query saying give me all trades where quoteCurrency is B, we will give both 1st and 2nd because Base/Quote currency looks at both sides of the trade.
26
29
@@ -55,7 +58,7 @@ If you see this [query](https://ide.bitquery.io/Ethereum-Trades-for-specific-tim
55
58
Protocols are basically rules or behavior to explain how a system will work. In the context of DEX, A DEX protocol is a set of smart contracts showing how DEX will work. When a protocol is deployed by any entity on the blockchain, it becomes an actual exchange.
56
59
For example, Uniswap is an exchange and a protocol. Uniswap protocol deployed by the Uniswap team created the Uniswap exchange. In the case of PancakeSwap, the exchange is PancakeSwap, but the protocol is still Uniswap.
57
60
58
-
## How to check if exchange is indexed by Bitquery?
61
+
## How to check if an exchange is indexed by Bitquery?
59
62
60
63
If Bitquery index a protocol (ex - Uniswap v2 protocol), therefore any other exchange which is implemented this Uniswap V2, we have already indexed them. We might not be naming them, but you can get their trades using [**this API**](https://ide.bitquery.io/query/pzizr56shpq6wQrX), by simply replacing exchangeAddress with that exchange's factory address.
## Get Ethereum DEX Trades for a Liquidity Pool Contract Address
503
506
504
507
To get trades for pair tokens, you should use buy/sell; in the case of using Base/Quote, it will replicate the result.
505
-
For example, if there is a swap A <-> B, using Base/Quote, it will give two results in one A as the base currency and in another B as the quote currency.
508
+
For example, if there is a swap A < - > B, using Base/Quote, it will give two results in one A as the base currency and in another B as the quote currency.
506
509
507
510
[Open this query in IDE](https://ide.bitquery.io/Trades-for-a-pair-token-on-ethereum)
0 commit comments