從 Discord.js 14 執行緒啟動訊息中檢索綜合論壇數據
P粉337385922
P粉337385922 2024-03-29 16:54:08
0
1
279

我對discord.js 與node 相對較新。我正在嘗試從線程中讀取第一條訊息,我不知道,作為數組並稍後保存。因為我想稍後透過 API 傳遞資料。

我在這裡打破了我的王冠。

我已經嘗試過:

const { ChannelType } = require('discord.js');

client.on('threadCreate', async (thread) => {
    if (thread.type == ChannelType.GuildPublicThread) {
        // When a new forum post is created
        console.log(thread.parentId) // The forum channel ID
        console.log(thread.id) // The forum post ID
        console.log(thread.name) // The name of the forum post
    }
})

但我找不到獲取 wohl 線程資料的方法。也許有人可以幫我解決這個問題?

P粉337385922
P粉337385922

全部回覆(1)
P粉794851975

雷雷
熱門教學
更多>
最新下載
更多>
網站特效
網站源碼
網站素材
前端模板
關於我們 免責聲明 Sitemap
PHP中文網:公益線上PHP培訓,幫助PHP學習者快速成長!