#topgg-open-source

1 messages · Page 2 of 1

wary stratus
#

Yeah viewer won't work

kindred maple
#

One message removed from a suspended account.

deft merlin
#

i just updeted your perms

wary stratus
#

updeted

kindred maple
#

One message removed from a suspended account.

deft merlin
#

well actually knowing topgg

kindred maple
#

One message removed from a suspended account.

deft merlin
#

you wont be able to for like an hour due to cache

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

deft merlin
#

its updated on my end so you just have to wait onionpray

kindred maple
#

One message removed from a suspended account.

dusky shale
#

I wonder, what do you need the API token of the lib dev bot for?

drowsy thistle
#

because... she's a lib dev?

dusky shale
#

That says nothing about what I just asked

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

drowsy thistle
#

^

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

dusky shale
#

I feel like this bot was made for a different purpose but that works as well, never saw the actual reason behind it

deft merlin
#

Lets not be condescending

kindred maple
#

One message removed from a suspended account.

drowsy thistle
#

the bot is useful for testing things like posting stats

kindred maple
#

One message removed from a suspended account.

drowsy thistle
#

when you don't want to modify your actual bot's server count

kindred maple
#

One message removed from a suspended account.

dusky shale
#

Sure okay

kindred maple
#

One message removed from a suspended account.

dusky shale
#

👍

dusky shale
#

Me when I'm in a being annoying competition and my opponent is Faithie romaniansquidgif

kindred maple
#

One message removed from a suspended account.

kindred maple
#

One message removed from a suspended account.

dusky shale
kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

dusky shale
#

I mean sure but who are you waiting for to review?

kindred maple
#

One message removed from a suspended account.

karmic valley
#

so, a long time ago i was supposed to create a C++ library for posting to top.gg etc

#

i havent yet made a library that is standalone for it, but i took the first steps of making native support to post to top.gg in my latest bot rather than doing what i did the last two times, handing it off to backend php

#

heres what i got:

#

so theres a base struct type called botlist which accepts the details of a bot list; 99% of bot lists are compatible with top.gg, give or take naming of two json fields, so this is compatible with near everything. There's a timer that runs every 15 minutes setup from the bot's on_ready, which calls the post() function of all registered bot list struct types

#

defining a bot list's structure is simple as:

#

so basically this is all predefined, and all you'd need is config:

#
"botlists": {
    "top.gg": {
        "token": "XXX"
    }
}
#

it would need a fair bit of work to make it generic to not require D++, but as it stands, with this code its required as it provides the timer functionality and the asynchronous HTTPS POST... other requirements are only nlohmann::json.

drowsy thistle
#

@karmic valley @dusky shale wanna continue working on the C++ SDK?

#

the library has lacked any development since - do y'all have plans for it?

dusky shale
#

let’s rewrite that thing

#

its rushed as u can see

dusky shale
#

though it’s been a while since i created a project using cpp

drowsy thistle
#

i could work on the library's core features once the http part is done tho

#

everything else after that is smooth sailing

karmic valley
#

C++ coroutines arent something you can really do standalone imho

#

but they are rather cool

karmic valley
#

because it takes a massive amount of boilerplate

#

and you need something underneath it to marshall the coroutines

#

like an event driven loop

#

you cant just shoehorn two or more of those easily into a program

#

i think they expect some kind of framework like boost or something (or in our case dpp) to implement the coroutine support

drowsy thistle
#

