-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #33 from tetu-io/dev-ruby
Added check tetubal balances from subgraph
- Loading branch information
Showing
11 changed files
with
11,959 additions
and
10,291 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
TETU_MATIC_RPC_URL=https://polygon-mainnet.g.alchemy.com/v2/key | ||
TETU_PRIVATE_KEY=deployer_key | ||
TETU_NETWORK_SCAN_KEY=key | ||
TETU_SUBGRAPH_URL=https://api.thegraph.com/subgraphs/name/alexandersazonof/tetubal | ||
TETU_VALIDATE_USER_BALANCE_ON_CHAIN=true | ||
TETU_VALIDATE_TOTAL_SUPPLY=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,3 +23,4 @@ core_addresses.txt | |
tool_addresses.txt | ||
.env | ||
docs | ||
generated |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"name": "TetuGame GraphQL Schema", | ||
"schemaPath": "schema.graphql", | ||
"extensions": { | ||
"endpoints": { | ||
"Default GraphQL Endpoint": { | ||
"headers": { | ||
"user-agent": "JS GraphQL" | ||
}, | ||
"introspect": false, | ||
"url": "https://api.thegraph.com/subgraphs/name/alexandersazonof/tetubal" | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
documents: ./gql/*.graphql | ||
generates: | ||
./generated/gql.ts: | ||
plugins: | ||
- typescript | ||
- typescript-operations | ||
config: | ||
immutableTypes: true | ||
addExplicitOverride: true | ||
strictScalars: true | ||
scalars: | ||
BigDecimal: string | ||
BigInt: string | ||
Bytes: string | ||
Int8: number | ||
schema: https://api.thegraph.com/subgraphs/name/alexandersazonof/tetubal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
query GetUserBalanceByBlock($userAdr: String!, $block: BigInt!) { | ||
userBalanceHistoryEntities( | ||
where:{ | ||
user: $userAdr | ||
blockNumber_lte: $block | ||
} | ||
first: 1 | ||
orderBy: blockNumber | ||
orderDirection: desc | ||
) { | ||
balance | ||
blockNumber | ||
} | ||
} |
Oops, something went wrong.