health reports whether a publish reaches readers, rather than whether it was…
health reports whether a publish reaches readers, rather than whether it was accepted.
GET /v1/projects/edge
| Address | https://api.hanzo.ai/v1/projects/edge |
| Method | GET |
| Operation | get_projects_edge |
| Auth | Authorization: Bearer $HANZO_API_KEY |
health reports whether a publish reaches readers, rather than whether it was accepted. Those are different questions and only the second one was ever visible.
It asks the edge and nothing else. There is no live call to the provider here: Configured is a local fact, it is the fact that was missing, and a health check that spends a third-party API call is one an operator learns not to run.
Request
GET /v1/projects/edge takes no parameters and no body — the credential is the whole request.
Response
| Status | Body | Meaning |
|---|---|---|
200 | edgeState | ok |
503 | edgeState | service unavailable |
200 body — 8 fields.
| Field | In | Type | Always | Description |
|---|---|---|---|---|
configured | body | boolean | — | Configured is whether the edge holds credentials to act at all. |
error | body | string | — | Error is the blocker, so an operator reads it instead of guessing at it. |
freshness | body | string | — | Freshness says, in one phrase, how long after a publish a reader sees it. |
policy | body | object | — | Policy is the Cache-Control this edge serves each class of object with. |
policy.* | body | string | — | |
provider | body | string | — | Provider is the CDN behind this edge, or "none". |
reach | body | string[] | — | Reach is the apexes a publish is invalidated on. |
status | body | string | — | Status is "ok" when a publish reaches readers immediately, else "degraded". |
Failure carries the platform error shape — see Errors.
Examples
hanzo has no subcommand for this operation — the CLI serves only what cloud's live route table confirms. Use HTTP or an SDK.
import { Configuration, ProjectsApi } from 'hanzoai';
const api = new ProjectsApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getProjectsEdge();from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import ProjectsApi
client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = ProjectsApi(client).get_projects_edge()cfg := cloud.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := cloud.NewAPIClient(cfg)
resp, _, err := client.ProjectsAPI.GetProjectsEdge(context.Background()).Execute()
if err != nil {
return err
}use hanzo_cloud::apis::{configuration::Configuration, projects_api};
let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();
let result = projects_api::get_projects_edge(&cfg, Default::default()).await?;import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.ProjectsApi;
ApiClient client = new ApiClient();
client.setRequestInterceptor(b -> b.header("Authorization", "Bearer " + System.getenv("HANZO_API_KEY")));
var result = new ProjectsApi(client).getProjectsEdge();The method above is the one at the current release of the document. [email protected] (npm) and [email protected] (PyPI) were generated from an earlier release, where this operation carried a different id, so it spells the method differently — regenerating the clients is what makes the two agree. SDKs →
curl https://api.hanzo.ai/v1/projects/edge \
-H "Authorization: Bearer $HANZO_API_KEY"The door reaches projects through the projects tool, which names its 48 operations with its own verbs — this one among them, under a name only the door declares. describe explains any of them:
curl -X POST https://api.hanzo.ai/v1/mcp \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "describe",
"arguments": {
"op": "list_projects"
}
}
}'How is this guide?