From f5cb0fff0c585ce97f4b8ed9bf0fc845202f6031 Mon Sep 17 00:00:00 2001 From: allburov Date: Sat, 25 Nov 2023 10:39:35 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20devlikea?= =?UTF-8?q?pro/whatsapp-http-api@2d64b26e868ab1c7773bbcda9f8a7fd225aaece1?= =?UTF-8?q?=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 404.html | 2 +- blog/index.html | 2 +- blog/say-hello-to-doks/index.html | 2 +- categories/index.html | 2 +- categories/news/index.html | 2 +- contributors/henk-verlinde/index.html | 2 +- contributors/index.html | 2 +- docs/examples/index.html | 2 +- docs/examples/python/index.html | 2 +- docs/how-to/chats/index.html | 2 +- docs/how-to/config/index.html | 25 +++++++++++++++---- docs/how-to/contacts/index.html | 2 +- docs/how-to/deploy/index.html | 2 +- docs/how-to/engines/index.html | 2 +- docs/how-to/groups/index.html | 2 +- docs/how-to/index.html | 2 +- docs/how-to/install/index.html | 2 +- docs/how-to/plus-version/index.html | 2 +- docs/how-to/polls/index.html | 2 +- docs/how-to/presence/index.html | 2 +- docs/how-to/receive-messages/index.html | 18 +++++++++---- docs/how-to/security/index.html | 2 +- docs/how-to/send-messages/index.html | 2 +- docs/how-to/sessions/index.html | 2 +- docs/how-to/webhooks/index.html | 2 +- docs/index.html | 2 +- docs/overview/changelog/index.html | 17 +++++++++++-- docs/overview/faq/index.html | 2 +- .../overview/how-to-avoid-blocking/index.html | 2 +- docs/overview/index.html | 2 +- docs/overview/index.xml | 2 +- docs/overview/introduction/index.html | 2 +- docs/overview/quick-start/index.html | 2 +- index.html | 2 +- ...522903ccba929feefd61ec991aa185c9919552d.js | 16 ++++++------ tags/index.html | 2 +- tags/performance/index.html | 2 +- tags/security/index.html | 2 +- tags/seo/index.html | 2 +- 39 files changed, 92 insertions(+), 54 deletions(-) rename index.min.5534c4c89b43183d4c15c157e63901b03403b7093be2a8802fe8d7a153d65a3bead4d36b063add6fd26e8dc5e281d5d25a299e20ea200ffc92d859f78a7f2bee.js => index.min.6973eb6663f037ad0358dce0335cd756c8c10f50c7f73face3d4bea74431f1d7c01f53e7173d76f26e0c5509e522903ccba929feefd61ec991aa185c9919552d.js (98%) diff --git a/404.html b/404.html index af6f8fd3..535e260b 100644 --- a/404.html +++ b/404.html @@ -7,4 +7,4 @@

