#topgg-api

1 messages ยท Page 95 of 1

vapid cape
#

wait

#

you spelled it wehook

#

iinstead of webhook

restive otter
#

oh my... ๐Ÿคฆ

radiant peak
#

can I get the votes of a bot as a int in python?

sullen nymph
#

"as a string"?

radiant peak
#

oh as a int

#

nvm

restive otter
#

My bot logs that its webhook is running, but it doesn't catch any votes whenever it receives a vote. What could I be doing wrong?

radiant peak
#

My bot logs that its webhook is running, but it doesn't catch any votes whenever it receives a vote. What could I be doing wrong?
@restive otter maybe your auth is wrong

restive otter
#

I just checked those, they weren't wrong

sullen nymph
#

vote count? for monthly and total votes use get_bot_info
for last 1000 votes, get_bot_upvotes

radiant peak
#

okay thanks

restive otter
#

This is what I'm trying to do and it's not working, is something about my event wrong or what?

dbl.webhook.on('vote', vote => {
  var channel = client.channels.cache.get("731772484285759600");
    var user = client.users.cache.get(vote.user);
    console.log(`${user.tag} just voted!`);
    try {
    var embed = new MessageEmbed()
    .setAuthor(user.tag, user.avatarURL())
    .setColor(randomColor())
    .setDescription(`Thanks for voting for Semblance!! :D`)
    .setFooter("You can see the vote links by typing +vote :D");
    channel.send(embed);
});
#

This one works though

dblVoting.webhook.on('ready', hook => {
    console.log(`Webhook running at https://${hook.hostname}:${hook.port}${hook.path}`)
});
radiant peak
#

so shouldt it be this? @sullen nymph

info = self.dblpy.get_bot_info(bot_id=708700387770630194)```
#

because its not working

sullen nymph
#

How come?

radiant peak
#

because you said I should use get_bot_info

sullen nymph
#

What exactly isn't working, though?

#

Any errors?

radiant peak
#

oh

#

it said info isnt defined

sullen nymph
#

Send code

radiant peak
#

wait+

#
class TopGG(commands.Cog):
    def __init__(self, bot):
        self.bot = bot
        self.token = ''
        self.dblpy = dbl.DBLClient(self.bot, self.token, autopost=True, webhook_path='/dblwebhook', webhook_auth='', webhook_port='')

    @commands.command()
    async def topgg(self, ctx):
        if ctx.author.id in info.team:
            info = self.dblpy.get_bot_info(bot_id=708700387770630194)
            await ctx.send(info)
    
    # some more code for upvotes

def setup(bot):
    bot.add_cog(TopGG(bot))```
#

i also imported everything

sullen nymph
#

well you see

#

hold on what

radiant peak
#

wait Im stupid af

#

i did info.team because its a var in a file named team

sullen nymph
#

Are you sure you are not confusing fetch_application from d.py with dblpy's get_bot_info

radiant peak
#

I wanna get the upvotes later

#

this is just a test

#

but i know the error now ty anyways

restive otter
#

Why does my ready event for my webhook work, but not my vote event?

twin matrix
#

i am not able to use webhooks

#

can anybody help?

#

im using dblapi.js package

#

i need the vote event

deep estuary
#

Tell me what u need I got it

#

Ps4 only

#

No bs

vapid cape
#

@restive otter whats your configuration on your top.gg bot edit page (scroll down to webhooks, URL and Authorization)

#

@twin matrix same as above, and also show code

shrewd river
#

url ?

vapid cape
#

where is your bot hosted?

shrewd river
#

vps

vapid cape
#

then the url is http://YOUR.VPS.IP.ADDRESS:YOURWEBHOOKPORT/dblwebhook

#

for example http://123.32.52.42:5000/dblwebhook

shrewd river
#

dblwebhook need to be created ?

green mantle
#

yes....

vapid cape
#

no

#

dblwebhook is the default path used by dblapi.js

#

you can change it if you use the option webhookPath:"yourpathhere"

#

but if you dont use it, then its dblwebhook

twin matrix
#

what does this mean

#

'look for the value'

#

where to look?

vapid cape
#

dblapi.js does that for you

#

you only need that if you're listening to requests yourself through a webserver

twin matrix
#

ok thanks

#

but what should i put in the authorization part in the form?

vapid cape
#

in top.gg you write what you want

#

in your code's webhookAuth, you need to write exactly what you wrote in top.gg

hasty mortar
#

is this an example of posting the server count?

#
const Discord = require("discord.js");
const client = new Discord.Client();
const DBL = require("dblapi.js");
const dbl = new DBL('Your top.gg token', client);

// Optional events
dbl.on('posted', () => {
  console.log('Server count posted!');
})

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

i saw this on the docs

rapid kettle
#

Yes

#

That is an example of posting your server count

hasty mortar
#

ah ok

#

im new to this i just got verified

trail sigil
#

click ur bot on here

#

and that super long string of characters is the token

hasty mortar
#

oh wow thats neat never seen that before

low quail
#

are you sure it's the token? smirk

hasty mortar
#

wow!

#

it worked

#

thats so cool

#

thanks!

hasty mortar
#

how do i make the server count update on the site?

#

im using the server count example from the docs

#
const Discord = require("discord.js");
const client = new Discord.Client();
const DBL = require("dblapi.js");
const dbl = new DBL('Your top.gg token', client);

// Optional events
dbl.on('posted', () => {
  console.log('Server count posted!');
})

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

would it be

dbl.on('guildCreate', () => {
    console.log('Server count updated!');
})
```?
#

just wondering

hasty mortar
#
const snekfetch = require('snekfetch')

setInterval(() => {
  snekfetch.post(`https://discordbots.org/api/bots/stats`)
    .set('Authorization', 'YOUR DISCORDBOTS.ORG API TOKEN')
    .send({ server_count: client.guilds.size })
    .then(() => console.log('Updated discordbots.org stats.'))
    .catch(err => console.error(`Whoops something went wrong: ${err.body}`));
}, 3600000)
#

i looked in pins and that was there

#

ah

#

it doesnt work

#

oh wait yes it does indeed work

#

stops typing

#

thank you site admins!

jaunty plank
#

๐Ÿค”

#

the api by default posts updates every 30 minutes when you initilize it @hasty mortar

hasty mortar
#

Oh

#

oop

restive otter
jaunty plank
#

the 0.0.0.0 you changed just to hide your actual ip right?

restive otter
#

