NASER fix price issues & close trade when tahesab is unavailable
This commit is contained in:
@@ -359,4 +359,18 @@ class TahesabController extends Controller
|
||||
|
||||
}
|
||||
|
||||
public function healthCheck()
|
||||
{
|
||||
$tahesab = Http::withoutVerifying()->withHeaders([
|
||||
'Content-Type' => 'application/json',
|
||||
'DBName'=> 'tahesabDB1',
|
||||
'Authorization'=> 'Bearer K7F5P8H2Q1O4I8M8M4J3L4L3W8N2A2P6I2T4I8N4E2T2N2D7O7Y5K3W6P2N4G3X2T1T4C5V4I1X2T6S1'
|
||||
])->post('https://217.114.40.30:8081/', ["CheckHealth" => [] ])->json();
|
||||
|
||||
if($tahesab['Api_Status'] === "OK" && $tahesab['DB_Status'] === "OK"){
|
||||
return true;
|
||||
}else{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user