Algaza

Script Instagram Unfollow yang tidak MengFollow

May 3rd, 2016
2,774
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.93 KB | None | 0 0
  1. <?php
  2. @ini_set("output_buffering", "Off");
  3. @ini_set('implicit_flush', 1);
  4. @ini_set('zlib.output_compression', 0);
  5. @ini_set('max_execution_time',1000000);
  6. header( 'Content-type: text/html; charset=utf-8' );
  7. include 'akun.php';
  8. include 'API.php';
  9. echo "Mengambil list yang tidak follback anda...<br/>";
  10. notFollback();
  11. function notFollback($next_max_id = null, $i = 1)
  12. {
  13.     global $agent, $ID;
  14.      
  15.     $action = 'following';
  16.     $following = SendRequest('friendships/'.$ID.'/'.$action.'?max_id='.$next_max_id, false, false, $agent, true);
  17.     $obj = json_decode($following[1]);
  18.     @$max_id = $obj->next_max_id;
  19.     foreach ($obj->users as $users) {
  20.         $user_id = $users->pk;
  21.         $username_ = $users->username;
  22.         $check = SendRequest('friendships/show/'.$user_id.'/', false, false, $agent, true);
  23.         $cek = json_decode($check[1]);
  24.         if ($cek->followed_by == false) {
  25.             echo $i . ". @" . $username_ . " belum follback<br/>";
  26.             $action = 'destroy';
  27.             $data = '{"user_id":"'.$user_id.'"}';
  28.             $sig = GenerateSignature($data);
  29.             $new_data = 'signed_body='.$sig.'.'.urlencode($data).'&ig_sig_key_version=4';
  30.             $follow = SendRequest('friendships/'.$action.'/'.$user_id.'/', true, $new_data, $agent, true);
  31.             $obj2 = json_decode($follow[1]);
  32.             if ($obj2->status == "ok") {
  33.                 echo "-- Mengunfollow @" . $username_ . " Sukses<br/>";
  34.                 sleep(1);
  35.             }
  36.             $i++;
  37.             flush();
  38.             ob_flush();
  39.         } else {
  40.             echo "@" . $username_ . " saling follow<br/>";
  41.             flush();
  42.             ob_flush();
  43.         }
  44.     }
  45.     if($max_id) {
  46.         notFollback($max_id, $i);
  47.         exit();
  48.     }
  49.     $i--;
  50.     echo "$i yang belum follback sudah di unfollow<br/>";
  51. }
  52. echo "Adek Lelah... Sudah dulu bang<br/>";
  53.  
  54.  
  55. ___ITCrews.blogspot.com ft AT998.blogspot.com____
Advertisement
Add Comment
Please, Sign In to add comment