Skip to main content

No project description provided

Project description

Bots for quiz

Description

Build Status Maintainability GitHub Platform wemake-python-styleguide

This repository contains Vk and TG bots for the quiz. They get used to the questions and check the correctness of the answers to them.

Bot examples:

  • Tg bot
  • Vk bot - write to group messages 'Новый вопрос'

Table of content

Installation

  • Install using pip:

    pip install quiz-bots
    
  • Create a bot in Telegram via BotFather, and get it API token.

  • Create redis account in Redislabs, and after that create cloud database (you can choose free plan). Get your endpoint database url and port.

  • Create VK's group, allow it send messages, and get access token for it.

  • Register environment variables in the operating system:

    export TELEGRAM_TOKEN=telegram_token
    export DB_ENDPOINT=redis endpoint
    export DB_PASSWORD=redis_password
    export VK_GROUP_TOKEN=token_vkontakte
    
  • Put the question files in a folder(sample files are in the repository folder quiz_files_example) and export quiz content to Redis:

    quiz-bots --export_quiz_content_to_redis [path_to_questions_folder]
    

How to use

Run TG bot:

quiz-bots --start_bot tg

Run VK bot:

quiz-bots --start_bot vk

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Project Goal

The code is written for educational purposes on online-course for web-developers dvmn.org.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

quiz-bots-0.1.3.tar.gz (9.0 kB view hashes)

Uploaded Source

Built Distribution

quiz_bots-0.1.3-py3-none-any.whl (10.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page