Page not found :(

The page you are looking for doesn't exist or has been moved.

- \ No newline at end of file + \ No newline at end of file diff --git a/blog/index.html b/blog/index.html index 858404b7..7c9c1e74 100644 --- a/blog/index.html +++ b/blog/index.html @@ -7,4 +7,4 @@

Blog

Say hello to Doks 👋

Say hello to Doks 👋

Introducing Doks, a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default.

Posted in News on November 4, 2020 by Henk Verlinde ‐ 1 min read

- \ No newline at end of file + \ No newline at end of file diff --git a/blog/say-hello-to-doks/index.html b/blog/say-hello-to-doks/index.html index 83175afb..35fe3152 100644 --- a/blog/say-hello-to-doks/index.html +++ b/blog/say-hello-to-doks/index.html @@ -9,4 +9,4 @@ SEO - \ No newline at end of file + \ No newline at end of file diff --git a/categories/index.html b/categories/index.html index bde43f02..0978b234 100644 --- a/categories/index.html +++ b/categories/index.html @@ -7,4 +7,4 @@

Categories

- \ No newline at end of file + \ No newline at end of file diff --git a/categories/news/index.html b/categories/news/index.html index 3bcffe22..dbd931c5 100644 --- a/categories/news/index.html +++ b/categories/news/index.html @@ -7,4 +7,4 @@

News

Say hello to Doks 👋

Say hello to Doks 👋

Introducing Doks, a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default.

Posted in News on November 4, 2020 by Henk Verlinde ‐ 1 min read

- \ No newline at end of file + \ No newline at end of file diff --git a/contributors/henk-verlinde/index.html b/contributors/henk-verlinde/index.html index d7d85e84..0fa46e9f 100644 --- a/contributors/henk-verlinde/index.html +++ b/contributors/henk-verlinde/index.html @@ -7,4 +7,4 @@

Henk Verlinde

Creator of Hyas.

@HenkVerlinde

Say hello to Doks 👋

Say hello to Doks 👋

Introducing Doks, a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default.

Posted in News on November 4, 2020 by Henk Verlinde ‐ 1 min read

- \ No newline at end of file + \ No newline at end of file diff --git a/contributors/index.html b/contributors/index.html index 2aa0f046..9176444f 100644 --- a/contributors/index.html +++ b/contributors/index.html @@ -7,4 +7,4 @@

Contributors

The Doks contributors.

- \ No newline at end of file + \ No newline at end of file diff --git a/docs/examples/index.html b/docs/examples/index.html index b9ed90a2..5da3a3e0 100644 --- a/docs/examples/index.html +++ b/docs/examples/index.html @@ -13,4 +13,4 @@ Examples
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/examples/python/index.html b/docs/examples/python/index.html index 793ddd03..d5e4ce98 100644 --- a/docs/examples/python/index.html +++ b/docs/examples/python/index.html @@ -16,4 +16,4 @@ Examples

Python

WhatsApp HTTP API Python examples.

We’ve created a few examples on how to interact with WAHA WhatsApp HTTP API with Python.

You can find the examples in examples folder on GitHub with detailed instructions in README.md

- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/chats/index.html b/docs/how-to/chats/index.html index 82839cc4..984b53fc 100644 --- a/docs/how-to/chats/index.html +++ b/docs/how-to/chats/index.html @@ -21,4 +21,4 @@ GET /api/{session}/chats

Get messages from chat

Get 100 messages from the chat

GET /api/{session}/chats/{chatId}/messages?limit=100

Get 100 messages from the chat, skip downloading media (images, files)

GET /api/{session}/chats/{chatId}/messages?limit=100&downloadMedia=false

Delete chat

Use the method to delete chat

DELETE /api/{session}/chats/{chatId}

Clear messages

Use the method to clear all messages from the chat

DELETE /api/{session}/chats/{chatId}/messages

← Polls
FAQ →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/config/index.html b/docs/how-to/config/index.html index 0f57d684..04695eef 100644 --- a/docs/how-to/config/index.html +++ b/docs/how-to/config/index.html @@ -32,11 +32,25 @@ This is a way to select a proxy from while you start session.

Session proxy configuration

You can configure proxy when you start session by setting config.proxy fields. Read more about it on Session page ->.

Keep in mind that session’s proxy configuration takes precedence over proxy configuration set by environment variables!

Security

Files

The following environment variables can be used to configure the file storage options for the WAHA:

Files

The following environment variables can be used to configure the file storage options for the WAHA:

Examples

Debug Mode

To enable debug mode, set the DEBUG environment variable to any value:

DEBUG=1
+will be stored. The default value is /tmp/whatsapp-files.

💡 Even if WAHA doesn’t process the message media because of WHATSAPP_FILES_MIMETYPES or WHATSAPP_DOWNLOAD_MEDIA +you’ll get a webhook event with hasMedia: True field, but with no media.url.

{
+  "event": "message",
+  "session": "default",
+  "payload": {
+    "hasMedia": true,
+    "media": {
+      "url": null,
+      "mimetype": "video/mp4",
+      "filename": null
+    }
+  }
+}
+

Examples

Debug Mode

To enable debug mode, set the DEBUG environment variable to any value:

DEBUG=1
 

Protecting the API with a Secret Code

To protect the API with a secret code, set the WHATSAPP_API_KEY environment variable to your secret code:

WHATSAPP_API_KEY=mysecret
 

You must include the X-Api-Key: mysecret header in all requests to the API.

Starting Sessions Automatically

To start sessions automatically when the API is launched, set the WHATSAPP_START_SESSION environment variable to a comma-separated list of session names:

WHATSAPP_START_SESSION=session1,session2
@@ -47,6 +61,7 @@
 WHATSAPP_SWAGGER_PASSWORD=admin
 

Downloading Specific Mimetypes

To download only specific mimetypes from messages, set the WHATSAPP_FILES_MIMETYPES environment variable to a comma-separated list of mimetypes:

WHATSAPP_FILES_MIMETYPES=audio,image/png,image/gif
+

Disable Downloading Media Files

To disable downloading media files, set the WHATSAPP_DOWNLOAD_MEDIA environment variable to false:

WHATSAPP_DOWNLOAD_MEDIA=false
 

Setting the File Lifetime

To set the time (in seconds) after which files will be removed to free up space, set the WHATSAPP_FILES_LIFETIME environment variable:

WHATSAPP_FILES_LIFETIME=300
 

Setting the File Storage Folder

To set the folder where files from chats (images, voice messages) will be stored, set the WHATSAPP_FILES_FOLDER @@ -54,4 +69,4 @@

← Security
Engines →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/contacts/index.html b/docs/how-to/contacts/index.html index c0705239..86d219f4 100644 --- a/docs/how-to/contacts/index.html +++ b/docs/how-to/contacts/index.html @@ -60,4 +60,4 @@
← FAQ
Groups →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/deploy/index.html b/docs/how-to/deploy/index.html index 7356d39f..3e9bd76b 100644 --- a/docs/how-to/deploy/index.html +++ b/docs/how-to/deploy/index.html @@ -37,4 +37,4 @@ By default, the whatsapp-http-api service will be used.

To use the whatsapp-http-api-plus service, you need to specify it in the command.

← Presence
WAHA Plus →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/engines/index.html b/docs/how-to/engines/index.html index 69ac8470..5de10292 100644 --- a/docs/how-to/engines/index.html +++ b/docs/how-to/engines/index.html @@ -31,4 +31,4 @@ please create an issue

WEBJSNOWEBVENOM
Session
POST /api/sessions/start✔️✔️✔️
POST /api/sessions/stop✔️✔️✔️
POST /api/sessions/logout✔️✔️✔️
GET /api/sessions/✔️✔️✔️
GET /api/sessions/{session}/me✔️✔️
Authentication
POST /api/{session}/auth/qr✔️✔️
POST /api/{session}/auth/request-code✔️
POST /api/{session}/auth/authorize-code✔️
Screenshot
POST /api/screenshot✔️✔️
ChattingWEBJSNOWEBVENOM
GET /api/checkNumberStatus✔️✔️✔️
GET /api/sendContactVcard✔️
GET /api/sendText✔️✔️✔️
POST /api/sendText✔️✔️✔️
POST /api/sendPoll✔️
POST /api/sendLocation✔️✔️✔️
POST /api/sendLinkPreview✔️✔️
POST /api/sendImage ✔️✔️✔️
POST /api/sendFile ✔️✔️✔️
POST /api/sendVoice ✔️✔️✔️
POST /api/sendVideo ✔️✔️
POST /api/reply✔️✔️✔️
POST /api/sendSeen✔️✔️✔️
POST /api/startTyping✔️✔️✔️
POST /api/stopTyping✔️✔️
POST /api/reaction✔️✔️
GET /api/messages✔️✔️
WEBJSNOWEBVENOM
Status
POST /api/{session}/status/text✔️
POST /api/{session}/status/image ✔️
POST /api/{session}/status/voice ✔️
POST /api/{session}/status/video ✔️
Chats
GET /api/{session}/chats✔️
DELETE /api/{session}/chats/{chatId}✔️
GET /api/{session}/chats/{chatId}/messages✔️✔️
DELETE /api/{session}/chats/{chatId}/messages✔️
Contacts
GET /api/contacts✔️
GET /api/contacts/all✔️
GET /api/contacts/check-exists✔️✔️✔️
GET /api/contacts/about✔️
GET /api/contacts/profile-picture✔️
POST /api/contacts/block✔️
POST /api/contacts/unblock✔️
GroupsWEBJSNOWEBVENOM
POST /api/{session}/groups✔️✔️
GET /api/{session}/groups✔️✔️
GET /api/{session}/groups/{id}✔️✔️
DELETE /api/{session}/groups/{id}✔️
GET /api/{session}/groups/{id}/settings/security/info-admin-only✔️
PUT /api/{session}/groups/{id}/settings/security/info-admin-only✔️
POST /api/{session}/groups/{id}/leave✔️✔️
PUT /api/{session}/groups/{id}/description✔️✔️
PUT /api/{session}/groups/{id}/subject✔️✔️
GET /api/{session}/groups/{id}/invite-code✔️✔️
POST /api/{session}/groups/{id}/invite-code/revoke✔️✔️
GET /api/{session}/groups/{id}/participants✔️✔️
POST /api/{session}/groups/{id}/participants/add✔️✔️
POST /api/{session}/groups/{id}/participants/remove✔️✔️
POST /api/{session}/groups/{id}/admin/promote✔️✔️
POST /api/{session}/groups/{id}/admin/demote✔️✔️
WEBJSNOWEBVENOM
Presence
POST /api/{session}/presence✔️
GET /api/{session}/presence✔️
GET /api/{session}/presence/{chatId}✔️
POST /api/{session}/presence/{chatId}/subscribe✔️
Other
POST /api/version✔️
WebhooksWEBJSNOWEBVENOM
message✔️✔️✔️
message with files ✔️✔️✔️
message.any✔️✔️✔️
message.ack✔️✔️✔️
message.revoked✔️
state.change✔️✔️✔️
group.join✔️✔️✔️
group.leave✔️
presence.update✔️
poll.vote✔️
poll.vote.failed✔️
← Configuration
Presence →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/groups/index.html b/docs/how-to/groups/index.html index b436e474..ae490fab 100644 --- a/docs/how-to/groups/index.html +++ b/docs/how-to/groups/index.html @@ -86,4 +86,4 @@
← Contacts
Changelog →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/index.html b/docs/how-to/index.html index b841665b..d744f071 100644 --- a/docs/how-to/index.html +++ b/docs/how-to/index.html @@ -13,4 +13,4 @@ Examples
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/install/index.html b/docs/how-to/install/index.html index 39438526..659aa54e 100644 --- a/docs/how-to/install/index.html +++ b/docs/how-to/install/index.html @@ -54,4 +54,4 @@
← Introduction
Quick Start →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/plus-version/index.html b/docs/how-to/plus-version/index.html index 2fcc4b8b..15a9b12c 100644 --- a/docs/how-to/plus-version/index.html +++ b/docs/how-to/plus-version/index.html @@ -31,4 +31,4 @@

Then in all commands use Plus image devlikeapro/whatsapp-http-api-plus instead of Core devlikeapro/whatsapp-http-api.

← Deploy
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/polls/index.html b/docs/how-to/polls/index.html index 9e868d43..83147c6c 100644 --- a/docs/how-to/polls/index.html +++ b/docs/how-to/polls/index.html @@ -122,4 +122,4 @@ prepared for such cases!

← Sessions
Chats →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/presence/index.html b/docs/how-to/presence/index.html index e822388f..9f2f1611 100644 --- a/docs/how-to/presence/index.html +++ b/docs/how-to/presence/index.html @@ -95,4 +95,4 @@
← Engines
Deploy →
- \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/receive-messages/index.html b/docs/how-to/receive-messages/index.html index 7f1aec2a..1ceae4ea 100644 --- a/docs/how-to/receive-messages/index.html +++ b/docs/how-to/receive-messages/index.html @@ -114,14 +114,19 @@ } }

