#topgg-api

1 messages · Page 72 of 1

wide aspen
#

    var request = require('request');
    request('https://cortex-genel.glitch.me/api/cortex', function (response, body) {
       var cortexg = JSON.parse(body);
      
      ```
green mantle
#

@wide aspen that is not related to DBL API IIRC

wide aspen
#

ok ay

hoary minnow
#

dbl python lib requires aiohttp below 3.6.0, but discord.py requires 3.6.0 minimum

#

slight conflict there

sullen nymph
#

install from source for now

hoary minnow
#

alrighty

restive otter
#

Hey im just wondering, how would I handle the webhook when my bot is sharded

runic grove
#

in a different process (this could be your sharding manager process)

restive otter
#

previously i had a simple

const DBL = require('dblapi.js');
const dbl = new DBL('token', {webhookPort: 3000, webhookAuth: 'token')

but now that wont work because if every shard did that itd get errors with the port.

How can I make just one shard handle it HmmmWeeb or where else would I handle it. using discord.js btw h_lurk

runic grove
#

are you using internal sharding

restive otter
#
const Discord = require('discord.js');
const manager = new Discord.ShardingManager('./bot.js')

manager.spawn(3);
manager.on('launch', shard => {
    console.log(`Launched shard ${shard.id} now`)
})

is my shard manager

runic grove
#

okay yeah

#

you could set up the webhook in that shardingmanager

restive otter
#

and then how could I like. make the client send something to people who voted

runic grove
#

is that stable or master

restive otter
#

idek

#

shrugg idk wha im doing or what that means

#

but its discordjs v11.5.1-dev or something i thinkk

runic grove
#

do you want to send a dm to the user who voted

restive otter
#

yep

#

basically just need to be able to send something to the user and thats all id need

runic grove
#

oh wait

#

ignore that

#

you could use <Shard>.send() to make one of your shards dm the user

restive otter
#

ill give it a try

#

thx Love

#

ye no i have no idea how id send something to a specific shard and how to then receive that. google aint helping

inland spindle
#

still doesnt work

#

halp

obsidian tide
#

@inland spindle few questions

  1. did you download the npm?
inland spindle
#

yep

obsidian tide
#
const dbltoken = "DBL TOKEN"
const dblport = 80
const dblpassword = "enter password here"

const DBL = require('dblapi.js');
const dbl = new DBL(dbltoken, { webhookPort: dblport, webhookAuth: dblpassword });

dbl.webhook.on('ready', hook => {
  console.log(`Webhook running at http://${hook.hostname}:${hook.port}${hook.path}`);
});
dbl.webhook.on('vote', vote => {
  console.log(`User with ID ${vote.user} just voted!`);
});
#

use that

inland spindle
#

excuse my sillyness but whats dbl pass? @obsidian tide

obsidian tide
#

so where's ur bot page?

#

there should be a edit button

#

scroll down

#

and then you can add your webhook AND password

#

so you can make ur password anything u want

#

i reccomend a secure password

#

like completely random

inland spindle
#

so I only need to edit dblpassword at top right

#

btw does this code count server

past sky
#

No

obsidian tide
#

no

#

let me find code to post server

#

i put this in a eval cmd constantly dbl.postStats(client.guilds.size)

#

if u put it in some loop when u connect to the dbl server, u might be able to make auto post

inland spindle
obsidian tide
#

u dont put it there

#

if u do, u have to make an autopost loop

#

what's , client);

#

@inland spindle ^

inland spindle
#

got the code from documentation website

obsidian tide
#

...

#

here's a simple way to sperate the dbl code

#
  1. delete all the current dbl code u did
#
  1. make a file called "dbl.js" (same direction as bot.js/server.js)
#
  1. add require("./dbl.js") in your code (usually at the top)
#
  1. add this to dbl.js
const dbltoken = "DBL TOKEN"
const dblport = 80
const dblpassword = "enter password here"

const DBL = require('dblapi.js');
const dbl = new DBL(dbltoken, { webhookPort: dblport, webhookAuth: dblpassword });

dbl.webhook.on('ready', hook => {
  console.log(`Webhook running at http://${hook.hostname}:${hook.port}${hook.path}`);
});
dbl.webhook.on('vote', vote => {
  console.log(`User with ID ${vote.user} just voted!`);
});
#

ofc change the vars of dbltoken, dblport and dblpassword

#

if you are using glitch.com which im assuming u are because of the formatting colors, change dblport = process.env.PORT

#

dblpassword can be anything, but you need to also set the same pass in the dbl website using the edit button in ur bot page

inland spindle
#

Thanks

#

lemme do it

obsidian tide
#

k

frigid shore
restive otter
#

Your dbltoken is right?

frigid shore
#

yes

harsh stream
#

The dbl token is not the same as the bot token

restive otter
#

how can i give user who vote a credits ! like probot

i tried this but there's nothing in console 😕

dbl.on('vote', async vote => {
  console.log(vote);
})
frigid shore
#

where is the webhook's password??

#

if i create server

#

where is password?

clever rock
#

ok I'll make this easy and brainless to make you understand
Webhook URL is your server ip:port of where a webserver will receive the vote.
Webook Auth is your webhook password of your choice 200x emphasis on of your choice
@frigid shore

frigid shore
#

@clever rock thanks, i already understood

#

but i have a problem

clever rock
#

if you receive no votes

#

make sure to configure your firewall

#

or portforward properly if hosted on home

frigid shore
#
const app = express();
const server = http.createServer(app);
const dbl = new DBL('token', { webhookAuth: 'password', webhookServer: server });
console.log(dbl.webhook);
dbl.webhook.on('ready', hook => {
  console.log(`Webhook running with path ${hook.path}`);
});
dbl.webhook.on('vote', vote => {
  console.log(`User with ID ${vote.user} just voted!`);
});
#

it doesnt work

#

oh

#

i didnt save

#

my progect

#

😄

harsh stream
#

make sure the webhook URL on your bot page is correct

#

and save your stuff before testing it n_facepalm

frigid shore
#

how to get ip of my server? coolstory

clever rock
#

thats something you can google

#

that already falls into too much spoonfeeding category

frigid shore
#

