Golang API for Whatsapp API MultiDevice version

Go Whatsapp API Multi Device Version

Required

  • Mac OS:
    • brew install vips
    • export CGO_CFLAGS_ALLOW="-Xpreprocessor"
  • Linux:
    • sudo apt update
    • sudo apt install libvips-dev
  • Windows (not recomended, prefer using WSL):

How to use

  1. Clone this repo git clone https://github.com/aldinokemal/go-whatsapp-web-multi-device
  2. run go run main.go
  3. open http://localhost:3000

You can fork or edit this source code !

Current API

Feature Menu Method URL Payload
Login GET /app/login
Logout GET /app/logout
Reconnect GET /app/reconnect
User Info GET /user/info
Param Type Type Example
phone string querystring 6289685024099
User Avatar GET /user/avatar
Param Type Type Example
phone string querystring 6289685024099
User My Group List GET /user/my/groups
User My Privacy Setting GET /user/my/privacy
Send Message (Text) POST /send/message
Param Type Type Example
phone string form-data 6289685024099
message string form-data Hello guys this is testing
Send Message (Image) POST /send/image
Param Type Type Example
phone string form-data 6289685024099
caption string form-data Hello guys this is caption
view_once bool form-data false
image binary form-data image/jpg,image/jpeg,image/png
Send Message (File) POST /send/file
Param Type Type Example
phone string form-data 6289685024099
file binary form-data any (max: 10MB)
Send Message (Video) POST /send/video
Param Type Type Example
phone string form-data 6289685024099
video binary form-data mp4/avi/mkv
✅ = Available
❌ = Not Available Yet

App User Interface

  1. Homepage Homepage
  2. Login Login
  3. Send Message Send Message
  4. Send Image Send Image
  5. Send File Send File
  6. User Info User Info
  7. User Avatar User Avatar
  8. User Privacy User My Privacy
  9. User Group List Group

Mac OS NOTE

  • Please do this if you have an error (invalid flag in pkg-config --cflags: -Xpreprocessor) export CGO_CFLAGS_ALLOW="-Xpreprocessor"
Comments
  • can't sent to group chat

    can't sent to group chat "phone: must be a valid E164 number"

    curl -X POST -F '[email protected]' -F 'message=hi' http://172.17.12.185:3000/send/message

    {"code":400,"message":"phone: must be a valid E164 number.","results":null}

  • message: the length must be between 1 and 50

    message: the length must be between 1 and 50

    got error when sending message to personal and group, return json error: {code: 400, message: "message: the length must be between 1 and 50.", results: null}

    it's have limitation on sending message?

  • The Caption field is missing in File Send Request or Document Message

    The Caption field is missing in File Send Request or Document Message

    The Caption field in Domains->Send->File.go-> FileRequest is missing type FileRequest struct { Phone string json:"phone" form:"phone" File *multipart.FileHeader json:"file" form:"file" Caption string json:"caption" form:"caption" <------ should be added }

    along with its assignment in service->send.go ->SendFile-> waProto.DocumentMessage at line number 182. A caption field should also be there in the waProto.DocumentMessage initialization. A field Caption is already there in waProto.DocumentMessage which needs to be mapped to FileRequest.Caption

    msg := &waProto.Message{DocumentMessage: &waProto.DocumentMessage{ Url: proto.String(uploadedFile.URL), Mimetype: proto.String(http.DetectContentType(dataWaFile)), Title: proto.String(request.File.Filename), FileSha256: uploadedFile.FileSHA256, FileLength: proto.Uint64(uploadedFile.FileLength), MediaKey: uploadedFile.MediaKey, FileName: proto.String(request.File.Filename), FileEncSha256: uploadedFile.FileEncSHA256, DirectPath: proto.String(uploadedFile.DirectPath), Caption: proto.String(request.File.Caption), <------ should be added }}

  • feat: add image url in webhook

    feat: add image url in webhook

    Context

    • When we enable webhook, we got an encrypted image URL, in this PR, webhook going to send a downloadable image without a host (just a full path image)
    Screenshot 2023-01-03 at 08 38 16

    Moreover, we can download directly with accessing localhost:3000/statics/media/fileName.jpe

  • feat: add avatar preview

    feat: add avatar preview

    Context:

    • Updating library to the latest version (v0.0.0-20221213225758-70ef67df3c68), added a new feature to preview thumbnails avatar
    • Update OpenAPI
    • Set timeout when fetching avatar
    • Update Docs
  • feat: add checking whether group or not

    feat: add checking whether group or not

    Context

    • Currently, the webhook has a bug. It will trigger to send in the direct message even though other people send through group message, not the direct message. This happens if a bot is joined in the same group as the sender. This PR will check whether the JID type is a group or direct message
  • feat: allow to change os name

    feat: allow to change os name

    Context

    • Some of you probably would like to change the app name with your application name, now you can do this with simple command --os=MyApplication
