A Twitter Bot that returns CoCDice that can be used on Nodejs. This repository is a modification of the repository (Python) at the following URL so that it can run on Nodejs.
The program of this repository is running on the following Twitter account. You can reply or send a direct message.
This bot will reply to Twitter replies and direct messages. BCDice basic commands and CoC7th commands are available. For example,
User> @Bot 1d100
Bot > @User (1D100) > 83
User> @Bot cc<=50
Bot > @User (1D100<=50) ボーナス・ペナルティダイス[0] > 1 > 1 > クリティカル
Here, Twitter and Vercel preparations are written separately, but please proceed in order depending on the situation.
-
Create a Project and App on the TwitterDeveloperPortal. Set the permission to
Read and write and Direct message
and set theCallback URI
. -
Register the App created above in
Account Activity API / Sandbox
which is one of the DevEnvironments of PremiumAPI. Please note that you can only register one per account. -
Register webhooks and subscriptions using this API reference. Please note that you can only register one for each account. If you want to change it, you need to erase it once.
-
Deploy to Vercel from the button below.
-
Register the key and secret for using TwitterAPI in the environment variables.
CONSUMER_KEY=**************** CONSUMER_SECRET=************************** ACCESS_TOKEN_KEY=**************************** ACCESS_TOKEN_SECRET=*************************************
-
Complete!!! Use your Twitter Bot!!!
This repository is available under the MIT license. Check the respective pages for other libraries.
Negima1072 (Twitter@Negima1072)