i created server, but i cant see its ip :(

harsh stream
#

if you got a VPS then the VPS provider often shows the IP in the admin page on their website.
if the server is at your home then it is your own ip address.
if you host your server somewhere else then just google how to find the IP

frigid shore
#

i created server with express

#
const app = express();
const server = http.createServer(app);
const dbl = new DBL('token', { webhookAuth: 'password', webhookServer: server });
console.log(dbl.webhook);
dbl.webhook.on('ready', hook => {
  console.log(`Webhook running with path ${hook.path}`);
});
dbl.webhook.on('vote', vote => {
  console.log(`User with ID ${vote.user} just voted!`);
});

#

so, its ip is my ip?

restive otter
#

how to make bot online in glitch

willow spindle
restive otter
#

ok

dark briar
#

isn't there a way to bind the api to library your using or something so the lib handles all the events?

#

like with discord.js

kind barn
#

Good evening all

const DBL = require('dblapi.js');
const dbl = new DBL(yourDBLTokenHere, { webhookPort: 5000, webhookAuth: 'password' });
dbl.webhook.on('ready', hook => { console.log(`Webhook running at http://${hook.hostname}:${hook.port}${hook.path}`); });
dbl.webhook.on('vote', vote => { console.log(`User with ID ${vote.user} just voted!`); });

I set up the token and password in my code.
Also the url is my vps' ip and port
Similat this
1.1.1.1:5000
The console logs that am running on
0.0.0.0:5000
So what im missing?

#

I tried changing the port also didnt work

#

Does it needs to set the static ip in the code ?

vapid cape
#

why does it say its running on port 80 when ou set it on port 5000?

#

you dont need to set up any ip in your code, it will listen to all requests that come through that port

#

you just need to make sure the requests arrive correctly, by providing the correct public ip and port to your vps

kind barn
#

No that screen after changing the port in top.gg website and code

#

Also tried using express

#

But nothing done

#

@vapid cape im sure that vps' ip and port are correct

restive otter
#

Does anybody have a NSFW api i can have or no?

vapid cape
#

@kind barn check with your hosting company if you need to open ports

kind barn
#

@vapid cape thanks brother

restive otter
#

@restive otter no

restive otter
#

Hello j polanf

#

Poland*

spiral steeple
#

@restive otter wrong channel

restive otter
#

i am making dbl vote log

#

what i should put their

narrow zenith
#

webhook url and authorization

#

like if you have a webhook for your bot

restive otter
#

yes i have created

noble iron
#

direct webhooks when

restive otter
#

so the webhook url will go to URL and what about authorization

narrow zenith
#

that's where you put your key or password that authorizes the webhook to be used

restive otter
#

getting this error

trim venture
#

Hi! I'm trying to use the example python code. I have dblpy 0.3.3 and I'm getting this error:

Extension 'dbl' raised an error: AttributeError: module 'dbl' has no attribute 'DBLClient'
sullen nymph
#

print(dbl.__version__)

#

@restive otter That means top.gg does NOT support Discord webhooks

#

You have to make a webserver yourself

restive otter
#

how to make that

#

???

sullen nymph
#

Do I send you the Google search link

trim venture
#

Also pip show dblpy shows 0.3.3

Nemeth-MacBook-Pro:DBL-Python-Library nemetharon$ pip show dblpy
Name: dblpy
Version: 0.3.3
Summary: A simple API wrapper for top.gg written in Python
Home-page: https://github.com/DiscordBotList/DBL-Python-Library
Author: Assanali Mukhanov, top.gg
Author-email: shivaco.osu@gmail.com
License: MIT
Location: /usr/local/lib/python3.6/site-packages
Requires: ratelimiter, aiohttp
Required-by: 
sullen nymph
#

Did you decide to utterly ignore me

trim venture
#

print(dbl.__version__) also says 0.3.3

restive otter
#

i didn't find it

noble iron
#

@sullen nymph nice osu email >w>

sullen nymph
#

Shush

#

@trim venture Do you have any file/folder named dbl in your bot's folder

trim venture
#

no, also my file name is topgg.py

#

I'll try reinstall it

restive otter
restive otter
#

Somewhere

willow spindle
#

is there any rate limit for top.gg api

sullen nymph
willow spindle
#

ty

restive otter
#

Why does the api take forever

#

Like for the .hasvoted I vote then my bot still says I haven’t voted for the next 2 minutes

#

While unbelievabot takes like seconds after I vote

vapid cape
#

use webhooks instead

restive otter
#

How would I check if the message author has voted

#

Ooooooh nvm

#

I’ll see if that’s faster

restive otter
#

Why does it say on is undefined dbl.webhook.on("ready", hook => { console.log( `Webhook running at http://${hook.hostname}:${hook.port}${hook.path}` ); });

#

@mighty shuttle do you know why

mighty shuttle
#

Please don't ping me or any other random user for support, if people know how to answer the question they will answer on their own

restive otter
#

Mk

#

nvm

rustic burrow
#

How do i do the webhook, i see the code on the website and it says something about choosing a website to send the thing to but what would that be

dawn fjord
#

The IP of a domain pointing to the server you will be running the webhook receiver on

rustic burrow
#

Ok so i was able to lookup a webhook website and send the test msgs to it

#

but how to i connect that back up with my bot?

#

mk

silk bluff
#

hello

#

I have issues with votes

#

last time I saw my bot it had votes ~43

#

and now it says 1

#

whie?

true talon
#

Month votes or permanent votes?

silk bluff
#

month votes

#

yesterday they were ~43

true talon
#

Maybe it resets only tday

silk bluff
#

whiee?

#

nope

#

it resets every month

#

iirc

#

1st day of month (i.e. 1st feb this month)

sullen nymph
#

It resets on new month after someone votes

silk bluff
#

ay

sullen nymph
#

Which means no one has voted for your bot until yesterday/today

silk bluff
#

dude

#

I track votes 😐

#

see the date

#

I have complete logs of votes 😐

true talon
#

No

silk bluff
#

except a few which occurred during bot downtime ~2

#

what?

sullen nymph
#

That wasn't exactly the start of new month

true talon
#

U voted twice in a minute?

silk bluff
#

😐

sullen nymph
#

Weekend votes Luma

true talon
#

Oh

silk bluff
#

there is a test named button on top.gg

#

if you every used it?

#

webhook test

#

😐

#

Weekend votes Luma
not weekend it was a webhook test done by me

#

because I had some issues tracking votes

#

so tested it

sullen nymph
#

The messages didn't state so explicitly OR implicitly

silk bluff
#

ye

#

ik that

#

but I am telling you that it was a webhook test

#

I maintain diffrent logs for them

sullen nymph
#

Was the 11:57 PM one a test too?

silk bluff
#

nope

#

11:56 was tested one

#

and see the diffrence

#

AM | PM

#

lumap

#

ping if you find answers to this.

sullen nymph
#

If it doesn't make sense, blame cache :wesmart:

silk bluff
#

what?

#

ay this is a bug

sullen nymph
silk bluff
#

what's this?

sullen nymph
#

Basically top.gg stats logs for your bot

silk bluff
#

see the votes

#

shows 1 why?

sullen nymph
vapid cape
#

o nice ranking thingy

#

found my bot in there

#

rank 442 by server count lul

silk bluff
#

wew

#

will this issue get fixed?

vapid cape
#

why is there a bot with 170 shards at 1850 servers

sullen nymph
#

100 servers per shard? pogey

#

@silk bluff doubtfully

vapid cape
#

more like 10 servers

#

lmao

#

or wrong posting setup

sullen nymph
#

Soz I can't mathz

vapid cape
#

there should be a ranking for most shards

silk bluff
#

sed

#

lols

gaunt steeple
#

oh really

#

give me a few minutes and i'd spool up 1024 shards 🤣

#

90% of them would be empty, mind

#

have you noticed that some of the biggest bots dont post user/server/shard counts to top.gg?

green mantle
#

Most do

gaunt steeple
#

it only works if you report per-shard user counts iirc

balmy hamlet
#

I'm not a booster anymore F

thick flint
#

Eee... I have a problem with top.gg API
I want to use that

client.on('ready', () => {
    setInterval(() => {
        dbl.postStats(client.guilds.size, client.shards.Id, client.shards.total);
    }, 1800000);
});

But...

TypeError: Cannot read property 'Id' of undefined
    at Timeout.setInterval [as _onTimeout] (c:\Users\####\index.js:37:57)
    at ontimeout (timers.js:436:11)
    at tryOnTimeout (timers.js:300:5)
    at listOnTimeout (timers.js:263:5)
    at Timer.processTimers (timers.js:223:10)

Can someone help me?

fast comet
#

@thick flint is client.shards defined?

thick flint
#

no

fast comet
#

so why are you trying to get data of an undefined object?

thick flint
#

Oh

#

How i define it?

#

require?

fast comet
#

no, I don't think they are required. Just put 0s

thick flint
#

But this doesn't work

willow spindle
#

does your bot has a shard?

thick flint
#

ow

fast comet
#

sounds like a no

thick flint
#

Where i fine my shard ? The bot shard?

fast comet
#

shards aren't required

willow spindle
#

if no:

dbl.postStats(client.guilds.size);
thick flint
#

Ok

willow spindle
#

which library do you use

fast comet
#

that's js

willow spindle
thick flint
#

Thanks for helping

icy summit
#

Why does webhook give my ip as 0.0.0.0?

  console.log(`Webhook running at http://${hook.hostname}:${hook.port}${hook.path}`);
});```
spiral steeple
#

because that's all ipv4's

harsh stream
#

It means that it will accept connections on all the ip addresses that the computer has

icy summit
#

Should I enter the server's external connection ip on my editing page?

#

https://**.***.***.78:3000/dblwebhook

spiral steeple
#

if that's your machine's ip

icy summit
#

IP address will be as I sent?

harsh stream
#

also check if your webhook listener expects http or https

icy summit
#

Okey

ancient ridge
#

Any typescript wrapper?

#

nvm found it on the docs

late crater
#

so

#

The python api

#

requires a version of aiohttp

#

but discord api wrapper thingy for python requires a different incompatible version

#

halp

#

let's hope it works

#

lol

sullen nymph
#

Install from source

ancient ridge
#

Curious why the webhook doesnt support discord webhooks?

#

It would be soooo awesome to receive alerts in a channel on my server as opposed to having to open up a port to listen to webhooks

#

It would be soo amazing just to get them in anchannel

green mantle
#

You can do that anyway

#

It's not hard to do a webhook to discord

#

The API hook is only for sending it to your webhook server for you to handle yourself

vapid cape
#

you can use stuff like IFTTT to convert one webhook into the other

lean yew
#

hellow

#

whoever

#

can help me

sullen nymph
#

Anyone could probably help if you actually stated the issue

gaunt steeple
#

IFTTT?

sullen nymph
#
gaunt steeple
#

thanks shivaco

#

i just sent this to my collegue whos having problems with getting his smart boiler to do stuff

#

hes well chuffed

#

he said "i know what app im playing with tonight" lol

sullen nymph
gaunt steeple
#

shivaco what library do you develop btw

sullen nymph
#

dblpy

ancient ridge
#

😭

#

after looking at the wrapper

#

the issue is in the typings

#

Sent a PR to fix

dapper copper
#

no?

#

its not?

#

you should be doing is TopGG.on

#

@ancient ridge

ancient ridge
#

webhook is its own emitter

#

i ended up making my own webhook handler sadly as the internal one in the wrapper wasnt supporting TS properly

dapper copper
#

i mean

#

its literally a JS lib

ancient ridge
#

Sent a PR to fix for anyone in future so hope it helps

#

TS is JS

dapper copper
#

thing is

#

webhook isnt its own emitter

#

TopGG extends EventEmitter

#

meaning TopGG itself is the emitter

#

@arctic arch I am correct yea? (sorry about the ping)

ancient ridge
#

TopGG is a event emitter but TopGG.webhook is also an EventEmitter

#

vote events are not emitted by TopGG

#

they are emitted by .webhook

dapper copper
#

👍

marsh panther
#

why am I getting tons of Error: 401 Unauthorized at IncomingMessage.res.on (/home/hector/Desktop/UpvoteBot/node_modules/dblapi.js/src/index.js:118:25)?

#

(from cloudflare)

sullen nymph
#

Regenerate token

marsh panther
#

but it's still working

#

my logs are just getting spammed from that

vapid cape
#

the error is coming from a dbl request, which includes all dbl methods except webhooks

#

so which part is still working?

rain igloo
#

hey I'm using dblapi.js to report stats and had a quick question. I'm using discord.js and my bot is sharded.

Do I just need to pass my client object into the dblapi constructor on each of my shards? Or would I need to manually add up server counts across shards and just send it from one shard?

#

just a little confused about what the serverCount argument on postStats refers to - the total server count or just the count for the current shard?

vapid cape
#

when you pass client into dblapi, you dont need to use poststats

brisk marten
#

^

vapid cape
#

dblapi is also smart enough to handle shards

brisk marten
#

there is an autoposter

vapid cape
#
data.server_count = this.client.guilds.size;
      if (this.client.shard && this.client.shard.count) {
        data.shard_id = this.client.shard.id;
        data.shard_count = this.client.shard.count;
      } else if (this.client.shards && this.client.shards.size !== 1) {
        data.shard_count = this.client.shards.size;
      }```
