<?php

/*
# 發送訊息
MESSAGE=$(printf "[維護確認]\n${DATETIME}\n${GAME_TYPE_DISPLAY}-${COUNTRY_CODE_DISPLAY} => MissionServer 自爆檢查 OK!\n自爆日期: ${DEADLINE} 剩餘天數: ${DEADLINE_DAY_REMAINING}")

# 送出資訊給 API
curl -sS -X POST --data-urlencod "message=${MESSAGE}" "https://web-dev.x-legend.com/api/${ROUTE}/"
*/
$SET=2;
//$MESSAGE=urlencode(sprintf("[M12-GLOBAL]: GET Data-Clean TimeZone Config Error => SET%d", $SET));
$MESSAGE=sprintf("\#\#\#\#\#\# ZABBIX INFORMATION \#\#\#\#\#\#\n[M12-GLOBAL]: GET Data-Clean TimeZone Config Error => SET%d\n\#\#\#\#\#\# ZABBIX INFORMATION \#\#\#\#\#\#", $SET);
echo $MESSAGE."\n";
$request = array(
	"message" => "$MESSAGE"
);

$ch = curl_init();
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_URL, "https://web-dev.x-legend.com/api/INTERNAL-TEST/");
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/x-www-form-urlencoded'));
curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($request));
//$ret = curl_exec($ch);
curl_exec($ch);
curl_close($ch);
//$data = json_decode($ret);
//printf($data);

?>
