<?php
// Data to be sent
$data = [
    "tradeResult" => "1",
    "oriAmount" => "400.00",
    "amount" => "400.00",
    "mchId" => "100666810",
    "orderNo" => "20000910610011",
    "mchOrderNo" => "ORD20251749809940",
    "sign" => "90f2c58f56112643b1d3ceac9c67f9a8",
    "signType" => "MD5",
    "orderDate" => "2025-06-13 18:19:01"
];

// Convert to JSON if required (but in this case, we send as application/x-www-form-urlencoded)
$postData = http_build_query($data);

// Setup cURL
$ch = curl_init('https://earningxs.in.net/services/callback.php');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $postData);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'Content-Type: application/x-www-form-urlencoded'
]);

// Execute and capture response
$response = curl_exec($ch);

// Check for errors
if (curl_errno($ch)) {
    echo 'cURL error: ' . curl_error($ch);
} else {
    echo "Response: " . $response;
}

// Close cURL session
curl_close($ch);
?>
