Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

94 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rewards Eligibility Oracle

Deciding who is eligible for indexing rewards on The Graph

CI Latest release Contract Dashboard

At a glance | How it works | What is measured | Check your status | When requirements change | On chain | Questions


This oracle decides which indexers on The Graph are eligible for indexing rewards, and records that decision on chain. Once a day it reviews the queries each indexer answered, works out who meets the published requirements, and renews eligibility for those addresses in the RewardsEligibilityOracle contract on Arbitrum One.

If you run an indexer, this repository is where you find out what is being measured, what the requirements currently are, when they are going to change, and how to check where you stand.


At a glance

Question Answer
When the oracle runs Every day at 10:00 UTC
What the oracle looks at The queries your indexer served over a rolling window
What the requirements are See the ELIGIBILITY_CRITERIA.md
Where the decision is recorded RewardsEligibilityOracle on Arbitrum One
How to see your status The Foundation dashboard for a quick look, the contract for the definitive answer

How eligibility works

Eligibility is granted for a fixed period rather than permanently. Every day the oracle renews eligibility for each indexer that still meets the eligibility requirements, so while you keep qualifying your eligibility keeps rolling forward.

flowchart LR
    A["Your indexer<br/>serves queries"] --> B["10:00 UTC<br/>the oracle reviews<br/>the rolling window"]
    B --> C{"Requirements<br/>met?"}
    C -->|Yes| D["Eligibility renewed<br/>on chain"]
    C -->|No| E["Current period<br/>runs to its end"]
    D --> F["You stay marked<br/>eligible"]
    E --> G["You stop being marked<br/>eligible until you requalify"]
    F --> A
    G --> A
Loading

If you stop qualifying, your eligibility is not revoked on the spot. Your current period runs to its end without being renewed, and from then on you are no longer marked eligible until you qualify again. A change to the requirements works the same way: it does not cut short a period that has already been granted to you.


Check where you stand

The Graph Foundation publishes a dashboard listing every indexer and their current status. Search it by address or ENS name to find yourself, and it will show whether you are currently eligible, when you were last renewed, and how much of that renewal is left. Adding ?indexer=0x... to the URL opens a single indexer directly. It is the quickest way to check, though the contract rather than the dashboard is the source of truth.

To go straight to the source, open the Read as Proxy tab on Arbiscan and call:

Call What it tells you
isEligible(your address) Whether the contract considers you eligible right now
getEligibilityRenewalTime(your address) The Unix timestamp of your most recent renewal, or 0 if you have never been renewed
getEligibilityPeriod() How long a single renewal lasts, in seconds
getEligibilityValidation() Whether the contract is enforcing eligibility at all

Your current period ends at your renewal time plus the eligibility period. Every time the oracle renews you, that clock restarts.

The same checks from a terminal

Using Foundry:

CONTRACT=0x02753BaE61C08AbD4351Bce7F48524935C2Cc78E
RPC=https://arb1.arbitrum.io/rpc
YOU=0xYourIndexerAddress

cast call $CONTRACT "isEligible(address)(bool)" $YOU --rpc-url $RPC
cast call $CONTRACT "getEligibilityRenewalTime(address)(uint256)" $YOU --rpc-url $RPC
cast call $CONTRACT "getEligibilityPeriod()(uint256)" --rpc-url $RPC

When the requirements change

flowchart LR
    A["Change published under<br/>Upcoming Criteria"] --> B["Notice period<br/>time to adjust"] --> C["New requirements<br/>go live"]
Loading

Planned changes are published under Upcoming Eligibility Criteria before they take effect, with a notice period between the announcement and the change going live so there is time to adjust. Changes are announced through official channels as well, so you do not have to watch this repository to hear about them.

Every past change is recorded in the changelog at the end of that same document, which lets you work out which requirements applied on any given date.


Where eligibility is recorded

Every renewal is written to the contract, so who was marked eligible, and when, is public and permanent.

Network Chain ID Contract
Arbitrum One 42161 0x02753BaE61C08AbD4351Bce7F48524935C2Cc78E
Arbitrum Sepolia 421614 0x62c2305739CC75f19a3A6d52387CEb3690D99A99

Common questions

I have just started indexing. When can I become eligible?

As soon as you have accumulated enough active days inside the rolling window. The window and the number of days are in ELIGIBILITY_CRITERIA.md. The first daily run after you meet the requirements will mark you eligible.

I stopped serving queries. When do I lose eligibility?

Not straight away. Your last renewal stands until it expires, which is the renewal timestamp plus the eligibility period. Both values are readable on the contract, so you can work out the exact moment.

Why does isEligible say true when I have never been renewed?

Because enforcement is switched off. While getEligibilityValidation reads false, the contract answers true for every address, whether the oracle has ever renewed it or not.

The requirements changed while I was eligible. Am I cut off?

No. A period that has already been granted to you runs its full course. The new requirements apply from your next renewal onwards.

Which of my queries count?

Only the query attempts the network recorded as routed to your indexer, and among those, only the ones that met every quality bar at the same time. Response code, response time and distance behind chainhead are all judged on the same query.


Working on the oracle itself

How the service is built, and how it behaves when an RPC provider fails, are described in the technical design document.


License

License information to be determined.

About

Rewards Eligibility Oracle (REO) for The Graph Protocol. The REO evaluates indexer performance and, in a future update, will manage indexer eligibility for indexing rewards. A convenient visual dashboard has been provided by The Graph Foundation, linked here for easy access 👇. Note, the source of truth is the REO contract, not the dashboard.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages