#topgg-api

1 messages Β· Page 69 of 1

late crater
#

You could go through the shards

fiery tree
#
@tasks.loop(seconds=1800)
async def change_presence():
    guilds = await client.fetch_guilds().flatten()
    status = discord.Activity(type=discord.ActivityType.watching, name=f'for &help | Rolling for {str(len(guilds))} servers')
    await client.change_presence(activity=status)```
#

this is how it was before

#

i dont have any shards

late crater
#

Oh

#

I think fetch_guilds only gets a certain amount

fiery tree
#

then how are you getting your server count?

late crater
#

len(self.bot.guilds)

#

For you it would prob be client.guilds

#

Lemme read docs

fiery tree
#

ok so

#

it works?

#

huh

late crater
#

Can confirm

fiery tree
#

the why did they recommend me fetch_guilds?

#

thats weird

#

either way thanks man

late crater
#

Idk why they did

#

You could use fetch_guilds if you really wanted to

#

But

#

The default limit is 100

#

That’s why you only got a server count of 100

fiery tree
#

oh, that explains a lot

#

man i should look into the docs more

#

took at face value what they gave me

late crater
#

Welp, now you know

fiery tree
#

yeah

late crater
#

Always check the docs

#

Iapetus11: After around 45 minutes of unwillingness to read any documentation, I think I got it to work properly!

sweats nervously

delicate aspen
#

question, been trying for awhile to get my vote command to work. I can redirect them, they can vote,
I just can't connect my bot(s) to DBL to see if they actually voted.
any help would be amazing thank you :)
PS I've looked on YouTube and GitHUB but nothing has helped, at least not what I've found

narrow zenith
#

did you use your api token?

silk bluff
#

How to make server count work on top.gg?

late crater
silk bluff
#

Need help configuring webhooks

#

What do i need to add here

gray vault
#

@topaz wyvern hello, refreshing the server gives an error 500 Internal server error, server lost?

If you believe something should be here contact us through our Discord Server or at support@top.gg
Login | Return Home

spiral steeple
#

500 is a server error

#

And dbl has more server errors than any website I've ever seen

gray vault
#

alright, what can I do now to fix that?

spiral steeple
#

nothing

#

it's a server error

gray vault
#

np, it worked now.

silk bluff
#

Ay?

#

What to add there??

#

Need help with webhooks

delicate aspen
#

ive added my token i just can't / don't know how to use the API fully. I'm still learning everything as i go, sorry if i ask dumb questions :/
Just decided one day i wanted to torture myself and teach myself how to make discord bots

sweet urchin
#

Webhook is not sending.

#

it works on my end as I have tested it and get a response.

tame kindle
#

can you show the code

sweet urchin
#
module.exports = Noel => {
    dashboard.get('/votehook', (re, res) => {
        console.log(re.headers) // Just getting headers from response
    });
};
#

it works fine

#

Just not getting ones from top.gg

tame kindle
#

it has to be a POST request

sweet urchin
#

ahhhh

tame kindle
#

not a get request

sweet urchin
#

I c

tame kindle
#

what ur doing is

sweet urchin
#

Getting a request

#

yea

tame kindle
#

yea

sweet urchin
tame kindle
#

also the data top.gg is gonna send is in Request#body (if you're using express)

sweet urchin
#

aite

#

hmm

#

using the test button still doesn't seem to send

#

or my server receive

sweet urchin
#

nvm, it works now

grave jetty
#

I

silk bluff
#

Aye?🀣

#

Can someone help me with those webhooks?

#

Please?πŸ˜‚

hollow iron
#

Isn't this supposed to work?

dbl.isWeekend(weekend => {
            let WeekEnd = 'false';
            if (weekend) WeekEnd = 'true';
            else if (!weekend) WeekEnd = 'false';

The database had weekend as false, even though it's weekend.

sullen nymph
#

It returns JSON with isWeekend key storing a boolean value

hollow iron
#

Oh, so I should do weekend.isWeekend instead?

sullen nymph
#

Yup

hollow iron
#

Aright, thank you.

sullen nymph
#

Or so I would guess since I never worked with JS

hollow iron
#

So, I've just put my code as

#
dbl.webhook.on('vote', vote => {
    console.log(`Thanks to ${vote.user} for voting!`);

    fse.readJson(`databases/voters.json`, (err, db) => {
        if (err) return console.error(err);
        dbl.isWeekend(weekend => {
      let WeekEnd = 'false';
      let booster = '1.15';
        if (weekend.isWeekend) {
                WeekEnd = 'true';
            booster = '1.3';
        }    
                let twoh = 1000 * 60 * 60 * 2;
            let TIME = Date.now() + twoh;

            let devGuild = client.guilds.get(`642304841170812939`);
    let channel = devGuild.channels.get(`651059734077767680`);
    let msg;
    if (devGuild.members.get(vote.user)) msg = `Thanks to <@!${vote.user}> for voting!\nThey've just recieved a global ${booster} XP Booster for 2 hours!`;
    else if (client.fetchUser(vote.user)) msg = `Thanks to ${client.fetchUser(vote.user).tag} for voting!\nThey've just recieved a global ${booster} XP Booster for 2 hours!`;
    else msg = `Thanks to ${vote.user} for voting!\nThey've just recieved a global ${booster}x XP Booster for 2 hours!`;
    channel.send(msg);

            db.users[vote.user] = {
                voted: 'true',
                TIME: TIME,
                Weekend: WeekEnd
            }
            fse.writeFile(`databases/voters.json`, JSON.stringify(db, null, 2));
        });
    });
});
#

And the only output I get is a log

#

And nothing got stored in the database.

#

And now I just commented everything about the weekend stuff, and then it returned more than just a log

#

It actually doesn't get inside of the event at all.

#

Or, it doesn't get inside of the isWeekend function.

#

