• 04-03-2022, 21:22:26
    #1
    Merhaba. Bir api kodu ile ilgili yardıma ihtiyacım var yardım edebilecek birisi var mıı?
  • 04-03-2022, 21:25:20
    #2
    neyler ilgili ayrıntı verseydin
  • 04-03-2022, 21:34:24
    #3
    icexsolution adlı üyeden alıntı: mesajı görüntüle
    neyler ilgili ayrıntı verseydin
    https://developers.tron.network/refe...nfo-by-address
    APİ bu
     public function login(Request $request)
        {
    
           
            $checkAccount = curl_init('https://api.trongrid.io/v1/accounts/address' . $request->wallet);
            curl_setopt($checkAccount, CURLOPT_RETURNTRANSFER, 1);
    
    
            $data = curl_exec($checkAccount);
            curl_close($checkAccount);
            $type = json_decode($data);
    
            if(!$type->success){
                return response()->json(['error' => 'Address is invalid']);
            }else{
                //Check if the wallet has already been taken
                $account = Account::where('wallet', $request->wallet)->first();
    
                if($account){
                    if($account->status==0){
                        return response()->json(['error' => 'This address is banned by admin']);
                    }
                    session()->put('ACCOUNT', $request->wallet);
                    return response()->json(['success' => 'Account found']);
                }
    Kullandığım kod bu fakat adress girdiğimde tanımıyor
  • 04-03-2022, 21:40:32
    #4
    semihunwin adlı üyeden alıntı: mesajı görüntüle
    https://developers.tron.network/refe...nfo-by-address
    APİ bu
     public function login(Request $request)
        {
    
          
            $checkAccount = curl_init('https://api.trongrid.io/v1/accounts/address' . $request->wallet);
            curl_setopt($checkAccount, CURLOPT_RETURNTRANSFER, 1);
    
    
            $data = curl_exec($checkAccount);
            curl_close($checkAccount);
            $type = json_decode($data);
    
            if(!$type->success){
                return response()->json(['error' => 'Address is invalid']);
            }else{
                //Check if the wallet has already been taken
                $account = Account::where('wallet', $request->wallet)->first();
    
                if($account){
                    if($account->status==0){
                        return response()->json(['error' => 'This address is banned by admin']);
                    }
                    session()->put('ACCOUNT', $request->wallet);
                    return response()->json(['success' => 'Account found']);
                }
    Kullandığım kod bu fakat adress girdiğimde tanımıyor
    /accounts/address kısmını /accounts/ olarak değiştirip dener misiniz
  • 04-03-2022, 21:47:53
    #5
    profweb adlı üyeden alıntı: mesajı görüntüle
    /accounts/address kısmını /accounts/ olarak değiştirip dener misiniz
    2 gündür uğraştığım sorunum aslında buymuş address kısmını da girmişim koda. Teşekkür ederim bunu hatırlattığınız için.