|
1 | | -# Stellar Trade Effects API |
| 1 | +--- |
| 2 | +title: Stellar Trades API |
| 3 | +description: Access comprehensive Stellar Trade API with Effects and Price |
| 4 | +slug: /blockchain/Stellar/trade-effects-api |
| 5 | +keywords: |
| 6 | + - Stellar Trade Effects API |
| 7 | + - Stellar DEX API |
| 8 | + - Stellar trading API |
| 9 | + - Stellar blockchain API |
| 10 | + - Stellar GraphQL API |
| 11 | + - Stellar trade data |
| 12 | + - Stellar token swaps |
| 13 | + - Stellar DEX trades |
| 14 | + - Stellar trading analytics |
| 15 | + - Stellar API documentation |
| 16 | + - Stellar blockchain data API |
| 17 | + - Stellar asset trading |
| 18 | + - Stellar orderbook API |
| 19 | + - Stellar liquidity pools |
| 20 | + - free stellar api |
| 21 | + - stellar data api |
| 22 | +--- |
2 | 23 |
|
3 | | -A successful trade operation will yield zero or more effects. These effects represent specific changes that occur in the ledger. |
| 24 | +# Stellar Trades API |
4 | 25 |
|
5 | 26 |
|
6 | | -## Latest Trade Effects on Stellar |
| 27 | +## What are Stellar Trade Effects? |
7 | 28 |
|
8 | | -You can run the query [here](https://ide.bitquery.io/Latest-Trade-Effects-on-Stellar) |
| 29 | +A successful trade operation on the Stellar network will yield zero or more effects. These effects represent specific changes that occur in the ledger as a result of trading activities. Trade effects capture detailed information about asset exchanges. |
| 30 | + |
| 31 | +## Getting Started |
| 32 | + |
| 33 | +New to Bitquery? Here's how to get started: |
| 34 | + |
| 35 | +1. **[Create a free account](https://ide.bitquery.io/)** - Get instant access to our GraphQL IDE |
| 36 | +2. **[Generate your Access token](https://docs.bitquery.io/docs/authorisation/how-to-generate/)** - Required for API access |
| 37 | + |
| 38 | +Need help crafting a query or subscription? Message us on [support](https://t.me/Bloxy_info). |
9 | 39 |
|
| 40 | +### Trades of a Token on Stellar |
| 41 | + |
| 42 | +This query retrieves trade effects for a specific token on the Stellar network. The `priceAmount` field represents the sell asset per buy asset ratio, providing you with accurate pricing information for each trade. |
| 43 | + |
| 44 | +**Key Features:** |
| 45 | +- Filter by buy currency name |
| 46 | +- Time range filtering |
| 47 | +- USD value conversions for both buy and sell amounts |
| 48 | +- Complete currency and issuer information |
| 49 | +- Transaction context with block and hash |
| 50 | + |
| 51 | +[Run Query](https://ide.bitquery.io/AQUA-Stellar-Trades) |
| 52 | + |
| 53 | +```graphql |
| 54 | +query { |
| 55 | + stellar(network: stellar) { |
| 56 | + tradeEffects( |
| 57 | + options: { desc: "block", asc: "transaction.index", limit: 10, offset: 0 } |
| 58 | + time: { since: "2025-11-24T01:05:00.000Z", till: "2025-11-25T13:35:00.999Z" } |
| 59 | + buyCurrencyName: { is: "AQUA [GBNZILSTVQZ4R7IKQDGHYGY2QXL5QOFJYQMXPKWRRM5PAV7Y4M67AQUA]" } |
| 60 | + ) { |
| 61 | + timestamp { |
| 62 | + time(format: "%Y-%m-%d %H:%M:%S") |
| 63 | + } |
| 64 | + block |
| 65 | + transaction { |
| 66 | + hash |
| 67 | + index |
| 68 | + } |
| 69 | + sellAmount |
| 70 | + sell_amount_usd: sellAmount(in: USD) |
| 71 | + sellCurrency { |
| 72 | + symbol |
| 73 | + name |
| 74 | + } |
| 75 | + sellIssuer { |
| 76 | + address |
| 77 | + annotation |
| 78 | + } |
| 79 | + buyAmount |
| 80 | + priceAmount |
| 81 | + buy_amount_usd: buyAmount(in: USD) |
| 82 | + buyCurrency { |
| 83 | + symbol |
| 84 | + name |
| 85 | + } |
| 86 | + buyIssuer { |
| 87 | + address |
| 88 | + annotation |
| 89 | + } |
| 90 | + } |
| 91 | + } |
| 92 | +} |
10 | 93 | ``` |
| 94 | + |
| 95 | +### Latest Trade Effects on Stellar |
| 96 | + |
| 97 | +This query retrieves the most recent trade effects on the Stellar network, providing comprehensive information about each trade including seller addresses, operation details, and complete currency information. |
| 98 | + |
| 99 | + |
| 100 | +You can run the query [here](https://ide.bitquery.io/Latest-Trade-Effects-on-Stellar) |
| 101 | + |
| 102 | +```graphql |
11 | 103 | query MyQuery { |
12 | 104 | stellar(network: stellar) { |
13 | 105 | tradeEffects( |
@@ -48,5 +140,5 @@ query MyQuery { |
48 | 140 | } |
49 | 141 | } |
50 | 142 | } |
| 143 | +``` |
51 | 144 |
|
52 | | -``` |
|
0 commit comments