Ok I found the issue.

  1. I used dbl.isWeekend(weekend => { when it's actually dbl.isWeekend().then(weekend => {
  2. Trying out if (weekend.isWeekend) { was another error, as apparently it's supposed to be if (weekend) { instead
#

I found the issue while looking over the api documentation again.

#

Also, can I emit a vote event? So like, without the vote counting on the site, I can emit it with vote.user being someone else's user id?

silk bluff
#

Ello?🀣

#

What do I need to put in password??

#

For code found in discord developer docs (language:Discord.JS)

hollow iron
#

Go to your bots edit page, and you can decide it yourself. @silk bluff

silk bluff
#

??

hollow iron
silk bluff
#

Okie

hollow iron
#

It's all the way at the bottom of your edit page for your bot.

restive otter
#

All Stars Music

#

Β‘Hi! I'm Blade

sullen nymph
#

@hollow iron test button

#

It fires the vote event iirc

hollow iron
#

No, I mean for others, example when they vote, but doesn't get their rewards because of a bug or me updating the bot.

sullen nymph
#

Oh, uhh

hollow iron
#

So then I can do %fixvote <mention>

silk bluff
#

Um?

#

Unable to set it up πŸ™

hollow iron
#

I could put all the code into a command, but I feel like emitting the event instead would be a lot easier.

silk bluff
#

How do I get message to my guild when my bot is voted?πŸ™πŸ™

#

How do I configure it that way

#

And which hosting?πŸ™

sullen nymph
#

Ehh there isn't an easy way to guess if a user has actually voted 10-60 minutes before executing a command
Unless you want to restrict that command to yourself?

silk bluff
#

πŸ˜•

hollow iron
#

I do want to restrict it to myself.

#

As the vote event does it automatically, unless the project restarts

#

And @silk bluff I use this

        let devGuild = client.guilds.get(`642304841170812939`);
    let channel = devGuild.channels.get(`651059734077767680`);
    let msg;
    if (devGuild.members.get(vote.user)) msg = `Thanks to <@!${vote.user}> for voting!\nThey've just recieved a global ${booster} XP Booster for 2 hours!`;
    else if (client.users.get(vote.user)) msg = `Thanks to ${client.users.get(vote.user).tag} for voting!\nThey've just recieved a global ${booster} XP Booster for 2 hours!`;
    else msg = `Thanks to ${vote.user} for voting!\nThey've just recieved a global ${booster}x XP Booster for 2 hours!`;
    channel.send(msg);
sullen nymph
#

Spoonfeed rule

silk bluff
#

Lol

sullen nymph
#

ig put all the code that is executed on vote into some function attached to your bot's variable that you will call on a command execution

#

"which hosting" what does that question even mean

silk bluff
#

Lol

hollow iron
#

Alright, so pretty much, just paste my code into a command.

silk bluff
#

Where do I create a webhook

sullen nymph
#

... or that, yeah

silk bluff
#

I am new to coding 🀣

sullen nymph
#

Do you know what a webhook is

silk bluff
#

Yep

#

Webhook sends updates when a specific event occurs

#

Using HTTP POST

sullen nymph
#

More or less

#

A webhook is a program that runs on a machine expecting HTTP requests, essentially

silk bluff
#

Yep πŸ˜‚

#

But where do I create them?

sullen nymph
#

Wdym "where"

#

Are you using some special host

silk bluff
#

Yep

#

Integromat

#

....

#

Lol

#

Is there any other free hosting?

sullen nymph
#

Good lord, is Integromat similar to IFTTT

silk bluff
#

YepπŸ˜‚

#

IFTTT

sullen nymph
#

That ain't "hosting"

silk bluff
#

Lol?

#

This one πŸ˜‚

sullen nymph
#

Why am I getting 3 fckin ads for Integromat, Google thid ain't right

silk bluff
#

πŸ˜•

#

Wait πŸ˜‚

#

You know any free hosting and its configuration?

sullen nymph
#

"free hosting" does not exist as it requires maintaining a machine and Internet connection

hollow iron
#

@silk bluff try Glitch. It works pretty well. You can just set up 2 projects constantly pinging each other, and a uptime robot for your non-main project. So that way it will never go off.

silk bluff
#

I have glitch account

sullen nymph
#

Or just use a cheap VPS like a sane person

silk bluff
#

And its configured

#

But how to create a webhook then?πŸ˜‚

hollow iron
#

I have no income, so I just use Glitch with http constantly pinging every 1 minute.

silk bluff
#

Same πŸ˜‚

#

But I ping it at 3 minutes

sullen nymph
#

So why are you using Integromat

sharp wigeon
#

There is no "free" hosting, there is always a catch. Like heroku, it goes to sleeps automatically after 10 minutes

silk bluff
#

Lol

hollow iron
#

Glitch sleeps after 5 minutes.

silk bluff
#

For heroku I have procfile

hollow iron
#

Unless you pings it

silk bluff
#

Keeping it online πŸ˜‚

#

With procfile

sullen nymph
#

Literally run a webhook on one of your machines, use port 3000 and make your code send a request to Discord webhooks

silk bluff
#

But how to create a webhook?

#

πŸ˜• πŸ˜• 😭

sharp wigeon
#

Use a cheap vps, and theres no problems lol

sullen nymph
#

Use an official DBL library if you are too lazy to research on how to create one

silk bluff
#

Lol

#

This one?

#

I don't understand this

sullen nymph
#

You linked API docs but yes

#

An official DBL library for your programming language

silk bluff
#

Yeps

#

It exists

#

But howto config it?

#

Like the port and paths

sharp wigeon
#

It reads on the website

#

Read it

silk bluff
#

And passwords

sullen nymph
#

Did you evem read the docs

silk bluff
#

Yess

sullen nymph
#

webhookAuth is anything you come up with

silk bluff
#

....

sullen nymph
#

webhookPort for Glitch is 3000

silk bluff
#

Okie

#

Thanks

sharp wigeon
#

Ok cheapskate

silk bluff
#

πŸ™

sullen nymph
#

refer to this channel's topic

silk bluff
#

How about url?

#

What to add in url?

sullen nymph
#

http://<projectname>.glitch.me/<webhookpath>
I hope you know what the stuff between <> needs to be replaced with

silk bluff
#

<webhookpath>

#

What to add there?πŸ˜‚

#

πŸ˜• πŸ˜•

sullen nymph
#

What library do you use for your bot

silk bluff
#

Discord.js

hollow iron
#

not that one

silk bluff
#

Node.js

hollow iron
#

not that one either

silk bluff
#

Lol?

sullen nymph
#

Library, not language

silk bluff
#

Dblapi.js

hollow iron
#

close

silk bluff
#

...

#

Then?πŸ˜‚

hollow iron
#

Can I say it?

silk bluff
#

Yes

sullen nymph
#

So let's get back to dblapi.js example and see what webhookPath is

silk bluff
#

Okie

sullen nymph
#

Wdym Apexio, what are you even taking about

hollow iron
#

The weebhook path

silk bluff
#

..πŸ˜•

silk bluff
#

@hollow iron you know how to config webhook on glitch?

sullen nymph
#

Am I not helping you with that

hollow iron
#

Exact same as everywhere else.

sullen nymph
#

You run the webhook on port 3000

silk bluff
#

Okie

#

Then =>

#

Webhook path?

hollow iron
#

shivu, can I say what the webhook path is for me?

sullen nymph
#

Why does it matter

silk bluff
#

.....

hollow iron
#

Trying to help them, but I don't know if that would be spoonfeeding to just tell him what it is.

sullen nymph
#

Ehh I'd rather open their eyes and let them rtfd than just spoonfeed

hollow iron
#

Alright.

sullen nymph
#

Too many people already don't like reading docs because they expect others to give everything to them

silk bluff
#

How about webhook path?

#

....

hollow iron
#

@silk bluff Try logging the webhook path.

silk bluff
#

..?

#

How

#

😭

hollow iron
#

Use console.log

silk bluff
#

Okie

hollow iron
#

That's what you always use to find information from things you're unsure about.

silk bluff
#

Console.log(${webhookpath})

#

Is that correct?

hollow iron
#

Not exactly

#

Check the docs

#

And you will see how.

sullen nymph
#

read dblapi.js example

#

specifically the line where webhookPath is mentioned

silk bluff
#

😭 πŸ˜•

#

Can't understand that

hollow iron
#

It's literally stated so high up on the page, you just can't miss it.

silk bluff
#

Api docs

hollow iron
#

JavaScript > Example > Example of using webhooks

#

it's literally stated in the title

#

Example of using **webhooks**

silk bluff
#

This doesn't work for me

hollow iron
#

Bruh, I told you to log the path.

silk bluff
#

Password?

hollow iron
#

You will see how in there.

silk bluff
#

πŸ˜•

hollow iron
#

The password is the authentication you should've set up earlier.

sullen nymph
#

"anything you come up with" = "anything you can think of"

#

Password != path

silk bluff
#

yourDBLTokenHere

#

πŸ˜•

#

Whats that?

#

DBL token?

#

Are they same??

sullen nymph
#

Yeah

silk bluff
#

Thanks

gaunt steeple
#

hmmm

#

@silk bluff i misread your nickname as FART HASHE

sweet urchin
#

I swear somethings not right with the webhooks...

#

It was working fine yesterday

#

Tested it

#

and now it's stopped

#

nothing has changed

sullen nymph
#

Works fine for me

sweet urchin
#

It was for me yesterday

#

and now it's not

late crater
#

Check to see if you accidentally reset your token, half the time I do it when I’m doing stuff on mobile and I have to vnc over to my β€œserver” and restart my bot with the correct tokens

sweet urchin
#

it's not using the token

#

using express for the webhook server.

late crater
#

Did you accidentally exceed the rate limit?

sweet urchin
#

Nope, I don't think so

late crater
#

Sorry, idk

sweet urchin
#

bots only had like 4 votes since it was added

#

and none shown on the votes channel I set.

late crater
#

Idk, what language are you using?

sweet urchin
#

js

#
dashboard.post('/votehook', (re, res) => {
        if (re.headers.authorization === `${tSettings.auth}`)
            Noel.fetchUser(`${re.body.user}`).then(async usr => {
                const voteEmbed = new Discord.RichEmbed()
                    .setColor(0x8CDFFC)
                    .setThumbnail(usr.avatarURL)
                    .setTitle(`User Voted`)
                    .addField('ID', `${re.body.user}`, true)
                    .addField('Username', `${usr.username}#${usr.discriminator}`, true)
                    .setTimestamp();
                Noel.channels.get("652341632879820800").send(voteEmbed);
            });
    });
#

That's what I've got for it.

#

(runs on port 80)

silk bluff
#

Unable to find my webhook path πŸ™

#

Getting this 😭 😭

#

For webhook port =3000 using glitch

sweet urchin
#

the ports already being used by something else

#

stopping the webhook lib from using it

silk bluff
#

How do I fix this?

#

Switching to another port?

summer hawk
#

@silk bluff Can you see which file the problem is in?

#

Or if you can link me to join the project, I can help you.

#

@silk bluff

sullen nymph
#

@late crater Webhooks aren't affected by ratelimits

#

where did you even get that idea from

dense basalt
#

They have their own rate limits though

sullen nymph
#

Are we talking about the Discord or "DBL" ones

gaunt steeple
#

Did you accidentally exceed the rate limit?

#

wait, theres a rate limit for webhooks?

#

thats a bit backwards, as your system isnt causing them

limber bramble
#

Pin me whene we have a answer please

sullen nymph
#

@limber bramble Try resetting your token

limber bramble
#

Ok

#

Thanks bro it's working now πŸ˜„ @sullen nymph

silk bluff
#

Hello

#

@sullen nymph

#

I found my webhook path

#

Sorry for ping πŸ˜‚

#

But it seems wrong

#

0.0.0.0:3001

#

Is that correct or not?πŸ˜‚

late crater
#

0.0.0.0 refers to your machine only on your machine

#

You need to use a global ip, not 0.0.0.0

#

Also your webhook path is whatever you set it to, I believe the default is ip:port/dblwebhook

silk bluff
#

πŸ˜‚

#

How to?πŸ˜‚

#

Using glitch

late crater
#

I don’t know exactly how on glitch

silk bluff
#

Okie

#

Using default code for js

#

Listed on docs

#

Developer docs

late crater
silk bluff
#

Thanks!

#

But it shows port is occupied?

sullen nymph
#

Didn't I put my 5 cents in about that

#

Doesn't look like it
Either way, the port is in use by something else that you are running

#

Turn that off

spiral steeple
#

Probably an uptime robot

sullen nymph
#

Hello darkness my old friend

spiral steeple
#

In which case you need to pass the http.Server

silk bluff
#

What?

#

How do I turn that port off

#

Means don't let anyone else use it?

#

Yes thats a uptime bot

dawn kernel
#

My bot stats haven't been updating for weeks

#
    fun updateTopDotGG(serversArray: List<Long>) {
        val token = settings.tokens.topDotGG
        val url = "$TOP_GG_URL/bots/${settings.id}/stats"
        if (token.isBlank()) return
        taskManager.async {
            val body = MultipartBody.Builder()
                .setType(MultipartBody.FORM)
                .addFormDataPart("shards", serversArray.joinToString(",", "[", "]"))
                .build()

            val request = Request.Builder()
                .addHeader("Authorization", token)
                .url(url)
                .post(body)
                .build()

            httpClient.newCall(request).enqueue(defaultCallbackHandler)
        }
    }```
#

ok so

#

I forgot api

#

now this

#

does it need json instead

#

ok I guess it does

#

bruh

sullen nymph
#

www-form-urlencoded

dawn kernel
#

same error shivuwu

#

404

sullen nymph
#

/api/bots

#

Not /api/bot

dawn kernel
#

I see I'm blind

#

owo

#

Array of Numbers

#

The amount of servers the bot is in per shard.

#

I'm confused

#

I think I got this working

#

thx for poining out my wrong things

silk bluff
#

Hello

#

I created a webhook successfully but

#

It doesn't show any log about user who voted for my bot

sweet urchin
#

They are in the request body

silk bluff
#

??

#

How to get them?

sweet urchin
#

Are you using the dbl library or something else?

silk bluff
#

Yes

#

Dblapi

#

Dblapi.js(module name)

sullen nymph
#

Are you using the events provided by dblapi.js webhook

silk bluff
#

Yes

sullen nymph
#

Show your code

silk bluff
#

Okay

heady cradle
#

maybe he means that he has built up the code, but the connection isnt being made

late crater
#

If you need to test webhooks, you can find a test button at the bottom of the top.gg edit page for your bot! Of course, you will need to add an event listener for the test.

silk bluff
#

Tested it

late crater
#

Did you get anything back?

silk bluff
#

Nopes

#

Shows it may take a few seconds

late crater
#

It’s usually immediate

sweet urchin
#

I have the same issue

silk bluff
#

Lols

sweet urchin
#

using express or the dbl module

silk bluff
#

Dbl

late crater
#

what language?

silk bluff
#

Js

sweet urchin
#

my bot wont receive the webhook

silk bluff
#

Yeps

sullen nymph
#

Are you using the port 3000, Fate

silk bluff
#

Same

#

Yes

#

3000

sullen nymph
#

And are you sure the URL you entered is correct

silk bluff
#

Yes

sullen nymph
#

You exposed your bot token

late crater
#

Your token is showing

silk bluff
#

Lols

#

Regenerated it

#

No worries

late crater
#

Scroll to the right, so we can see the rest of the code

sullen nymph
#

Are you sure it's not erroring out somewhere in the code

silk bluff
#

nopes

late crater
#

Also you don’t have a listener for a webhook test

sullen nymph
#

There isn't one

late crater
#

I guess it’s just for python then

#

?

sullen nymph
#

Yes, I did that intentionally

#

Because imo it's easier to maintain two different events for each type of request rather than have it all under one with 2 checks

silk bluff
late crater
#

Censor your stuff bro

sullen nymph
#

Send screenshot of your bot's webhook settings on its top.gg Edit page in my DMs

late crater
#

Also password9090 is not the greatest password

silk bluff
#

lol

#

resets password

sullen nymph
#

It's http

#

not https

#

Also I hope your Glitch project is private

silk bluff
#

yes

#

xD

#

http

#

changed

#

now if someone votes

#

will it show updates?

sullen nymph
#

Save the changes and press test

silk bluff
#

pressed test

#

nothing happens

late crater
#

I don’t think you have anything display in the console when someone votes

silk bluff
#

um

sullen nymph
#

Did you even read their code

silk bluff
#

console.log(`User with ID ${vote.user} just voted!`);

#

xD

late crater
#

Sorry was reading the first version he posted

sullen nymph
#

Did it log anything

late crater
#

Either that or I’m blind af

silk bluff
#

nopes

#

now?

late crater
#

Nvm I’m just blind af

silk bluff
#

lol

sullen nymph
#

Did you make sure to press save

late crater
#

Well the user is probably null cause it’s a test

silk bluff
#

nopes

sullen nymph
#

It's never null...

silk bluff
#

i saved

#

I voted just now xD

sullen nymph
#

That's literally what I asked just now

silk bluff
#

doesn`t show

sullen nymph
#

Did you press "Save"

silk bluff
#

saved

sullen nymph
#

on the edit page

#

now test

silk bluff
#

I pressed save

#

testing...

#

Webhook tested! This may take a few seconds

sullen nymph
#

Any output

silk bluff
#

no log updates

#

sad

late crater
#

sorry I’m being extremely unhelpful, I have almost 0 knowledge of js. Just tryin to help

silk bluff
#

np

#

atleast you guys helping me

late crater
#

If it’s a webhook test, there shouldn’t be a user, right? If so there would probably be an error from trying to use vote.user?

#

Ignore that fate

sullen nymph
#

There's always a user

late crater
#

So test just passes the bot owner instead of the voter?

silk bluff
#

um I tried to vote it from my friend`s account

sullen nymph
#

Yes

silk bluff
#

no log updates

late crater
#

Ah ok

silk bluff
#

now?

#

anything wrong with code??

sullen nymph
#

The only thing optional in vote data is query, the rest is always sent

silk bluff
#

.....

sullen nymph
#

Why do you keep sending the dots

#

I would suggest randomly poking restarts at the code and testing since I'm shit outta luck and clue

silk bluff
#

sad

late crater
#

Maybe try making sure all the tokens/keys/passwords are correct?

silk bluff
#

correct

late crater
#

Ok

silk bluff
#

cleared all the code

late crater
#

I still think it wasn’t a problem with your code, but with the tokens/keys. Idrk tho.

silk bluff
#

lol

#

doesn`t seem to work

#

asked my friends to vote xD

#

still doesn`t work (votes updated on top.gg)

#

😦

silk bluff
#

someone? to help me with the webhooks??

restive otter
#

*help

opal dawn
#

im trying to set the vote webhook, but idk what to put in the webhook URL part

#

nvm

dusty roost
#

for some reason, the bot page isn't updating how many servers my bot is in

late crater
#

It doesn't do it automatically

dusty roost
#

@late crater how do i get it to update?

late crater
#

what language

#

?

tame kindle
#

you have to make a post request

dusty roost
#

how

restive otter
#

Hey

#

I really don't know what I am doing wrong here. I do what the docs said but it still doesnt work

#
    @commands.Cog.listener()
    async def on_dbl_vote(self, data):
        channel = await self.bot.fetch_channel(562784997962940476)
        user = await self.bot.fetch_user(int(data['user']))
        await channel.send(f"{str(user)} has voted!")```
#

it doesnt send anything

tame kindle
#

Feel like you're missing a @ emitter, (i.e: @commands.command as an example)

#

maybe check the docs example

restive otter
#

oh no, I have that. didnt copy it

#

there

tame kindle
#

I'm not familar with Python, so I have no idea

restive otter
#

this is basically what the docs say

#

so that's why I dont understand why it isnt working :/

#

Even this doesnt do anything py @commands.Cog.listener() async def on_dbl_vote(self, data): print(data)

sullen nymph
#

@restive otter Make sure you forward your port

restive otter
#

I do

#

I've been trying everything with on_dbl_test too

#

even changed port

#

but still nothing

sullen nymph
#

Are you using Glitch

late crater
#

Do you have something like this in __init__?

self.token = 'dbl_token' # set this to your DBL token
self.dblpy = dbl.DBLClient(self.bot, self.token)
sullen nymph
#

Yes

silk bluff
#

Hi

digital linden
#

glitch only has one port

sharp wigeon
#

^^

#

I have been trying to tell that for so long but they dont understand xd

restive otter
#

@sullen nymph I'm not using glitch

#

I have a vps

#

@late crater yes. But with the webhook_auth, password etc

dusty roost
#

hey guys, so i started using webhooks with my glitch project. when i first added it, it worked fine, but now the voting event doesn't work.

#

(i haven't changed anything)

dusty roost
#

anyone?

austere swallow
#

would be nice if you can show your code and your current implementation

#

its hard to comment when we don't know much about whats going on and your code

#

also did you glitch address change or anything

dusty roost
#
const DBL = require("dblapi.js");
const dbl = new DBL('my token',
                    { webhookPort: 5000, webhookAuth: 'my pass' });


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!`);
  client.channels.get(`642715142504710148`).send(`<@${vote.user}> just voted and received 10 ${chest}!`)
});
#

nope

austere swallow
#

hmm

dusty roost
#

the webhook url on top.gg is https://myprojectname.glitch.me/dblwebhook

austere swallow
#

wait does the port correspond to that url though

dusty roost
#

it did before so i don't know why it wouldn't

austere swallow
#

and did you try using the testing button on the bot edit page for the webhook

dusty roost
#

yeah

austere swallow
#

well then I'm not too sure either, since I don't use glitch

dusty roost
#

also, how do i manually update the server count on top.gg, i have a feeling they may be related

austere swallow
#

you can look at the api docs

#

the endpoint to post the count is there

dusty roost
#

not post the count, update it on top.gg

austere swallow
#

afaik posting the server count updates it on the website?

dusty roost
#

it does?

austere swallow
#

yeah I think thats how the library works as well

dusty roost
#

i'll see

#

oh no i see now

#

ok

austere swallow
#

yup so its possible to manually update it but you should try to fix the issue with the bot

#

also is your bot online?

dusty roost
#

yep

austere swallow
#

since iirc there is an "inactivity timer" on glitch

dusty roost
#

there is yeah

#

it's always online so that's not the issue

#

updating the server count worked...

#

but it still won't respond to testing the vote event

restive otter
#
const DBL = require('dblapi.js');
const dbl = new DBL(yourDBLTokenHere, { webhookPort: 5000, webhookAuth: 'password' });```
how do i get webhook password?
spiral steeple
#

you set it

restive otter
#

I define the token of a webhook I created?

late crater
#

no

#

and click on your bots

#

and the bot

#

and you should see your token

#

for the webhookAuth, you set it on the edit page of your bot on top.gg

restive otter
#

[py] how can I make a function that is called on a vote? I looked at the docs and I tried implementing it but it didnt work https://discordbots.org/api/docs#pylib (3rd exmple)
the guild counter works fine, but not this

restive otter
#

[Js] how can I make dbl webhook work

half olive
sullen nymph
#

@late crater @restive otter token is generated by DBL, webhook password is generated by you

#

@restive otter Forward your port, set at least webhook_port in DBLClient and you have a working dblpy webhook

stark escarp
restive otter
#

members limited

unkempt sequoia
#

#help

mighty arrow
#

Idk my bot hasnt been verified since a week I hope that doesnt happend to me

stark escarp
#

But idk the webhook port/password

#

Where can i find them?

#

And is that right?

#

At the image above

#

Webhook running at http://0.0.0.0:5000/dblwebhook

formal sparrow
#

I need a new token to use

#

And I can't login

tame kindle
#

what

formal sparrow
#

Bruh token for api

#

That's the oauth that needs me to be logged in to get the token

tame kindle
#

discord is probs broken

formal sparrow
#

k

#

Any other way to get token?

tame kindle
#

no

late crater
#

Ik shivuwu

dusty roost
#

so once again i'll ask for help:
i'm trying to do a vote event, but for some reason it doesn't work. i have an on ready event that posts the guild count, and that works fine, but i can't figure out why the vote event won't work.
code:

const DBL = require("dblapi.js");
const dbl = new DBL('my token',
                    { webhookPort: 5000, webhookAuth: 'my pass' });


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!`);
  client.channels.get(`642715142504710148`).send(`<@${vote.user}> just voted and received 10 ${chest}!`)
});
client.once("ready", () => {
  dbl.postStats(client.guilds.size)
})
#

i'm using glitch, and when i first set it up, it worked fine. the url on top.gg is correct, and the token and pass are also correct, as the stats posting works correctly

dusty roost
#

nevermind, it just magically fixed itself without me doing anything

late crater
#

ok

dawn fjord
#

@lethal tiger this is not a question for this channel. Ask in #development

lethal tiger
#

oh ok thanks

dusty roost
#

nnnnnnnever mind

#

does anyone know why the connection between top.gg and the voting event sometimes stops working?

spiral steeple
#

Can you confirm it's dbl's side?

#

Try to curl it from your own side

#

Make sure it's still working

narrow zenith
gaunt steeple
#

Imagine using glitch for a bot

late crater
#

lol

sharp wigeon
#

^^

dusty roost
#

@spiral steeple how do I do that

#

@gaunt steeple is there any better solution that you would recommended? I've been trying to host it on google cloud but its very tricky

gaunt steeple
#

a virtual server at somewhere like digitalocean or ovh

#

or even the free trial of amazon web services works fine

#

google cloud isnt that tricky if you just ask it to spin you up a virtual machine, and put node and your deps on it

#

if youre trying to use all the fancy fandangles and scalability stuff, you'll get very confused, i did and i consider myself quite clued up re. hosting

dusty roost
#

do you think you could help me set up my bot on google cloud?

gaunt steeple
#

probably but i cant promise to help you as i dont have any free time atm

#

got all kinds of stuff going off at work and at home

#

plus upkeep of my own bot πŸ˜›

dusty roost
#

fair enough

#

im trying to get it on google cloud before glitch runs out of storage

gaunt steeple
#

tbh, i'd get a vm at digitalocean, do 'apt install nodejs' and then npm your deps, sorted

#

its like $5 a month

#

and if you can convince others to sign up, you get free hosting off the referal

dusty roost
#

is there a free trial

gaunt steeple
#

one sec....

#

if i refer you, you get $50 of 30 days free credit

dusty roost
#

hm

gaunt steeple
#

i think dbl also have a referal link

#

it used to be just $50 plain credit

#

but they realised people like me, that would last ten months πŸ˜›

#

how many servers is your bot on?

dusty roost
#

uhhh about 250

sharp wigeon
#

A 5 dollar server can run that easily

#

As long as the os is Linux

dusty roost
#

?

gaunt steeple
#

im getting towards 500 servers, and my server is barely touched by my bot

#

admittedly i have a server far beyond whats needed for a bot, i do other stuff on it

#

like, hosting websites for my games, etc

sharp wigeon
#

I just bought a 200 dollars a month server from Google, because I need it for a month and I have 220€ credit

dusty roost
#

alright well I still have time to work about servers

#

my big issue is that the voting event doesnt work sometimes

dusty roost
#

help?

gaunt steeple
#

How do you mean doesn't work

#

Do you log all requests at the webserver level?

#

I assume you have something like Apache or ngix as the front end server between you and any webhook request

dusty roost
#

I dont know much about this, so I dont know

#

I just did what it said on the api docs

#

it worked before

gaunt steeple
#

You should probably put Apache or ngix between your bot and the internet, set it up as reverse proxy to talk to the bot

dusty roost
#

how

gaunt steeple
#

Then you can set up that server software to log, and if a voting event is missed you can see where it was missed

#

Google for setting up reverse proxy with ngix to whatever you're using for your bots voting webhook

dusty roost
#

is this really necessary?

gaunt steeple
#

Well, it's the proper way to do it

#

Directly exposing an application to the internet is a bad idea for security, stability, and scalability

worn quail
#

that's why my bot's clone on github is a suuuper early version of it

gaunt steeple
#

If you have a reverse proxy inbetween, you can log the requests, or set up load balancing, centralise SSL renewals, and more

#

The logging is the important bit for you

#

So you can prove the requests are reaching your server

#

Even if your bot is down that log will still exist

dusty roost
#

I dont want to sound like I know better, because I certainly dont

#

but I think i could be doing something wrong

gaunt steeple
#

Maybe

#

But you can't know without a way to trace the request

worn quail
#

I honestly dont care who uses my api

#

$1.5 per month for 1mil requests

#

most I hit every month is like 2-5k

gaunt steeple
#

You have a limit?

#

Do you pay for proxied requests?

worn quail
#

oi

#

I just let AWS do its thing

gaunt steeple
#

Ok

#

CDN then?

austere swallow
#

@dusty roost ok apparently I think it might be an issue with glitch

#

not 100% sure on that though

worn quail
#

I just upload it through my bot

dusty roost
#

what do you think could be wrong?

#

it worked over the weekend, when I first added it

gaunt steeple
#

Does your webhook contain an IP address?

#

And if so can glitch projects move around IP addresses at random?

dusty roost
#

i know that it's connected because it updates the server count on top.gg

grim dew
#

is something wrong with the API?

#

I am getting horrible error messages

dusty roost
#

site's offline

grim dew
#

I see

#

allright

#

since 9pm right?

dusty roost
#

dunno

#

I only just checked a couple mins ago

grim dew
#

my logs show that the first time my bot failed to update the server count was about 10pm

#

meh if its offline it doesnt matter anyway

#

thanks for your help

dusty roost
#

Β―\_(ツ)_/Β―

restive otter
#

How do i make the dbl webhook

#

:/

placid peak
#

idk

worn quail
fierce grotto
digital linden
#

lmao

dawn fjord
#

@worn quail @fierce grotto @digital linden This channel is for discussion of the top.gg API only. All other conversations should take place in #general or #memes-and-media

digital linden
#

ok

worn quail
#

huh what did I do

#

I was commenting on the "how do I make a webhook" thing

#

that url didn't help much

formal sparrow
#

Error: 401 Unauthorized

#

Does that mean wrong token?

#

I tried regenerating and using

tame kindle
#

could be

gaunt steeple
#

can be lack of permissions

#

eg.updating the wrong bot id

arctic arch
#

thats 403

#

forbidden

formal sparrow
#

Then what is 401

spiral steeple
#

401 is unauthorized. Brain described a 403

narrow zenith
#

401 is an invalid login

sharp wigeon
#

@formal sparrow You could have just searched it on https://www.google.com/

formal sparrow
#

kk

rose zealot
#

huhh

#

how does the api works?

#

cuzz when i put it in the code it sees it as a link

#

wow rip english

shrewd ginkgo
#

in the python library is there a way to get the total number of votes and not just the last 1000

#

oof nvm

unborn blade
#

@unborn blade

#

aawk lar daha rol koyamΔ±yo

sharp wigeon
olive pagoda
#

@sharp wigeon need some .js help and I think this is the right section

#
C:\Users\Admin\Desktop\Bowsette>node index.js
C:\Users\Admin\Desktop\Bowsette\index.js:4
const dbl = new DBL('revoked.meme.nope', client);
                                                                                                                                                                                   ^

ReferenceError: client is not defined
    at Object.<anonymous> (C:\Users\Admin\Desktop\Bot-Chen-master\Bowsette\index.js:4:180)
    at Module._compile (internal/modules/cjs/loader.js:701:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:712:10)
    at Module.load (internal/modules/cjs/loader.js:600:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:539:12)
    at Function.Module._load (internal/modules/cjs/loader.js:531:3)
    at Function.Module.runMain (internal/modules/cjs/loader.js:754:12)
    at startup (internal/bootstrap/node.js:283:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:622:3)


#

wait

#

think I got the error

sharp wigeon
#

is your client defined before or after that

olive pagoda
#

after
should I do before?

worn quail
#

yes

sharp wigeon
#

before...

worn quail
#

good lord

olive pagoda
#

lmaooo sorry never had to use

const client = new Discord.Client();
worn quail
#

variables always go above where they're called

#

you cant call "qt" if its below where you're trying to call it

young void
#

Lmao

worn quail
#

for example

console.print(qt_neko)
var qt_neko = "yes"
``` wont work
restive otter
#

https://IP.FROM.MY.HOST:5000/dblwebhook should work as a valid webhook url right?

sullen nymph
#

It's http by default, not https

#

other than that, that is correct unless your port isn't forwarded/is not 5000 and your webhookPath is not dblwebhook

restive otter
#

@dusty roost in your ```const DBL = require("dblapi.js");
const dbl = new DBL('my token',
{ webhookPort: 5000, webhookAuth: 'my pass' });

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!);
client.channels.get(642715142504710148).send(<@${vote.user}> just voted and received 10 ${chest}!)
});
client.once("ready", () => {
dbl.postStats(client.guilds.size)
})``` code which token dbl or webhook ?

dusty roost
#

webhook

#

@restive otter

restive otter
#

my pass

#

what pass

#

@dusty roost

dusty roost
#

it's the auth pass on top.gg for my bot

#

@restive otter

restive otter
restive otter
#

@restive otter

gleaming thistle
#

w

restive otter
#

x

sullen nymph
#

Let's not

tardy zephyr
#

my music bot comes to the audio channel when I command to play music, then comes out without playing the music

young void
#

Ok?

dusty roost
#

does anyone know why the voting event sometimes doesnt register?

queen crystal
#

the dbl.webhook.on -< does not work

#

property is undefined

queen crystal
#

and i dont have a pass for the webauth

loud gulch
#

you make your own pass

queen crystal
loud gulch
#

yes its that

queen crystal
#

ahh

restive otter
#

uh

#

no

#

ah

#

yeah

#

i thought you were going to use your own password

scarlet cobalt
#

One message removed from a suspended account.

queen crystal
#

const dbl = new DBL(tokenf.dbl, client); but whats happening with the "client" then?

#

do i still need that?

loud gulch
#

yes

queen crystal
#

const Discord = require("discord.js");
const client = new Discord.Client();
const DBL = require("dblapi.js");
const dbl = new DBL(tokenf.dbl, client);

#

not remove the line for client

#

but this

loud gulch
#

i mean idk lmao

queen crystal
loud gulch
#

ok no need to screenshot that

queen crystal
#

ok

#

hello?

queen crystal
#

What will the thing for the webhook look like?

digital linden
#

Uh

#

it’s like a bot

queen crystal
#

what will this fully look like? js const Discord = require("discord.js"); const client = new Discord.Client(); const DBL = require("dblapi.js"); const dbl = new DBL(tokenf.dbl, client);

digital linden
#

Why don’t you try it

heady cradle
#

and see

covert sparrow
#

.mp4

spiral steeple
queen crystal
#

no

#

i want that if a user votes it logs

#

i just do not understand this line

#

(tokenf.dbl, { webhookPort: 5000, (etc) })

weary ember
#

those seem to be making a client for the dbl webhook server. webhookPort and stuff are the configuration

queen crystal
#

and the client at the default for guild count like, do i still need that or can i remove it?

tame kindle
#

if you want to see if a user upvoted

#

you need to use the event emitter

#

i.e <emitter>.on

#

<emitter> being the emitter

queen crystal
#

no not that

#

the client

sharp wigeon
sullen nymph
#

@queen crystal did you read the docs

queen crystal
#

y

#

im confused about it

#

and you guys dont know where im talking about

#

so im going to say it in steps

#

(tokenf.dbl, { webhookPort: 5000, (etc) })

#

this is the line for if someone voted

#

for the webhook

#

const Discord = require("discord.js"); const client = new Discord.Client(); const DBL = require("dblapi.js"); const dbl = new DBL(tokenf.dbl, client);

#

thats the script ussd for server count or other things

#

im confused about this line

#

const dbl = new DBL(tokenf.dbl, client);

#

the client

#

if for the webhook there is no client

#

is that ok or do i have to do something else?

sullen nymph
#

You provide the client if you want dblapi.js to automatically post servee count for you

#

Providing client does not do anything related to webhooks

queen crystal
#

(tokenf.dbl, client, { webhookPort: 5000, (etc) }) so this?

#

or is that undefined

sullen nymph
#

new DBL(token, [options], [client])

or

new DBL(token, [client])
Β© docs

#

So either make client the last arg or don't use it at all

restive otter
#

how i get dbltoken?

willow spindle
queen crystal
#

so (token, { webhookstuff }, client)

#

@sullen nymph

sullen nymph
#

Yup

queen crystal
#

thanks.....................................................................

#

idk what my webhook port is

tame kindle
#

it should be in the webhook config

#

you set your own password and port

queen crystal
#

i use requestbin

#

idk where it is

tame kindle
#

what?

#

what does that have to do with anything

sullen nymph
#

If you are using Glitch, it's 3000. If not, any port above 1024

glacial pier
#

how can i setup webhooks for my supprt server?

#

like when someone upvotes my bot, it'll send a message to my server

#

im so confused what the docs said

restive otter
#

Is it possible to send the name of a person who voted for my bot in specific channel?

valid herald
#

I need help with the api I want to make a web hook that notifies me when someone votes my bot but i can't get it (I use JavaScript)

#

how can I do it?

safe flicker
#

how do i get a api token for my bot?

#

nvm i found it

dense basalt
#

oh cool

safe flicker
#

ha i am just a genius xd why doing it by interval if you can do it when the bot joins a new guild xd

#
bot.on('guildCreate', async () => {
    console.log(`New Guild joined! | ${bot.guilds.size}`);
    dbl.postStats(bot.guild.size)
});
topaz wyvern
#

posting on guild join probably isn't the best idea tbh

#

just set an interval in your ready event of about 15 minutes or just let dblapi auto post

placid peak
#

so if you implement a way dbl.postStats(...) it wont auto post, right? (on js lib)

spiral steeple
#

If you provide a client in the constructor it will autopost

placid peak
#

ok

azure hedge
#

me is back idk everytime i vote the next day the votes are stacking up

#
      console.log(`User with ID ${vote.user} just voted!`);
      let embedd = new Discord.RichEmbed()
      .setTitle("**Thank you very much for voting!**")
      .setColor(color.inori)
      .setDescription("As a reward, You have received **Β₯1000** and Receive **1** Reset Token.")
      .setFooter(`Use Reset Tokens to reset Service and Work Command.`)
    client.users.get(vote.user).send(embedd);
let targetBalance = await db.get(`userBalance_${vote.user}`);
  db.add(`userBalance_${vote.user}`, amount);
  db.add(`userReset_${vote.user}`, 1);
});
#

idk what is wrong kekw

sharp wigeon
azure hedge
#

sad life

#

:"<

heady cradle
#

bruh

#

he asked for help

#

not for confirmation

wide oriole
#

oh shit

dawn fjord
#

@sharp wigeon do not shitpost in this channel. This channel is for constructive discussion and questions relating the top.gg API only.

sharp wigeon
#

I meant he should try the code and the compiler would show the error

#

If there was any errors

#

And then it would work, or he could fix the error

dawn fjord
#

Sending that link is an obnoxious way to say that

sharp wigeon
#

At least they will remember, I hope they can fix simple stuff with the compiler and hard stuff here

#

But ok, I wont send that link

amber dune
#

-api @restive otter

abstract mothBOT
#

@restive otter

THIS CHANNEL IS ONLY FOR SUGGESTIONS/HELP/BUGS TO DO WITH OFFICIAL API LIBRARIES AND API DOCS FOUND AT
https://top.gg/api/docs

restive otter
#

I don't said anything @amber dune

amber dune
#

yea because I removed your messages mmulu

restive otter
#

?

hardy acorn
misty mica
#

my bot won't recieve test webhook vote

#

can anyone help me?

dusty roost
#

@misty mica send your code

#

and any errors

#

did it work before?

#

because i've been having an issue where mine stops randomly

gaunt steeple
#

add logging if you dont have any

#

at the http level

#

to check the webhook calls are reaching your code

misty mica
#

@dusty roost

#
dbl.webhook.on("vote", vote => {
     console.log(`${vote.user} have voted!`);
})
wise onyx
#

to test your webhook make sure you save the options on the website and then come back and hit test

dusty roost
#

yeah I know

#

@gaunt steeple how do I do that

hidden marten
#
const DBL = require('dblapi.js');
const dbl = new DBL(config.dbl_token, { /*webhookAuth: config.api_token,*/ webhookServer: server });

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 wont run on my webhook and I'm using an express server...
dawn fjord
#

-moreinfo

abstract mothBOT
#

If you want people to be able to assist you, please provide more information, such as what library and language you're using, the code in question and what you are trying to do and/or what is causing the error.

dusty roost
#

@hidden marten what url is on the edit page for your bot

restive otter
#

Good evening, you could help me with the voting system with lew webhooks I understand with the dosc

#

i am french

#

mention me if you can help me

hidden marten
#

@dusty roost sorry for the ping, I already managed to fix this. Sorry, thank you anyways <3

hidden marten
#

Okay just kidding

#

only test votes are working?

short cairn
#

@hidden marten Just open that document again but with a binary editor change all the "1" to "0" and it should work

hidden marten
#

@short cairn thank you that solved my problem

short cairn
#

Np

lone sun
#

How do i know if my bot is accepted or rejected?

sullen nymph
#

You get a DM and a mention in #logs

restive otter
#

hi

#

api how to used on json

#

this discord official api example:
"Authorization: Bot verysecretcode"

scarlet cobalt
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

restive otter
#

No im dont know how to use top.gg api πŸ˜„

runic grove
#

top.gg api doesnt require the Bot prefix

#

why are you looking at the discord api docs

#

what the fuck are you even trying to do

restive otter
#

i want to get bot last votes

#

GET /bots/BOT ID/votes

#

But result

#

Unauthorized

runic grove
#

then authorize

#

by providing a header

restive otter
#

Okey

#

Thz

#

im trying Authorization: Bot TopGGcode πŸ˜„

runic grove
#

i just said

#

you dont need the Bot prefix

restive otter
#

Now working thx

#

@runic grove /votes command is running, but i dont get stats

runic grove
#

sad

restive otter
#

i want to get total server count

runic grove
#

aaaaaaand why are you using the api for htat

restive otter
#

im use api for web dashboard in my bot

sharp wigeon
#

so are you exposing the key to the public?

late crater
#

Bruh

azure plover
#

Is it possible to post stats to the DBL website without being approved yet?

#

I want to get the code set up for it

spiral steeple
#

You don't get an api key until you're approved

signal hawk
#

i mean you can set up the code but cant test it until you have a key

azure plover
#

oh ok

arctic arch
#

@restive otter post memes in off-topic

#

as you can see in the topic, this channel is only for help, suggestions or bugs

carmine dawn
#

Im new to top.gg and i dont know about webhooks im confused anyone help me

#

ping me if you like to help

sullen nymph
#

A webhook is just a server running in background that responds with something on request.
Official DBL libraries usually have webhooks implemented for easy usage.

carmine dawn
#

ok

restive otter
#

did something change to the api? Suddenly I'm getting an "Unauthorized" error...

topaz wyvern
#

You're required to provide auth when using GET

restive otter
#

I'm using dblpy, sorry forgot to mention

#

Also, I cant get the webhook to work. https://111.222.333.444:5000/dblwebhook

#

I press test, use the on_test thingy to print the dict it receives, but I get nothing

restive otter
#

Could anyone help me set up this webhook thing? I've tried everything I could think of and nothing works...

sullen nymph
#

It's http

#

@restive otter

sullen nymph
#

If you are getting Unauthorized error when sending the token, reset it

restive otter
#

@sullen nymph I have reset the token, that seems to be gone now.

#

And yea, I also tried http but that didn't do anything either

upper nebula
#

How to get bot token from top.gg?

#

Or is it my main bot token?

covert sparrow
#

It's from top.gg. You have to press edit then scroll down and you will see some stuff

#

@upper nebula

upper nebula
#

Oh I see it, did not scroll far enough. Ty

#

now if only it was short enough to stay on my screen

covert sparrow
#

Oof