PUT /sites/s_ab12cd34ef56/status-domain
Request examples and the documented response.
Back to this endpoint in the API reference
curl
Request
curl -X PUT "https://api.pagehum.com/v1/sites/s_ab12cd34ef56/status-domain" \
-H "Authorization: Bearer $PAGEHUM_API_KEY" \
-H "Content-Type: application/json" \
-d '{"host":"status.harbor.example"}'JavaScript
Request
const response = await fetch("https://api.pagehum.com/v1/sites/s_ab12cd34ef56/status-domain", {
method: "PUT",
headers: { Authorization: `Bearer ${process.env.PAGEHUM_API_KEY}`, "Content-Type": "application/json" },
body: JSON.stringify({"host":"status.harbor.example"}),
});
const { ok, data, error } = await response.json();
if (!ok) throw new Error(error);Response
Response
{
"ok": true,
"data": {
"host": "status.harbor.example",
"state": "pending",
"records": [
{
"type": "CNAME",
"name": "status",
"value": "cname.vercel-dns.com"
}
],
"detail": "Waiting for DNS. Add the CNAME record at your DNS provider; it usually shows within minutes, sometimes an hour.",
"addedAt": 1791710700000,
"checkedAt": 1791710700000,
"liveAt": null
}
}