Browse Source

update config, hidden threads

Joystream Stats 3 years ago
parent
commit
37c04f641a

+ 8 - 8
scripts/joystreamtelegrambot/config.ts

@@ -1,17 +1,14 @@
 // website
-export const domain = "https://testnet.joystream.org";
+export const domain = "https://pioneer.joystreamstats.live";
 
 // websocket location
-export const wsLocation = "wss://rome-rpc-endpoint.joystream.org:9944/";
+export const wsLocation = "wss://joystreamstats.live:9945";
 
-// telegram bot token
-export const tgToken: string = "1974714706:AAHTMCCBshZOzZ-vpKlotn9k7-o03lzb0vI";
-
-export const discordToken: string =
-  "ODgyNjMwNzE1ODU3MDQzNTE2.YS-L6Q.r_NMrRZhjJoqqXk6FqFePziiRGA";
+export const discordToken = ""
+export const tgToken = "";
 
 // telegram chat ID
-export const chatid: string = "-1001298425580";
+export const chatid = "-1001438587296";
 
 // time between heartbeat announcement in milliseconds
 export const heartbeat = 60000 * 60 * 6;
@@ -20,3 +17,6 @@ export const councilStatusHeartbeat = 300000; // 86400000;
 
 // minutes between checking for proposal updates
 export const proposalDelay = 15;
+
+export const suppressedThreads = [180, 265, 275, 390]; // 180 tokens, 265 faucet, 275 pets, 390 bounty-24
+

+ 2 - 2
scripts/joystreamtelegrambot/src/lib/announcements.ts

@@ -1,3 +1,4 @@
+import { suppressedThreads } from "../../config";
 import {
   Api,
   Block,
@@ -261,8 +262,7 @@ export const posts = async (
     );
     const categoryId = thread.category_id.toNumber();
     if (categoryId === 19 || categoryId === 38) continue; // hide: 19 Media, 38 Russian
-    if ([180, 265, 275].includes(threadId)) continue;
-    // 180 tokens, 265 faucet, 275 pets
+    if (suppressedThreads.includes(threadId)) continue;
 
     const category: Category = await query("title", () =>
       categoryById(api, categoryId)