'Discord bot to see which servers the logged in user is on

I'm trying to make a Discord server list, but I have no idea how to see which servers the users are on. disboard.org i will give an example sample: enter image description here

If you found the Discord server list infrastructure from somewhere or if you have a link to the infrastructure, can you send it to me?



Solution 1:[1]

Discord's OAuth2 API contains the guilds scope, allowing an application to access an authorized user's guilds. After authenticating with OAuth2, you can GET /users/@me/guilds to retrieve a list of guilds that the user is in. This returns a partial guild object containing the following data:

{
  "id": string,
  "name": string,
  "icon": string,
  "owner": boolean,
  "permissions": string,
  "features": Array<string>
}

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1