API リファレンス
ベース URL: https://api.gitflare.net/v1。Bearer トークンで認証します。
ベース URL は https://api.gitflare.net/v1。すべて HTTPS です。
認証
$ curl -sS https://api.gitflare.net/v1/accounts/me \ -H "Authorization: Bearer $GITFLARE_API_TOKEN"
バンドルから Worker を作る
$ tar -C dist -czf bundle.tgz . $ curl -sS -X PUT https://api.gitflare.net/v1/workers/checkout-api \ -H "Authorization: Bearer $GITFLARE_API_TOKEN" \ -H "Content-Type: application/gzip" \ --data-binary @bundle.tgz
キャッシュを消す
await fetch("https://api.gitflare.net/v1/zones/example.com/purge", {
method: "POST",
headers: { authorization: `Bearer ${token}`, "content-type": "application/json" },
body: JSON.stringify({ prefixes: ["/assets/"] }),
});
DNS レコード一覧
$ curl -sS "https://api.gitflare.net/v1/zones/example.com/dns?type=A" \ -H "Authorization: Bearer $GITFLARE_API_TOKEN"