@automagik/omni 2.260406.1 → 2.260407.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1 -1
- package/dist/server/index.js +14 -13
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -76887,7 +76887,7 @@ import { fileURLToPath } from "url";
|
|
|
76887
76887
|
// package.json
|
|
76888
76888
|
var package_default = {
|
|
76889
76889
|
name: "@automagik/omni",
|
|
76890
|
-
version: "2.
|
|
76890
|
+
version: "2.260407.1",
|
|
76891
76891
|
description: "LLM-optimized CLI for Omni",
|
|
76892
76892
|
type: "module",
|
|
76893
76893
|
bin: {
|
package/dist/server/index.js
CHANGED
|
@@ -222829,7 +222829,7 @@ var init_sentry_scrub = __esm(() => {
|
|
|
222829
222829
|
var require_package8 = __commonJS((exports, module) => {
|
|
222830
222830
|
module.exports = {
|
|
222831
222831
|
name: "@omni/api",
|
|
222832
|
-
version: "2.
|
|
222832
|
+
version: "2.260407.1",
|
|
222833
222833
|
type: "module",
|
|
222834
222834
|
exports: {
|
|
222835
222835
|
".": {
|
|
@@ -486632,6 +486632,17 @@ var WHATSAPP_CAPABILITIES = {
|
|
|
486632
486632
|
// ../channel-whatsapp/src/handlers/all-events.ts
|
|
486633
486633
|
init_src();
|
|
486634
486634
|
|
|
486635
|
+
// ../channel-whatsapp/src/senders/contact.ts
|
|
486636
|
+
function computeWaid(digits) {
|
|
486637
|
+
if (digits.length === 13 && digits.startsWith("55") && digits.charAt(4) === "9") {
|
|
486638
|
+
const ddd = Number(digits.slice(2, 4));
|
|
486639
|
+
if (ddd >= 31) {
|
|
486640
|
+
return digits.slice(0, 4) + digits.slice(5);
|
|
486641
|
+
}
|
|
486642
|
+
}
|
|
486643
|
+
return digits;
|
|
486644
|
+
}
|
|
486645
|
+
|
|
486635
486646
|
// ../channel-whatsapp/src/jid.ts
|
|
486636
486647
|
var JID_SUFFIX = {
|
|
486637
486648
|
USER: "@s.whatsapp.net",
|
|
@@ -486645,7 +486656,8 @@ function toJid(identifier, lidCache) {
|
|
|
486645
486656
|
return identifier;
|
|
486646
486657
|
}
|
|
486647
486658
|
const cleaned = identifier.replace(/\D/g, "");
|
|
486648
|
-
const
|
|
486659
|
+
const normalized = computeWaid(cleaned);
|
|
486660
|
+
const phoneJid = `${normalized}${JID_SUFFIX.USER}`;
|
|
486649
486661
|
if (lidCache) {
|
|
486650
486662
|
const lidJid = lidCache.get(phoneJid);
|
|
486651
486663
|
if (lidJid)
|
|
@@ -488019,17 +488031,6 @@ function buildMessageContent2(message2, buildVCard) {
|
|
|
488019
488031
|
return builder(message2, buildVCard);
|
|
488020
488032
|
}
|
|
488021
488033
|
|
|
488022
|
-
// ../channel-whatsapp/src/senders/contact.ts
|
|
488023
|
-
function computeWaid(digits) {
|
|
488024
|
-
if (digits.length === 13 && digits.startsWith("55") && digits.charAt(4) === "9") {
|
|
488025
|
-
const ddd = Number(digits.slice(2, 4));
|
|
488026
|
-
if (ddd >= 31) {
|
|
488027
|
-
return digits.slice(0, 4) + digits.slice(5);
|
|
488028
|
-
}
|
|
488029
|
-
}
|
|
488030
|
-
return digits;
|
|
488031
|
-
}
|
|
488032
|
-
|
|
488033
488034
|
// ../channel-whatsapp/src/senders/reaction.ts
|
|
488034
488035
|
function buildReactionContent(targetJid, targetMessageId, emoji, fromMe = true) {
|
|
488035
488036
|
return {
|