东道主主

update()

host.update({ label }) → Promise<Host>

重命名主机。仅标签——子弹是地址,它不会改变。

PATCHlabel onlythe slug is the URL
Using Python?

Switch any code block to Python: the choice applies to every page. Python SDK guide and resource reference.

await site.update({ label: "Portfolio (2026)" });
site.update(label="Portfolio (2026)")

为何打球的子弹是固定的,

改变它会同时打破三件事

链接已经共享,客户域名已经连接,主机名证书已经签发,三个链接都已经停止工作,三个链接都无法大声使用,它们只是停止工作。

另一地址, 另一个主机主机

const next = await api.hosts.create({ kind: "site", slug: "portfolio-2026", label: "Portfolio" });
await next.deploy({ files: "./out" });
// Then move the domain, and remove the old host when nothing points at it.
nxt = api.hosts.create(runtime="static", slug="portfolio-2026", label="Portfolio")
nxt.deploy(files="./out")
# Then move the domain, and remove the old host when nothing points at it.

标签是用来做什么的

显示在列表中。 没有什么取决于它, 所以改变它是安全的—— 正因为如此,它才能改变。

更新对象

host.label 被回来的东西取代