ooooooooff :(

#

soo are callbacks the way to go?

dusky shale
drowsy thistle
dusky shale
#

You don't need to go the callbacks path, you can definitely do it with coroutines but of course it's going to take much longer

#

And you'll have to learn C++ coroutines, which is hell :)

drowsy thistle
drowsy thistle
#

@deft merlin hai, can you dm me Top.gg's library developer bot token?

#

i needed a token to test my SDK but i don't have a bot listed

deft merlin
#

I can in the morning yeah, I'm currently in bed

cunning zodiacBOT
#

success I will remind you about dm null lib bot token* in 8 hours. Make sure I can DM you.

deft merlin
drowsy thistle
drowsy thistle
#

@deft merlin good morning xiuh, any information regarding top.gg's documentation page? (docs.top.gg)

#

(or any staff member who is a part of the task force handling this, if the task force is even still working)

woven granite
#

Me and xiuh had a conversation about the docs page awhile back. Iirc a different staff member needs to change a setting for us to be able to update anything. That was the last I heard.

drowsy thistle
woven granite
#

Idk, I'm not the taskforce leader for this right now. Real life has been in the way.

drowsy thistle
#

sooo who is it?

#

it has been over three months

woven granite
#

Family friendly currently.

I imagine he wouldn't be up to date on the situation. I never had the chance to update them on that situation before he took my place.

drowsy thistle
#

@faint fern

faint fern
drowsy thistle
kindred maple
drowsy thistle
#

?

kindred maple
faint fern
# drowsy thistle soo any updates?

Got busy moving back home for the holidays so it slipped my mind. Handled it now but don't expect anything before sometime next year as many are on holiday vacation blob_nod

drowsy thistle
drowsy thistle
#

any updates on it? @faint fern

deft merlin
#

I have to check in with some people from medal and we just got back today nod hopefully in the next few days

drowsy thistle
#

oh btw are we allowed to post bot stats for testing the autoposting feature through the lib dev bot?

deft merlin
#

Yep that's fine for testing

drowsy thistle
#

my SDK's autoposter isn't even auto at all, i'll fix it in a future major update

#

learning about Serenity will be fun

drowsy thistle
#

any updates on it? @faint fern

faint fern
drowsy thistle
#

aight

faint fern
#

@drowsy thistle works now?

drowsy thistle
#

mhm

faint fern
#

Dope

drowsy thistle
#

just wanted to say about the issue again but top.gg is broken atm so i'll ask again later

jade sandal
#

Why I can talk in here

#

👀

drowsy thistle
#

be gone intruder

faint fern
#

Wait are not everyone supposed to see this?

jade sandal
cunning locust
#

but not talk 👍

faint fern
#

Yea I fixed

cunning locust
#

alt says no so i guess nickname has perms

#

ah ok

kindred maple
#

One message removed from a suspended account.

dense barn
#

to elaborate:

  • search never was a thing in the code ClownSun
  • number makes much more sense for shards.
drowsy thistle
#

what happened to search

#

it used to work

dense barn
cunning locust
#

yeah it used to work

dense barn
#

when?

cunning locust
#

i mean i use search api and it works rn and has for a few months

dense barn
#

which route?

cunning locust
#

its the one from the docs

#

its like 50/50 functional KEKW

kindred maple
dense barn
kindred maple
#

One message removed from a suspended account.

dense barn
#

@cunning locust @drowsy thistle ???

cunning locust
#

its always been weird

#

it 1000% worked

dense barn
#

imma be real with u

#

there's no reference to "search" in the route

cunning locust
#

i gotta search my chat logs cuz i've sent it before

kindred maple
#

One message removed from a suspended account.

dense barn
#

nice

#

the api route was last changed three years ago

drowsy thistle
#

wth i thought pim did something about it notlikekomi

kindred maple
#

One message removed from a suspended account.

dense barn
#

yea no

#

it never worked

#

i checked the last few commits

drowsy thistle
#

well yeah it used to be bugged

#

but we reported to pim about it

cunning locust
#

yeah no i think i am going insane

#

idek anymore

drowsy thistle
#

why

dense barn
cunning locust
#

because i am fully convinced it worked when i ran dbl simulator (late 2021)

dense barn
#

thats so funny

#

thank u veld in 2021

#

wth is dbl simulator

drowsy thistle
#

then make an api route for the new search system? mmLol

#

the top.gg API doesn't feel right without the /api/search route

cunning locust
#

it was a site that let you fake approve bots based on a leaked ss of the old mod dashboard KEKW

dense barn
#

no

kindred maple
#

One message removed from a suspended account.

dense barn
#

api/v1 maybe

cunning locust
#

it was funny

dense barn
#

but for now i wanna just get it over with :D

#

anyways idk who maintains all the libs

#

but the number change might be breaking?

drowsy thistle
#

nah

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

dense barn
#

also docs deploy works again

cunning locust
#

yipee

drowsy thistle
#

lesgo

kindred maple
#

One message removed from a suspended account.

drowsy thistle
#

there's a list?

dense barn
#

CODEOWNERS is a thing in docs

kindred maple
#

One message removed from a suspended account.

dense barn
#

but that doesnt seem up to date

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

dense barn
#

poggies

#

fish a real one

#

anyways

#

good progress today

#

will deploy and hope the api doesn't explode

drowsy thistle
#

nah im sure maintaining the api is way easier than the site

dense barn
#

real

kindred maple
#

One message removed from a suspended account.

dense barn
#

this is gonna be the first test deploy with CI on new machines

#

spooky.

cunning locust
#

gl 🙏

dense barn
#

im just hoping at this point

cunning locust
#

checked and python + js libs both handle shards correctly

dense barn
#

nice

#

thank you

kindred maple
cunning locust
#

sue

#

sure

dense barn
#

god im so happy i did that migration

#

builds no longer take 27 minutes

cunning locust
#

W

kindred maple
#

One message removed from a suspended account.

drowsy thistle
cunning locust
#

yep

#

going through all of them

#

gonna pretend i know how rust works

drowsy thistle
cunning locust
dense barn
#

epic

#

Some(shard_count) moment

#

2 minute build time Pog

drowsy thistle
#

blazingly fast!! 🚀

dense barn
#

before api migration it was 2:42

#

another dub for me

#

another L for prod

cunning locust
#

dotnet handles it

kindred maple
#

One message removed from a suspended account.

dense barn
#

god im such a goated dev

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

dense barn
#

lets hope the deploy works tho

kindred maple
#

One message removed from a suspended account.

woven granite
cunning locust
#

cpp handles it too

dense barn
#

@faint fern get ur ass over here

#

so basically all along

#

the api was just wrong

#

and everyone ignored it

cunning locust
#

java handles it

kindred maple
#

One message removed from a suspended account.

drowsy thistle
cunning locust
#

idk about php, it doesn't say much

drowsy thistle
#

buffer left

cunning locust
#

i think its based on what the user sends

dense barn
#

i made an ssh key in system32

cunning locust
#

go handles it

#

also go supports this, wonder if the API still returns it

#

ruby handles it

drowsy thistle
#

@cunning locust have you checked the struct definitions in my Rust SDK?

cunning locust
#

lua only supports the server_count and shard_count fields, not shards array

drowsy thistle
#

don't just only look at that method

kindred maple
drowsy thistle
#

do people still use ruby

kindred maple
#

One message removed from a suspended account.

drowsy thistle
#

in general

kindred maple
cunning locust
#

rust confusing

drowsy thistle
#

rust ez

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

cunning locust
#

anyways, every lib supports it!

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

cunning locust
drowsy thistle
faint fern
#

time to read what be going on

#

oh yes library maintainer lists

#

this is what happens when I dont actually note down what im supposed to do I just forget

#

my brain pushes that to the side to save space for random wikipedia articles I find at 2 am

drowsy thistle
faint fern
#

^ I did set up some microsoft to do app to help me keep in touch of things I need to do tho

drowsy thistle
#

nice nice

dense barn
#

fun fact

#

you can't read a body twice

#

now i have to do this

#
    app.use((req, res, next) => {
      // migrate /api to new part of the app dir
      if (req.path.startsWith("/api")) {
        return next();
      }

      return express.json({ limit: "1mb" })(req, res, next);
    });
#

@kindred maple do u know who maintains the js api

kindred maple
#

One message removed from a suspended account.

dense barn
#

@tiny shard the hasVoted url uses undocumented api stuff

#

/api/check should be /api/:botid/check

tiny shard
#

hi

dense barn
#

for now i'll keep the logic in, but wanna get rid of it :3

tiny shard
#

we dont take the botId as a parameter

dense barn
#

you can fetch it from the token body

tiny shard
#

i was pushing for the ability to pass an @me to properly recreate the functionality

dense barn
#

to avoid breaking the api

tiny shard
#

and i still believe that should be the case

#

/api/bots/@me/check

dense barn
#
const jwt = my_topgg_token
const payload = jwt.split('.')[1]
const payloadDecoded = btoa(payload)
const payloadDeserialized = JSON.parse(payloadDecoded)
return payloadDeserialized.id
#

either way

#

i'll keep maintaining it for now

#

since it's used in most js bots

tiny shard
#

yeah i mean, we're in a troubled situation where most people dont update their sdk

dense barn
#

yea fair

#

other things seem ok btw

#

just wasn't aware that was a thing while doing this migration lolol

#

also docs repo is fixed

tiny shard
#

this is finally becoming real !?!

dense barn
#

good to know

tiny shard
#

lol

dense barn
#

yea

tiny shard
#

remember the golden "we'll have a v1" days

dense barn
#

we'll have a v1

#

but for now im cleaning up our codebase

#

and one of the things is the v0 api

#

that hasn't been touched for years

drowsy thistle
#

i still don't get why you would want to check votes for other bots anyway

#

you would get a 403 afaik

#

do you know how to retrieve the bot ID from the API token?

dense barn
#

yea Shruge

#

i didnt design the api

drowsy thistle
#

then how are we supposed to use the /api/check endpoint?

dense barn
#

/api/bots/check works rn

drowsy thistle
#

ah icic, thanks!

drowsy thistle
dense barn
#

it doesn't do anything yeah

drowsy thistle
drowsy thistle
dense barn
#

@drowsy thistle merged it!

drowsy thistle
dense barn
#

i think

#

theres a bug in the publish

#

it spent like

#

2h publishing

#

ill check it soon

drowsy thistle
kindred maple
#

One message removed from a suspended account.

dusky shale
#

Hey! This is Buffer. My account was compromised, and I didn't realize it until someone brought up the issue. By then, it was too late—the hijacker had already published those commits. They were never published by me, and I was unaware of my GitHub account being compromised until this incident. I'm truly sorry for what happened. Regarding my departure from the Top.gg server, I felt pressured and uncertain about what to do. I was embarrassed, and I apologize to @drowsy thistle for cutting you off. I was afraid you would be against me. I'm sorry for this late explanation; personal matters have kept me busy, which is why I didn't realize I had been hacked. I'm very grateful to those who helped me revert the commits. I've forgotten how to use the git command already. That's all, thank you.

I'm also writing this message because some guy posted me on bleepingcomputer and it's affecting my reputation... I'm truly sorry..

#

(copy-pasted my explanation on Github)

drowsy thistle
#

It's okay ❤️❤️

dusky shale
#

Someone please remove my contributor role now, I don't even deserve it lol

drowsy thistle
#

I would be more than happy to become the current maintainer for the Python SDK

#

it's okay buffer, you've tried your best! ❤️

dense barn
drowsy thistle
#

This is a good wake up call for the Python SDK itself too because it's incredibly outdated KEKW

dense barn
#

yea real

#

someone should take a look at it

drowsy thistle
dense barn
#

go for it SCthumbsup

drowsy thistle
#

poggies

dense barn
#

also i saw u were unable to merge urself?

#

i guess we need to add you to the repo

#

good moment to test if the protected branches work as intended :)

