【Discord】如何推播Twitter 推文到Discord 特定頻道 - HackMD

文章推薦指數: 80 %
投票人數:10人

選擇 要傳送訊息的頻道 ,替自動推播機器人 命名 與 修改頭像 並複製這時出現的網址,第11 步會用到. 在 IFTTT 上註冊帳號 (可直接使用其他網站帳號登入).       Published LinkedwithGitHub Like7 Bookmark Subscribe --- title:"【Discord】如何推播Twitter推文到Discord特定頻道" tags:Discord description:"即時轉貼Twitter文章至Discord的特定頻道內" image: --- {%hackmd@f6bfb5/biKBG-dnSQajGm3NZj38Fg%} #【Discord】如何推播Twitter推文到Discord特定頻道 ![](https://badgen.net/badge/created/~2019-12-14/)![](https://badgen.net/badge/last-modify/2021-09-27/) ##[pipedream](https://pipedream.com/) -自訂性極高,可依需求進行細部設定 ###設定步驟 1.註冊帳號或使用其他平台帳號快速登入 2.Selectasource選「Twitter」->選「UserTweets」->登入推特取得API授權 3.Screenname輸入想轉推的帳號->點「Createsource」 4.網站會自動跳到Sources分頁->點「Createworkflow」->點下面的「+」 5.選「Discordwebhook」->選「Sendmessagetochannel」 6.登入Discord取得API授權->選擇要轉發的伺服器與頻道 7.點params底下的`+message` 8.本文以轉貼網址為例,故此處輸入`https://twitter.com/{{steps.trigger.raw_event.user.screen_name}}/status/{{event.id_str}}` 9.點上方的「deploy」->點開steps.trigger右邊的開關 10.完成! ##[IFTTT](https://ifttt.com/) -IFTTT=IfThisThenThat(當某個服務有某個活動時做某件事) -[HowtouseDiscordWebhooks](https://gist.github.com/Birdie0/78ee79402a4301b1faf412ab5f1cdcf9) -[IFTTTGuide](https://birdie0.github.io/discord-webhooks-guide/services/ifttt.html) -[FetchRSS](https://fetchrss.com/) -2021/9/25起因不明原因,IFTTT的Twitter轉貼至Discord功能出現異常,目前仍待官方維修中 ###設定步驟 1.在想要中介轉貼資訊的Discord頻道右方點擊`齒輪(設定)` 或是直接點選`伺服器選單`進入`伺服器設定`,點擊進到`Webhooks`分頁 ![](https://i.imgur.com/BMGtucR.png) ![](https://i.imgur.com/ec7izWd.png) 2.點擊右上角`新增一個Webhooks`, 選擇`要傳送訊息的頻道`,替自動推播機器人`命名`與`修改頭像` **並複製這時出現的網址,第11步會用到** ![](https://i.imgur.com/nah6BsE.png) 3.在==[IFTTT](https://ifttt.com/)==上註冊帳號 (可直接使用其他網站帳號登入) ![](https://i.imgur.com/2E7GVqp.png) 4.點擊右上角頭像點選`Create` ![](https://i.imgur.com/f0iYDrK.png) 5.按IfThis的`This` ![](https://i.imgur.com/VAMMAnL.png) 6.選擇要獲取訊息的服務,這次是要從推特拿訊息, 所以在搜尋列輸入`Twitter`選推特 ![](https://i.imgur.com/qyg54Of.png) 7.選擇要獲取的對應事件,這次例子是要拿GBF新推文 所以點下方的`Newtweetbyaspecificuser` (當某位特定使用者發送推文時) ![](https://i.imgur.com/aUPwy1g.png) 8.輸入發送推文的帳號:`granbluefantasy` ![](https://i.imgur.com/3iphUox.png) 9.按ThenThat的`That` ![](https://i.imgur.com/QOCLvG7.png) 10.輸入Webhooks選取`Webhooks`, 只會出現一個功能選項,直接點選 ![](https://i.imgur.com/vXQsvO3.png) ![](https://i.imgur.com/9IvgJNW.png) 11.在URL欄位貼上`第2步複製的網址`, Method選`POST`, ContentType選`application/json`, Body複製貼上↓(※**`{`和`}`也要複製**) ```json { "content":"@{{UserName}}{{CreatedAt}}:{{LinkToTweet}}" } ``` ![](https://i.imgur.com/bzVfLR0.png) 12.按下`Createaction`與下一頁的`Finish`,到此才算完成 指定帳號發送推文後,就會自動轉貼到指定的Discord頻道上 ![](https://i.imgur.com/cbRSlzl.png) 13.欲修改時,同樣點選頭像的`MyApplets` ![](https://i.imgur.com/f0iYDrK.png) 即可看到目前啟用的程序,點入欲修改的程序後,點選右上角`Settings` ![](https://i.imgur.com/fGrobSP.png) 便可修改獲取訊息的帳號、傳送伺服器、訊息格式...etc.等內容 7 × Signin Email Password Forgotpassword or Byclickingbelow,youagreetoourtermsofservice. SigninviaFacebook SigninviaTwitter SigninviaGitHub SigninviaDropbox SigninviaGoogle NewtoHackMD?Signup



請為這篇文章評分?