Code Monkey home page Code Monkey logo

web3terms's Introduction

web3terms

GitHub issues GitHub forks GitHub stars GitHub watchers Twitter Follow

A Twitter bot explaining and simplifying web3 terms to everyone!

Screenshot 2022-04-07 at 22 58 40

๐Ÿ† Features

  • Web3 terms explanation โœ…
  • Daily Web3 terms tweet โœ…
  • Acknowledgement tweet โœ…
  • Test Coverage โœ…
  • Endpoint https://web3terms.onrender.com/terms to retrieve all terms โœ…
    • Response:
        {
            "previousPage": "xx",
            "nextPage": "xx",
            "total": xxx,
            "totalPages": xxx,
            "items": [
                {
                    "term": "abi",
                    "meaning": "ABI is the standard way to interact with contracts in the Ethereum ecosystem, both from outside the blockchain and for contract-to-contract interaction."
                },
                
                //...
            ]
        }
    • To filter, pass the query params page and/or limit.

๐Ÿ›  Installation

  • Install Node.js on your PC
  • Start by making a fork of the repository. Click on the "Fork" symbol at the top right corner
  • Clone this repo
git clone https://github.com/Olanetsoft/web3terms.git
  • Run
yarn

It will install Twit, the library that lets us talk to Twitter.

๐Ÿฅ‚ After making a change

  1. Sort the file
yarn run sort
  1. Run a test to check all definition length
yarn test
  1. Create a new branch
git checkout -b <Your-branch-name>
  1. Add changes
git add .
  1. Add a commit message
git commit -m "<your message>"
  1. Push your changes
git push --set-upstream origin <branch-name>
  1. Create a Pull Request

  2. Congratulations ๐Ÿ™Œ๐Ÿผ

๐Ÿ”€ Connecting to Twitter

  1. Register a Twitter account and also get its "app info".

Twitter doesn't allow you to register multiple twitter accounts on the same email address. I recommend you create a brand new email address (perhaps using Gmail) for the Twitter account. Once you register the account to that email address, wait for the confirmation email.

  1. Now go here and log in as the Twitter account for your bot:
  2. Fill up the form and submit.
  3. Next once the submission completes you will be taken to a page which has the
  • "Settings" tab : Update details here
  • "Permissons" tab : Enable Read and Write
  • "Key and Access Token" tab : Click on Generate access token.
  1. Create a .env file and fill in the generated tokens in the "Key and Access Token" tab.

It should look like this:

PORT=xxxx
NODE_ENV=development

DEV_BASE_URL=http://localhost:$PORT
PROD_BASE_URL=http://localhost:$PORT

TWITTER_CONSUMER_KEY=xxxx
TWITTER_CONSUMER_SECRET=xxxx

TWITTER_ACCESS_TOKEN=xxxx
TWITTER_ACCESS_TOKEN_SECRET=xxxx
  1. Type the following in the command line in your project directory to start the project
yarn dev

You should have something similar to what is shown below on your terminal.

[LOGGING] info: "Connected!"
[LOGGING] info: "Server running on port xxxx"

๐Ÿ‘จโ€๐Ÿ‘ฉโ€๐Ÿ‘ฆ Community

Don't forget to follow Web3terms on twitter

๐Ÿง‘โ€๐Ÿ’ป Contributing

  • Contributions make the open source community such an amazing place to learn, inspire, and create.
  • Any contributions you make are greatly appreciated.
  • Check out our contribution guidelines for more information.
  • Star - If you like it
  • Fork - If you like to build your own version
  • File an issue - If you found a bug
  • Send a pull request - If you want to contribute

Whats Next

You might want to push this app to a running server, here is a curated list you can checkout..

Do not misuse the twitter api to spam or burden the server load for twitter api, as twitter follows a strict rule of closing down accounts that do that. Please read here for the rules

Note to Contributors

  • All web3 terms in the data/terms.json directory should be in lowercase.
  • Look to ensure that newly added terms aren't already available to avoid repetition of terms and keywords.

๐Ÿซ‚ Credits

Thanks to all Contributors ๐Ÿ’ช

Thanks a lot for spending your time helping Web3Terms Bot grow. Happy Hacking ๐Ÿป

Contributors

Thanks to all Stargazers โญ๏ธ

Thanks to all stargazers

web3terms's People

Contributors

0xcryptochica avatar 2brownc avatar afpedreros avatar ahmedsilat44 avatar amethystcodes avatar anant-c avatar asaniyan avatar awojobigodfrey avatar devmukhtarr avatar firascodes avatar francescoxx avatar frankiefab100 avatar himanshu-malviya15 avatar ivcandela avatar josh4324 avatar mide001 avatar mm-s avatar nully0x avatar nwizu033 avatar olanetsoft avatar omahs avatar oneknucklehead avatar oyedeletemitope avatar qudusayo avatar rabeet8 avatar rishav-12 avatar vinyl-davyl avatar xeno097 avatar yhuakim avatar zenunicorn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

web3terms's Issues

Handle Case Sensitive Keywords

ISSUE

Currently, the keyword that is present inside the terms.json is matched exactly with the provided input KW from the tweet which shouldn't be matched exactly. So, it's better to handle the case of the keyword.

SOLUTION

Converting the input KW to lowercase and comparing the KW (in lower case) present in terms.json should solve the issue.

feat: Add tests to verify web3 terms data format

Context

Issue 35 specifies that the term's meaning should be 280 characters long or less and the term should be lowercase but currently, nothing enforces this rule or warns about it, which means that the only way to notice this is either during a code review or if the Twitter API does not respond as explained here 41

Suggested Solution

  • Add tests to check that every meaning is 280 characters or less and the term is lower case
  • Add a GitHub action that runs the tests when a pull request is opened to check if the data complies with the before-mentioned constraints

Extra

  • A test to verify that every term is unique could be added

Fix: Format ReadMe

  • Add required information where necessary
  • Add styles or formats to make the ReadMe better

Docs: Add a short explanation of conventional commits in the contributing.md file

I saw in the commit history that you're following the conventional commits, which may not be familiar to new contributors.

I would like to add a short explanation with practical examples in the contributing.md file to help new contributors write a better subject line in their commits before contributing.

I can work on this issue.

Refactor: Remove duplicated web3 terms

I noticed some web3 terms were repeated.
Eliminating the first instance should fix this.

See Screenshot:

L2
web3terms-terms-json-GAS FEES

node
web3terms-terms-json-NODE

gas fees
web3terms-terms-json-at-develop-ยท-frankiefab100-web3terms

In the case of sha256 and sha-256. This could be a variance.

web3terms-terms-json-SHA256

Fix: Fix all the terms without tag

Fix all the Web3 terms in the terms.json without a tag. e.g. we have some in this format is a .... or This is a, change it to contain the terms like Bitcoin is a ...

Error: 404 Bad Streaming Request

After setting up all the Twitter Secret Keys and starting the run command yarn run dev

  • I noticed the following error message (Bad request Stream)
    image

I'm guessing it's from the Twit framework and the updated twitter API endpoint for filtered streaming. I tried logging the streaming request from the node_module, like in the image above but couldn't find the requested link
I also tried updating the streaming endpoints to twitter v2 from node_module... (locally), still logging the same error.

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.