#

^this is what dblapi does automatically

rain igloo
#

gotcha, so it'll call postStats internally using info from my client with each shard's serverCount, and then they'll get added up on top.gg's server?

vapid cape
#

yes, each shard will send its individual server count, and the server should add them up

rain igloo
#

perfect, thank you 😄

willow spindle
vapid cape
#

in url yes

willow spindle
#

with http/https ?

harsh stream
#

yes

#

make sure your webhook server is expecting http or https when you enter it

willow spindle
#

ok

harsh stream
#

the url should look like http://(IP)ADDRESS:5000/dblwebhook

#

change the port and path if needed

#

and the authorization can be whatever you want it to be as long as it is the same as what the webhook is expecting

willow spindle
#
Webhook running at http://0.0.0.0:0/dblwebhook

is this normal?

#

finally I did. Thanks

harsh stream
#

I don't think the port should be 0

#

but i guess you fixed it ^^

restive otter
#

So im trying to fetch if a user has voted but it says .hasVoted is not a function?
My Type of Error: TypeError: dbl.hasVoted is not a function

spiral steeple
#

Show some code

restive otter
#
if (message.content.startsWith(config.prefix + "checkupvote")) {
      function hasVoted(id) {
        client.dbl.hasVoted(id).then(voted => {
            if (voted)
                return true;
            else
                return false;
        });
    }
    
 dbl.hasVoted().then(votes => {
    if (!votes.get(vote => vote.id == message.author.id)) {
const noupvote = new Discord.RichEmbed()
.setTitle("You haven't upvoted.")
.setDescription("This is your __reminder__ for updating the bot today!\nLink to Upvote: [https://top.gg/bot/390295962159022080](Upvote Bot)\nThis message will be removed once upvoted!")
.setColor("BLUE")
.setTimestamp()

  } else {
    message.reply('thx')
  }
 })
#

Help

spiral steeple
#

@restive otter it takes an id, but you forgot client.dbl on the second one

restive otter
#

ah

#

I did not understand anything about the authorization of the token ;=;

#

can someone explain it to me in an easy to understand way this?

#

🥺

restive otter
#

I got it appreicated it!

restive otter
#

can you emit dbl.webhook.on("vote")?

pulsar gyro
#

-play swing Twice

#

!play swing Twice

jade rune
#

!play believer

green mantle
spiral steeple
#

@restive otter you can emit anything.

nova skiff
green mantle
#

You need to actually install the DBL module

nova skiff
green mantle
#

You need to install from source

#

Aiohttp versions clash

nova skiff
#

pip install dblpy

#

i found it

green mantle
#

You will still have an issue about aiohttp

sullen nymph
#

Read channel topic nekohmm

restive otter
#

ahh thankyou couldn't see the api doc link i'll read it now

calm mural
#

i cant get webhook to post in server please help

marsh panther
#

I'm getting a lot of logs like:

{ Error: 401 Unauthorized
    at IncomingMessage.res.on (/home/hector/Desktop/UpvoteBot/node_modules/dblapi.js/src/index.js:118:25)
    at IncomingMessage.emit (events.js:203:15)
    at endReadableNT (_stream_readable.js:1145:12)
    at process._tickCallback (internal/process/next_tick.js:63:19)
  raw: '{"error":"Unauthorized"}',
  body: { error: 'Unauthorized' },
  status: 401,
  headers:
   { date: 'Fri, 07 Feb 2020 19:11:19 GMT',
     'content-type': 'application/json; charset=utf-8',
     'content-length': '24',
     connection: 'close',
     'set-cookie':
      [ '__cfduid=d0beea544c8207ffcff3987f538fa09431581102679; expires=Sun, 08-Mar-20 19:11:19 GMT; path=/; domain=.discordbots.org; HttpOnly; SameSite=Lax; Secure' ],
     'x-powered-by': 'Express',
     'access-control-allow-origin': '*',
     'access-control-allow-headers': 'Authorization',
     etag: 'W/"18-XPDV80vbMk4yY1/PADG4jYM4rSI"',
     'cf-cache-status': 'DYNAMIC',
     'expect-ct':
      'max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"',
     'strict-transport-security': 'max-age=15552000; includeSubDomains; preload',
     'x-content-type-options': 'nosniff',
     server: 'cloudflare',
     'cf-ray': '5617ab410e46d46b-HAM' },
  ok: false,
  statusText: 'Unauthorized' } ```
#
  • it's using more cpu than my main bot
harsh stream
#

Do you have a loop that keeps spamming the DBL website?

#

Keep in mind that there is a rate limit of 60 calls per minute for the DBL api

#

401 Unauthorized probably means that your token is incorrect

willow spindle
#

yes

#

use vote event of DBL webhook

remote slate
#

Hi

#

I'm wondering

#

why there is a GET request from DBL after a POST request

#

(for the webhook)

sonic sphinx
#

Can someone explain me a Lil bit of it 😅

queen sierra
#

(Python) Just started using the dbl API. I tried to test the webhook with the provided webhook example but I am receiving this error. Any ideas what's causing it?

green mantle
#

@sullen nymph did you change the aiohttp version for the pypi package?

sullen nymph
#

Do you want me to answer honestly

#

Cuz not honestly yes I did :^)

queen sierra
#

it was changed around 10 days ago to support discord 1.3 (which i am currently using) afaik

sullen nymph
#

Only the github repo

queen sierra
#

that might be the issue

#

i did use the pypi package instead of the repo. I will test it now

#

unfortunately, that did not fix it for me

#

:/

green mantle
#

whats yer code

queen sierra
#

using the webhook example from the repo readme

#

could it be that I am using the wrong port?

#

right now its 5000 (the default one)

green mantle
#

well what are you hosting your bot on

queen sierra
#

digitalocean (vps)

green mantle
#

you need the port you set to be open

queen sierra
#

the port seems to be open but I am still experiencing the issue

#

ok, I found where the issue is

#

I changed the webhook url from https to http, which is not really desirable

green mantle
#

well it cant be secure if you dont have a secure system lmaop

queen sierra
#

sorry, networks are really out of my comfort zone. I managed to figure things out. Thank you for your time

#

🙂

harsh stream
#

The library only supports http by default, if you want https then you need to use another web server

jagged escarp
#

Hello, would anyone be able to guide me towards resources for configuring a custom webhook in C# with Discord.NET / .NET Core?

green mantle
jagged escarp
#

Yeah I've been using this, I don't believe this supports webhooks, but instead makes queries to the API which is forbidden if you have a lot of upvotes. Though correct me if I'm wrong

green mantle
#

good point actually

#

i didnt notice that

harsh stream
#

the java lib also doesn't support webhooks, but it isnt that hard to implement I think

jagged escarp
#

Yeah I'm trying to find resources online but literally everything is ASP.NET exclusive, kinda stumped cuz I've never done this in regular .net core

harsh stream
#

I don't use the DBL webhook, but my private bot has already a tiny webserver attached to it for other reasons

#

Im sure there are some C# libs that can create a webserver

jagged escarp
#

Alright cool I'll try and look into that

harsh stream
#

I'm a Java dev, so I can't help with .net specific stuff

jagged escarp
#

gotcha

harsh stream
#

But it looks like it might work

jagged escarp
jagged escarp
#

Nvm ^ lol

#

that's something completely different

split plinth
#

Dd

#

Ssd

restive otter
#

:

rose cargo
#

I dont understand the webhook things can anyone explain it a bit more to me im interested in learning it.

#

hello?

vapid cape
#

basically whenever a vote happens, top.gg will send you a POST request to the url you specify in the bot edit page

#

its up to you to provide a webserver or address that is able to receive those requests

rose cargo
#

@vapid cape how would I do a webserver?

vapid cape
#

depends on your language

rose cargo
#

discord.js

vapid cape
#

for javascript there is a library which does it for you

#

dblapi.js

#

if you dont want to use the library, you can setup a webserver using the built-in http module, or with libraries such as express.js

green mantle
#

@sullen nymph i take it pypi install is still oofed?

sullen nymph
#

yup

green mantle
#

i gotta work out where df i put the code for the API, my command handlers made it a bit weird

sudden notch
#

hi how do i get webhook

#

my name Locked

willow spindle
restive otter
#

I don't know if this is an API issue or a bot issue, but at a random point my bots server count went to 1 until I restarted, this only appeared on the website, as evaling showed the appropriate server count

#

Oh nvm I made a really big brain move and accidently posted my testing bots server count lmao

versed junco
#

So for the widgets. How can I change the widgets size?

dapper copper
versed junco
#

@dapper copper That says nothing about the size.

dapper copper
#

use css to change the image size

versed junco
#

it doesnt work

#

Oh

#

Should I use CSS in the link?

spiral steeple
#

It's an svg image, you should be able to resize it (on a website, just sending it as a link you cant afaik)

versed junco
#

ok

rigid lichen
#

I'm getting a Uncaught Promise Error: Error: 400 Bad Request error

#

using the dblapi.js package

rose cargo
#

Im teying to figure out how to create a webhook to get votes for my bpt but i cant figurw out how to use it

#

where would i go to create a webhook?

spiral steeple
#

@rigid lichen can you show me the code where you use dblapi.js?

#

like where you call a method

rigid lichen
#

yes sure

#

ready.js

// Post DBL stats
        const DBL = require("dblapi.js");
        const dbl = new DBL(this.client.config.dbl, this.client);
        dbl.postStats(this.client.guilds.size, this.client.shard.id, this.client.shard.count);
        dbl.on("posted", () => {
            client.logger.log("Server count posted to DBL!");
        });
#

Oh!

#

My bad

#

It's because of the discord.js update

willow spindle
#

@rose cargo click "Edit" on your bot's page and scroll down

rigid lichen
#

we have to use guilds.cache.size

#

sorry

rose cargo
#

@willow spindle ok thx

spiral steeple
#

You're on master I assume? @rigid lichen

rigid lichen
#

yes

#

fixed

#

thank you

spiral steeple
#

👍

rose cargo
vapid cape
#

@rose cargo you need a webserver to receive the webhooks

#

the url is the address of your webserver

rose cargo
#

i dont understand how to make a webserver tho

vapid cape
#

what language are you using?

rose cargo
#

js

vapid cape
#

where is your bot hosted?

rose cargo
#

24/7

vapid cape
#

you can use dblapi.js

#

it creates the webserver for you

#

for glitch, you need to use process.env.PORT as your webhook port

rose cargo
#

i dont understand much about it

vapid cape
#

and in the url field you need to put your glitch project url plus /dblwebhook

rose cargo
#

ok then what?

vapid cape
#

you know how to install modules?

rose cargo
#

yes

vapid cape
#

then install dblapi.js

rose cargo
#

i did

vapid cape
#
const DBL = require('dblapi.js');
const dbl = new DBL(yourDBLTokenHere, { webhookPort: 5000, webhookAuth: 'password' });
dbl.webhook.on('ready', hook => {
  console.log(`Webhook running at http://${hook.hostname}:${hook.port}${hook.path}`);
});
dbl.webhook.on('vote', vote => {
  console.log(`User with ID ${vote.user} just voted!`);
});``` this is the example code for how to use it
#

yourDBLtoken is the token from your bot's edit page

#

webhookport should be process.env.PORT for glitch

rose cargo
#

ok

vapid cape
#

webhookAuth doesnt matter what you put, as long as you put the same thing in the authentication field in the website

rose cargo
#

ok

#

thank u ima try it out now

vapid cape
#

in the url field, it should be YOURGLITCHPROJECT.glitch.me/dblwebhook

rose cargo
#

ok

#

thx so much

vapid cape
#

then save the setup in your dbl edit page, and hit the test button

#

you should see the console.log in your logs

rose cargo
#

@Tim#2373 i used the stuff u said to use now my console gives and error

Error: listen EADDRINUSE :::30003:54 PM

at Server.setupListenHandle [as _listen2] (net.js:1360:14)3:54 PM

at listenInCluster (net.js:1401:12)3:54 PM

at Server.listen (net.js:1485:7)3:54 PM

at Function.listen (/rbd/pnpm-volume/0a96f05c-d7e5-41d5-8422-6adb49bbe599/node_modules/.registry.npmjs.org/express/4.17.1/node_modules/express/lib/application.js:618:24)3:54 PM

Jump Toat Object.<anonymous> (/app/server.js:179:20)3:54 PM

at Module._compile (module.js:653:30)3:54 PM

at Object.Module._extensions..js (module.js:664:10)3:54 PM

at Module.load (module.js:566:32)
spiral steeple
#

Your uptime robot is on the same port

#

Have them use the same server

#

instead of a different one

vapid cape
#

@rose cargo if you already have a webserver, then add it to dblapi

#

{webhookAuth:yourpassword,server:yourExistingServer}

rose cargo
#

how do i get my existing server?

vapid cape
#

acutally remove port, because with an existing server you dont need the port

#

the existing server is the uptimerobot server

rose cargo
#

oh

#

how do i add it

vapid cape
#

what is your code?

rose cargo
#

@vapid cape dm me

vapid cape
#

the uptime part

#

you can post here

rose cargo
#

i cant copy and paste

#

because im on mobile

#

and glitch doesnt allow it

#

so ima have to send u the glitch link

vapid cape
#

lol ok

rose cargo
#

@vapid cape i sent it to ur dms

#

go to the server.js part

#

this is so confusing

#

@vapid cape did u check it?

#

this is so confusing lol

vapid cape
#

@rose cargo

#

this should be your server

#

move that entire code block to the top

#

and add server:listener to the dbl config

rose cargo
#

do i remove webhookAuth?

spiral steeple
#

no

rose cargo
#

@vapid cape now it says cannot read property on of undefined on the dbl.webhook.on

#

what do i do now

#

?

#

@spiral steeple ^

spiral steeple
#

your webhook is undefined

#

can you show me your code?

rose cargo
#

@spiral steeple dm me

spiral steeple
#

Are my dms off?

rose cargo
#

yes

vapid cape
#

@rose cargo apparently its webhookServer:listener

#

and not server:listener

rose cargo
#

ok

vapid cape
#

and you should probably put your dbl token in your env file as well

rose cargo
#

i probably will

#

what do i pit in the top.gg webhook page again?

vapid cape
#

and your webhookAuth

#

then hit the save button, then test

rose cargo
#

ok

#

ok it works

#

@vapid cape how would i get it to show a users name and discriminator though?

willow spindle
#

client.users.fetch()

rose cargo
#

huh

spiral steeple
#

it sends vote

vapid cape
#

the webhook gives you a user id, and you probably noticed

rose cargo
#

ye

vapid cape
#

now you need to use this id to get the user from your bot

rose cargo
#

how

spiral steeple
vapid cape
#

check your discord library's documentation

#

for example

willow spindle
#

@rose cargo vote.user returning as user id who was voted

#

use this ^

rose cargo
#

I use this but it shows it as undefined

#

@willow spindle ^

#

should I use await on the fetchUser?

willow spindle
#

yes

rose cargo
#

ok let me try it

#

Im sorry if im trouble it just that i havent done this type of stuff before

spiral steeple
#

the function will need to be async as well

#

so async vote =>

rose cargo
#

ik

#

i always put the text after async in ()

spiral steeple
#

yeah that's good practice

rose cargo
#

so like if wamted it to send to a certain channel instead of console would i use async (vote, message)?

#

@spiral steeple ^

spiral steeple
#

no, to send it to a channel you'd have to either get the channel from cache or fetch a channel

#

then use its send method

rose cargo
#

for some reason my code isnt woeking

#

working*

willow spindle
#

add ) after }

rose cargo
#

thanks.

hollow sandal
#

The python package of dblpy library requires aiohttp<3.60 but discord.py requires aiohttp>3.6.0
Should I use get and set api calls to top.gg instead of using the library dblpy

green mantle
#

You need to install of source atm

#

The GitHub version has been updated for 1.3.1 d.py

hollow sandal
#

Okay, thanks

#

But one problem:

#

How to install python library from Github source code

green mantle
#

pip install git+https://github.com/DiscordBotList/DBL-Python-Library

hollow sandal
#

Thanks again.

little ice
#

vote webhook test is not working for me

#

my api doesn't received any data

#

using postman to simulate the request work fine tho

#

so url and authorization are fine

#

when people vote it doesn't receive anything too

#

was working fine in the past tho

restive otter
#

do u get any error?

little ice
#

nope nothing

vapid cape
#

you used postman to test dbl -> postman or postman -> bot?

little ice
#

postman -> bot

vapid cape
#

then idk, show relevant code i guess?

little ice
#

actually it doesn't even enter the route of the api

vapid cape
#

and you used exactly the same url as in your bot edit page?

little ice
#

yup

vapid cape
#

did you save before using the test button?

little ice
#

yup

#

but it's the same config for a while now

#

since it was working before

#

and just it cease working i don't know why

vapid cape
#

does the test button also not work?

little ice
#

i just see a confirmation of the webhook being sent but the bot doesn't receive anything

vapid cape
#

try dbl -> some api tester

little ice
#

any website idea to do so ?

vapid cape
little ice
#

mhh

#

seems to work

vapid cape
#

so dbl is sending

little ice
#

lol

#

no that i put my ancient url back

#

it seems ok ?

#

really can't explain

vapid cape
#

lol

#

¯_(ツ)_/¯

#

maybe there was a bug in dbl's database

#

and changing the url fixed it

little ice
#

maybe

#

for now test are working but not actual vote tho

#

i asked for a friend to vote and it didn't work

#

if anybody have a solution ? would be greatly appreciated

mental raft
#

on top.gg how can I display the amount of servers my bot is in

nimble steeple
mental raft
#

Oh, thank you

restive otter
#

Did anybody have an Naruto bot ?

ionic flame
#

This is api related channel

restive otter
#

How can i make Webhooks?

green mantle
restive otter
#

i don't understand how to make it

#

i want help

vapid cape
#

what do you want to do?

mental raft
#

where do I find my top.gg token?

green mantle
#

if you go to the edit part of your bot

#

and scroll

#

down

#

to the bottom

#

should be a button like generate token or somthing

mental raft
#

thanks

little ice
#

still having problem with it btw ... test work but actual vote don't

little ice
#

and after looking throught my nginx log i can see it doesn't even reach my server sometimes

#

so not a code problem

#

but i don't get how i would be the only one to get such an issue

#

anyway to get a log of what is happening with webhooks on the website part ?

green mantle
#

Its almost defo not the website

little ice
#

certainly

green mantle
#

Make sure your firewall isnt blocking anything

little ice
#

but why would the request sometime pass

#

and sometime not

green mantle
#

And check if your port is actually open on that address

little ice
#

like if i change the url

#

and test it out right away

#

it works 1 time

#

and after that never again

#

basically

#

could this be cache or something ?

#

is there any staff i can pm to maybe get a log of what's going on or something ?

#

cause all my other webhook are working perfectly fine so this is weird

#

do the test button have a rate limit ?

opal cypress
#

<@&264889767072628742> mind at least acting like you care?

craggy sentinel
#

-atmods

abstract mothBOT
#

Please do not mention (ping) more than one or two moderators for help, unless there is an emergency.

Here are some examples of emergencies:

  • Raids / Multiple members mass spamming.
  • Severe disruption of Discord's ToS (NSFW content, etc)
  • Anything that requires more than 2 moderators to handle.
dense basalt
#

they left

arctic arch
#

left the server

craggy sentinel
#

did they have a bot in the queue

mighty shuttle
#

No

craggy sentinel
#

lmaoo

compact pond
#

imagine

willow spindle
#

@restive otter english only

restive otter
#

I have a problem with my Bot

#

When I start my program on the bot everything goes without errors but always after a certain time the bot goes offline on its own server but there is no error message. For this reason, I tried my program with many others and everything went without problems and the bot stayed online. Did I do something wrong or is it up to you?

green mantle
#

@restive otter TopGG is not responsible / will not host the bot for you

narrow zenith
#

this channel is to do with the api for the discord bot website

green mantle
#

This channel is for the DBL API

#

You issue belongs more in #development altho it seems to be a hosting problem

restive otter
#

ok

silent pilot
#

What language can I code a bot in?

#

Is there a python version?

runic grove
#

wrong channel

#

you can use literally any language

#

including python

harsh stream
#

js and python are the most popular languages on this server, but you want to be in #development if you have questions about bot development

restive otter
#

hey

#

i need help with webhook on site

willow spindle
#

ask and wait for someone who can answer to help you.

restive otter
green mantle
#
  1. Url: Your webhook server address (This is normally your IP you host the bot on, port and then /dblwebhook)
  2. AuthKey: litterally anything
arctic arch
#

to run a webhook you need to host a webserver that will receive the web requests

#

the javascript and python libraries can do that for you

#

then you need to find out your public ip, make sure your ports are forwarded and fill in the details on the website

#

save before testing

little ice
#

i'm still not receiving all of the webhooks

little ice
#

anyway to get more insight on what is the website side error whenever it send a "upvote" event and doesn't succeed ?

silk bluff
#

Oops! Error: 400 Bad Request

#

using dblapi.js

#

^2.3.0

#

ping me

#

recent error after updating to discord.js v12

vapid cape
#

show full error

silk bluff
#

that's only the error 🙂

vapid cape
#

change js dbl.on('error', e => { console.log(`Oops! ${e}`); }) to js dbl.on('error', console.log)

silk bluff
#
    at IncomingMessage.res.on (/rbd/pnpm-volume/ce908d90-1591-4e68-8e70-6fd0493443ea/node_modules/.registry.npmjs.org/dblapi.js/2.3.0/node_modules/dblapi.js/src/index.js:118:25)
    at IncomingMessage.emit (events.js:194:15)
    at endReadableNT (_stream_readable.js:1125:12)
    at process._tickCallback (internal/process/next_tick.js:63:19)
  raw:
   '{"error":"Required parameter server_count or shards missing"}',
  body:
   { error: 'Required parameter server_count or shards missing' },
  status: 400,
  headers:
   { date: 'Fri, 14 Feb 2020 11:48:06 GMT',
     'content-type': 'application/json; charset=utf-8',
     'content-length': '61',
     connection: 'close',
     'set-cookie':
      [ '__cfduid=d834ee1878c0e7a32c303969e7b7e5a671581680886; expires=Sun, 15-Mar-20 11:48:06 GMT; path=/; domain=.discordbots.org; HttpOnly; SameSite=Lax; Secure' ],
     'x-powered-by': 'Express',
     'access-control-allow-origin': '*',
     'access-control-allow-headers': 'Authorization',
     etag: 'W/"3d-AG5DMcRAr7VonaedOjpOtCEaVnk"',
     'cf-cache-status': 'DYNAMIC',
     'expect-ct':
      'max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"',
     'strict-transport-security': 'max-age=15552000; includeSubDomains; preload',
     'x-content-type-options': 'nosniff',
     server: 'cloudflare',
     'cf-ray': '564ecfa47893cefc-IAD' },
  ok: false,
  statusText: 'Bad Request' }```