#

@drowsy thistle do you have some time to help test?

drowsy thistle
#

sure!

#

i was unable to merge the pr at the top-gg/docs repo, yes

dense barn
#

oh, what about the rust-sdk ones?

drowsy thistle
#

i'm able to merge that one

dense barn
#

ok goodie

#

are you able to commit to main?

drowsy thistle
dense barn
#

rust-sdk

#

without a review

drowsy thistle
#

no

dense barn
#

nice

#

perfect

drowsy thistle
#

that requires me to create a new branch and make a pull request

dense barn
#

yea that's good

drowsy thistle
dense barn
#

any library dev should be able to review your code

#

so feel free to use this channel as like the channel for anything SDKs

#

ofcourse I will also be around to do reviews

#

and will do more of them Ok

drowsy thistle
#

i doubt any library dev has write access lmao

dense barn
#

yea we'll change that ofcourse

#

lib devs can be added to the top-gg-community org directly now because its no longer shared with internal code

drowsy thistle
#

kekw nice

dense barn
#

left some comments

#

windows cooked with this emoji

drowsy thistle
#

lmaooo

drowsy thistle
#

i've replied to some poggythumbsup

dense barn
#

@drowsy thistle replied back!

drowsy thistle
#

replied back! now waiting for shivaco (now sky) to do something about the API token

