Tellor Docs V2
  • The Basics
    • Welcome
    • Fundamentals
    • Contracts Overview
    • Contracts Reference
  • Getting Data
    • Introduction
    • Creating a Query
    • Reading Data
      • Tellor Playground
    • Funding a Feed
    • Tellor Functions
  • Reporting Data
    • Introduction
    • Becoming a Reporter
      • Staking / Unstaking
      • Submitting Values
    • Getting Paid
    • Setting up New Chains
  • Disputing Data
    • Introduction
    • Monitoring
    • How to Dispute
    • Voting/Resolution
  • Vulnerability Disclosure
Powered by GitBook
On this page
Edit on GitHub
  1. Getting Data

Introduction

PreviousContracts ReferenceNextCreating a Query

Last updated 2 years ago

The Tellor system allows users to request specific pieces of data, and reporters can then submit those values. Every piece of data that is requested, reported, and retrieved within the Tellor system is associated with a Query Type, Query Data, and a specific identifier, known as the Query ID.

Some quick definitions before we move on:

A Query Type is a for custom data you want to receive from the oracle. It defines the parameters of a Query that users can input for their specific requests. For example:

Query Type - SpotPrice

  1. asset

    • description: Asset ID (e.g. BTC)

    • value type: string

  2. currency

    • description: Selected currency (e.g. USD)

    • value type: string

Query Data is used to form your new Query's unique identifier, or Query ID. It's also emitted in data submission and payment contract events so Tellor users and reporters can programmatically construct query objects.

The Query ID is your Query's unique identifier and . It's required for submitting, retrieving, and paying for all data in the Tellor system.

To generate a query ID, use this simple tool:

What data do you need?

Price data

First check if the data is already being reported by viewing our .

Tellor data is free for anyone to read. This means that if someone else just updated the value, you can use it free of charge!

Need a spot price from Tellor?

  1. Generate a query ID for the asset/currency pair using

  2. Next, use that ID to to put that data on-chain.

  3. Then retrieve the reported spot price from the oracle .

Custom Data

First, check in if there's already a query type that defines the data you need.

If not, you'll need to .

Once that is done you'll need to to put that data on-chain, and retrieve that data from the Tellor oracle .

/types
specification
feeds
like this
Get A Query ID
Query ID Builder
Logo
create a new query type
pay reporters
Example of Query Data
hash of the Query Data
this tool.
pay reporters
like this