Skip to content

Commit 394fca3

Browse files
authored
Merge pull request #20 from tendermint/daria/cwu
add get CwU
2 parents 74d0b1f + 8aaec99 commit 394fca3

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,10 @@ npm run start
8080

8181
**200**: Returns a list of Events
8282

83+
### GET `/cwu`
84+
85+
**200**: Returns a list of CwU
86+
8387
### GET `/coingecko-cosmos-marketcap`
8488

8589
**200**: Returns the value of total market cap of Cosmos projects using Coingecko API

src/index.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,20 @@ app.get("/events", async (req, res) => {
215215
});
216216
});
217217

218+
app.get("/cwu", async (req, res) => {
219+
const airtable = new Airtable({ apiKey: AIRTABLE_API_KEY })
220+
.base("appGq4J4B7aGj2d3P")
221+
.table("cwu");
222+
223+
airtable
224+
.list({
225+
maxRecords: 1000,
226+
})
227+
.then((response) => {
228+
res.send(response);
229+
});
230+
});
231+
218232
app.get("/coingecko-cosmos-marketcap", cache.serve(30), async (req, res) => {
219233
const data = [
220234
"cosmos",

0 commit comments

Comments
 (0)