dense barn
#

approved both

drowsy thistle
#

thanks!

#

❤️

drowsy thistle
#

@dense barn noooooo topggSob

dense barn
#

github pages very nice

drowsy thistle
#

mhm

dense barn
#

kk moving it to cf pages @drowsy thistle

#

this is unacceptable lol

drowsy thistle
dense barn
#

ok its back

drowsy thistle
#

pog

#

bruh what happened to the syntax highlighting on all of the libraries

dense barn
#

no idea

drowsy thistle
kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

drowsy thistle
#

sure :D

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

drowsy thistle
#

if you can merge it, merge it

kindred maple
#

One message removed from a suspended account.

drowsy thistle
#

slay

kindred maple
#

One message removed from a suspended account.

drowsy thistle
#

poggies!

drowsy thistle
#

documentation overhaul topggParty

dense barn
#

very fancy

drowsy thistle
#

@faint fern Veld has summoned you sir

faint fern
drowsy thistle
#

yessir!

#

:D

drowsy thistle
karmic valley
#

I'm guessing so you get the same warnings turned off

drowsy thistle
#

yup

karmic valley
#

you probably don't need to ever pass dpp::snowflake by ref

#

it's simply a wrapper object around a single uint64_t, so the whole class only is 64 bits wide

drowsy thistle
#

alright, thanks

karmic valley
#

it's very neat

#

does it auto retry when rate limited?

drowsy thistle
#

nope lmao

#

atm it just returns the error

karmic valley
#

what C++ standard is needed? 17 or 20?

drowsy thistle
#

17

#

same as D++

karmic valley
#

nice

#

looks good to me

#

you could probably use a dpp::iconhash for avatar

#

instead of string

#

but then you'll need a separate bool or bit value to indicate animated

drowsy thistle
karmic valley
#

two 64 bit integers put together into a 128 bit value

drowsy thistle
#

ooooo alright!

faint fern
#

I'll take a look after brekkie! poggythumbsup

karmic valley
#

i made a PR that adds optional coroutine support to the top.gg C++ library

#

using coroutines if you can is so much neater, it avoids callback hell

#

old API remains unchaged, if you enable it via a cmake flag it will add new function calls to the client class, e.g. co_get_user(user_id)

#

meaning you can do this:

#
#include <topgg/topgg.h>
#include <dpp/dpp.h>
#include <iostream>

int main() {
  dpp::cluster bot{"your bot token"};
  topgg::client topgg_client{&bot, "your top.gg token"};

  const auto result = co_await topgg_client.co_get_bot(264811613708746752);
  try {
    const auto topgg_bot = result.get();
    std::cout << topgg_bot.username << std::endl;
  } catch (const std::exception& ext) {
    std::cout << "error: " << ext.what() << std::endl;
  }

  return 0;
}
faint fern
#

Yep looks really solid! Good work

karmic valley
#

it may need some documentation

#

I don't think the readme is best place for it, where do you think that should go?

drowsy thistle
karmic valley
#

yeah sounds good

karmic valley
drowsy thistle
karmic valley
#

sure

#

left a review

#

small stuff

#

one thing I didn't put in review but worth discussing I'm really not sure how all that move && voodoo is going to interact with dpp coroutines

#

as they're quite fussy about ownership

#

but I'm sure it's fine

drowsy thistle
karmic valley
#

no the move operators on the topgg_async

#

looks good to me now tho

drowsy thistle
karmic valley
#

&&

drowsy thistle
#

ah

#

this one inline T&& operator co_await() && { ... }

karmic valley
#

yeah

#

i am not sure how that stuff works alongside dpp async

#

because when you co await in dpp, dpp owns the promise

#

so what are you moving?

drowsy thistle
#

the future ig?

return std::forward<dpp::async<result<T>>>(m_fut).operator co_await().get();
karmic valley
#

but if youre able to run it and it doesnt crash immediately.... its probably ok

#

seems like overthinking ownership

#

it isnt rust 😄

drowsy thistle
#

😭

karmic valley
#

btw, what do you think of all the "members must start m_" stuff

#

im not keen as any good ide tells you this info, but...

#

could be worse, could be like m_lpszString

