├── README.md ├── THEMES.md ├── images ├── add2slack.png ├── bluebar.png ├── bluebar.svg ├── db-config1.png ├── db-config2.png ├── definecmd.png ├── draganddrop.png ├── fetch.png ├── gaugechart.png ├── guide.png ├── springbar.png ├── springbox.svg └── svglink.png ├── themes └── example-style.css └── trainers ├── example-multiple.yaml └── example.yaml /README.md: -------------------------------------------------------------------------------- 1 | ![Fetch](./images/fetch.png) 2 | 3 | # Overview: Chatlytics Data Visualization For Slack 4 | Chatlytics is a data query and visualization platform. Part of the platform is a bot called "Fetch". Think of Fetch not just as a chatbot, but as an analytics assistant too. 5 | 6 | Fetch has one key job to perform: help teams use their data to create beautiful visualizations without ever needing to leave Slack (or Hipchat). Fetch takes care of the query, visualization and reporting grunt work so your team can focus on more important things. Fetch packages everything in flexible and customizable PNG & interactive SVGs. 7 | 8 | - [Prerequisites](#prerequisites) 9 | - [How To Interact With Fetch, Your Analytics Bot](#how-to-interact-with-fetch-your-analytics-bot) 10 | - [Step 1: Add To Slack](#step-1-add-to-slack) 11 | - [Step 2: Setup Your Database connection](#step-2-setup-your-database-connection) 12 | - [Step 3: Ask Fetch To Run Queries For You](#step-3-ask-fetch-to-run-queries-for-you) 13 | - [Teaching Fetch Custom Commands](#teaching-fetch-custom-commands) 14 | - [Step 1: Defining Custom Commands Via YAML File](#step-1-defining-custom-commands-via-yaml-file) 15 | - [Step 2: Train Fetch To Understand Your Command](#step-2-train-fetch-to-understand-your-command) 16 | - [Drag-and-Drop](#drag-and-drop) 17 | - [Attachments](#attachments) 18 | - [Remote Import from URL](#remote-import-from-url) 19 | - [Step 3: Tell Fetch To Run Your New Commands](#step-3-tell-fetch-to-run-your-new-commands) 20 | - [Creating Your Own Themes](#themes) 21 | - [Notes](#notes) 22 | - [MySQL](#mysql) 23 | - [Issues](#issues) 24 | - [Contributing](#contributing) 25 | 26 | ## Prerequisites 27 | You will need: 28 | 29 | * Database connection parameters. Currently only `PostgreSQL`, `MySQL`, `Amazon Redshift`, `Amazon Aurora (Postgres/MYSQL)` and `AmazON RDS (Postgres/MYSQL)` are supported) 30 | * Slack account for the bot to use. If you do not have one you need to get yourself a Slack account. Go to the Slack website: https://slack.com/ 31 | 32 | 33 | 34 | ## How To Interact With Fetch, Your Analytics Bot 35 | 36 | ### Step 1: Add To Slack 37 | 38 | The first step required to set the bot up involves clicking the "Add to Slack" button at [https://www.chatlytics.co](https://www.chatlytics.co). 39 | 40 | ![Add To Slack](./images/add2slack.png) 41 | 42 | Chatlytics is only available for use with Slack at the moment. Other chat clients (Hipchat, Facebook, Skype, etc.) will be added soon! 43 | 44 | ### Step 2: Setup Your Database Connection 45 | You'll want to start by setting up your database connection. Run the command `!dbconfig` and follow the prompts to get started. 46 | 47 | 48 | 49 | In addition to your database type, Fetch will need your host address (which can be an IP address or domain), your username & password, port and database name. After you provide this info, you'll be able to review the configuration and start giving Fetch commands! 50 | 51 | 52 | 53 | 54 | 55 | ### Step 3: Ask Fetch To Run Queries For You 56 | 57 | Once you have connected Chatlytics to your database, you can interact with Fetch by sending commands to the linked Slack account. 58 | 59 | You'll find a guide to these commands at [https://www.chatlytics.co/guide.html](https://www.chatlytics.co/guide.html). Just select a command in the dropdown to see what Fetch will do with it and get additional tips. 60 | 61 | ![Guide](./images/guide.png) 62 | 63 | Fetch has a built-in set of commands it understands. To see a list of available commands Fetch can recognize, type `!help`. 64 | 65 | The following is a list of available predefined commands: 66 | * `!list_tables`: Returns a list of all tables in the database. 67 | * `!table_count `: Returns the number of rows in the table. 68 | * Example: `!table_count MyTable` 69 | * `!count_compare