GithubHelp home page GithubHelp logo

icomenezes / sufficit-quepasa Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ediboko1980/sufficit-quepasa-fork

0.0 0.0 0.0 81.63 MB

License: GNU Affero General Public License v3.0

Shell 0.38% JavaScript 0.44% Go 49.41% CSS 49.18% Makefile 0.51% DTrace 0.02% Dockerfile 0.06%

sufficit-quepasa's Introduction

Go Build

Quepasa-logo

Quepasa is a Open-source, all free license software to exchange messages with Whatsapp Platform


Telegram-logo Chat with us on Telegram: Group || Channel

Special thanks to Lukas Prais, who developed this logo.


# QuePasa

A (micro) web-application to make web-based WhatsApp bots easy to write.

Run in Postman PostMan Shared Documentations PostMan Public Workspace

Features:

  • Verify a number with a QR code
  • Persistence of account data and keys
  • Exposes HTTP endpoints for:
    • sending messages
    • receiving messages
    • download attachments
    • set webhook for receiving messages

WARNING: This application has not been audited. It should not be regarded as secure, use at your own risk.

This is a third-party effort, and is NOT in any affiliated with WhatsApp.

Clone and Install

git clone https://github.com/sufficit/sufficit-quepasa /opt/quepasa-source
bash /opt/quepasa-source/helpers/install.sh

Final step


Anything is section was not reviewed

Implemented features:

  • Verify a number with a QR code
  • Persistence of account data and keys
  • Exposes HTTP endpoints for:
    • sending messages
    • receiving messages
    • download attachments
    • set webhook for receiving messages

WARNING: This application has not been audited. It should not be regarded as secure, use at your own risk.

This is a third-party effort, and is NOT in any affiliated with WhatsApp.

Why ?

Angry, Angry ... WhatsApp keeps canceling our number.

When you need to communicate over WhatsApp from a different service, for example, a help desk or other web-app, QuePasa provides a simple HTTP API to do so.

QuePasa stores keys and WhatsApp account data in a postgres database. It does not come with HTTPS out of the box. Your QuePasa API tokens essentially give full access to your WhatsApp account (to the extent that QuePasa has implemented WhatsApp features). Use with caution.

For HTTPS use Nginx.

If are you looking for a NODE.JS Project

Take a look at https://github.com/pedroslopez/whatsapp-web.js/pulls

Its a lot more complete tool to whatsapp unofficial api

Join our community

Matrix chat room #cdr-link-dev-support:matrix.org https://app.element.io/#/room/#cdr-link-dev-support:matrix.org

Usage

Prerequisites Local Deployment

  • Mysql (Recommended)
  • Golang (Version go1.18 minimum version)

installing above golang version

cd /usr/src

sudo wget https://go.dev/dl/go1.20.linux-amd64.tar.gz
sudo rm -rf /usr/local/go && sudo tar -C /usr/local -xzf go1.20.linux-amd64.tar.gz

#export the PATH
export PATH=$PATH:/usr/local/go/bin

First step

Clone the repo 

```bash

git clone https://github.com/sufficit/sufficit-quepasa-fork.git

```

Second step

Create Database and Users
sudo mysql

# create the user

mysql> CREATE USER 'quepasa'@'%'IDENTIFIED BY 'S0me_RaNdoM_T3*T';

# Granting Permition to the Quepasa User

mysql> GRANT ALL ON quepasa.* TO 'quepasa'@'%';

# Flushing the Privileges 

mysql> FLUSH PRIVILEGES;

# Create quepasa DataBase 

mysql> CREATE DATABASE quepasa;

# exit mysql 

mysql> exit

Third step

Creating the Tables Required

```bash

cd into the cloned reop

cd <git_clone_location>/src/migrations/

#below will create the relevent tables in the quepasa database for you

sudo mysql --database=quepasa < 1_create_tables.up.sql

```

Forth step

Creating the .env file

# this file contains all the environment varibles that the system needed do the changes that matches your deployment

#create the .env file in the below location

nano <git_clone_location>/src/.env

# content of the file should looklike this 

WEBAPIHOST=0.0.0.0 
WEBAPIPORT=31000 # web port of the API
WEBSOCKETSSL=false # http or Https
DBDRIVER=mysql #Databse Server
DBHOST=localhost
DBDATABASE=quepasa
DBPORT=3306
DBUSER=quepasa
DBPASSWORD='S0me_RaNdoM_T3*T' #the string you created in the third step 
DBSSLMODE=disable
APP_ENV=development # this will write some extra debug messages you can change it to production if needed
MIGRATIONS=false
SIGNING_SECRET=5345fgdgfd54asdasdasdd #some random test this will be used for password encription 

Fifth step

Compiling the Packge

# cd into the src directory

<git_clone_location>/src/

# compile using golang this may take few seconds to compile

go run main.go

if error occourd such as "go not found" please make sure to export the path again

Final step


Docker Implimentation

Prerequisites

For local development

  • docker
  • golang
  • postgresql

Run using Docker

  • Add info about database migrations
make docker_build
# edit docker-compose.yml.sample to your hearts content
docker-compose up

Environment Variables

# WEBAPIHOST
> http server bind host (HOST:PORT) default empty.

# WEBAPIPORT
> http server bind port (HOST:PORT) default 31000.

# WEBSOCKETSSL
> Should websocket for qrcode reads use ssl, default false.	

# APP_ENV
> Environment name, only knows "development", any other will be not development, implies on logs only, default empty.	

# APP_TITLE
> Suffix for quepasa name on whatsapp devices list like (QuePasa Sufficit), default empty.	

License

License GNU AGPL v3.0

QuePasa is a free software project licensed under the GNU Affero General Public License v3.0 (GNU AGPLv3) by Sufficit Soluções.

sufficit-quepasa's People

Contributors

hugodeco avatar redaranj avatar ssteeltm avatar zhiru avatar kakalpa avatar

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.