vapid cape
#

Required parameter server_count or shards missing

silk bluff
#

Discord.js v12

vapid cape
#

are you using .postStats?

silk bluff
#

what's that now?

vapid cape
#

show your dbl code

silk bluff
#

ok

#
dbl.on("posted", () => {
  console.log("Server count posted!");
  client.channels.fetch("668510061362151425",true);
  client.channels.cache.get("668510061362151425").send("Server count posted!");
});
dbl.on('error', console.log)
#

one taken from the official docs and modified a bit

#

this worked for me on discord.js v11.5.1

frigid shore
#

what is isWeekend()?

vapid cape
#

it seems @arctic arch didnt add the recent v12 changes to dblapi.js yet

frigid shore
silk bluff
#

okie

arctic arch
#

likely wont be supporting master right now as it's in development

silk bluff
#

okay

#

any manual way to post server count?

arctic arch
#

at least yet

#

things could still change drastically

vapid cape
#

instead of adding your client to new DBL() use dbl.postStats() instead

silk bluff
#

okies

arctic arch
#

@frigid shore on weekends, votes are counted as double

vapid cape
#

@arctic arch well for now you could simply do something like data.server_count = (this.client.guilds.size || this.client.guilds.cache.size);

frigid shore
#

tks

silk bluff
#

