Skip to content

Typebot integration sends lid and not jid #2251

Description

@Ben-Avrahami

Closing as duplicate of #1872 — @lid handling meta-issue (cross-cuts Typebot in this case).

See #1872 for tracked symptoms and the Typebot umbrella is forthcoming.

Activity

  1. Bonilhajvv commented on Nov 24, 2025

    @Bonilhajvv

    I'm having this problem too

  2. maestropsi commented on Nov 24, 2025

    @maestropsi

    Mesmo problema aqui

  3. gustauobr commented on Nov 25, 2025

    @gustauobr

    Mesma coisa aqui!

  4. FernandoBolzan commented on Nov 25, 2025

    @FernandoBolzan

    PT: Eu resolvi com uma expressão no N8N, nela identifico se o remoteJid vem com @lid, se vier, utiliza o campo remoteJidAlt, se não vier e for @whatsapp.net ele passa o nó pra frente.

    EN: I solve this using an expression in N8N. In it, I identify if the remoteJid comes with @lid. If it does, I use the remoteJidAlt field; if it doesn't and is @whatsapp.net, I pass the node to the next page.

    code:

    {{ ( $('Webhook EVO').item.json.body.data.key.remoteJid.endsWith('@lid') ? $('Webhook EVO').item.json.body.data.key.remoteJidAlt : $('Webhook EVO').item.json.body.data.key.remoteJid ) .toString() .replace(/[\n\r\t ]+/g, '') }}

  5. Ben-Avrahami commented on Nov 25, 2025

    @Ben-Avrahami
    Author

    Eu resolvi com uma expressão, nela identifico se o remoteJid vem com @lid, se vier, utiliza o campo remoteJidAlt, se não vier e for @whatsapp.net ele passa o nó pra frente.

    Segue ccódigo: {{ ( $('Webhook EVO').item.json.body.data.key.remoteJid.endsWith('@lid') ? $('Webhook EVO').item.json.body.data.key.remoteJidAlt : $('Webhook EVO').item.json.body.data.key.remoteJid ) .toString() .replace(/[\n\r\t ]+/g, '') }}

    this is possible with n8n, but here the problem is with typebot, it is not possible to do it since typebot only receives this data currently
    const prefilledVariables = {
    remoteJid: "JID of the contact",
    pushName: "Contact's name",
    instanceName: "Name of the instance",
    serverUrl: "API server URL",
    apiKey: "Evolution API key",
    ownerJid: "JID of the number connected to the instance"
    };

  6. raphael0627f commented on Nov 25, 2025

    @raphael0627f

    Estou com o mesmo problema

  7. marlonvinicius commented on Nov 25, 2025

    @marlonvinicius

    mesmo problema aqui

  8. lucascampuus commented on Nov 26, 2025

    @lucascampuus
    Contributor

    mesmo problema aqui

  9. kasambr commented on Nov 26, 2025

    @kasambr

    Mesmo problema aqui

  10. DanielBelorini commented on Nov 26, 2025

    @DanielBelorini

    Também… mesmo problema aqui!

  11. cristiandigisat-hub commented on Nov 26, 2025

    @cristiandigisat-hub

    Mesmo problema.

  12. GustavoCPrado commented on Nov 26, 2025

    @GustavoCPrado

    Estou com o mesmo problema, inicialmente utilizando o o typebot as mensagens do robô não iam por conta do @lid consegui corrigir isso porém com o "Stop bot from me" marcado, quando interajo com o cliente a sessão não muda para pausada, fica aberta e o robô continua atuando, alguém passou por isso e conseguiu resolver?

    I'm having the same problem. Initially, using TypeBot, the bot's messages weren't going through because of the @lid attribute. I managed to fix that, but with "Stop bot from me" checked, when I interact with the client, the session doesn't change to paused; it stays open and the bot continues to act. Has anyone else experienced this and managed to solve it?

  13. cristiandigisat-hub commented on Nov 26, 2025

    @cristiandigisat-hub

    Estou com o mesmo problema, inicialmente utilizando o o typebot as mensagens do robô não iam por conta do @lid consegui corrigir isso porém com o "Stop bot from me" marcado, quando interajo com o cliente a sessão não muda para pausada, fica aberta e o robô continua atuando, alguém passou por isso e conseguiu resolver?

    I'm having the same problem. Initially, using TypeBot, the bot's messages weren't going through because of the @lid attribute. I managed to fix that, but with "Stop bot from me" checked, when I interact with the client, the session doesn't change to paused; it stays open and the bot continues to act. Has anyone else experienced this and managed to solve it?

    Como você fez para resolver?

  14. GustavoCPrado commented on Nov 26, 2025

    @GustavoCPrado

    Estou com o mesmo problema, inicialmente utilizando o o typebot as mensagens do robô não iam por conta do @lid consegui corrigir isso porém com o "Stop bot from me" marcado, quando interajo com o cliente a sessão não muda para pausada, fica aberta e o robô continua atuando, alguém passou por isso e conseguiu resolver?
    I'm having the same problem. Initially, using TypeBot, the bot's messages weren't going through because of the @lid attribute. I managed to fix that, but with "Stop bot from me" checked, when I interact with the client, the session doesn't change to paused; it stays open and the bot continues to act. Has anyone else experienced this and managed to solve it?

    Como você fez para resolver?

    Fiz alteração no arquivo:
    src/api/integrations/chatbot/base-chatbot.service.ts

    ANTES:
    number: remoteJid.split('@')[0]

    DEPOIS:
    number: remoteJid.includes('@lid') ? remoteJid : remoteJid.split('@')[0]

    Com isso o typebot passou a responder normalmente.

    Lembra de rebuildar e reiniciar o EvolutionAPI depois.

  15. 2 remaining items

  16. dujobi-contato commented on Nov 27, 2025

    @dujobi-contato

    remoteJidAlt

    Same problem here

  17. leonardomnds commented on Nov 27, 2025

    @leonardomnds

    I had the same issue. I downgraded to version v2.3.4 and the problem stopped happening.

  18. elizeufranca commented on Nov 27, 2025

    @elizeufranca

    I had the same issue. I downgraded to version v2.3.4 and the problem stopped happening.

    Funcionou! maravilha.
    Obrigado. Tanks

  19. Ben-Avrahami commented on Nov 27, 2025

    @Ben-Avrahami
    Author

    I had the same issue. I downgraded to version v2.3.4 and the problem stopped happening.

    What happened? You received jid for everyone? What do you mean the problem stopped happening

  20. marlonvinicius commented on Nov 27, 2025

    @marlonvinicius

    Obrigado @GustavoCPrado !

    Aqui funcionou também!

  21. srvelososantos commented on Dec 2, 2025

    @srvelososantos

    no meu conteiner não tem esse arquivo, o mais perto que achei foi evolution/dist/api/integrations/chatbot
    dentro dessa pasta tem varios arquivos mas nao tem esse base-chatbot.service.ts

  22. DanielBelorini commented on Dec 2, 2025

    @DanielBelorini
    Image

    @srvelososantos, Dependendo da sua instalação... provavelmente no diretório /evolution/dist/api/integrations/chatbot do seu container, vai ver que tem alguns arquivos, semelhantes a este da imagem anexada.

    Esse arquivo não aparece no container porque o build remove o código-fonte TypeScript. O .ts original está no repositório, não dentro do dist. No container só existe o resultado compilado/minificado, que vira vários bundles .js dentro de evolution/dist/api/integrations/chatbot. O base-chatbot.service.ts é transformado e incorporado nesses bundles, então ele deixa de existir como arquivo separado.

    Você até consegue editar na mão o arquivo base-chatbot.service.js que seria o .js minificado do base-chatbot.service.ts, porém, isso não é recomendado e nada prático (Mas resolve, por um tempo). Melhor solução, na minha opinião, é tratar direto na imagem e depois subir para o hub e usar ela, para se caso, precisar parar ou recriar o container não ter que ficar editando esse arquivo novamente.

  23. srvelososantos commented on Dec 2, 2025

    @srvelososantos

    Eu só não entendi por onde que eu edito esse arquivo .ts, eu preciso clonar o repositório do evolution-api ?

  24. willDullius commented on Dec 4, 2025

    @willDullius

    Mesmo problema aqui! Quando o contato é @lid, simplesmente não identifica a resposta do cliente.

    @GustavoCPrado Fiz a edição do parâmetro em todas as linhas que encontrei no base-chatbot.ts. Um exemplo ficou assim:

    await new Promise((resolve) => {
    setTimeout(async () => {
    await instance.textMessage(
    {
    number: remoteJid.includes('@lid') ? remoteJid : remoteJid.split('@')[0],
    delay: settings?.delayMessage || 1000,
    text: message,
    linkPreview,
    },
    false,
    );
    resolve();
    }, delay);
    });

    Rebuildei a imagem, subi pro HUB e fiz um novo Deploy.

    Estou esquecendo de algo?

  25. srvelososantos commented on Dec 4, 2025

    @srvelososantos

    @willDullius eu fiz a mesma coisa, agr o numero pode aparecer ou na variável remoteJid ou remoteJidAlt do webhook, só tratar no seu código. Comigo ta dando certo agora.

  26. GustavoCPrado commented on Dec 4, 2025

    @GustavoCPrado

    Mesmo problema aqui! Quando o contato é @lid, simplesmente não identifica a resposta do cliente.

    @GustavoCPrado Fiz a edição do parâmetro em todas as linhas que encontrei no base-chatbot.ts. Um exemplo ficou assim:

    await new Promise((resolve) => { setTimeout(async () => { await instance.textMessage( { number: remoteJid.includes('@lid') ? remoteJid : remoteJid.split('@')[0], delay: settings?.delayMessage || 1000, text: message, linkPreview, }, false, ); resolve(); }, delay); });

    Rebuildei a imagem, subi pro HUB e fiz um novo Deploy.

    Estou esquecendo de algo?

    Lembrou de rebuildar e reiniciar o EvolutionAPI?

  27. GustavoCPrado commented on Dec 5, 2025

    @GustavoCPrado

    Pessoal, consegui corrigir também o problema do EvolutionAPI com TypeBot que não estava identificando o stop from me.

    Quando a conversa caia no typebot ele identificava o @lid nas sessões, mas a conversa não considerava o @lid, ai mesmo um humano interagindo o robô não parava de atual.

  28. Ben-Avrahami commented on Dec 7, 2025

    @Ben-Avrahami
    Author

    I saw a new version is released, with a suggested fix, hope the fix will work

  29. GustavoCPrado commented on Dec 8, 2025

    @GustavoCPrado

    I saw a new version is released, with a suggested fix, hope the fix will work

    Have you used it before?
    If so, can you say if the @lid problems were resolved in Typebot?

    • Typebot not responding to @lid numbers
    • Typebot's StopFromMe doesn't work for @lid
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions