Code Monkey home page Code Monkey logo

Comments (3)

TheDevYellowy avatar TheDevYellowy commented on June 10, 2024

if you fetch messages there is a type, type 18 is a thread ( idk if it's active or not I couldn't find a not active one to test on ).

{
  "attachments": [],
  "author": {},
  "channel_id": "",
  "components": [],
  "content": "", // ( the name of the thread )
  "edited_timestamp": null | "",
  "embeds": [],
  "flags": 0,
  "id": "",
  "mention_everyone": false,
  "mention_roles": [],
  "mentions": [],
  "message_reference": {},
  "pinned": false,
  "thread": {}, // data about the thread
  "timestamp": "",
  "tts": false,
  "type": 18
}

from discord.js-selfbot-v13.

DominosCinnaStix avatar DominosCinnaStix commented on June 10, 2024

if you fetch messages there is a type, type 18 is a thread ( idk if it's active or not I couldn't find a not active one to test on ).

{
  "attachments": [],
  "author": {},
  "channel_id": "",
  "components": [],
  "content": "", // ( the name of the thread )
  "edited_timestamp": null | "",
  "embeds": [],
  "flags": 0,
  "id": "",
  "mention_everyone": false,
  "mention_roles": [],
  "mentions": [],
  "message_reference": {},
  "pinned": false,
  "thread": {}, // data about the thread
  "timestamp": "",
  "tts": false,
  "type": 18
}

Mhmm, but this would lead to sending even more API requests just to figure out which channels have threads. I'd have to repeatedly fetch messages from all text based channels, which doesn't sound friendly to Discord' API

from discord.js-selfbot-v13.

DominosCinnaStix avatar DominosCinnaStix commented on June 10, 2024

Hmm, I decided to look at DevTools when running Discord. I saw that Discord is able to get the small menu list when hovering over a channel that has threads WITHOUT sending an API request. I looked at the WS events it sends and by sending

{
    "op": 37,
    "d": {
        "subscriptions": {
            "GUILD_ID": {
                "typing": true,
                "activities": true,
                "threads": true
            }
        }
    }
}

the client recieves a THREAD_LIST_SYNC that contains thread objects in that guild. I don't know if theres a limit on how many it sends, but it is definitely enough for me.

from discord.js-selfbot-v13.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.