drowsy thistle
karmic valley
#

says who tho

#

😄

#

ide can tell you that

drowsy thistle
#

idk.. felt good to differentiate which variable is a part of the class object and which isn't

karmic valley
#

i guess its harmless

#

i tend to just use this-> on them

#

then its clear 😄

drowsy thistle
#

this-> is disgusting

#

🤢

karmic valley
#

it is clearly telling the reader you are referring to a variable that is a member of this

drowsy thistle
#

m_ is a million times better than this->

#

saves you from typing 4 characters KEKW

#

but still gets the idea across

karmic valley
#

lol

#

spoken like a rust dev

#

we could also rename void to vd

#

and int to i

#

at least we arent forced to do like public static final void main()

#

at least its not java

drowsy thistle
#

REAL

#

why type unsigned long long when you can just type u64

karmic valley
#

uint64_t

#

i think some languages go too far, you have to be able to read the code

#

i cant agree with rusts pub fn mut lol

#

must be hell for non-english speakers

drowsy thistle
#

lmaoo you would get used to it

#

at least it's not like go

#

where members starting with a capital letter means public

faint fern
#

Alr so im not very good at cpp anymore but seems the PR has a brain seal of approval

#

I'll merge

karmic valley
dusky shale
#

yo @drowsy thistle, im adding google test on the cpp sdk. Im also gonna implement the webhook feature on the cpp version since it hasnt been implemented yet

dusky shale
drowsy thistle
#

@dusky shale please let me know if you've made a pull request! poggythumbsup

dusky shale
drowsy thistle
#

what are you struggling on?

dusky shale
drowsy thistle
#

the build instructions are in the readme

#

the Windows one worked for me at least

dusky shale
#

im fixing them one by one and will update you

drowsy thistle
#

i don't have any information on what you're doing because you didn't fork the repo hahaha

dusky shale
#

yup i didnt fork it yet

#

afraid ill do a mess

drowsy thistle
#

you won't!

#

just make a separate branch

#

and the upstream branch should be untouched

#

if you wanna make a change in which you're afraid that it could make a mess, just make a branch for it

dusky shale
#

thats just a sample error that im getting

#

theres alot

drowsy thistle
#

oh god

dusky shale
#

im fixing them dont worry

drowsy thistle
#

TOPGG_UNUSED is supposed to be a macro that expands to an unused attribute if it exists, or nothing if it doesn't

dusky shale
#

ill create a branch soon

drowsy thistle
#

poggies

dusky shale
dusky shale
drowsy thistle
#

noted!

dusky shale
#

the pushed commit should do that too

drowsy thistle
dusky shale
drowsy thistle
drowsy thistle
#

@dusky shale heya uhm

#

it would be cool if the changes stayed consistent with the codebase's style lol (like there are some usage of 4-space indentation)

#

but it's okay!

dusky shale
#

what are the other things that i need to know about the repo?

#

so i can take 📓

drowsy thistle
dusky shale
#

is it?

#

though member functions defined insdie a class are implicitly inline by default

#

but we can add it back if u want to

#

nothing will change after that

#

its restored again

drowsy thistle
#

thanks for letting me know! ❤️

dusky shale
drowsy thistle
#

@dusky shale soooo how do i test it?

dusky shale
#

mkdir build

#

if exists, rmdir it first

#

then cd into it

#

then cmake --build .

#

it uses google test so ctest --output-on-failure

drowsy thistle
#

@dusky shale why did you remove these lines?

dusky shale
drowsy thistle
#

oh

dusky shale
#

for some reason i succesfully built the project removing those

#

im using Windows so

#

🤷‍♂️

drowsy thistle
#

fyi

