Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/namila007/daily-quote-twitter-bot

A twitter bot who post daily QOD and reply to user with random quotes
https://github.com/namila007/daily-quote-twitter-bot

bot express expressjs heroku heroku-ready nodejs quotes-api twitter twitter-api twitter-bot twitter-streaming-api

Last synced: about 17 hours ago
JSON representation

A twitter bot who post daily QOD and reply to user with random quotes

Awesome Lists containing this project

README

        

# Daily-Quote-Twitter Bot

![nb bot](https://nb-twitter-bot.herokuapp.com/main.png)

[![Build Status](https://travis-ci.org/namila007/daily-quote-twitter-bot.svg?branch=master)](https://travis-ci.org/namila007/daily-quote-twitter-bot)

## Intro

A twitter bot made by nodejs, using twitter api. this will post QOTD, hourly quotes and reply to @ mention with a random quotes

## Run the code

1. Create a twitter account and create a [Twitter app](https://apps.twitter.com/)

2. Clone the git

3. make `.env` file and copy `.env.example` and add the relevant keys from twitter app
set `NODE_ENV = 'dev'` for developing and `NODE_ENV = 'production'` for normal usage

4. run `npm install`

5. run `npm start`

## Deploy

User can deploy this to heroku. Create ` Config Vars` for each in `.env` file and deploy

## API End Points

### GET `/count`

- return relevent `botid` tweet count
- example: `{"data":258}`

### GET `/quote`

- return a random quote
- example: `{"quote": "TEXT","author":"TEXT"}`

### GET `/ping`

- return a ` HTTP Status 200 OK`

#### this repo is derived from the [NB-personal-bot repo](https://github.com/namila007/nb-twitter-bot)