no

jaunty plank
#

0.0.0.0 isnt an ip

rapid kettle
#

I hope so, If you didn't change it for that, your problem is that you have to use the server's ip

jaunty plank
#

^

#

wait

restive otter
#

oh?

rapid kettle
#

port forwarding may be required

#

depends on where you're hosting

jaunty plank
#

i wonder if 0.0.0.0 is a valid ip.
i mean 1.1.1.1 is a valid ip ๐Ÿค”

restive otter
#

The webhook logged that it was running, it just wouldn't catch any votes with the vote event

jaunty plank
#

0.0.0.0 isnt your ip

#

you need to tell the website to go to your ip

rapid kettle
#

Well that's because 0.0.0.0 isn't your ip

#

(or ask your vps provider, if you use a vps)

restive otter
#

okee doke, thanks ๐Ÿ˜„

#

How am I suppose to make my bot actually use my IP? I changed the URL in the webhook options in my bot's edit page but my bot still logs the 0.0.0.0

jaunty plank
#

it will always log 0.0.0.0

restive otter
#

ah

jaunty plank
#

its hardcoded in

spiral steeple
#

0.0.0.0 is basically just an alias for "all available ips on this machine"

#

(ipv4s*)

jaunty plank
#

yeah, found it on Wikipedia

frigid basin
#

Any ideas on how I would post my shard count to top.gg too?

twin matrix
sullen nymph
#

http

#

should work

willow spindle
#

webhookAuth should be a string

twin matrix
#

and the port?

#

oh

willow spindle
#

"123"

twin matrix
#

ok

#

port is fine?

#

5000

#

when i test the webhook it doesnt return anything in my console

#

dbl.webhook.on('vote', vote => {
console.log(vote);
});

#

i have changed the auth to string

restive otter
#

Sadly, I'm dealing with the same problem as you, Firez, which everyone just told me to check if my auth, URL, and webhookauth were right, which they are.

twin matrix
#

๐Ÿ˜ฆ

#
const dbl = new DBL(DBL_API_KEY, { webhookPort: 5000, webhookAuth: 'pokescape'});
restive otter
#

It doesn't look like anything is wrong

frozen jolt
#

^

twin matrix
#

then why i wont get anything in the console

sullen nymph
#

What's that IP

twin matrix
#

does the 'vote' event runs
if i test the webhook

sullen nymph
#

Why is there two colons

twin matrix
#

k

sullen nymph
#

What's 7009

restive otter
#

Okay, I'm not sure if that is right

twin matrix
#

the ip address

sullen nymph
#

Are you sure it's a good idea to post your IP address in a public server

frozen jolt
twin matrix
#

ill check the ip address again

#

if its right or not

restive otter
#

why doesn't the api work for me?

#

I can't post my server stats

#
client.on('ready', () => {
  setInterval(() => {
    dbl.postStats(client.guilds.cache.size);
  }, 1800000);
});

dbl.on('posted', () => {
  console.log('Server count posted!');
})```
#

the 'posted' event never gets called

#

and no events are called

knotty garnet
#

The official api lib has an autoposter iirc

restive otter
#

oh it does?

#

so all I have to do is just connect?

#

yep

#

var dbl = new DBL(API-KEY-THINGY, client);
pretty much just this is all you need for the stats to update ^

twin matrix
#
const dbl = new DBL(DBL_API_KEY, { webhookPort: 7009, webhookAuth: 'pokescape' });
``` why is it not working
knotty garnet
#

It ain't a great thing to show ur auth password ig

twin matrix
#

i can change it

#

can not cant

#

xd

knotty garnet
#

Ik, but keep that in mind when showing screenshots, someone could send fake vote data to ur bot by knowing the auth

twin matrix
#

hm

#

i have alr changed it

#

so nvm

spiral steeple
#

I mean they'd need the ip first

twin matrix
#

but why does this not work

spiral steeple
#

is the port open?

knotty garnet
#

I mean they'd need the ip first
Still, better not to facilitate

spiral steeple
#

did you save before testing?

knotty garnet
#

Yeah, try using postman to see if the port is actually receiving requests

twin matrix
#

yes

knotty garnet
#
twin matrix
#

thanks

olive arrow
twin matrix
#

@restive otter my webhook worked

restive otter
#

@twin matrix What was wrong with yours and what did you do to make it work? Because mine still doesn't work lol

twin matrix
#

the ip address was wrong

#

and save the edited form and then test the webhook

#

ur webhookPort should match with the port given on ur form

restive otter
#

can i use top.gg api on python without cog?

#

or i need to use cog

#

k

true talon
#

i just have a question with the dbl webhook: should i return a 401 error if the authorization token is wrong?

sullen nymph
#

Response doesn't matter afaik

#

top.gg doesn't listen to the response

restive otter
#

question to ppl who use discord.py: how to use on_dbl_vote(data)?

#

it just wont trigger on vote

vapid cape
#

did you configure it in your top.gg edit page?

restive otter
#

configure what?

vapid cape
#

your webhook settings for your bot

restive otter
#

no

#

i dont even know the webhook link ๐Ÿ’€

vapid cape
#

where is your bot hosted?

restive otter
vapid cape
#

then your webhook url should be https://REPLNAME.ACCOUNTNAME.repl.run/dblwebhook or something like that

#

you can see it in your repl.it editor, whats your project url

restive otter
#

ok

#

and then?

vapid cape
#

did you set a webhook_path in your dblpy?

restive otter
#

no

vapid cape
#

so then your path should be /dblwebhook by default

#

your webhook URL is your project url + /dblwebhook

#

thats what you need to put in the URL field

#

in your webhook settings in top.gg

restive otter
#

ok

#

still nothing happens

vapid cape
#

do you have a webhook_auth in your dblpy?

restive otter
#

no

vapid cape
#

do you have a webhook_port?

restive otter
#

no

vapid cape
#

then you're using the wrong example

restive otter
#

then what example i should use?

vapid cape
restive otter
#

a

#

my bad

#

are webhook_auth and webhook_port required params?

green mantle
#

yes...

restive otter
#

still silence

restive otter
#

hey

vapid cape
#

show current code and current top.gg settings (url and authorization)

restive otter
restive otter
vapid cape
#

looks correct

#

are you using any other http server like flask?

#

or any other thing that listens to a port?

restive otter
#
#!/usr/bin/env python3.7
# -*- coding: utf-8 -*-