ye

arctic arch
#

yea I could

silk bluff
#

maybe I will fork it

arctic arch
#

it's just weird maintaining something for a development version with lots of breaking changes

vapid cape
#

yeah its understandable

#

although djs v12 has been in development for years and many people use it in production lmao

arctic arch
#

but if it seems like this is settled on and v12 is still far away from ever getting stable then I might

#

including us

vapid cape
#

yup

frigid shore
#

is there a time limit of getting votes?

#

i want to set interval on each second

#

to get votes

green mantle
#

df

frigid shore
#

?

green mantle
#

isnt the votes a event

frigid shore
#

what?

green mantle
#

when someone votes for your bot

#

it triggers an event

frigid shore
#

but i dont want to use webhook

green mantle
#

you NEED

#

to use the webhook

frigid shore
#

but it doesnt work

#

i tried :(

green mantle
#

flooding the API with requests is gonna get you told off by tonkku

#

if you need help with the webhook then ask here and if its JS im sure tim can help ui

frigid shore
#

ok

silk bluff
frigid shore
arctic arch
#

you can do whatever with your fork

restive otter
silk bluff
#

okie thanks

restive otter
#

help me

arctic arch
#

@frigid shore nothing, that's just an example of existing routes in the web server

frigid shore
#

ok

#

and webhook will work?

arctic arch
#

@restive otter you are not logged in

restive otter
#

im logged

#

:))

