2017-04-25 3 views
0

whatsapp API를 사용하여 whatsapp 암호를 얻는 방법?Whatsapp api에서 Whatsapp 암호 가져 오기

저는 아직 API를 사용하는 법을 배우고 있으며 사용하지 않을 것입니다. 코드에 sublime 코드 편집기를 사용하고 있습니다. 아래는 자습서 중 하나에서받은 샘플 코드입니다.

Array ([cc] => 60 [in] => 6012xxxxxxx [lg] => en [lc] => MY [id] => 蜀��|#b�պ�`���x [token] => IAW+aljx1hbtx0Vh/sqxJmKytyc= [mistyped] => 6 [network_radio_type] => 1 [simnum] => 1 [s] => [copiedrc] => 1 [hasinrc] => 1 [rcmatch] => 1 [pid] => 5138 [rchash] => 6557f1fa8776a69cc3427a6196467690cb85cc651b36cc7be02062470a72a742 [anhash] => 3c24581d24189c24a487cae2ef84d1c3 [extexist] => 1 [extstate] => 1 [mcc] => 502 [mnc] => 000 [sim_mcc] => 502 [sim_mnc] => 000 [method] => sms) stdClass Object ([login] => 6012xxxxxxx [status] => fail [reason] => old_version) 
Fatal error: Uncaught exception 'Exception' with message 'There was a problem trying to request the code.' in C:\xampp\htdocs\tutorial\whatsapp-api\Chat-API\src\Registration.php:316 Stack trace: #0 C:\xampp\htdocs\tutorial\whatsapp-api\requestCode.php(33): Registration->codeRequest('sms') #1 {main} thrown in C:\xampp\htdocs\tutorial\whatsapp-api\Chat-API\src\Registration.php on line 316 

내가 bad_token

의 오류와 함께 암호를 얻을뿐만 아니라,하지만 여전히 수없는 Wart 응용 프로그램을 사용하려고 있나요 : 나는 그것을 실행하면

require_once('Chat-API/src/Registration.php'); 
username = "6012xxxxxxx"; 
$debug = true; 

// Create a instance of Registration class. 
$r = new Registration($username, $debug); 

$r->codeRequest('sms'); // could be 'voice' too` 

, 나는이 오류가 나타납니다 내가 추가해야하는 다른 기능이나 응용 프로그램. 이것을위한 훌륭한 튜토리얼이나 비디오가 있습니까?

+0

안녕하세요, 당신은 당신의 WhatsApp에 암호 다른 방법을 얻을 관리 않았다? –

답변

2

또한이 lib를 시도했지만 "fail [reason] => old_version"이 있습니다. 이 라이브러리는 2016 년 8 월 10 일부터 지원되지 않으므로 작동하지 않을 것입니다.

+0

안녕하세요, WhatsApp 암호를 다른 방법으로 얻을 수 있었습니까? –

+0

안녕하세요. 아뇨, 죄송합니다 ... –

2

이 하나의 시도 :로 변경, 라인 (22)에 SRC/Constants.php에서

, 라인 (27)에 SRC/Constants.php에서

const WHATSAPP_VER = '2.17.242'; 

로 변경

const WHATSAPP_USER_AGENT = 'WhatsApp/2.17.242 Android/4.3 Device/Xiaomi-HM_1SW'; 

10 행의 src/token.php에서

$classesMd5 = 'ziYneeSZm5qExsEFX/AoMQ=='; // 2.17.242 

희망이 도움이됩니다.

https://github.com/tgalal/yowsup/issues/1905

+1

고맙습니다 ..... – Bharath