Files

When people send you media - images, voice messages, and documents - WAHA saves it in the file storage. -In your application you must download it and use it as you want to. You can find the URL in mediaUrl field.

For example, you can get the webhook like this with mediaUrl value (we’ve skipped other fields):

{
+In your application you must download it and use it as you want to. You can find the URL in media.url field.

For example, you can get the webhook like this with media value (we’ve skipped other fields):

{
   "event": "message",
   "session": "default",
   "payload": {
     "id": "true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
     "timestamp": 1667561485,
     "from": "11111111111@c.us",
-    "mediaUrl": "http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.jpg"
+    "hasMedia": true,
+    "media": {
+      "url": "http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.jpg",
+      "mimetype": "image/jpeg",
+      "filename": null
+    }
   }
 }
 

Then you can use the link to download the file http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.jpg.

For documents (file attachments) there’s also filename field with the original file name.

{
@@ -131,8 +136,11 @@
     "id": "true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
     "timestamp": 1667561485,
     "from": "11111111111@c.us",
-    "mediaUrl": "http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.pdf",
-    "filename": "some-file.pdf"
+    "media": {
+      "url": "http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.pdf",
+      "filename": "some-file.pdf",
+      "mimetype": "application/pdf"
+    }
   }
 }
 

To configure the url you can use environment variables WHATSAPP_API_HOSTNAME and WHATSAPP_API_PORT.

