flipsidecrypto⚡️ LQ / Bitquery LiveQuery Function Guide
Updated 2023-07-25
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
›
⌄
-- Bitquery 🤝 Flipside LiveQuery Function Guide
-------------------------------------------------------------------------
-- Real-time & historical blockchain data via GraphQl APIs. Bitquery's
-- LiveQuery integration enables you to issue graphql queries directly
-- in SQL to all of Bitquery's curated data sets.
-- -----------------------------------------------------------------
-- 🚨 WARNING 🚨
-- To run these examples you must associate your Bitquery API Key
-- with your Flipside Account here:
-- https://flipsidecrypto.xyz/livequery/bitquery
-- ======================================================================
--
-- ⚡️ Bitquery Functions
-- schema: `bitquery`
-- function docs: https://docs.bitquery.io/
--
-- ======================================================================
--
-- #️⃣ bitquery.graphql
-- (https://ide.bitquery.io/explore/All%20queries)
--
SELECT
bitquery.graphql({
'query': '{
ethereum( network: bsc ) {
dexTrades(
options: {limit: 1}
baseCurrency: {is: "0x6679eB24F59dFe111864AEc72B443d1Da666B360"}
quoteCurrency: {is: "0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c"}
) {
buyAmount
buyAmountInUsd: buyAmount(in: USD)
buyCurrency {
Run a query to Download Data