import flask, waitress
from threading import Thread

app = flask.Flask('')

@app.route('/')
def main():
    return "Bot is online and working."

def run():
    waitress.serve(app, host='0.0.0.0', port=8080)

def keep_alive():
    server = Thread(target=run)
    server.start()
vapid cape
#

idk how python works with ports, but normally you cant use the same port more than once

#

unless python somehow does some sort of redirection internally

#

try testing it without the keepalive server

#

you can also test it with postman or reqbin, should give you more information on whats wrong

restive otter
#

i cant use bot without keep_alive

#

it will shut down after 5 minutes or instantly

vapid cape
#

just for a test

restive otter
#

even without keep_alive() it still wont work

opal parcel
trail sigil
#

@opal parcel what language do you use?

opal parcel
#

js

trail sigil
#

try using the top.gg lib for this (dblapi.js)

vapid cape
#

@restive otter try testing with postman or reqbin

green mantle
#

@restive otter thats because you're using a service that isnt for bot hosting

opal parcel
#

ok i try, tnk @trail sigil

green mantle
#

ofc its going to shutdown the service if it isnt constantly being pinged

vapid mango
#

How can I put custom Prefix?

#

The code pls

trail sigil
#

you'll need to setup the ip/port too, so feel free to ask again here once you've set this first bit up

green mantle
#

@vapid mango 1) we dont spoonfeed 2) wrong channel

restive otter
#

@restive otter thats because you're using a service that isnt for bot hosting
@green mantle then why are discord bots still alive?

vapid mango
#

Oh sorry i think we was in another server

#

Sorry

restive otter
vapid mango
#

Excuse

green mantle
#

@restive otter because people dont use repl.it and actually pay for hosting...

restive otter
#

well, it's our choice, pay or not

green mantle
#

i mean you can choose to run a bot and pay or not run a bot and dont pay lol

restive otter
#

oh

#

oh

#

i received the print of vote data

#

it kinda took long

opal parcel
rapid kettle
#

That's not how DBL hooks work, I think

trail sigil
#

yeah, but glitch only has port 3000 open

restive otter
trail sigil
#

so you need to firstly set the port to 3000

restive otter
#

that's right?

opal parcel
#

so you need to firstly set the port to 3000
@trail sigil ok tnk

sullen nymph
#

api/bots

restive otter
#

ty

trail sigil
#

and then on your bot page, click 'edit' and enter the url to your glitch project, plus the port then followed by /dblwebhook

#

include the authorisation too

restive otter
#

what's wrong

trail sigil
#

you need /stats after your bot id

restive otter
#

ok

scarlet river
#

my vote webhook isnt works i copied code from docs

trail sigil
#

what do you have so far?

restive otter
#

not working

trail sigil
#

ah

#

it needs to be http not https i think @restive otter

restive otter
#

i will try

#

same

#

๐Ÿ˜ฆ

opal parcel
trail sigil
#

@restive otter you've included incorrect property names

#

it is supposed to be server_count, not serverCount

#

and shard_count, not shardCount

#

@opal parcel you need to make a server, because something else is also using that port

opal parcel
#

@trail sigil how do I do it?

#

ops

trail sigil
#

so you can try the http module to make a server

#

then just put the server into your dbl options

opal parcel
#

But how do I open server

trail sigil
#

try the http module

opal parcel
#

I download it and that's it??

#

ok

trail sigil
#

you shouldn't have to download it

#

it is a standard module that comes with node js

#

and at the constructor the the dbl api, put the server into your options

#

{ webhookServer: server }

opal parcel
#

Do I need to change anything in the code?

trail sigil
#

and remove the port

#

you can remove the middle bit with the 'request listener'

opal parcel
#

what?

#

oh 1sec

mental lotus
#

i need a api for a random cat image

spiral steeple
mental lotus
#

o ok

#

thx

opal parcel
vapid cape
#

what did you put in your top.gg edit page?

#

in the url and authorization

#

also, does "webook running at" show in your console/terminal/logs?

opal parcel
vapid cape
#

the url is wrong

spiral steeple
#

You cant post directly to a discord webhook

opal parcel
#

What am I supposed to do?

spiral steeple
#

it should go to the webserver that the lib makes for you, the url should be http://yourip:3000/dblwebhook

opal parcel
spiral steeple
#

yourip should be a public ip of the server your bot runs on

vapid cape
opal parcel
#

oh

#

1sec

#

If so, I combine them both

rapid kettle
#

I'm no API expert, but I believe yes, you just combine them

opal parcel
#

How do I combine these

rapid kettle
#

I'd say after the webhook shite, just add , client, but then again, I'm no expert

vapid cape
#

(token, {web hook options}, client)

opal parcel
#

Does not work @vapid cape

vapid cape
#

show current code and top.gg options

opal parcel
#
const dbl = new DBL('token', bot);

const dbl = new DBL(`url`, { webhookPort: 3000, webhookAuth: 'token' });

How do I combine these?

vapid cape
#

there is no url

#

its (token, {webhook options}, bot)

opal parcel
#

the url webhook

vapid cape
#

and webhookAuth is not a token

opal parcel
#

How do I combine these?

vapid cape
#

i just told you

#

twice

#

(token, {webhook options}, bot)

rapid kettle
#

I told you once, he told you twice

opal parcel
rapid kettle
#

What you put as your webhook auth in top.gg site

opal parcel
mental lotus
#

i need help how to make this

summer folio
#

How would i go about getting a DBL api key?

opal parcel
bleak bay
#

is there a way to use the widgets as images in an embed?golu_molu

vapid cape
#

@opal parcel i showed you an image

#

which part of it do you not understand

summer folio
#

Do i have to wait till my bot gets apporved to get an api?

vapid cape
#

yes

summer folio
#

daymm

bleak bay
#

is there a way to use the widgets as images in an embed?golu_molu
anybody?shitt

vapid cape
#

what widgets

opal parcel
#

I did it, I press
"Test" and it does not work @vapid cape

vapid cape
#

show current stuff

opal parcel
#

I do not need to set up the UrlWebHook anywhere?
@vapid cape

vapid cape
#

the URL is only in your top.gg options

#

there i no URL in code

opal parcel
#

@vapid cape

vapid cape
#

looks good now

jaunty plank
#

wait

vapid cape
#

always press the save button before testing

jaunty plank
#

oh nvm

opal parcel
#

yes

jaunty plank
#

can spaces be used?

#

