$ch = curl_init();
    
    curl_setopt($ch, CURLOPT_URL,"https://posservice.esnekpos.com/api/services/EYVBinService");
    curl_setopt($ch, CURLOPT_POST, 1);
    curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode(array("CardNumber"=>$bin)));
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_HTTPHEADER, [
        'Content-type: application/json'
    ]);
    $response = curl_exec($ch);
    curl_close($ch);
    $response=json_decode($response,true);
    if($response["Card_Type"]!=""){
        $binc=array(
            "BANKA"=>$response["Bank_Name"],
            "SEMA"=>$response["Bank_Brand"],
            "TIP"=>$response["Card_Type"],
            "TUR"=>$response["Card_Kind"]
        );
        die(json_encode(array("status"=>"true", "data"=>$binc)));
    } else{
        die(json_encode(array("status"=>"nodata")));
    }