dispatch(); // on l'execute /* [3] Si erreur =========================================================*/ if( $answer->error != ManagerError::Success ){ // on l'explicite var_dump( ManagerError::explicit($answer->error) ); // on quitte return; } /* [4] Sinon on recupere le resultat =========================================================*/ $sms = $answer->get('sms'); $call = $answer->get('call'); $contact = $answer->get('contact'); /* [5] On debug les donnees recues =========================================================*/ var_dump( "Il y a ".count($contact)." personnes :" ); var_dump( "- ".count($sms)." par SMS/MMS" ); var_dump( "- ".count($call)." par telephone" ); echo "
"; echo "TOP 10 DES APPELS
"; echo "=================
"; foreach($call as $v) var_dump( $v[0] ." (".$contact[$v[0]].") \t\t\t". $v[1] ." appels"); echo "TOP 10 DES MMS/SMS
"; echo "==================
"; foreach($sms as $v) var_dump( $v[0] ." (".$contact[$v[0]].") \t\t\t". $v[1] ." appels"); var_dump("\n\n\nOBJET COMPLET"); var_dump( $sms ); var_dump( $call ); var_dump( $contact ); } // parseCallLog(); debug(); $api = new client(); var_dump( $api->send('parse-call-log', array( '@token'=> 'bb21158c733229347bd4e681891e213d94c685bf', '@username' => 'xdrm', '@password'=> 'mypassword' ) )); ?>