Reputation: 1918
I found an example to send instant messages in C# using Whatsapp.
this application connects to this address
request = string.Format("https://v.whatsapp.net/v2/code?cc={0}&in={1}&to={0}{1}&method={2}&mcc={3}&mnc={4}&token={5}&id={6}&lg={7}&lc={8}", pn.CC, pn.Number, method, pn.MCC, pn.MNC, token, id, pn.ISO639, pn.ISO3166);
when run, the application's request is the following
https://v.whatsapp.net/v2/code?cc=98&in=9356256952&to=989356256952&method=sms&mcc=432&mnc=035&token=qrlotgzUkVUYr8yBz3aeQt67TiM%3D&id=s%e8%ad%e83%c1%0c%1ap%0a%c8j%f4%f1%c4%2d%eag%e0%85&lg=fa&lc=IR
but this results in an error
"{\"status\":\"fail\",\"reason\":\"old_version\"}"
Upvotes: 0
Views: 4743
Reputation: 33
vim Yowsup/Common/constants.py
change only
v="0.90"
tokenData = {
"v": "2.12.29",
"r": "S40-2.12.29",
"u": "WhatsApp/2.12.49 S40Version/14.26 Device/Nokia302",
"t": "PdA2DJyKoUrwLw1Bg6EIhzh502dF9noR9uFCllGk1413401214298{phone}",
"d": "Nokia302"
}
Upvotes: 0
Reputation: 10896
Looks like the error is self-explanatory. The WhatsAPI.NET project is unofficial and the request sent by this port has been superseded by something else (newer version) by WhatsApp. You will either have to use another unofficial API or not use WhatsApp as your messaging back-end in the absence of an official API.
Upvotes: 1