fleet
POST /v1/fleet/heartbeat
Stamp fleet liveness, ship the host report, collect queued commands.
प्रमाणीकरण
बेअरर टोकन म्हणून API की पाठवा. या एंडपॉईंटने स्पष्टीकरणामध्ये ठराविक परवानगी नमूद केलेली नाही, त्यामुळे तुमच्या कीला आवश्यक तेवढाच कमीत कमी ॲक्सेस द्या आणि गृहीत धरण्याऐवजी प्रतिसाद तपासा.
या एंडपॉइंटला कोणतीही संस्था आयडी (organisation id) लागत नाही. तुमची की (key) आधीच ती कोणत्या संस्थेशी संबंधित आहे हे ओळखते आणि प्रतिसाद त्यानुसार मर्यादित केला जातो.
प्रयत्न करा
कोनसांस्कृतिक कंसात (<>) असलेली कोणतीही गोष्ट तुमच्या स्वतःच्या मूल्यांनी बदला आणि key प्लेसहोल्डरला तुमच्या डॅशबोर्डवरील किने बदला.
curl -X POST https://api.zinndigital.com/v1/fleet/heartbeat \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "instance_id": <string> }'साइन इन केलेले आहे? तुमच्या डॅशबोर्डमधील API कन्सोल तुमची खरी संस्था आयडी आणि तुमची स्वतःची की आपोआप भरतो आणि लाइव्ह API विरुद्ध विनंती कार्यान्वित करतो जेणेकरून तुम्हाला वास्तविक प्रतिसाद पाहता येईल. एपी कन्सोलमध्ये हा एंडपॉइंट उघडा
तपशील
Sent every heartbeatIntervalSeconds. Carries the host health report — the same document the console has always shown — because the heartbeat and the report answer the same question, and one call means the report can never be fresher than the heartbeat it is judged against. This is where a declared box becomes real capacity. A host that has never heartbeated is promoted to active and starts accepting deploys on its first successful beat; every beat after that leaves acceptsDeploys untouched, so an operator's drain sticks across an agent restart. A down host that heartbeats again is revived to active or draining according to the operator's existing intent. A decommissioned host gets continue: false and nothing is written. The response carries any commands the engine claimed for this host (bounded per tick). The claim is still SELECT … FOR UPDATE SKIP LOCKED, so exactly-once semantics are unchanged; only who runs the query moved, because a worker box has no database connection.
विनंती मुख्य भाग
| नाव | प्रकार | आवश्यक | हे काय आहे |
|---|---|---|---|
instance_id | string | होय | — |
agent_version | string | नाही | — |
report | WorkerHostReport | नाही | One heartbeat's observed host state. |
प्रतिसाद
| नाव | प्रकार | आवश्यक | हे काय आहे |
|---|---|---|---|
worker_id | string | नाही | — |
hostname | string | नाही | — |
status | string<provisioning, active, draining, down, decommissioned> | नाही | — |
accepts_deploys | boolean | नाही | — |
region | string | नाही | — |
pool | string | नाही | — |
driver | string | नाही | — |
capacity | integer | नाही | — |
product_lines | string[] | नाही | — |
heartbeat_interval_seconds | integer | नाही | How often to heartbeat, decided engine-side. The box no longer reads its own interval from an env file, so "the host-down window is ten missed beats" stays a fact about the… |
continue_running | boolean | नाही | False only for an answered "this host is gone" (decommissioned or removed). An error is never reported as one — that distinction is what stops a transient failure retiring a… |
commands | WorkerClaimedCommand[] | नाही | — |
ही एंडपॉइंट परत करू शकेल अशा त्रुटी
401 · 422 · 429