if(WIN32 AND NOT EXISTS ${CMAKE_SOURCE_DIR}/deps/dpp.lib)
string(TOLOWER ${CMAKE_BUILD_TYPE} INSTALL_DPP_BUILD_TYPE)
execute_process(COMMAND powershell "-NoLogo" "-NoProfile" "-File" ".\\install_dpp_msvc.ps1" ${INSTALL_DPP_BUILD_TYPE} WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
endif()
``` runs the install D++ script for Windows (Microsoft Visual C++) if it couldn't find any
dusky shale
#

OH

drowsy thistle
#

that's what install_dpp_msvc.ps1 is for hahahaha

dusky shale
#

ill add those back

#

sorry!

drowsy thistle
#

no need to be sorry!

#

it's okay!

dusky shale
#

is there anything else that i need to change or know? ill be out after a few mins

dusky shale
#

nope ill just drive

drowsy thistle
#

oh alrighty

#

@dusky shale why did you remove these docstrings?

#

is it for the same reason?

dusky shale
#

if u saw my comment on the commit, i was about to create the docs on docsify and was about to edit the docstrings because of the new updates

dusky shale
#

i use docsify on every repo i got lol

dusky shale
#

docsify is like an md to html converter

drowsy thistle
#

ahh

#

doxygen is much more popular among the C++ community tho

#

that's what i was aiming for with those docstrings

dusky shale
#

i see

#

well ill leave the docs for u

drowsy thistle
dusky shale
drowsy thistle
#

i've been waiting for more updates from you buffer!

dusky shale
#

other than that u did everything good

drowsy thistle
#

uhm, where's the commit that adds the webhook feature?

drowsy thistle
#

your commit messages don't seem to mention webhooks in them so i assumed it's not implemented yet haha

dusky shale
#

np!

drowsy thistle
#

you're almost there, buffer!

dusky shale
# drowsy thistle you're almost there, buffer!

hiii, thanks! can you show me build output of yours of the current repo? like the latest repo without my commits... Its weird because it shows these on mine when I cloned the repo and built it lol

drowsy thistle
#

i am on Windows 11, so i just ran the build commands as instructed in the readme

#
cmake -B build .
cmake --build build --config Release
dusky shale
# drowsy thistle

I see, then I gotta void every commit that is related to the build script now

dusky shale
drowsy thistle
#

oh, sorry!

#

take your time buffer

broken frost
drowsy thistle
#

hai zobs!

broken frost
#

henlo

#

r u behaving

drowsy thistle
#

yes i am very much behaving

#

why wouldn't i

kindred maple
drowsy thistle
drowsy thistle
#

does anyone here have access to the repo settings of the Python, C++, and Rust SDKs? i want to add a few secrets

drowsy thistle
#

@faint fern do you have access?

faint fern
drowsy thistle
#

😭

drowsy thistle
#

@faint fern maybe xiuh can do it for me

faint fern
deft merlin
#

WOW LEAKING MY DMS

#

😭

drowsy thistle
#

i dont want to make family friendly sad

drowsy thistle
#

do you guys think i should adapt the breaking changes (i have a v0 branch in every top.gg sdk that i maintain) to the python sdk because it's has not been released since 2021?

dense barn
#

singlehandedly carrying top.gg open source

pastel girder
dense barn
#

bet

pastel girder
#

it was sarcasm

#

but like if you do that's neat lmao

dense barn
#

they deserve it

pastel girder
#

true

#

they did the same for topstats btw

#

null is awesome

dense barn
#

just need to get my business credit card

#

which is at home

pastel girder
#

lmao

#

RIP

drowsy thistle
#

thank you all! ❤️

drowsy thistle
#

it's a huge honor ayaka_pray

drowsy thistle
#

columns marked in red are affected by v0, bold columns are of priority

drowsy thistle
#

alright the Python and C++ SDKs are now pretty much done!

#

the Rust SDK is done too, but its autoposting feature is still not tested yet

dense barn
#

awesome!

drowsy thistle
woven granite
#

👀 you're pulling the ID from the token?

#

I didnt even know that was in there 😄

dense barn
drowsy thistle
#

really?? i thought it you patched it 😭

drowsy thistle
dense barn
#

lgtm

drowsy thistle
dense barn
#

wait until ci is done

drowsy thistle
#

i realized i messed up the docs because of ctrl+ring and you've already reviewed it by the time i made a commit lol

#

😭

#

it's done (i'm not sure if the jest tests are supposed to fail like that tho)

dense barn
#

i assume not

#
FAIL tests/Api.test.ts
  ● Test suite failed to run

    Got a malformed API token.

      44 |     
      45 |     if (tokenSegments.length !== 3) {
    > 46 |       throw new Error("Got a malformed API token.");
         |             ^
      47 |     }
      48 |     
      49 |     const tokenData = atob(token[1]);

      at new Api (src/structs/Api.ts:46:13)
      at Object.<anonymous> (tests/Api.test.ts:5:18)
drowsy thistle
#

yeah

#

i don't think the repo has a TOPGG_TOKEN secret

dense barn
#

no there's not

#

it doesnt need to be a real token

#

it just need to pass your validation

drowsy thistle
#

but that would require a real token, no?

dense barn
#

no?

#

your token validates

#

random-string.base64objectwithid.random-string

#

its close enough to the structure of the token

#

it doesn't check validity

#

neither is it able to

drowsy thistle
#

because some of them do need to validate actual valid API requests

dense barn
#

if you want to write tests that test response cases use a mock

tiny shard
dense barn
#

i dont know

#

we support both

#

im just commenting on that it doesnt need to change because the api endpoint still exists

tiny shard
#

gotcha. and as for this deprecation stuff, are the existing endpoints still working or will they just break

#

because if they’re just gonna break we ought to just release a new major and move on rather than deprecating

dense barn
#

no they still work

#

user api is removed tho

#

read the pinned post

tiny shard
#

gotcha

dense barn
#

we just cut down on the legacy api

drowsy thistle
dense barn
#

while retaining the actual used features

tiny shard
#

yeah

drowsy thistle
#

such as invite, support, and avatar returning the full URL now

tiny shard
#

Parsing out the id is certainly an interesting choice. Why couldn’t the api just do an @me/ like discord?

drowsy thistle
#

originally wanted to add deprecated to everything but i just gave up

tiny shard
#

well all this console log deprecated stuff?

dense barn
#

any of the bot api routes are not deprecated

#

you dont need to parse the token

#

all the api endpoints still work without needing to do so

drowsy thistle
#

yup

#

at one point it didn't work so i thought you patched it lol

drowsy thistle
dense barn
#

you cant send a request to the API

#

because you're not testing the API

#

yep, but unit tests arent' about testing external code

#

you don't want to have tokens in your testing code

#

that's bad practice

#

test your code

drowsy thistle
#

oh wait

#

changing it from authorization to Authorization changed it from 403 to 401

dense barn
#

yea

drowsy thistle
#

@tiny shard what do you think about this?

#

ohhh wait nevermind it all makes sense now

#

i didn't see jest.setup.ts onesieKEKW

drowsy thistle
#

@dense barn it should work now, check the pull request again

dense barn
#

in morning

#

its 4:30 am here

#

thank u <3

drowsy thistle
#

AAAAAAAAAAAAAAAAAAAA

#

😭

#

okay good night veld

drowsy thistle
kindred maple
#

One message removed from a suspended account.

drowsy thistle
#

yes

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

drowsy thistle
#

(im kidding, i dont know much about php, lua, or ruby)

#

its up to their maintainers

#

i aint maintaining seven SDKs at once 💀

#

im gonna die when v1 gets announced

kindred maple
#

One message removed from a suspended account.

#

One message removed from a suspended account.

drowsy thistle
#

no

#

it's v0

#

it's not even stable yet

drowsy thistle
#

every component of the API structure should be implemented now!

#

every endpoint is also implemented (except for autoposter in the Java and C# SDKs)

drowsy thistle
#

(the libraries are still largely not tested yet though, i'm still waiting further updates from Veld to be able to test them properly.)

dense barn
#

what did u need from me?

drowsy thistle
#

oh and also i needed to clarify whether the search parameter in GET /bots was removed or not, as it's no longer available in the docs

drowsy thistle
#

the Python, C++, Rust, Lua, Java, Node.js, Go, Ruby, and C# SDKs have been tried and tested! (except for the broken POST /bots/stats endpoint which is beyond my control)

drowsy thistle
dense barn
#

whats broken about it? MonkaChrist

drowsy thistle
drowsy thistle
#

@kindred maple just wondering, how are we supposed to use CreateListener and/or SubmissionAdapter?

drowsy thistle
#

every aspect of the Python, C/C++, Rust, Lua, Node.js, Go, Java, and Ruby SDKs has been implemented and tested. 1 SDK left to go.

drowsy thistle
#

the autoposter feature has been implemented and tested in the java sdk iaraThumbsUp all that's left now is the C# sdk

drowsy thistle
# drowsy thistle <@301379068941828096> just wondering, how are we supposed to use `CreateListener...

i'm thinking of making SubmissionAdapter public instead of internal (since it already has RunAsync() implemented), make it inherit a base class Adapter which handles the Start() and Stop() methods, and remove the lastTimeUpdated check since it's being called periodically every updateTime by Start(). Adapter here implements the IAdapter interface

i don't know much about C# so i could have interpreted this incorrectly, please let me know if i should revise my changes

drowsy thistle
drowsy thistle
#

(which is deprecated i know but still)

#

time to work on updating the docs!

drowsy thistle
dense barn
#

no

#

been a pain maintaining them though, we rewrote the service after this service error

#

so im deploying and fixing that later

drowsy thistle
#

oh nice

#

adding them to my sdks

dense barn
#

kk

#

leftcolor and stuff like that dont add those

drowsy thistle
#

why?

dense barn
#

new service infers colors from your bot metadata

drowsy thistle
#

sooo no parameters are needed? like at all?

dense barn
#

small/large

#

then for small you can set the three different variants

dense barn
#

lib? that has been deprecated 3 years ago

#

status? HUH

#

those havent existed in years

drowsy thistle
#

yeah the dotnet sdk hasn't been updated in so long

dense barn
#

yeah

#

i was the original author :)