frigid shore
arctic arch
#

not when you made the request @restive otter

frigid shore
#

:((

arctic arch
#

@frigid shore do you have an existing express server

frigid shore
#

ok

#

no

arctic arch
#

then you can use the other example

frigid shore
#

i dont know how to use servers

#

hmm...

restive otter
#

@arctic arch where put this code

#

?

#

i need

frigid shore
#

@arctic arch but what port?

#

5000?

arctic arch
#

you can choose

frigid shore
#

random?

arctic arch
#

as long as it's over 1024

frigid shore
#

mm

#

ill try....

arctic arch
#

@restive otter I think you should seek help from someone who can also speak your language

restive otter
#
const config = require('./../config.json');
exports.run = (client, member, sql) =>{
  snekfetch.post(`https://top.gg/bot/668481980547072007`)
    .set('Authorization', config.dbotAuth)
    .send({"server_count": client.guilds.size})
    .then(() => client.users.get(config.ownerID).send(`Red Music (best bot) has been added to a server.`))
    .catch(err => client.users.get(config.ownerID).send(`${err}`));
}```
#

why no work?

arctic arch
frigid shore
#

@arctic arch

#

it doesnt work

arctic arch
#

you need to add your webhook details on the website

frigid shore
#

i added

#

but

arctic arch
#

the url is empty

frigid shore
#

what is url?

arctic arch
#

http://<your ip>:<the port you chose>/dblwebhook

willow spindle
#

server ip:port/dblwebhook

frigid shore
#

thank you

#

but when i use hosting

#

i need to use it's ip?

arctic arch
#

yes

worn quail
#

oh

#

my

#

god

#

this conversation, Smoky this all can be found through google

frigid shore
#

no

worn quail
#

yes

#

what is url?
@frigid shore

frigid shore
#

tonkku is better google smiley2

arctic arch
#

not really asking what the url is

#

but what it should be

worn quail
#

ah, fair

#

yeah i took part of that out of context, forgive me as you know im dumb

frigid shore
#

@arctic arch does the bot need to be online to make webhook?

worn quail
#

no, the script that makes the webhook run (i do my dbl stuff in a backend server) must be running

frigid shore
#

hm.. but it doesnt work..

arctic arch
#

you need to also make sure the ports are forwarded

#

are you on your home pc

worn quail
#

@frigid shore do you have a static IP

frigid shore
#

?

arctic arch
#

if yes you'd need to configure your router to open the port, on a host you just need to make sure there's no firewall blocking it

frigid shore
#

what's static ip.

worn quail
#

google it

#

your internet provider changes your IP (sometimes at random, once or twice daily even i think) and you would need to update it.

frigid shore
#

nono

worn quail
#

you are going to want that

frigid shore
#

hmmm i can....

#

go to glitch

#

and

#

host there...

arctic arch
#

on glitch only port 3000 is open

#

which leads to your project url

frigid shore
#

the script

#

if i put webhook here

#

YEEE

#

WEBHOOK WORKKS

#

v

#

@arctic arch tks))))

arctic arch
#

did you just make it 1024

#

lmao

frigid shore
#

yes..

arctic arch
#

so the webhook is running but does it receive the test request

frigid shore
vapid cape
#

@frigid shore is it your home pc?

#

or a vps?

frigid shore
#

yes

#

home pc

vapid cape
#

what did you put in the url?

#

in the website

frigid shore
#

its ip

vapid cape
#

show an example

frigid shore
#

??

vapid cape
#

show what you put

frigid shore
vapid cape
#

and authorization you put the same one in your code?

frigid shore
#

yes

vapid cape
#

did you save and press the test button?

frigid shore
#

yes

vapid cape
#

and nothing appeared in the logs?

frigid shore
#

appeared

arctic arch
#

what appeared

frigid shore
arctic arch
#

thats just saying the webhook started

#

do you have an on vote event

frigid shore
#

not yet

arctic arch
#

that's what the test button should trigger

frigid shore
#

i made event but

#

i can vote in 12h

#

:(

#

i need to use 2 account

arctic arch
#

the test button is there for a reason

#

so you can test without having to wait 12h

frigid shore
#

but i cant vote

little ice
#

is there a rate limit to it ? (to the test button)

arctic arch
#

@frigid shore you dont need to vote, just press the test button where you added the url and authorization

little ice
#

please

frigid shore
#

what is test button?

vapid cape
frigid shore
#

ok

arctic arch
#

@little ice I am having no problem receiving every webhook post

little ice
#

yeah

frigid shore
#

no

little ice
#

using webhook.site it is working

frigid shore
#

doesnt work

little ice
#

but my for some reason my api doesn't receive all of them

#

and whenever i use postman (for example) everything is working fine

#

so i guess there is a problem somewhere

#

is there a way to see the webhook side error ?

#

cause my nginx doesn't record the webhook being sent so i don't even receive a request

arctic arch
#

do you have anything else around nginx

#

like cloudflare?

little ice
#

nope

#

webhook was working fine before

#

but it just doesn't work now i don't know why

#

so for now i'm using Zapier as a work around and it is working

#

but it is very limited

arctic arch
#

but it seems the problem is somewhere within your network

little ice
#

maybe but

vapid cape
#

is your nginx configured with any sort of rate limiting?

little ice
#

why twitch webhooks and zapier one are working perfectly

#

no rate limit that i am aware of

#

every other service are working fine

frigid shore
#

@arctic arch test button doesnt work :(

#

is it 'vote' event?

arctic arch
#

yea

#

also make sure webhookAuth and the Authorization value are the same

frigid shore
#

yes

#

nothing in console

arctic arch
#

then it should be all about the url with correct ip and open ports

vapid cape
#

check if you need to port forward in your router

#

and in your firewall

frigid shore
#

but why ready event works

vapid cape
#

ready event works because it means the server is running

#

but if the server is not receiving anything then something is blocking the requests

frigid shore
#

oh.

#

i forgot

vapid cape
#

@little ice try doing something like monitoring incoming connections instead of relying on nginx logs

#

the connection might be coming but be rejected somewhere before it reaches nginx or by nginx itself

little ice
#

mhh

frigid shore
#

does anybody speak russian?

vapid cape
#

niet

little ice
#

any idea how to do that ?

vapid cape
#

on linux you do use things like netstat

#

or tcpdump

frigid shore
#

niet
@vapid cape blin, zhalko

little ice
#

will look into it

#

thanks for the answer

frigid shore
#

-tonkku :(((

sullen nymph
#

Chto ne tak

frigid shore
#

vebhuk ne rabotayet

sullen nymph
#

Что пробовал, что нет?

frigid shore
#

Он запускается, а ивент на нажатие кнопки не работает