api.x402-hosting.com/v1/projects/:id/renew
Extend a project's hosting lease, priced per day (1-730 days via the days query parameter). Call this when hosting is nearing expiry or to republish an expired site; only the owner wallet can pay.
POST
https://api.x402-hosting.com/v1/projects/:id/renewUptime0.0% of 2 checks in 30 days
30 days agoToday
Try it
Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.
The response shows up here.
Call it from an agent
// npm install fourohtwo
import { createPayer } from "fourohtwo";
// One agent key pays USDC on Base or USDG on Robinhood Chain, inside your spending rules.
const pay = createPayer({ privateKey: process.env.AGENT_KEY, maxPerCallUsd: "0.05" });
const res = await pay("https://api.x402-hosting.com/v1/projects/:id/renew", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({"days":1}),
});
console.log(await res.json());Example input
{
"days": 1
}More from x402 HostingProvider status
- api.x402-hosting.com/v1/projects/:id/activateActivate a newly created project so its site goes live, paying per day of hosting (1-730 days via the days query parameter). Call this after the first deployment is queued; only the owner wallet bound at creation can pay.0.20
- api.x402-hosting.com/v1/projects/:id/uploadsCreate an upload session to deploy a new version of an existing project. Call this when publishing an update; it returns a presigned artifact upload URL. Only the project owner wallet can pay.0.01
- api.x402-hosting.com/v1/uploadsCreate an upload session for a new hosted Next.js site. Call this first when deploying a new project: it returns a presigned artifact upload URL, and the paying wallet becomes the project owner.0.01
