function post($url, $data) {
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
return $response;
}
$data = [
"json_string" = '{"key":"value"}';
];
post("my-second.domen/api.php", $data);
$_POST["json_string"]
.