#

i wrote it as a miki package first

#

then donated the code to top.gg

#

fun fact

#

I'm also the author of the C# cleverbot api client

drowsy thistle
#

YOU COULD DONATE CODE??

dense barn
#

?? yeah just hand over ownership of the code

#

you can always do that

drowsy thistle
#

ohhh

drowsy thistle
dense barn
#

idk lol

drowsy thistle
#

kek

drowsy thistle
drowsy thistle
#

for the time being, i'll just implement the large widget endpoint in my sdks

#

super awaiting following v1 updates!

drowsy thistle
#

alrighty, thanks veld!

drowsy thistle
#

noted noted

#

i'll refer to them in the sdks as entity IDs instead

dense barn
#

if you want a specific discord id

#

you can use these links

drowsy thistle
#

ahhh

#

but still not much different right

#

except that it gives out 404 on mismatched entity types

#

will implement, thanks veld ayaka_pray

#

can't wait to hear more v1 news from ya

dense barn
#

mismatched entity types?

#

yeah if you send a discord/server/<bot_id> it should be a 404 no?

drowsy thistle
#

yeah

dense barn
#

that's not different

#

if you pass a server id to the old api it also 404s

drowsy thistle
#

i know, i'm not saying it's a bad thing, it's expected

#

i'll adopt the more general endpoints to keep things simple

deft merlin
#

null poggers

drowsy thistle
#

thankies! appreciate it so muchhh! kittylove2

drowsy thistle
#

welp time to work on the php sdk as well plump_pain

drowsy thistle
#

php sdk almost done, only its autoposter left poggythumbsup

drowsy thistle
#

alright, done!

#

every sdk pretty much done! iara_yay

drowsy thistle
#

i'll work on the docs tomorrow or next week

