# GraphQL Tutorials

**URL:** https://community.bitquery.io/c/tutorials/6.md

[Latest](https://community.bitquery.io/latest.md) · [Categories](https://community.bitquery.io/categories.md) · [Tags](https://community.bitquery.io/tags.md)

---

## [About the GraphQL Tutorials category](https://community.bitquery.io/t/about-the-graphql-tutorials-category/116)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.bitquery.io/u/gaurav)\
**Replies:** 0

</div>

---

## [How to get started with Bitquery's Blockchain GraphQL APIs?](https://community.bitquery.io/t/how-to-get-started-with-bitquerys-blockchain-graphql-apis/13)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.bitquery.io/u/gaurav)\
**Replies:** 2\
**Last updated:** [December 24, 2024, 11:29am UTC](https://community.bitquery.io/t/how-to-get-started-with-bitquerys-blockchain-graphql-apis/13 "2024-12-24T11:29:49Z")

</div>

Note: GraphQL API = GraphQL Query (We use these terms interchangeably.) V1 docs - https://docs.bitquery.io/v1/ V2 Docs - https://docs.bitquery.io/ Difference between v1 and v2 - Difference between Bitquery GraphQL V1…

---

## [Working Java-Sample for SUBSCRIBING to Bitquery with/without Parameters](https://community.bitquery.io/t/working-java-sample-for-subscribing-to-bitquery-with-without-parameters/1613)

<div class="topic-metadata">

**Author:** [@Reinhard2500](https://community.bitquery.io/u/Reinhard2500)\
**Replies:** 0\
**Last updated:** [August 18, 2023, 11:43am UTC](https://community.bitquery.io/t/working-java-sample-for-subscribing-to-bitquery-with-without-parameters/1613 "2023-08-18T11:43:42Z")

</div>

// In order to get it up and running, you will have to include quite a lot of .JARs in your pom.xml // THIS is working in a correct way. // https://docs.bitquery.io/docs/graphql/subscription/websockets/ // The only prob…

---

## [Getting Top Gainers & Losers with Bitquery API](https://community.bitquery.io/t/getting-top-gainers-losers-with-bitquery-api/1479)

<div class="topic-metadata">

**Author:** [@Omkar](https://community.bitquery.io/u/Omkar)\
**Replies:** 2\
**Last updated:** [February 6, 2025, 11:38pm UTC](https://community.bitquery.io/t/getting-top-gainers-losers-with-bitquery-api/1479 "2025-02-06T23:38:15Z")

</div>

In this tutorial, we will explore how to calculate the top gainers and losers in pair trading using the Bitquery API. We’ll explain the method used for determining the performance of trading pairs and show you how to con…

---

## [How to Subscribe to Real-Time Data Stream using Bitquery API and Python GraphQL Client](https://community.bitquery.io/t/how-to-subscribe-to-real-time-data-stream-using-bitquery-api-and-python-graphql-client/1431)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 6\
**Last updated:** [January 6, 2025, 7:10am UTC](https://community.bitquery.io/t/how-to-subscribe-to-real-time-data-stream-using-bitquery-api-and-python-graphql-client/1431 "2025-01-06T07:10:44Z")

</div>

Step 1: Import required libraries from python\_graphql\_client import GraphqlClient import asyncio This code block imports the GraphqlClient library and asyncio for asynchronous operations. Step 2: Set up the OAuth toke…

---

## [Build Discord Bot using Bitquery APIs](https://community.bitquery.io/t/build-discord-bot-using-bitquery-apis/172)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.bitquery.io/u/gaurav)\
**Replies:** 0\
**Last updated:** [June 14, 2021, 12:08pm UTC](https://community.bitquery.io/t/build-discord-bot-using-bitquery-apis/172 "2021-06-14T12:08:44Z")

</div>

Today we will create a Discord bot that provides the user with the updated price of CAKE/USDT using Bitquery APIs. Discord offers free VoIP, text, and video chat servers, along with unique features for gamers like Twitc…

---

## [Questions about bitquery tutoirals](https://community.bitquery.io/t/questions-about-bitquery-tutoirals/2071)

<div class="topic-metadata">

**Author:** [@franbo](https://community.bitquery.io/u/franbo)\
**Replies:** 1\
**Last updated:** [September 10, 2024, 10:00am UTC](https://community.bitquery.io/t/questions-about-bitquery-tutoirals/2071 "2024-09-10T10:00:35Z")

</div>

Hi guys: I have read the v2 docs several times, but still have some questions about bitquery tutorials. I hope some specialists can offer me some help. Take the query below as an example. The ‘Transfer’ is called c…

---

## [How to get started with Bitquery’s Blockchain GraphQL APIs?](https://community.bitquery.io/t/how-to-get-started-with-bitquery-s-blockchain-graphql-apis/1963)

<div class="topic-metadata">

**Author:** [@akshat.bitquery](https://community.bitquery.io/u/akshat.bitquery)\
**Replies:** 0\
**Last updated:** [June 19, 2024, 5:13pm UTC](https://community.bitquery.io/t/how-to-get-started-with-bitquery-s-blockchain-graphql-apis/1963 "2024-06-19T17:13:15Z")

</div>

Note: GraphQL API = GraphQL Query (We use these terms interchangeably.) V1 docs - https://docs.bitquery.io/v1/ V2 Docs - https://docs.bitquery.io/ Difference between v1 and v2 - Difference between Bitquery GraphQL V1…

---

## [Could you provide the API to give me the price of a token?](https://community.bitquery.io/t/could-you-provide-the-api-to-give-me-the-price-of-a-token/1945)

<div class="topic-metadata">

**Author:** [@Vishal](https://community.bitquery.io/u/Vishal)\
**Replies:** 0\
**Last updated:** [May 29, 2024, 10:06am UTC](https://community.bitquery.io/t/could-you-provide-the-api-to-give-me-the-price-of-a-token/1945 "2024-05-29T10:06:51Z")

</div>

To get the latest token price, we need to find the most recent trade of a given token against a specific token. By analyzing the latest trade, we can determine the current price of the token. For example, using the foll…

---

## [Is it possible to monitor all the blockchain events?](https://community.bitquery.io/t/is-it-possible-to-monitor-all-the-blockchain-events/1944)

<div class="topic-metadata">

**Author:** [@Vishal](https://community.bitquery.io/u/Vishal)\
**Replies:** 0\
**Last updated:** [May 29, 2024, 9:43am UTC](https://community.bitquery.io/t/is-it-possible-to-monitor-all-the-blockchain-events/1944 "2024-05-29T09:43:58Z")

</div>

If you are interested in monitoring all the events and associated arguments, then kick off all your problems using the Bitquery subscription API. Bitquery API helps you catch all the real-time events of any blockchain. L…

---

## [How to track all coins and tokens that are deployed to BSC?](https://community.bitquery.io/t/how-to-track-all-coins-and-tokens-that-are-deployed-to-bsc/1943)

<div class="topic-metadata">

**Author:** [@Vishal](https://community.bitquery.io/u/Vishal)\
**Replies:** 0\
**Last updated:** [May 29, 2024, 9:32am UTC](https://community.bitquery.io/t/how-to-track-all-coins-and-tokens-that-are-deployed-to-bsc/1943 "2024-05-29T09:32:30Z")

</div>

The Bitquery API tracks all the coins in a given network within seconds. For instance, using the Bitquery API, we discovered 1,582,917 tokens were deployed on the BSC network until May 28, 2024. API link Tokens ( coins…

---

## [OHLC in Streaming APIs](https://community.bitquery.io/t/ohlc-in-streaming-apis/1513)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.bitquery.io/u/gaurav)\
**Replies:** 2\
**Last updated:** [May 1, 2024, 7:19am UTC](https://community.bitquery.io/t/ohlc-in-streaming-apis/1513 "2024-05-01T07:19:17Z")

</div>

Please check the following query, which provides real-time OHLC data in streaming APIs. { EVM(dataset: realtime) { DEXTradeByTokens( orderBy: {ascendingByField: "Block\_Time"} where: {Trade: {Side: {C…

---

## [جهت بازیابی توکنهای سرقت شده چه باید کرد](https://community.bitquery.io/t/topic/1884)

<div class="topic-metadata">

**Author:** [@Majid](https://community.bitquery.io/u/Majid)\
**Replies:** 0\
**Last updated:** [April 22, 2024, 8:03am UTC](https://community.bitquery.io/t/topic/1884 "2024-04-22T08:03:39Z")

</div>

رفیق من نمیدونم چطور باید بازیابی کنم تمام کیف پول خود به خود ناپدید شدند وقتی پیگیر شدم دیدم یک ادرس وارد کیف پول شده واز تمام ارزهای کیف پول برداشت کرده

---

## [MarketCap of a Token](https://community.bitquery.io/t/marketcap-of-a-token/117)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.bitquery.io/u/gaurav)\
**Replies:** 3\
**Last updated:** [February 12, 2024, 6:15pm UTC](https://community.bitquery.io/t/marketcap-of-a-token/117 "2024-02-12T18:15:33Z")

</div>

Let’s say if you want the Marketcap of a Binance Smart Chain token (BSC token) or Etheruem token or any other chain token. Here are the steps 1- Get total Supply 2- Getting Latest Price Getting the Total supply of a…

---

## [How to create a real-time blockchain data app in React](https://community.bitquery.io/t/how-to-create-a-real-time-blockchain-data-app-in-react/1480)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [May 8, 2023, 10:08am UTC](https://community.bitquery.io/t/how-to-create-a-real-time-blockchain-data-app-in-react/1480 "2023-05-08T10:08:44Z")

</div>

We will build a React application that fetches data from Bitquery using a WebSocket connection to a GraphQL server and displays the retrieved data in a list. Let’s create a react an empty application using npx create-r…

---

## [Utilizing Bitquery's Blockchain Data with Amazon Athena: A Comprehensive Guide](https://community.bitquery.io/t/utilizing-bitquerys-blockchain-data-with-amazon-athena-a-comprehensive-guide/1782)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [December 13, 2023, 6:35am UTC](https://community.bitquery.io/t/utilizing-bitquerys-blockchain-data-with-amazon-athena-a-comprehensive-guide/1782 "2023-12-13T06:35:14Z")

</div>

Bitquery offers a rich repository of blockchain data, enabling developers to access and analyze information from various blockchains. This tutorial will guide you through leveraging Bitquery’s blockchain data with Amazo…

---

## [Websocket in Javascript](https://community.bitquery.io/t/websocket-in-javascript/1772)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [December 1, 2023, 4:34pm UTC](https://community.bitquery.io/t/websocket-in-javascript/1772 "2023-12-01T16:34:44Z")

</div>

const { WebSocket, WebSocketServer } = require("ws"); const BQ\_API\_KEY = 'keyy'; const BITQUERY\_WS\_URL = "wss://streaming.bitquery.io/graphql"; const bitqueryConnection = new WebSocket(BITQUERY\_WS\_URL, \["graphql-ws"\],…

---

## [Getting token related data such as Marketcap, price, volume, price change](https://community.bitquery.io/t/getting-token-related-data-such-as-marketcap-price-volume-price-change/822)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.bitquery.io/u/gaurav)\
**Replies:** 1\
**Last updated:** [September 18, 2023, 9:27am UTC](https://community.bitquery.io/t/getting-token-related-data-such-as-marketcap-price-volume-price-change/822 "2023-09-18T09:27:43Z")

</div>

We will try to get the following data for a token - Price Marketcap Volume Volume 24h Circulating supply 1H % Change 24H Change 7D Change No. of Holders Price To get the price you need to get the latest trade …

---

## [NFT API - Complete Guide](https://community.bitquery.io/t/nft-api-complete-guide/1509)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [May 30, 2023, 1:12pm UTC](https://community.bitquery.io/t/nft-api-complete-guide/1509 "2023-05-30T13:12:24Z")

</div>

NFT Ownership API Owners of an NFT Top Holders of an NFT NFT Transfer API Latest Transfers of an NFT Latest NFT transfers from and to an User Subscribing to Realtime NFT Transfers NFT Calls API Latest Calls for …

---

## [How to access blockchain data from AWS S3 - Parquet Format](https://community.bitquery.io/t/how-to-access-blockchain-data-from-aws-s3-parquet-format/1630)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [August 29, 2023, 12:27pm UTC](https://community.bitquery.io/t/how-to-access-blockchain-data-from-aws-s3-parquet-format/1630 "2023-08-29T12:27:45Z")

</div>

Bitquery earlier introduced our new offering “Blockchain Data on the Cloud” where you can have any blockchain data uploaded to AWS. In the previous article we saw how to extract blockchain data from AWS S3 buckets where…

---

## [Introducing Expressions in GraphQL Queries](https://community.bitquery.io/t/introducing-expressions-in-graphql-queries/1322)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 1\
**Last updated:** [August 23, 2023, 5:38pm UTC](https://community.bitquery.io/t/introducing-expressions-in-graphql-queries/1322 "2023-08-23T17:38:50Z")

</div>

One of the core missions of Bitquery is to provide better accessibility to blockchain data. Therefore we choose GraphQL to provide control to developers pulling data through our APIs. We continue to make the GraphQL int…

---

## [GraphQL: BTC input address and output amount in one query](https://community.bitquery.io/t/graphql-btc-input-address-and-output-amount-in-one-query/1585)

<div class="topic-metadata">

**Author:** [@phwulf](https://community.bitquery.io/u/phwulf)\
**Replies:** 1\
**Last updated:** [July 31, 2023, 2:24pm UTC](https://community.bitquery.io/t/graphql-btc-input-address-and-output-amount-in-one-query/1585 "2023-07-31T14:24:31Z")

</div>

Hi, sorry, absolute beginner here. I’m looking for a way to combine a specific input address with an output amount (range) in one GraphQL query. What I have: one specific given input address, the date and the output a…

---

## [How to Use Bitquery APIs in Google Apps Script](https://community.bitquery.io/t/how-to-use-bitquery-apis-in-google-apps-script/1582)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [July 31, 2023, 8:33am UTC](https://community.bitquery.io/t/how-to-use-bitquery-apis-in-google-apps-script/1582 "2023-07-31T08:33:57Z")

</div>

In this tutorial, we will see how to run a script on Google Apps Script, which is a lightweight tool to run scripts. When it comes to building dApps on blockchain data, Google Apps Script with Bitquery APIs can be a powe…

---

## [Bitquery Trace API](https://community.bitquery.io/t/bitquery-trace-api/1556)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [July 7, 2023, 4:24pm UTC](https://community.bitquery.io/t/bitquery-trace-api/1556 "2023-07-07T16:24:34Z")

</div>

What is Ethereum Trace? An EVM(Ethereum Virtual Machine) trace is a detailed record of the steps taken by the Ethereum Virtual Machine (EVM) to execute a transaction. It includes information such as the gas used, the res…

---

## [Everything you need to know about Tron](https://community.bitquery.io/t/everything-you-need-to-know-about-tron/595)

<div class="topic-metadata">

**Author:** [@aman](https://community.bitquery.io/u/aman)\
**Replies:** 4\
**Last updated:** [July 3, 2023, 12:27pm UTC](https://community.bitquery.io/t/everything-you-need-to-know-about-tron/595 "2023-07-03T12:27:36Z")

</div>

TRON is a decentralized, open-source blockchain-based operating system. It provides a decentralized virtual machine, which can execute a program using an international network of public nodes. The network has zero transa…

---

## [How to Cancel Bitquery Subscription?](https://community.bitquery.io/t/how-to-cancel-bitquery-subscription/1531)

<div class="topic-metadata">

**Author:** [@Omkar](https://community.bitquery.io/u/Omkar)\
**Replies:** 0\
**Last updated:** [June 19, 2023, 5:40am UTC](https://community.bitquery.io/t/how-to-cancel-bitquery-subscription/1531 "2023-06-19T05:40:38Z")

</div>

If you want to cancel your subscription, here’s what you need to do: Login to your account Head over to the billing page. Look for the “Cancel Subscription” option. Click on it. That’s it! You’re all set. Rememb…

---

## [How To Use Bitquery With OpenBB Terminal](https://community.bitquery.io/t/how-to-use-bitquery-with-openbb-terminal/1149)

<div class="topic-metadata">

**Author:** [@bitquery-support](https://community.bitquery.io/u/bitquery-support)\
**Replies:** 1\
**Last updated:** [June 15, 2023, 10:59am UTC](https://community.bitquery.io/t/how-to-use-bitquery-with-openbb-terminal/1149 "2023-06-15T10:59:28Z")

</div>

How To Use Bitquery With OpenBB Terminal ▶ Table of Contents How to Sign up On Bitquery If you already have a Bitquery account, you can skip this step. To create an account you will have to go to Bitquery IDE and click…

---

## [Top tokens based on Token holders](https://community.bitquery.io/t/top-tokens-based-on-token-holders/1514)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.bitquery.io/u/gaurav)\
**Replies:** 0\
**Last updated:** [June 5, 2023, 11:24am UTC](https://community.bitquery.io/t/top-tokens-based-on-token-holders/1514 "2023-06-05T11:24:11Z")

</div>

The following queries provide top tokens based on holders. Top Token based on holders (All tokens) { EVM(network: eth, dataset: combined) { BalanceUpdates( where: {Currency: {SmartContract: {not: "0x69e37422…

---

## [Exporting account transactions as a CSV file](https://community.bitquery.io/t/exporting-account-transactions-as-a-csv-file/968)

<div class="topic-metadata">

**Author:** [@mbajpai](https://community.bitquery.io/u/mbajpai)\
**Replies:** 2\
**Last updated:** [May 23, 2023, 2:23pm UTC](https://community.bitquery.io/t/exporting-account-transactions-as-a-csv-file/968 "2023-05-23T14:23:33Z")

</div>

Velas is an AI-powered delegated Proof-of-Stake (AIDPOS) which claims to have the capacity to process 50k+ t/ps without giving way to security or decentralization applications. It is a project that combines blockchain an…

---

## [Build a tradingview chart app for blockchain data](https://community.bitquery.io/t/build-a-tradingview-chart-app-for-blockchain-data/1491)

<div class="topic-metadata">

**Author:** [@Divya](https://community.bitquery.io/u/Divya)\
**Replies:** 0\
**Last updated:** [May 18, 2023, 12:57pm UTC](https://community.bitquery.io/t/build-a-tradingview-chart-app-for-blockchain-data/1491 "2023-05-18T12:57:46Z")

</div>

This tutorial will help you build a TradingView chart app with blockchain data from Bitquery. Price Index for DEX Tokens The tutorial uses the token ADVT, which is not traded against USDT. As a result, we obtain the WET…

[Next page](https://community.bitquery.io/c/tutorials/6.md?page=1)