go-whatsapp-rest-API is a Go library for the WhatsApp web which use Swagger as api interface

go-whatsapp-rest-API go-whatsapp-rest-API is a Go library for the WhatsApp web which use Swagger as api interface Multi-devices (MD) Support. This ver

Dec 15, 2022
Package rhymen/go-whatsapp implements the WhatsApp Web API to provide a clean interface for developers

go-whatsapp Package rhymen/go-whatsapp implements the WhatsApp Web API to provide a clean interface for developers. Big thanks to all contributors of

Mar 19, 2022
Simple RESTful API for WhatsApp in Golang (using the Whatsmeow multi device library)
Simple RESTful API for WhatsApp in Golang (using the Whatsmeow multi device library)

WUZAPI WuzAPI is an implementation of @tulir/whatsmeow library as a simple RESTful API service with multiple device support and concurrent sessions. W

Dec 30, 2022
WhatsApp Web API

go-whatsapp Package rhymen/go-whatsapp implements the WhatsApp Web API to provide a clean interface for developers. Big thanks to all contributors of

Jan 7, 2023
WhatsAppExpenseTracker - Way to track expenses using whatsapp group

WhatsAppExpenseTracker Way to track expenses using whatsapp group One needs to c

Jan 4, 2022
This is a Golang wrapper for working with TMDb API. It aims to support version 3.
This is a Golang wrapper for working with TMDb API. It aims to support version 3.

This is a Golang wrapper for working with TMDb API. It aims to support version 3. An API Key is required. To register for one, head over to themoviedb

Dec 27, 2022
The client of NodeStatus / Golang Version

NodeStatus-client-go The client of NodeStatus written in Golang 使用说明 请直接下载release下的对应平台的二进制文件。 运行时需传入客户端对应参数。 假设你的服务端地址是https://tz.mydomain.com,客户端用户名

Dec 26, 2022
okex v5sdk for go version

okex v5sdk for go version

Jan 2, 2023
The task given by Appointy completed to develop APIs for a basic version of Instagram.

✨ Instagram APIs ✨ The task given by Appointy completed to develop APIs for a basic version of Instagram. Create an User Get User by Id Create a Post

Oct 9, 2021
The task is to develop a basic version of a Instagram.
The task is to develop a basic version of a Instagram.

Golang-api-task Developer: Mukka Deepak The task is to develop a basic version of aInstagram. You are only required to develop the API for the system.

Oct 23, 2021
A serverless teeny-tiny version of Diomedes which sends alerts to Telegram. Written in Go.
A serverless teeny-tiny version of Diomedes which sends alerts to Telegram. Written in Go.

diomedes-search Get a notification on Telegram whenever your movie opens bookings in a theater of your choice. Pre-requisites Install AWS CLI (v2) by

Oct 11, 2022
Sdk-go - Go version of the Synapse SDK

synapsesdk-go Synapse Protocol's Go SDK. Currently in super duper alpha, do not

Jan 7, 2022
Go-archvariant - Go package for determining the maximum compatibility version of the current system

go-archvariant Go package for determining the maximum compatibility version of t

Feb 19, 2022
🐥 Sturdy is an open-source, real-time, version control platform for startups
🐥 Sturdy is an open-source, real-time, version control platform for startups

Welcome to Sturdy! ?? ?? Real-time code collaboration. Sturdy is an open-source version control platform that allows you to interact with your code at

Dec 24, 2022
Simple-Weather-API - Simple weather api app created using golang and Open Weather API key
Simple-Weather-API - Simple weather api app created using golang and Open Weather API key

Simple Weather API Simple weather api app created using golang and Open Weather

Feb 6, 2022
An API client for the Notion API implemented in Golang

An API client for the Notion API implemented in Golang

Dec 30, 2022
A API scanner written in GOLANG to scan files recursively and look for API keys and IDs.

GO FIND APIS _____ ____ ______ _____ _ _ _____ _____ _____ _____ / ____|/ __ \ | ____|_ _| \ | | __ \ /\ | __ \_

Oct 25, 2021
Arweave-api - Arweave API implementation in golang

Arweave API Go implementation of the Arweave API Todo A list of endpoints that a

Jan 16, 2022
Reservationbox-api - Reservationbox Api with golang
Reservationbox-api - Reservationbox Api with golang

reservationbox-api How to set up application Cloning git on this link : https://

Jan 30, 2022