Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Msg type buttton is not working #172

Open
danillo10 opened this issue Mar 21, 2023 · 0 comments
Open

Msg type buttton is not working #172

danillo10 opened this issue Mar 21, 2023 · 0 comments

Comments

@danillo10
Copy link

Today my bot dont work with msg type button, my user dont see the msg with button...
the msg is send in my bot whatsapp i can see the msg, but my user dont see the msg, it's a whatsapp block ? Only msg buttons is not working, all others msg is working

buttons.push(
{buttonId: 'id1', buttonText: {displayText: "Preciso contratar"}, type: 1},
{buttonId: 'id2', buttonText: {displayText: "Preciso trabalhar"}, type: 1},
{buttonId: 'id3', buttonText: {displayText: "Quero suporte"}, type: 1}
);

                        const buttonMessage = {
                            text: "Bem-vindo ao Canal de Atendimento Serviços 24 Horas! Estamos felizes em atendê-lo. Aqui, resolvemos todas as suas necessidades, contando com a colaboração de milhares de profissionais em todo o país, como diaristas, pedreiros, advogados, profissionais de TI, psicólogos, garçons, serviços administrativos, entre outros. Todos os profissionais são rigorosamente selecionados e verificados por nossa plataforma, garantindo segurança e tranquilidade para você. Contratar um serviço é fácil e rápido, basta selecionar a opção desejada e aguardar nosso contato rápido. Experimente agora e tenha a solução para seus problemas a apenas alguns cliques de distância!",
                            buttons: buttons,
                            headerType: 1
                        }

                        client.sendMessage(BotsApp.chatId, buttonMessage, MessageType.buttonsMessage)
                            .then((data) => {
                                console.log(data)
                                // socket.emit('fromWhatsapp', {response: BotsApp.body, customer});
                                // customer.fromMe = true;
                                // customer.name = ownerName;
                                // socket.emit('fromCompany', {response: buttonMessage.text, customer});
                            })
                            .catch(err => console.log(err));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant