@@ -41,28 +41,63 @@ This subgraph is deployed under `/subgraphs/name/oceanprotocol/ocean-subgraph/`
41
41
42
42
``` graphql
43
43
{
44
- pools (orderBy : oceanReserve , orderDirection : desc ) {
45
- consumePrice
46
- datatokenReserve
47
- oceanReserve
48
- spotPrice
49
- swapFee
50
- transactionCount
44
+ pools (orderBy : baseTokenLiquidity , orderDirection : desc ) {
45
+ id
46
+ datatoken {
47
+ address
48
+ }
49
+ baseToken {
50
+ symbol
51
+ }
52
+ baseTokenLiquidity
53
+ datatokenLiquidity
51
54
}
52
55
}
53
56
```
54
57
55
- ** All datatokens **
58
+ ** Pools with the highest liquidity **
56
59
57
60
``` graphql
58
61
{
59
- datatokens (orderBy : createTime , orderDirection : desc ) {
60
- address
62
+ pools (where : {datatokenLiquidity_gte : 1 }, orderBy : baseTokenLiquidity , orderDirection : desc , first : 15 ) {
63
+ id
64
+ datatoken {
65
+ address
66
+ }
67
+ baseToken {
68
+ symbol
69
+ }
70
+ baseTokenLiquidity
71
+ datatokenLiquidity
72
+ }
73
+ }
74
+ ```
75
+
76
+ ** All Data NFTs**
77
+
78
+ ``` graphql
79
+ {
80
+ nfts (orderBy : createdTimestamp , orderDirection : desc , first : 1000 ){
81
+ id ,
82
+ symbol ,
83
+ name ,
84
+ creator ,
85
+ createdTimestamp
86
+ }
87
+ }
88
+ ```
89
+
90
+ > Note: 1000 is the maximum number of items the subgraph can return.
91
+
92
+ ** All Datatokens**
93
+
94
+ ``` graphql
95
+ {
96
+ tokens (where : {isDatatoken : true }, orderBy : createdTimestamp , orderDirection : desc , first : 1000 ) {
97
+ id
61
98
symbol
62
99
name
63
- cap
64
- supply
65
- publisher
100
+ address
66
101
holderCount
67
102
}
68
103
}
@@ -72,19 +107,71 @@ This subgraph is deployed under `/subgraphs/name/oceanprotocol/ocean-subgraph/`
72
107
73
108
``` graphql
74
109
{
75
- poolTransactions (
76
- where : { userAddressStr : $userAddress }
77
- orderBy : timestamp
78
- orderDirection : desc
79
- ) {
80
- poolAddressStr
110
+ poolTransactions (
111
+ orderBy : timestamp
112
+ orderDirection : desc
113
+ where : { user : $user }
114
+ first : 1000
115
+ ) {
116
+ baseToken {
117
+ symbol
118
+ address
119
+ }
120
+ baseTokenValue
121
+ datatoken {
122
+ symbol
123
+ address
124
+ }
125
+ datatokenValue
126
+ type
127
+ tx
128
+ timestamp
129
+ pool {
130
+ datatoken {
131
+ id
132
+ }
133
+ id
134
+ }
135
+ }
81
136
}
82
- }
83
137
```
84
138
85
- > Note: all ETH addresses like ` $userAddress ` in above example need to be passed in lowercase.
139
+ > Note: all ETH addresses like ` $user ` in above example need to be passed as a lowercase string .
86
140
141
+ ** All pool transactions for a given user in an individual pool**
142
+
143
+ ``` graphql
144
+ {
145
+ poolTransactions (
146
+ orderBy : timestamp
147
+ orderDirection : desc
148
+ where : { pool : $pool , user : $user }
149
+ first : 1000
150
+ ) {
151
+ baseToken {
152
+ symbol
153
+ address
154
+ }
155
+ baseTokenValue
156
+ datatoken {
157
+ symbol
158
+ address
159
+ }
160
+ datatokenValue
161
+ type
162
+ tx
163
+ timestamp
164
+ pool {
165
+ datatoken {
166
+ id
167
+ }
168
+ id
169
+ }
170
+ }
171
+ }
172
+ ```
87
173
174
+ > Note: all ETH addresses like ` $pool ` and ` $user ` in above example need to be passed as a lowercase string.
88
175
89
176
## 🏊 Development on Barge
90
177
0 commit comments