in the path?

#

in the auth*

vapid cape
#

they'll probably be converted to %20

#

in the auth im pretty sure you can

jaunty plank
#

okay

vapid cape
#

since its a string in the headers

opal parcel
#

If I pass the bot to VPS what should I do in the URL?
@vapid cape

vapid cape
#

http://YOUR.VPS.IP.ADDRESS:PORT/dblwebhook

opal parcel
#

Where do I put the WebHook in the bot options in TOP.GG

#

?

rapid kettle
#

Down at the bottom

vapid cape
#

what webhook

opal parcel
#

To run the messages from the bot

vapid cape
#

theres nothing else to do

opal parcel
vapid cape
#

your configuration should be correct, you should receive a "user with id just voted" in your console/terminal when you press the test button

#

not http://https:// lol

opal parcel
#

what

vapid cape
#

why do you have http://https://

opal parcel
#

ah ops

#

i fix it

#

but

#

the url from the discord the webhook

vapid cape
#

there is no discord webhook

#

top.gg webhook is a different thing

opal parcel
#

Where should I put the webhook from discord

vapid cape
#

nowhere

#

just delete it

opal parcel
#

ok...

#

How did it know to which room to send the message?

vapid cape
#

it doesnt

#

it gives you a "vote" event

#

and you need to make your own code inside the .on("vote")

opal parcel
#

If I want someone to do the voting it sends a message

#

How can i do it?

rapid kettle
#

Can I make the webhook send stuff to discord webhooks

vapid cape
#
dbl.webhook.on("vote", vote => {
  let user = bot.users.cache.get(vote.user);
  user.send("bla")
})
rapid kettle
#

Thanks Tim

opal parcel
vapid cape
#

i just told you?

opal parcel
#

How it will identify the specific room.

rapid kettle
#
channel.send(`${vote.user} just voted for us on top.gg!`)``` or something similar
restive otter
#

@vapid cape is that f or py?

#

i need a similar script for discord.js

vapid cape
#

its for js

restive otter
#

i dont think that will work

#

since you need to identifiy which channel to send it into

#

and it cant start with user.send

#

it should say message.send smthing

#

let me check

vapid cape
#

user.send() will send a dm to them

#

if you want to post in a channel, you need to specify which channel

#

from client.channels.cache

restive otter
#

i think he meant to send it in server

#

because dming to the person that voted to you doesnt maek sense

rapid kettle
vapid cape
#

it does make sense, many people use it to send a "thank you" message

restive otter
#

its about api tho

#

@vapid cape do you have a script that sends it in a specific channel?

rapid kettle
#

Yes

vapid cape
#

but i just showed how to use the vote event, up to you to code whatever you want with it

rapid kettle
#

It is quite literally above

restive otter
#

even tho my bot is not approved yet ๐Ÿ˜ฆ

knotty garnet
#

you can't use the voting api until your bot get approved

#

but you can setup the code beforehand

vapid cape
#

the code is the same, all you need to do is pick a channel instead of a user

#

using a channel id

restive otter
#

731944073673441393 if this is my channel id how do i implement that into the code

#

๐Ÿ™‚

rapid kettle
#
let channel = bot.channels.cache.get("channel ID")
channel.send(`${vote.user} just voted for us on top.gg!`)```
restive otter
#

will it automaticallly know if someone voted for us?

rapid kettle
#

If you put it in the webhook event, yes

vapid cape
#

yes if you configured your top.gg settings and your dblapi.js correctly

restive otter
#

what is dblapi.js

#

:/

rapid kettle
#

the api library

vapid cape
restive otter
#

Example of using webhooks to receive vote updates

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!);
});

#

hmmm

#

ill do this tomorrow

true jay
#

@restive otter

#

naber

mild otter
#

top.gg page: http://95.121.235.145:5000/dblwebhook (numbers of ip of course not real) auth: Passione12345
code: const dbl = new DBL(topggtoken, { webhookPort: 5000, webhookAuth: 'Passione12345'}, client);

so if the test doesnt work then port 5000 is not open right?

vapid cape
#

possibly

#

depends where your bot is hosted

mild otter
#

contabo vps

vapid cape
#

check if contabo needs opening ports

#

some hosts require you to do it in their admin panels

#

if you're running a windows vps, you also need to open ports in windows firewall

#

you can also test with postman or reqbin

#

should give you a timeout error if the ports are blocked

craggy anchor
#

question about dbl webhooks - if I reload the cog that contains the webhook, will it fail to work?

barren otter
#

Hm

#

Hello

#

Hey can I ask an question

#

Are you people real or bots?

restive otter
#

Lol

barren skiff
#

I'm a bot

restive otter
#

v

jaunty plank
#

i am also a bot

sonic forum
#

I am a bot too

ripe wren
#

No you are not bpt

#

Bot

hasty mortar
#

i had that problem too

restive otter
#

ye

hasty mortar
#

oi

restive otter
#

can someone help me set up a webhook thing for when someone upvotes my bot?

jaunty plank
#

The api docs are pretty good

restive otter
#

If I host my bot on heroku, is there a certain way to setup the webhook URL since it's on heroku or can it still be https://(ip):5000/dblwebhook ?

rapid kettle
#

It can still be ip yes

#

I think at least, heroku might not have dedi IP

noble adder
restive otter
#

That's the thing, nothing works still despite my URL using my IP, and yes, I've checked all the Auths if something was wrong, made sure the code was correct, and had someone here check if my code was wrong.

rapid kettle
#

use the url, itโ€™s perfectly fine

