本文介绍了WhatsappApi ..没有授权错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,



我正在尝试构建一个新产品,使用WhatsAppApi.WhatsApp发送批量邮件,但我收到错误,即登录失败...未经授权。我使用了以下代码,

Hello,

I am trying to build a new product to send bulk messages using WhatsAppApi.WhatsApp but I am getting an Error i.e. "Login Failed... Not authorized". I used the following code,

WhatsAppApi.WhatsApp wa = new WhatsAppApi.WhatsApp("fromnumber", "mynumberpassword", "NickName", false, false);
                wa.OnConnectSuccess += () =>
                {
                    Console.WriteLine("Connected successfully");

                    wa.OnLoginSuccess += (phoneNumber, data) =>
                    {
                        wa.SendMessage("toNumber", "Test Message");
                        Console.WriteLine("Send Successfully");
                    };

                    wa.OnLoginFailed += (data) =>
                    {
                        Console.WriteLine("Login Failed " +data);
                    };
                    wa.Login();
                };
                wa.OnConnectFailed += (ex) =>
                    {
                        Console.WriteLine("Connection Failed");
                    };
                wa.Connect();
                Console.ReadLine();



MynumberPassword上面是我用WART生成的密码(whatsapp注册工具)。

使用上面c#代码我可以连接,但我无法授权。我不知道,如果你们有请让我知道。


Above MynumberPassword is Password which i generated from WART (whatsapp registration tool).
Using above c# code I can connect but I am not able to authorized. I don't have any idea, if you guys have please let me know.

推荐答案


这篇关于WhatsappApi ..没有授权错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-14 17:39