drowsy thistle
#

should we use the latter?

dense barn
#

We need to know where the id comes from that's why there's a discord bot id

drowsy thistle
#

wait so the former only works for top.gg IDs?

#

noted noted, my bad

#

this is a bit confusing sorry 😭

#

time to rewrite the sdks to adapt to this plump_pain

#

i am so DUMB notlikekomi

drowsy thistle
#

alright, done! poggythumbsup

#

time to work on the docs again

drowsy thistle
#

C++, C#, and Go SDKs now have a proper documentation! i want to prioritize documentation coverage, consistency, and readability, so it may take a few days to properly document every SDK

drowsy thistle
#

done a little redesigning and restructuring!

drowsy thistle
#

hopefully things are more comfortable to read now BunNod

dense barn
#

the red deprecated tag is pretty heavy

#

but other than that is looks really neat!

#

Would be awesome to alphabetically sort the libraries

drowsy thistle
#

you're right, i'll change the text to white poggythumbsup

dense barn
#

can u make it grey background instead?

drowsy thistle
#

ohh suree

dense barn
#

the red in general is super harsh, seems more like a danger sign than "oh this is old"

drowsy thistle
#

i thought it would be more consistent with the site's color theme ia_lul_haha

drowsy thistle
#

the libraries are now alphabetically sorted and the color used for deprecated properties is now easier on the eyes!

drowsy thistle
#

i need it since the node sdk depends on it and @top-gg/eslint-config requiring old peer dependencies hinders me from trying to update the sdk's dependencies

drowsy thistle
#

the PHP and .NET SDKs now have working webhook wrappers for Laravel and ASP.NET Core/Blazor respectively with the possibility of future events in mind poggythumbsup, since the documentation said that future webhook events are possible in v1

drowsy thistle
#

the Ruby SDK now has a working webhook wrapper for Ruby on Rails and Sinatra! iaraThumbsUp

drowsy thistle
#

the Java SDK now has a working webhook wrapper for Spring Boot, Dropwizard, and Eclipse Jetty! poggythumbsup

dense barn
#

insanity

#

ur cooking

drowsy thistle
drowsy thistle
#

the C++ SDK now has a working webhook wrapper for cpp-httplib and Drogon! iaraThumbsUp

dense barn
#

amazing

drowsy thistle
#

if you have time of course

faint fern
drowsy thistle
drowsy thistle
#

the Lua SDK now has a working webhook wrapper for both HTTP and HTTPS!

#

which means that every SDK now should have every API feature covered poggythumbsup

#

the spreadsheet is now back to being fully green again proudkitty

dense barn
#

ur the goat

#

actually insane

drowsy thistle
#

appreciate it! you too, veld!

faint fern
drowsy thistle
#

maybe Woo?

faint fern
#

wrote this insightful comment but could not merge :(

woven granite
drowsy thistle
#

😔

#

at veld

dense barn
#

Why do we need to update it?

dense barn
#

Would prefer if we just break that dependency and archive the config repo

drowsy thistle
#

so we just directly include the eslint config in the node sdk?

dense barn
#

just make one in the repo yes

#

we don't use that repo internally anymore and I'd prefer it be archived

drowsy thistle
#

pull request closed, the updated eslint config is now embedded in the node.js SDK BunNod

dense barn
drowsy thistle
#

@dense barn regarding the endpoints prior to v1, will /v1/ be prepended to them?

dense barn
#

yes, it should show the exact url in the docs

drowsy thistle
#

oh alright

drowsy thistle
#

is it just name and description

#

because looking at discord's documentation, that's way too many dumb

dense barn
#

I mean I would recommend to accept them from library types

#

Why would you need to check all of them?

drowsy thistle
#

most of the SDKs are library-agnostic

#

because either there are way too many libraries to support or it would be a chore to also constantly adapt to newer releases

dense barn
#

right now we read:

  • type
  • name
  • description
  • name_localizations
  • description_localization
  • nsfw

in the future we will read:

  • options
    • name
    • description
    • name_localizations
    • description_localizations
    • required
    • choices
    • min_length
    • max_length
    • min_value
    • max_value
    • autocomplete
  • integration_types
  • contexts
#

though, I will recommend to use a type library from discord

#

that is, if you want to manage the type, otherwise just allow anything

#

we will throw a json error if there's descrepancies

drowsy thistle
#

this should also be reflected in the documentation, in case somebody goes libless

dense barn
#

I don't think it should imo

#

We may read more in the future

#

the goal is for it to be 100% discord-api compliant

#

what we support right now and what we will support in the future doesn't really matter for the public facing API

#

otherwise we will suddenly have to fail requests that miss data because the sdk is not up to date

#

which will be the worst case scenario for everyone, me, devs, and sdk maintainers

drowsy thistle
#

noted noted

#

i'll just support everything

#

just in case

#

this will take a bit, so be patient!

dense barn
#

@steady kite

#

You should be able to see this channel

steady kite
#

perfect

drowsy thistle
#

YESSSS

#

😭

steady kite
#

there is no GET for the /commands endpoint?

dense barn
#

no

#

you don't need to read them back because you generate them

#

im updating the docs with the latest variant now btw

steady kite
dense barn
steady kite
#

perfect checking now