By default, WAHA download all files that the account receive. @@ -146,4 +154,4 @@ GitHub, in examples folder ->.

  • This project is not affiliated, associated, authorized, endorsed by, or in any way officially connected with WhatsApp or any of its subsidiaries or its affiliates.
    The official WhatsApp website can be found at https://whatsapp.com/.
    "WhatsApp" as well as related names, marks, emblems and images are registered trademarks of their respective owners.
    - \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/security/index.html b/docs/how-to/security/index.html index 82bf273e..c0f7ef2a 100644 --- a/docs/how-to/security/index.html +++ b/docs/how-to/security/index.html @@ -33,4 +33,4 @@ Read more about it on Webhooks page ->

    • This project is not affiliated, associated, authorized, endorsed by, or in any way officially connected with WhatsApp or any of its subsidiaries or its affiliates.
      The official WhatsApp website can be found at https://whatsapp.com/.
      "WhatsApp" as well as related names, marks, emblems and images are registered trademarks of their respective owners.
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/send-messages/index.html b/docs/how-to/send-messages/index.html index bcd7ca82..8abc061e 100644 --- a/docs/how-to/send-messages/index.html +++ b/docs/how-to/send-messages/index.html @@ -173,4 +173,4 @@
      ← Quick Start
      How to Avoid Blocking →
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/sessions/index.html b/docs/how-to/sessions/index.html index b0d830a9..f4a95202 100644 --- a/docs/how-to/sessions/index.html +++ b/docs/how-to/sessions/index.html @@ -119,4 +119,4 @@ Plus version supports multiple sessions in one container.

      ← Webhooks
      Polls →
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/how-to/webhooks/index.html b/docs/how-to/webhooks/index.html index 3fa76601..37e793ac 100644 --- a/docs/how-to/webhooks/index.html +++ b/docs/how-to/webhooks/index.html @@ -341,4 +341,4 @@ GitHub, in examples folder ->.

      ← Receive messages
      Sessions →
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/index.html b/docs/index.html index 8815318e..be7ff5ee 100644 --- a/docs/index.html +++ b/docs/index.html @@ -13,4 +13,4 @@ Examples
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/overview/changelog/index.html b/docs/overview/changelog/index.html index b617a640..1ded00b8 100644 --- a/docs/overview/changelog/index.html +++ b/docs/overview/changelog/index.html @@ -17,7 +17,20 @@ On this page ExpandCollapse

      Changelog

      You can find here the list of changes made to WAHA.

      If you wish to get and read Release Notes - read them on one of our platforms, these posts are FREE.

      You even can subscribe to get new updates there!

      2023.11

      November 2023

      2023.10

      October 2023

      2023.9

      September 2023

      2023.8

      August 2023

      2023.7

      July 2023

      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/overview/faq/index.html b/docs/overview/faq/index.html index ba60dab1..f71eef23 100644 --- a/docs/overview/faq/index.html +++ b/docs/overview/faq/index.html @@ -22,4 +22,4 @@ communicate with it to prevent blocking from WhatsApp. It’s the reason why it’s so demanding on resources.

      If you’re looking for less resource demanded engine - have a look at NOWEB engine ->

      ← Chats
      Contacts →
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/overview/how-to-avoid-blocking/index.html b/docs/overview/how-to-avoid-blocking/index.html index 1f867607..35398520 100644 --- a/docs/overview/how-to-avoid-blocking/index.html +++ b/docs/overview/how-to-avoid-blocking/index.html @@ -31,4 +31,4 @@ guidelines and reduces the risk of being blocked.

      ← Send messages
      Receive messages →
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/overview/index.html b/docs/overview/index.html index 808120b1..6018272a 100644 --- a/docs/overview/index.html +++ b/docs/overview/index.html @@ -13,4 +13,4 @@ Examples
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/overview/index.xml b/docs/overview/index.xml index eed27c40..f1bd87c0 100644 --- a/docs/overview/index.xml +++ b/docs/overview/index.xml @@ -19,4 +19,4 @@ Accounts (sessions) in the container CPU Memory 1 30% 400MB 10 270% 1.5GB The na Boosty -> Patreon -> You even can subscribe to get new updates there! 2023.11 # November 2023 -Add filename field for document (file attachments) - the original filename of the document. Add /api/sendVideo endpoint to NOWEB and WEBJS engines. Available only in Plus version. Add security settings for edit group info GET /api/{session}/groups/{groupId}/settings/security/info-admin-only - updates the group settings to only allow admins to edit group info (title, description, photo). \ No newline at end of file +Add dedicated media field in webhook payload - now you can know which media is attached to the message. { "event": "message", "session": "default", "payload": { "hasMedia": true, "media": { "url": "http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.pdf", "mimetype": "application/pdf", "filename": "file. \ No newline at end of file diff --git a/docs/overview/introduction/index.html b/docs/overview/introduction/index.html index 2c239fc6..fc99fec0 100644 --- a/docs/overview/introduction/index.html +++ b/docs/overview/introduction/index.html @@ -21,4 +21,4 @@ Quick Start →.

      Features

      WAHA is distributed in two versions:

      See the list of engines that support the features ->.

      Here’s the available features:

      Messages

      Groups

      Contacts

      Sessions

      Security

      Updates

      Install →
      - \ No newline at end of file + \ No newline at end of file diff --git a/docs/overview/quick-start/index.html b/docs/overview/quick-start/index.html index 9666eec5..81c8b13a 100644 --- a/docs/overview/quick-start/index.html +++ b/docs/overview/quick-start/index.html @@ -60,4 +60,4 @@

      What is next?

      ← Install
      Send messages →
      - \ No newline at end of file + \ No newline at end of file diff --git a/index.html b/index.html index bef0d19e..3513ca35 100644 --- a/index.html +++ b/index.html @@ -9,4 +9,4 @@ totally safe.

      - \ No newline at end of file + \ No newline at end of file diff --git a/index.min.5534c4c89b43183d4c15c157e63901b03403b7093be2a8802fe8d7a153d65a3bead4d36b063add6fd26e8dc5e281d5d25a299e20ea200ffc92d859f78a7f2bee.js b/index.min.6973eb6663f037ad0358dce0335cd756c8c10f50c7f73face3d4bea74431f1d7c01f53e7173d76f26e0c5509e522903ccba929feefd61ec991aa185c9919552d.js similarity index 98% rename from index.min.5534c4c89b43183d4c15c157e63901b03403b7093be2a8802fe8d7a153d65a3bead4d36b063add6fd26e8dc5e281d5d25a299e20ea200ffc92d859f78a7f2bee.js rename to index.min.6973eb6663f037ad0358dce0335cd756c8c10f50c7f73face3d4bea74431f1d7c01f53e7173d76f26e0c5509e522903ccba929feefd61ec991aa185c9919552d.js index c5e126c1..361932b4 100644 --- a/index.min.5534c4c89b43183d4c15c157e63901b03403b7093be2a8802fe8d7a153d65a3bead4d36b063add6fd26e8dc5e281d5d25a299e20ea200ffc92d859f78a7f2bee.js +++ b/index.min.6973eb6663f037ad0358dce0335cd756c8c10f50c7f73face3d4bea74431f1d7c01f53e7173d76f26e0c5509e522903ccba929feefd61ec991aa185c9919552d.js @@ -105,11 +105,11 @@ message # Incoming message (text/audio/files) { \u0026quot;event\u0026quot;: \u0026quot;message.any\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: {} } message.ack # Receive events when server or recipient gets the message, read or played it. See details on Webhooks page -\u0026gt;. { \u0026quot;event\u0026quot;: \u0026quot;message.ack\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: {} } message.revoked # See details on Webhooks page -\u0026gt;. -{ \u0026quot;event\u0026quot;: \u0026quot;message.ack\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;before\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;some-id-here\u0026quot;, \u0026quot;timestamp\u0026quot;: \u0026quot;some-timestamp-here\u0026quot;, \u0026quot;body\u0026quot;: \u0026quot;Hi there!\u0026quot; }, \u0026quot;after\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;some-id-here\u0026quot;, \u0026quot;timestamp\u0026quot;: \u0026quot;some-timestamp-here\u0026quot;, \u0026quot;body\u0026quot;: \u0026quot;\u0026quot; } } } Files # When people send you media - images, voice messages, and documents - WAHA saves it in the file storage. In your application you must download it and use it as you want to. You can find the URL in mediaUrl field. -For example, you can get the webhook like this with mediaUrl value (we\u0026rsquo;ve skipped other fields): -{ \u0026quot;event\u0026quot;: \u0026quot;message\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\u0026quot;, \u0026quot;timestamp\u0026quot;: 1667561485, \u0026quot;from\u0026quot;: \u0026quot;11111111111@c.us\u0026quot;, \u0026quot;mediaUrl\u0026quot;: \u0026quot;http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.jpg\u0026quot; } } Then you can use the link to download the file http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.jpg. +{ \u0026quot;event\u0026quot;: \u0026quot;message.ack\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;before\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;some-id-here\u0026quot;, \u0026quot;timestamp\u0026quot;: \u0026quot;some-timestamp-here\u0026quot;, \u0026quot;body\u0026quot;: \u0026quot;Hi there!\u0026quot; }, \u0026quot;after\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;some-id-here\u0026quot;, \u0026quot;timestamp\u0026quot;: \u0026quot;some-timestamp-here\u0026quot;, \u0026quot;body\u0026quot;: \u0026quot;\u0026quot; } } } Files # When people send you media - images, voice messages, and documents - WAHA saves it in the file storage. In your application you must download it and use it as you want to. You can find the URL in media.url field. +For example, you can get the webhook like this with media value (we\u0026rsquo;ve skipped other fields): +{ \u0026quot;event\u0026quot;: \u0026quot;message\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\u0026quot;, \u0026quot;timestamp\u0026quot;: 1667561485, \u0026quot;from\u0026quot;: \u0026quot;11111111111@c.us\u0026quot;, \u0026quot;hasMedia\u0026quot;: true, \u0026quot;media\u0026quot;: { \u0026quot;url\u0026quot;: \u0026quot;http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.jpg\u0026quot;, \u0026quot;mimetype\u0026quot;: \u0026quot;image/jpeg\u0026quot;, \u0026quot;filename\u0026quot;: null } } } Then you can use the link to download the file http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.jpg. For documents (file attachments) there\u0026rsquo;s also filename field with the original file name. -{ \u0026quot;event\u0026quot;: \u0026quot;message\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\u0026quot;, \u0026quot;timestamp\u0026quot;: 1667561485, \u0026quot;from\u0026quot;: \u0026quot;11111111111@c.us\u0026quot;, \u0026quot;mediaUrl\u0026quot;: \u0026quot;http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.pdf\u0026quot;, \u0026quot;filename\u0026quot;: \u0026quot;some-file.pdf\u0026quot; } } To configure the url you can use environment variables WHATSAPP_API_HOSTNAME and WHATSAPP_API_PORT. +{ \u0026quot;event\u0026quot;: \u0026quot;message\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;id\u0026quot;: \u0026quot;true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\u0026quot;, \u0026quot;timestamp\u0026quot;: 1667561485, \u0026quot;from\u0026quot;: \u0026quot;11111111111@c.us\u0026quot;, \u0026quot;media\u0026quot;: { \u0026quot;url\u0026quot;: \u0026quot;http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.pdf\u0026quot;, \u0026quot;filename\u0026quot;: \u0026quot;some-file.pdf\u0026quot;, \u0026quot;mimetype\u0026quot;: \u0026quot;application/pdf\u0026quot; } } } To configure the url you can use environment variables WHATSAPP_API_HOSTNAME and WHATSAPP_API_PORT. By default, WAHA download all files that the account receive. If you want to limit files lifetime, specify file types for download or change directory for files - read more about file storage configuration and variables -\u0026gt;. Endpoints # See the list of engines that support the feature -\u0026gt;. Get messages # Read messages from the history - use GET /api/messages endpoint. @@ -263,7 +263,7 @@ Webhooks # See the list of engines that support the feature -\u0026gt;. group.join # { \u0026quot;event\u0026quot;: \u0026quot;group.join\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;engine\u0026quot;: \u0026quot;WEBJS\u0026quot;, \u0026quot;payload\u0026quot;: { ... } } group.leave # { \u0026quot;event\u0026quot;: \u0026quot;group.left\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;engine\u0026quot;: \u0026quot;WEBJS\u0026quot;, \u0026quot;payload\u0026quot;: { ... } } `}),e.add({id:14,href:"/docs/overview/changelog/",title:"Changelog",description:"WAHA's changelog",content:`If you wish to get and read Release Notes - read them on one of our platforms, these posts are FREE. Boosty -\u0026gt; Patreon -\u0026gt; You even can subscribe to get new updates there! 2023.11 # November 2023 -Add filename field for document (file attachments) - the original filename of the document. Add /api/sendVideo endpoint to NOWEB and WEBJS engines. Available only in Plus version. Add security settings for edit group info GET /api/{session}/groups/{groupId}/settings/security/info-admin-only - updates the group settings to only allow admins to edit group info (title, description, photo). 2023.10 # October 2023 +Add dedicated media field in webhook payload - now you can know which media is attached to the message. { \u0026quot;event\u0026quot;: \u0026quot;message\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;hasMedia\u0026quot;: true, \u0026quot;media\u0026quot;: { \u0026quot;url\u0026quot;: \u0026quot;http://localhost:3000/api/files/true_11111111111@c.us_AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA.pdf\u0026quot;, \u0026quot;mimetype\u0026quot;: \u0026quot;application/pdf\u0026quot;, \u0026quot;filename\u0026quot;: \u0026quot;file.pdf\u0026quot; } } } Add WHATSAPP_DOWNLOAD_MEDIA environment variable to control media download. Available only in Plus version. WHATSAPP_DOWNLOAD_MEDIA=True - download media WHATSAPP_DOWNLOAD_MEDIA=False - do not download media at all. Add filename field for document (file attachments) - the original filename of the document. Add /api/sendVideo endpoint to NOWEB and WEBJS engines. Available only in Plus version. Add security settings for edit group info GET /api/{session}/groups/{groupId}/settings/security/info-admin-only - updates the group settings to only allow admins to edit group info (title, description, photo). 2023.10 # October 2023 Add session.status event for all engines! Now you can get the latest session\u0026rsquo;s status immediately after it changes. Add message.revoked event in WEBJS engine Add me field in webhook payload - now you can know which number is associated with the session Add enviroment field in webhook payload - now you can know which environment is used for the session 2023.9 # September 2023 Add GET /api/sessions/{session/me endpoint so you can get the phone number associated with the session Add polls support in NOWEB engine Add dedicated Get QR endpoint! Support pairing method (NOWEB) - you can connect with a code instead of QR. Add string field ackName: DEVICE|READ|... in message.ack payload Support message.ack event webhook in NOWEB engine 2023.8 # August 2023 Added stories (aka status) endpoints to NOWEB engine! POST /api/{session}/status/text|image|voice|video - choose one that suites your! Added chats endpoints Get all chats - GET /api/{session/chats Delete chat - DELETE /api/{session/chats/{chatId} Get messages from chat - GET /api/{session/chats/{chatId}/messages?limit=1000?downloadMedia=true Clear messages in the chat DELETE /api/{session/chats/{chatId}/messages Added downloadMedia flag to speed up GET /api/messages and GET /api/{session/chats/{chatId}/messages performance. Added set presence endpoint! With online presence you can show your status as online #121 With offline presence you can get notifications for your device #28 Added security settings for edit group info PUT /api/{session}/groups/{groupId}/settings/security/info-admin-only - updates the group settings to only allow admins to edit group info (title, description, photo). 2023.7 # July 2023 @@ -298,14 +298,16 @@ Common # DEBUG=1: Set this variable to any value to enable debug and verbose log WHATSAPP_PROXY_SERVER=localhost:3128: Use this variable to set the proxy server in the format host:port, without http or https. WHATSAPP_PROXY_SERVER_USERNAME=username and WHATSAPP_PROXY_SERVER_PASSWORD=password: Use these variables to set up credentials for the proxy. WHATSAPP_PROXY_SERVER_LIST=host1.example.com:3138,host2.example.com:3138: Use this variable to set a comma-separated list of addresses to use, using a round-robin algorithm to choose the server for the session. WHATSAPP_PROXY_SERVER_INDEX_PREFIX=proxy-: Use this variable to parse the session name for the prefix and find the appropriate session. For example, if you have set WHATSAPP_PROXY_SERVER_LIST=host-first:80,host-second:80,host-third:80 and WHATSAPP_PROXY_SERVER_INDEX_PREFIX=proxy- and you run proxy-3 session, the host-third:80 proxy will be chosen for that session. This is a way to select a proxy from while you start session. Session proxy configuration # You can configure proxy when you start session by setting config.proxy fields. Read more about it on Session page -\u0026gt;. Keep in mind that session\u0026rsquo;s proxy configuration takes precedence over proxy configuration set by environment variables! Security # WHATSAPP_API_KEY=mysecret: If you set this variable, you must include the X-Api-Key: mysecret header in all requests to the API. This will protect the API with a secret code. WHATSAPP_SWAGGER_USERNAME=admin and WHATSAPP_SWAGGER_PASSWORD=admin: These variables can be used to protect the Swagger panel with admin / admin credentials. This does not affect API access. Files # The following environment variables can be used to configure the file storage options for the WAHA: -WHATSAPP_FILES_MIMETYPES: This variable can be used to download only specific mimetypes from messages. By default, all files are downloaded. The mimetypes must be separated by a comma, without spaces. For example: audio,image/png,image/gif. To choose a specific type, use a prefix (like audio,image). WHATSAPP_FILES_LIFETIME: This variable can be used to set the time (in seconds) after which files will be removed to free up space. The default value is 180. WHATSAPP_FILES_FOLDER: This variable can be used to set the folder where files from chats (images, voice messages) will be stored. The default value is /tmp/whatsapp-files. Examples # Debug Mode # To enable debug mode, set the DEBUG environment variable to any value: +WHATSAPP_FILES_MIMETYPES: This variable can be used to download only specific mimetypes from messages. By default, all files are downloaded. The mimetypes must be separated by a comma, without spaces. For example: audio,image/png,image/gif. To choose a specific type, use a prefix (like audio,image). See usage below. WHATSAPP_DOWNLOAD_MEDIA=true - this variable can be used to completely disable downloading media files. By default, all files are downloaded. Set this variable to WHATSAPP_DOWNLOAD_MEDIA=false to disable downloading media files. Under the hood, it sets WHATSAPP_FILES_MIMETYPES=mimetype/ignore-all-media to ignore all media files. WHATSAPP_FILES_LIFETIME: This variable can be used to set the time (in seconds) after which files will be removed to free up space. The default value is 180. WHATSAPP_FILES_FOLDER: This variable can be used to set the folder where files from chats (images, voice messages) will be stored. The default value is /tmp/whatsapp-files. 💡 Even if WAHA doesn\u0026rsquo;t process the message media because of WHATSAPP_FILES_MIMETYPES or WHATSAPP_DOWNLOAD_MEDIA you\u0026rsquo;ll get a webhook event with hasMedia: True field, but with no media.url. +{ \u0026quot;event\u0026quot;: \u0026quot;message\u0026quot;, \u0026quot;session\u0026quot;: \u0026quot;default\u0026quot;, \u0026quot;payload\u0026quot;: { \u0026quot;hasMedia\u0026quot;: true, \u0026quot;media\u0026quot;: { \u0026quot;url\u0026quot;: null, \u0026quot;mimetype\u0026quot;: \u0026quot;video/mp4\u0026quot;, \u0026quot;filename\u0026quot;: null } } } Examples # Debug Mode # To enable debug mode, set the DEBUG environment variable to any value: DEBUG=1 Protecting the API with a Secret Code # To protect the API with a secret code, set the WHATSAPP_API_KEY environment variable to your secret code: WHATSAPP_API_KEY=mysecret You must include the X-Api-Key: mysecret header in all requests to the API. Starting Sessions Automatically # To start sessions automatically when the API is launched, set the WHATSAPP_START_SESSION environment variable to a comma-separated list of session names: WHATSAPP_START_SESSION=session1,session2 Restarting All Sessions # To start all STOPPED sessions after container restarts, set the WHATSAPP_RESTART_ALL_SESSIONS environment variable to True: WHATSAPP_RESTART_ALL_SESSIONS=True Protecting the Swagger Panel # To protect the Swagger panel with admin / admin credentials, set the WHATSAPP_SWAGGER_USERNAME and WHATSAPP_SWAGGER_PASSWORD environment variables: WHATSAPP_SWAGGER_USERNAME=admin WHATSAPP_SWAGGER_PASSWORD=admin Downloading Specific Mimetypes # To download only specific mimetypes from messages, set the WHATSAPP_FILES_MIMETYPES environment variable to a comma-separated list of mimetypes: -WHATSAPP_FILES_MIMETYPES=audio,image/png,image/gif Setting the File Lifetime # To set the time (in seconds) after which files will be removed to free up space, set the WHATSAPP_FILES_LIFETIME environment variable: +WHATSAPP_FILES_MIMETYPES=audio,image/png,image/gif Disable Downloading Media Files # To disable downloading media files, set the WHATSAPP_DOWNLOAD_MEDIA environment variable to false: +WHATSAPP_DOWNLOAD_MEDIA=false Setting the File Lifetime # To set the time (in seconds) after which files will be removed to free up space, set the WHATSAPP_FILES_LIFETIME environment variable: WHATSAPP_FILES_LIFETIME=300 Setting the File Storage Folder # To set the folder where files from chats (images, voice messages) will be stored, set the WHATSAPP_FILES_FOLDER environment variable: WHATSAPP_FILES_FOLDER=/home/user/whatsapp-files `}),e.add({id:19,href:"/docs/how-to/engines/",title:"Engines",description:"Engines",content:`Engines # Under the hood WAHA allows you to use different engines. You can control what you want to run by settings WHATSAPP_DEFAULT_ENGINE environment variables. docker run -it -e \u0026quot;WHATSAPP_DEFAULT_ENGINE=WEBJS\u0026quot; devlikeapro/whatsapp-http-api If you have any problems with one engine - try another! diff --git a/tags/index.html b/tags/index.html index 98a01a68..37208297 100644 --- a/tags/index.html +++ b/tags/index.html @@ -7,4 +7,4 @@
      - \ No newline at end of file + \ No newline at end of file diff --git a/tags/performance/index.html b/tags/performance/index.html index f7547313..ac70f851 100644 --- a/tags/performance/index.html +++ b/tags/performance/index.html @@ -7,4 +7,4 @@

      performance

      Say hello to Doks 👋

      Say hello to Doks 👋

      Introducing Doks, a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default.

      Posted in News on November 4, 2020 by Henk Verlinde ‐ 1 min read

      - \ No newline at end of file + \ No newline at end of file diff --git a/tags/security/index.html b/tags/security/index.html index c079c0ab..ceba9cb1 100644 --- a/tags/security/index.html +++ b/tags/security/index.html @@ -7,4 +7,4 @@

      security

      Say hello to Doks 👋

      Say hello to Doks 👋

      Introducing Doks, a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default.

      Posted in News on November 4, 2020 by Henk Verlinde ‐ 1 min read

      - \ No newline at end of file + \ No newline at end of file diff --git a/tags/seo/index.html b/tags/seo/index.html index e73d7416..3c35ea4e 100644 --- a/tags/seo/index.html +++ b/tags/seo/index.html @@ -7,4 +7,4 @@

      SEO

      Say hello to Doks 👋

      Say hello to Doks 👋

      Introducing Doks, a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default.

      Posted in News on November 4, 2020 by Henk Verlinde ‐ 1 min read

      - \ No newline at end of file + \ No newline at end of file