nova sierra
#
const dbl = new DBL(config.apitoken, { 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!`);
  console.log(vote.user);
});```
Does anyone know why my console is not getting any voting updates? I loaded the code and I tried to vote but it does not give me the log.
vapid cape
#

webhooks require configuring in your bot's edit page

nova sierra
#

where do i do that?

vapid cape
#

in your bot's edit page

nova sierra
#

i just copied the url and clicking test doesnt do anything?

vapid cape
#

what url did you copy

nova sierra
#

the url that i receive on my ready log

vapid cape
#

where is your bot hosted?

nova sierra
#

local

#

but im going to deploy to heroku if it works

vapid cape
#

better testing it in heroku then

#

for home pcs, the correct url is http://YOUR.IP.ADDRESS.HERE:WEBHOOKPORT/dblwebhook

#

but home pcs usually have a firewall in their router/modem

#

that needs to be port forwarded

#

heroku doesnt have this issue

#

but heroku doesnt use IP based urls

#

the correct url for heroku is https://PROJECTNAME.herokuapp.com/dblwebhook

rapid kettle
#

im gonna make a webhook on my vps

nova sierra
#

how does the test function work? will it send a message to the console?

vapid cape
#

yes, you will receive a "vote" event

#

if it finds you

nova sierra
#

https://PROJECTNAME.herokuapp.com/dblwebhook
is this in my code or the url in top.gg

#

because i put in top.gg it doesnt work

vapid cape
#

what did you put in authorization?

nova sierra
#

do i need to put anything there

vapid cape
#

also, heroku uses port 3000

#

yes

#

you need to put your webhookAuth there

nova sierra
#

which one is webhookAuth?

vapid cape
#

the one you define in your code

#

ie, if you have webhookAuth:"password" then you write password in Authorization in top.gg

nova sierra
#

i see

#

it still doesnt work though

#

i got an error code of H14 instead of a vote log

vapid cape
#

you need to enable a web dyno in heroku

#

if you dont have one already

nova sierra
#

ah because im running free hosting so idk if running 2 dynos will double the rate of hours usage

vapid cape
#

most likely will

#

the only alternative is to use a middleman service to handle votes for you, i recall seeing something like that before

nova sierra
#

i see. i just got H10 error after switching on web dyno

vapid cape
#

what is the error

nova sierra
#

app crashed

vapid cape
#

any other logging?

#

thats not really useful

nova sierra
#

it also says web process failed to bind to $PORT within 60 seconds of launch

vapid cape
#

what port did you give it?

nova sierra
#

is it 3000?

#

or 5000

vapid cape
#

usually 3000

nova sierra
#

i gave 3000

vapid cape
#

but you can give it process.env.PORT instead to make it assign the correct port automatically

nova sierra
#

i think i got it to work??

#

if i were to get a raspberry pi to host my bot, do i keep the same settings? or is there something that i need to change

vapid cape
#

you will need to change the URL

#

if the pi is in your home network, it will be your home IP address and you need to port forward your modem/router

#

if your home has dynamic IPs, you will need a dynamic DNS service

nova sierra
#

okay tysm. just to check how long does it take for test to show up in my logs

vapid cape
#

should show instantly

#

but some people report delays of up to 30 mins when the api is having issues

nova sierra
#

alright. it doesnt show much problems rn but if something goes wrong ill just ask here again

restive otter
#

๐Ÿ‘Œ

restive otter
#

Any idea about aws webhook?

restive otter
#

which token i have to use in class DBLClient? (python)

#

ok nvm i figured it out

steep turret
#

Tem br

mild otter
#

what exactly makes the difference between
dbl.webhook.on('posted', () => {
and
dbl.on('posted', () => {

sullen nymph
#

One is wrong, the other is correct

mild otter
#

both are on the official site

#

dbl.on('posted', () => {
or will this not work when i use a webhook?

sullen nymph
#

dbl.on is the right one

#

The autoposter has nothing to do with webhooks

mild otter
#

so then this is a mistake on the website?

vapid cape
#

it seems so

#

this section is just plain wrong

mild otter
#

sherlock holmes

#

kappa

vapid cape
#

no idea how that got there

mild otter
#

so also
dbl.on('error', error => { right

dbl.webhook.on('error', error => { wrong

?

vapid cape
#

yes

#

posted and error are dbl events

#

vote and ready are webhook events

mild otter
#

lul they should defenitely update that

vapid cape
#

probably

#

@arctic arch

mild otter
vapid cape
#

yes, but you dont need that if you use the autoposter

mild otter
#

ik but just wanted to mention it

#

ahm btw is there a way to block the autoposter to post the stats if the client.user has a specific ID? for test bots? i guess only through editing the module folder right?

#

could that cause any issues?

jaunty plank
#

in my case, i just have an if and only initilize if the client id is right

mild otter
#

yeah for the full thing but for now i would need the "voted" event for testing purposes

jaunty plank
#

๐Ÿค”

#

pretty sure if you dont pass the client it wont post stats, so on test bots initlize without the client, on the real bot do

mild otter
#

ah right thanks

rapid kettle
#

does dbl.webhook.on work?

#

or is it dbl.on

willow spindle
#

dbl.webhook.on is for webhook events (ready / vote)

rapid kettle
#

good thanks

#

ok im gonna test it now

#

how long does testing usually take?

sullen nymph
#

instant to few minutes/hours

rapid kettle
#

oof, right i guess im sitting back

rapid kettle
#

ok its been a hour, is webhook test that slow?

#

it is posting to the api, just not getting any webhook stuff

vapid cape
#

test it with reqbin or postman

rapid kettle
#

Tried that

rapid kettle
#

Do I need to include port for my webhook?

vapid cape
#

where is your bot hosted

rapid kettle
#

on a VPS

vapid cape
#

then yes

rapid kettle
#

ok ill try that

restive otter
#

How can I check if a user has voted for my bot in discord.py?

#

Anyone?

torpid jewel
#

it's the ^ and the numbers next to it

#

@restive otter

restive otter
#

Huh?

torpid jewel
#

on top.gg the ^ arrow is where you can see the votes @restive otter

restive otter
#

Hmm, where exactly is this?

torpid jewel
#

@restive otter

restive otter
#

Nono thats not what I'm looking for,

#

I'm looking for how I can check whether a specific user voted for my bot in python. I'm trying to make a command where a user must vote for it to work.

torpid jewel
#

oh

restive otter
#

Yup.

#

Any idea about aws webhook?
Can anyone help with AWS guys?

granite ore
#

oops

restive otter
#

I'm trying to have my bot send a message in a specific channel whenever a vote goes through, but my channel variable always becomes undefined for some reason, making it impossible to actually send a message to the channel and my votes always return undefined with the user, so I'm unable to actually post a message about a specific user either. Does anyone have an idea for why this is happening?

dbl.webhook.on('vote', vote => {
  var channel = client.channels.cache.get("731772484285759600");
  if (vote.user) {
    //A bunch of code that's not important for situation
  } else {
      console.log("Test complete");
  }

}
jaunty plank
#

Is your client ready at that point?

restive otter
#

No, and it never goes ready for some reason

#

here's the top part of my script for the dblapi

const { Client, MessageAttachment, MessageEmbed } = require("discord.js");
const client = new Client();
const fs = require("fs");
const request = require('request');
const topGGAuth = JSON.parse(fs.readFileSync("./Scripts/websiteScripts/topGGAuth.json", "utf8"));
const DBL = require("dblapi.js");

[Edit: Problem Solved]

weak sandal
#

for node.js what did I have to download msi oder zip

median badger
#

Msi

untold sphinx
#

hi

hexed reef
#

Hi, does anyone know how to get my bot to send a message on a specific channel when someone votes?

lament cedar
#

You mean when someone reakts to a message?

hexed reef
#

When someone votes for my bot

lament cedar
#

Oh ok then i cant help

mild otter
#

You cna just do that with the vote event

#

The just client.channels.cache.get('ID').send('hello')

hexed reef
#

@mild otter Can you give me an example?

willow spindle
#

setup webhook first

rapid kettle
#

yes setup hook

#

then on vote just say vote.user voted

rigid lichen
#

Hello

#

Is there any way to check a key without updating bot's stats?

rapid kettle
#

check a key?

rigid lichen
#

I'd like to verify the dbl key

rapid kettle
#

oh

#

uh

#

thatโ€™s probably not allowed.

craggy anchor
#

is there a way to reset the webhook? without restarting the bot

rigid lichen
#

What do you mean?

rapid kettle
#

not to my knowledge

rigid lichen
#

It's to help my users to find errors in their config when they install my bot

rapid kettle
#

itโ€™s not hard to test it yourself

rigid lichen
#

๐Ÿค” test it myself?

rapid kettle
#

plus people arenโ€™t going to have top.gg tokens

rigid lichen
#

They could, there are some forks of Atlanta in this server

rapid kettle
#

if they can fork, they can get an api key working

#

itโ€™s not hard

rigid lichen
#

this is a fork of my bot

rapid kettle
#

ok, thatโ€™s fine.

#

if they get that working

#

they can easily verify a top.gg token

rigid lichen
#

How? They need to call post stats

restive otter
#

How can I check whether a specific user voted for my bot in python? I'm trying to make a command where a user must vote for it to work.

rigid lichen
#

And I don't want to post stats, I just want to check the key

rapid kettle
#

How can I check whether a specific user voted for my bot in python? I'm trying to make a command where a user must vote for it to work.
@restive otter webhooks, Iโ€™m not sure how they work in python, the top.gg docs probably have examples

#

And I don't want to post stats, I just want to check the key
@rigid lichen they get the key from the official top.gg site, then they can copy it, you donโ€™t need to check it

restive otter
#

Oh

rigid lichen
#

Thanks for your help... ๐Ÿ™„

restive otter
#

I don't know, I was checking the docs yesterday and couldn't really find anything

rapid kettle
#

there is no way to do it

#

nor would you need to do it

#

if you think that people cant copy paste a token then they shouldnโ€™t really have a bot

spark bison
#

Halo

rapid kettle
#

How do I check the authentication of my webhook vote?

#

Do any of you even read the channel topic? (TOP.GG API ONLY!!! ANY OFF-TOPIC CONVERSATION WILL BE DELETED AND MUTED...)

safe wraith
#

Ok

rapid kettle
#

Do webhooks authorise themselves?

jaunty plank
#

You mean the webhook auth?

rapid kettle
#

Yea

jaunty plank
#

In the offical js lib
The webhook checks against the webhook auth(whatever you set in your config)

#

I can find the line here in a sec

rapid kettle
#

ah, so I don't have to do anything?

jaunty plank
#

nah, no need to do anything. Just make sure your auth is secure

twin matrix
#

anyway to know the last day the user voted?

#

or after how many ms,min, hours or days the user has voted again?

placid peak
#

not in api-side in my knowledge, you have to store that information yourself.

restive otter
#

what I have to do lmao?

placid peak
#

did u do pip install dblpy?

restive otter
#

yh

#

@placid peak

placid peak
#

you use requirements.txt, right?

#

since that error

#

or smth

restive otter
#

pip install dblpy I've did, nothing more...

placid peak
#

is that error when you run your bot, or when you install that dblpy?

restive otter
#

yes

#

when I install it

placid peak
#

which version of python you use?

#

dblpy covers: 3.5, 3.6 & 3.7

sullen nymph
#

3.8 supported too

restive otter
#

oof, how to update it, I have 2.7 lmao

will google it

sullen nymph
#

Are you sure you are using the right env var

#

As in, do you have python3 or python3.x or py

restive otter
sullen nymph
#

Try the commands I listed

restive otter
#

@sullen nymph

sullen nymph
#

Use python3 -m pip or pip3, whichever works

restive otter
#

@sullen nymph both works and sends help cmds or sth like that

sullen nymph
#

pip3 install dblpy

restive otter
#

succesfully installed Dance

thx

dusky dock
#

Hey, I have tried to test a webhook on my local PC. I have port forwarded the 5000 and it's working perfectly.
The issue is, When testing a webhook in TOP GG it does nothing not even posting the server count.
I have configured everything, any mistake I have done?
def __init__(self, bot): self.bot = bot self.token = 'HIDDEN' # set this to your DBL token self.dblpy = dbl.DBLClient(self.bot, self.token, webhook_path='/dblwebhook', webhook_auth='HIDDEN', webhook_port=5000)
The Password and Token are hidden but I have added them already and the password has been updated on the TOP GG. Nothing works.

sullen nymph
#

Have you tried sending a test request with reqbin?

dusky dock
#

Yeah I have, It's Status 404

green mantle
#

youre url is wrong

#

and so is your port by the looks of it

dusky dock
#

I know, I have added /dblwebhook at the end. Whole URL is: http://IP:1500/dblwebhook

green mantle
#

okay but thats still not what your port is set to

sullen nymph
#

webook? :^)

jaunty plank
#

๐Ÿค”

dusky dock
#

I know bro, That was a snippet of the code. Everything is perfectly written, I have rechecked it. Nothing shows up.

jaunty plank
#

so your setting it to port 1500 in the code?

#

just your snippet is set to 5000?

dusky dock
#

I have set it to 1500 in code and top gg both.

#

yes

jaunty plank
#

and your path is

#

?

#

or?

dusky dock
#

/dblwebhook

jaunty plank
#

well, your not listing that in the url

#

should be http://ip:1500/dblwebhook

dusky dock
#

I know, I have added /dblwebhook at the end. Whole URL is: http://IP:1500/dblwebhook

#

I already did that above.

jaunty plank
#

is this on a vps? linux windows? home network?

dusky dock
#

Home Network

jaunty plank
#

port forward the port

dusky dock
#

I am just testing it on my pc.

#

Already did.

jaunty plank
#

also windows firewall will need it permitted

dusky dock
#

and tested on port check tool.

craggy grove
#

is voting not working right now?

jaunty plank
#

voting can be slow

#

very slow

golden adder
#

Paint spraycan tool errmahgawd

craggy grove
#

i just voted for a few bots and received nothing for it when i know they grant rewards, even my own

golden adder
#

Haven't seen that since the 90s

craggy grove
#

yea voting has been abysmally slow lately

#

10+ minute wait

golden adder
#

Yup same for everyone

#

It took 30 minutes for me the other day

jaunty plank
#

had someone add my bot to their server, got a vote, then it was kicked before they got thanked KEKW

golden adder
#

๐Ÿ˜‚

#

I get people DMing me like "where's my reward?"

#

Now most of the regulars just know it's DBL being slow

jaunty plank
#

yeah, gotta add to my page that votes are slow recently.

golden adder
#

I put it in my support server

#

Status channel

jaunty plank
#

i have one person in my support server

golden adder
#

You?

#

๐Ÿ˜‚

jaunty plank
#

i like to think it means my bot is perfect

#

lolol

craggy grove
#

I get people DMing me like "where's my reward?"
same dude for a while i thought it was an issue on my end

jaunty plank
#

I have rewards coded but not enabled for top.gg.
Hoping the delay issues get fixed before too long so I can enable them.

golden adder
#

Well there are often glitches like this. It was the same a couple of months ago

#

The api can be a bit dodgy

#

Don't wait for it to be flawless otherwise you'll never enable them ๐Ÿ˜‚

#

Like it seemed to be ok for me over the weekend, but today it was kinda slow again

formal sparrow
#

What's wrong with the API

#

People voting and it doesn't seem like I'm receiving in <dbl>.webhook.on('vote',..)

#

Is there any bug

jaunty plank
#

@formal sparrow votes take awhile to be received.
Can be 30 minutes

restive otter
#

Hi

formal sparrow
#

Wah

#

Will they come tho?

restive otter
scarlet river
#
const dbll = new DBL(require("./conf.json").dbl, { webhookPort: 5000, webhookAuth: 'whyareyoulookingherelol' });
dbll.webhook.on('ready', hook => {
  console.log(`Webhook running at http://${hook.hostname}:${hook.port}${hook.path}`);
});
dbll.webhook.on('vote', vote => {
  client.channels.cache.get("731235069867589783").send(`${vote.user} just voted.`)
});
#

its not working

#

why

rapid kettle
#

So, any idea why my dbl webhook isn't working, and how would I test it? Here is my dbl.webhook.on event dbl.webhook.on('vote', vote => { console.log(`User with ID ${vote.user} just voted!`); const channel = client.channels.cache.get("732691255452237904") channel.send(`${vote.user} just voted for us on <https://top.gg/bot/716061781172158464/vote>`) }); and my dbl constructor const dbl = new DBL('token', { webhookPort: 5000, webhookAuth: 'auth' }, client);

formal sparrow
#

Some problems in da API

rapid kettle
#

So my code is correct?

jaunty plank
#

You set the webhook on your bots edit page right?

rapid kettle
#

yup

jaunty plank
#

Theres a site for testing webhooks, cant remember the name

rapid kettle
#

what does dbl webhook respond with?

scarlet river
#

Some problems in da API
@formal sparrow no i guess, a bot can use correctly webhook vote

jaunty plank
#

Pretty sure whats sent is on the docs

rapid kettle
#

ah yea

formal sparrow
#

@formal sparrow no i guess, a bot can use correctly webhook vote
@scarlet river a bot?

#

Which bot

craggy grove
#

the api is most likely having problems, i tested voting on multiple bots including my own and nothing happens

rapid kettle
#

yes api is having problems

formal sparrow
#

I also tested and got no response, there's problem in API, I'm 100% sure

scarlet river
jaunty plank
#

Yeah, worked for me earlier

#

I'll try again

formal sparrow
#

Doesn't work for me still

jaunty plank
#

It can take 30 minutes

formal sparrow
#

But will it arrive

jaunty plank
#

๐Ÿคทโ€โ™‚๏ธ

#

We will find out

rapid kettle
#

nobody knows

formal sparrow
#

Are they aware of this issue?

jaunty plank
#

Of it taking a long time?

#

Or it not sending?

formal sparrow
#

Not sending

rapid kettle
#

Not sending

formal sparrow
#

If it's taking long time, it must be at least 30 mins

#

No received a response for 30 mins

rapid kettle
#

Same

#

I send a test to my hook, yesterday

formal sparrow
#

The question is, do the admins know about this issue?

rapid kettle
#

Yea, veld is working on it AFAIK

jaunty plank
#

The slow response they know about.

scarlet river
#

why my hostname 0.0.0.0 (i guess its not normal)

rapid kettle
#

thats all avaliable ips to that machine

jaunty plank
#

The lib has it hard-coded to say 0.0.0.0

#

๐Ÿค”

#

well

#

its been about 30 minutes

#

still nothing

restive otter
#

Some people had to wait for 2 hours

jaunty plank
#

wow its been real extra bad today

#

ay

#

took almost 50 minutes

#

but it came through

#

@rapid kettle

rapid kettle
#

ayy

#

same

#

took 1 hour here

#

@jaunty plank

jaunty plank
#

oof

#

feels bad

#

i wonder why its so slow

rapid kettle
#

How do I get username

#

and not just 265925031131873281

sullen nymph
#

getUser

rapid kettle
#

The webhooks are faster now

jaunty plank
#

oo

restive otter
#

is there a way to get the list of users who upvote a bot, and how many votes they have ?

rapid kettle
#

What language?

restive otter
#

python

rapid kettle
#

I think there is a way to do that

#

idk much about python sry

cerulean monolith
#

??

hexed reef
#

Is it possible to create a webhook on discord and put it on top.gg?

rapid kettle
#

No.

hexed reef
#

Is it possible for my bot to send messages when someone votes for my bot?

rapid kettle
#

Yes.

hexed reef
#

how do you do?

rapid kettle
#

DBL webhooks

hexed reef
#

But I would be creating a webhook, right?

rapid kettle
#

Nope.

hexed reef
#

could you give an example of code that makes my bot send a message when someone votes for my bot?

#

But if I want my bot to send a message when someone votes for it, why is it in the webhooks section?

rapid kettle
#

Because it uses a top.gg webhook

hexed reef
#

But then what do I put in the URL field?

rapid kettle
#

your.vps.ip.address:5000/dblwebhook

#

taking that you are using the example code

hexed reef
#

How to find my vps?

median badger
#

It will be on your vps panel

#

Somewhere

hexed reef
#

Where is this vps panel?

rapid kettle
#

where do you host your bot?

hexed reef
#

Can I send the website link?

rapid kettle
#

DM

restive otter
#

Is there something wrong about this? Because it doesn't post my server count automatically on the website

const topGGAuth = JSON.parse(fs.readFileSync("./Scripts/websiteScripts/topGGAuth.json", "utf8"));
const DBL = require('dblapi.js');
const dbl = new DBL(topGGAuth.Auth, {
        webhookPort: process.env.PORT, webhookAuth: topGGAuth.webAuth }, client);
rapid kettle
#

that should be right

restive otter
#

I'd think so too since the voting works right, just not the automatic stats posting. Maybe it's my client doing something wrong

restive otter
#

Same issue

bronze arch
#

I'm using dblapi.js and have had problems where a vote takes about 3 hours to register. Had anyone else had this problem?

#

^ ping me if you have any comments or questions

bitter terrace
#

I've been having that problem too. People report that their votes don't show up and they don't get the rewards. It's frustrating ๐Ÿ˜ฆ

gentle hawk
#

how i can make thin one

#

in JDA

trail sigil
#

@restive otter not here

#

or anywhere in this server

scarlet river
#
const app = express();
const server = http.createServer(app);
const dbll = new DBL(require("./conf.json").dbl, { webhookPort: 5000, webhookAuth: 'whyareyourlookinghere', webhookServer: server });
dbll.webhook.on('ready', hook => {
  console.log(`Webhook running at http://${hook.hostname}:${hook.port}${hook.path}`);
});
dbll.webhook.on('vote', vote => {
  client.channels.cache.get("731235069867589783").send(`${vote.user} just voted.`)
});
app.get("/", (request, response) => {
  response.sendStatus(200);
});
server.listen(5000, () => {
  console.log('Listening server...');
});
#

why its not working

trail sigil
#

@scarlet river have you setup the url to the webhook on your top.gg bot page?

restive otter
#

^ that and also if you have firewall rules setup properly on your server it can cause problems if you didnt allow port 5000

#

like on an ubuntu server if ur using ufw just do a quick ufw allow 5000

scarlet river
#

@trail sigil yep

#

i set password and

trail sigil
#

you did it as http://yourip:port/dblwebhook ?

scarlet river
#

yes

trail sigil
#

it needs to be http

#

and 0.0.0.0 is not ur ip

scarlet river
#

i said wrongly https

#

and why my ip is 0.0.0.0

#

idk

trail sigil
#

just search on google 'what is my ip'

#

or use the ip of ur vps

scarlet river
#

i host my bot on heroku

jaunty plank
#

0.0.0.0 means all available ip's

trail sigil
#

ah, im not too sure about heroku tbh

#

is there like a project ip/url?

scarlet river
#

idk exactly

scarlet river
#

ty

sullen nymph
#

read just below the message I sent

gentle hawk
sullen nymph
#

Anything you want to be a password

gentle hawk
#

i will make a channel and ther send the Bot(webhook) {user} vote {bot}
@sullen nymph how i can make?
Can you send me a code and werde i find my infos?

sullen nymph
#

webhookAuth is just a password you create for yourself to confirm that the requests come from top.gg

#

on vote, you get a channel from cache and send a message

gentle hawk
#

i have npm i express

restive otter
whole night
#
400 Bad Request (error code: 50035): Invalid Form Body
In embed.image.url: Not a well formed URL

can anyone tell me why this error occured while trying to set embed.set_image to a gifs url , it's only happing for some gifs

restive otter
#

How can I check whether a specific user voted for my bot in python? I'm trying to make a command where a user must vote for it to work.

frigid basin
scarlet river
frigid basin
#

That only shows server count

sullen nymph
#

shard_count oop

frigid basin
#

await self.dblpy.post_shard_count?

#

I'll just wait the half hour for it lol

sullen nymph
#

@frigid basin post_server_count accepts shard_count argument

restive otter
#

am i able to setup the posting of stats like guilds etc before the bot is approved?

#

or do i have to wait

rapid kettle
#

Have to wait.

bronze arch
#

does anyone know a workaround, fix, or reason why the webhook sometimes take 3 hours?

rapid kettle
#

No idea, just that it's happening to me

#

The API is just slow at some points

restive otter
#

How can I check whether a specific user voted for my bot in python? I'm trying to make a command where a user must vote for it to work.

#

No one answer my question wtfrick

#

weebhook

#

download ayayaya 10 hours

sleek sinew
#

Quick question, where can I find the latest version for the DBL Java library? I'm helping someone edit their bot and their DBL dependency seems to be outdated. I tried looking it up but found nothing

gentle pewter
#

one sec

#

2.0.1

tame trail
restive otter
#

discord bot*

#

And yes it can

median badger
#

But pingers are banned

#

So not really at the same time

gentle hawk
#

is there a vote listener in JDA?

gentle hawk
#

pls ping me

shrewd barn
#

why am i getting {"error":"Unauthorized"} when trying to post my bot's stats?

sullen nymph
#

Token either not set or invalid

shrewd barn
#

it's set and probably valid because is obtained via the My Bots page

sullen nymph
#

Try to reset it

shrewd barn
#

just tried. still getting the error

#

tried again and it worked. thanks

astral plaza
#

hello just wondering so this is a code i found in the docs

  dbl.webhook.on('vote', vote => {
  console.log(`User with ID ${vote.user} just voted!`);
});```

Can i use it but not as a webhook?
rapid kettle
#

no

#

you must have a webhook

astral plaza
#

how can i make it give a reward

#

or do i check it

#

then

#

if found he gets the reward

storm iron
#

i think u should have a db

astral plaza
#

i know

#

bruh

latent narwhal
#

Where can I get API

#

Of DBL

storm iron
#

i'm just saying don't bruh at me

latent narwhal
#

To give people a shout-out

#

Who voted

storm iron
#

it is on their site

latent narwhal
#

Ook

astral plaza