Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/apibrasil/apibrasil-whatsapp
Painel para gestão de dispositivos conectados na API do MYZAP, o software é de uso aberto e você pode alterar da forma que desejar.
https://github.com/apibrasil/apibrasil-whatsapp
apigratis laravel laravel8 php8 whatsapi
Last synced: 3 months ago
JSON representation
Painel para gestão de dispositivos conectados na API do MYZAP, o software é de uso aberto e você pode alterar da forma que desejar.
- Host: GitHub
- URL: https://github.com/apibrasil/apibrasil-whatsapp
- Owner: APIBrasil
- Created: 2022-05-31T04:27:03.000Z (over 2 years ago)
- Default Branch: stable
- Last Pushed: 2022-12-16T16:52:03.000Z (about 2 years ago)
- Last Synced: 2024-10-11T11:22:15.193Z (3 months ago)
- Topics: apigratis, laravel, laravel8, php8, whatsapi
- Language: HTML
- Homepage: https://apigratis.com.br
- Size: 15 MB
- Stars: 38
- Watchers: 4
- Forks: 15
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- Security: SECURITY.md
Awesome Lists containing this project
README
# 🧪 Painel OpenSource MyZap - Laravel
Painel para gestão de dispositivos conectados na API do MYZAP, o software é de uso aberto e você pode alterar da forma que desejar, caso queira testar o painel sem instalar, basta entrar no link abaixo.Afinal de contas o que esse painel faz? Ele foi desenvolvido para fazer a gestão dos seus dispositivos conectados a sua API do WhatsApp (MyZap) facilitando assim sua integração com demais ferramentas.
[![Stargazers repo roster for @APIBrasil/apibrasil-whatsapp](https://reporoster.com/stars/APIBrasil/apibrasil-whatsapp)](https://github.com/APIBrasil/apibrasil-whatsapp/stargazers)
### Como instalar o painel (vídeo)
[![Veja como instalar o painel](https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcSLqucU8YFD6urMWD33VaGz5yLresNoCjvIJA&usqp=CAU)](https://www.youtube.com/watch?v=zFs6JmZoF6g)### Servidor VPS gratuito
```https://www.oracle.com/br/cloud/free/```### Compre um servidor para utilizar o painel
```https://apibrasil.com.br/```### Servidor recomendado
```
Ubuntu 20.04 Superior
1 GB / 1 vCPU
6GB HD
```### Liberando regras de firewall
```
iptables -F
iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
iptables -A INPUT -i lo -j ACCEPT
iptables -A INPUT -p tcp --dport 22 -j ACCEPT
iptables -A INPUT -p tcp --dport 443 -j ACCEPT
iptables -A INPUT -p tcp --dport 80 -j ACCEPT
iptables -A INPUT -p tcp -j DROP
```### Instalando as dependencias e clonando o projeto
```bash
sudo apt install -y software-properties-common
``````bash
sudo add-apt-repository ppa:ondrej/php
``````bash
sudo apt update && apt install -y nginx git software-properties-common unzip zip build-essential zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libreadline-dev libffi-dev wget mariadb-server php7.4 php7.4-mbstring php7.4-xmlrpc php7.4-soap php7.4-gd php7.4-xml php7.4-cli php7.4-zip php7.4-bcmath php7.4-tokenizer php7.4-json php-pear php7.4-curl php7.4-intl php7.4-mysqli php7.4-fpm python3-certbot-nginx
``````bash
cd /opt && git clone https://github.com/APIBrasil/apibrasil-whatsapp.git painel-whatsapp
```### Altere as configurações do php
```bash
nano /etc/php/7.4/fpm/pool.d/www.conf
```listen = 127.0.0.1:9000
### Altere as informações do banco de dados
```bash
mariadb -u root -p
``````mysql
CREATE DATABASE apibrasil;
USE mysql;
UPDATE user SET PLUGIN='' WHERE User='root';
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '_SeT_On3_B1g_STR0NG_P@ssw0rd_';
FLUSH PRIVILEGES;
EXIT;
```### Instale as dependencias do composer
```bash
cd /opt/painel-whatsapp
``````bash
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
php -r "if (hash_file('sha384', 'composer-setup.php') === '55ce33d7678c5a611085589f1f3ddf8b3c52d662cd01d4ba75c0ee0459970c2200a51f492d557530c71c15d8dba01eae') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
php composer-setup.php
php -r "unlink('composer-setup.php');"
``````bash
php composer.phar install
``````bash
cp .env_example .env
``````bash
nano .env
```### Reinicie tudo e coloque para iniciar automaticamente
```bash
service mysql restart
service php7.4-fpm restart
service php7.4-fpm statussudo systemctl enable nginx
sudo systemctl enable mysql.service
```### Instale as crons necessárias
```bash
crontab -e* * * * * cd /opt/painel-whatsapp && php7.4 artisan schedule:run >> /dev/null 2>&1
```### Criar e Popular o banco de dados
```bash
php artisan migrate
php artisan db:seed
```### Permissões necessárias
```bash
chmod 777 storage/app
chmod 777 -R storage/framework
chmod 777 -R storage/logs
```### Execute os jobs
```bash
php artisan queue:work &
``````bash
jobs -l
```### Server Block Nginx
```bash
nano /etc/nginx/sites-available/painel
``````
server {root /opt/painel-whatsapp/public;
index index.php index.html index.htm;server_name SEU_DOMINIO.COM;
location / {
try_files $uri $uri/ /index.php?$query_string;
resolver 8.8.8.8 ipv6=off;
}location ~ \.php$ {
try_files $uri $uri/ /index.php?$query_string;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
listen 80;}
``````bash
ln -s /etc/nginx/sites-available/painel /etc/nginx/sites-enabled/painel
``````bash
certbot --nginx
```### Tudo certo.
Usuário padrão de acesso a plataforma[email protected]
1234### Esse software consumiu a SDK em PHP para o MYZAP
https://packagist.org/packages/jhowbhz/package-apigratis
### Prints