Аутентификација

Пошаљите API кључ као bearer токен. Ова крајња тачка не наводи конкретну дозволу у спецификацији, па свом кључу доделите најмања неопходна овлашћења и проверите одговор уместо да претпостављате.

Где се уноси ID ваше организације

Ова крајња тачка прихвата org_id као параметар упита. Изоставите га и позив ће обухватити цело подстабло вашег закупа; пошаљите га да бисте сузили позив на једну организацију.

Идентификатор ваше организације се налази на екрану са API кључевима на вашој контролној табли, поред самог кључа. То је исти идентификатор у сваком позиву који упутите.

Испробајте

Замените све што је у угластим заградама сопственим вредностима, а чувар места кључа кључем са своје контролне табле.

curl -X POST https://api.zinndigital.com/v1/uptime/monitors \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "url": <string> }'

Пријављени сте? API конзола на вашој контролној табли попуњава ваш прави id организације и ваш сопствени кључ, и покреће захтев према живом API-ју како бисте могли да видите стварни одговор. Отворите ову крајњу тачку у API конзоли

Детаљи

Gated on uptime.manage. The address may be any public http(s) URL — we do not need to host it, and it need not belong to the customer at all. Refused with 422 when the address is not a public web address (an internal or non-HTTP address is refused in wording that does not confirm our network shape), when this organisation already watches it, or when its allowance is used up. Every account includes three monitored URLs; further capacity is the uptime_urls_10 extra.

Параметри

НазивТипОбавезноШта је ово
org_id (query)stringНеWhich organisation in the caller's subtree the monitor belongs to — what the dashboard's org switcher sends. ⛔ Narrow only: intersected with what the caller may already write…

Тело захтева

НазивТипОбавезноШта је ово
urlstringДаAny public http(s) address. Stored canonicalised — userinfo stripped, fragment dropped, default port removed — so what is measured, cached and shown are the same string.
namestringНеWhat to call it on screen. Blank falls back to the host. ⛔ name, not label: label is an attribute of DRF's Field and cannot be a serializer field name, and a read key that…
expect_textstringНеText that must appear in the response for the check to pass. ⭐ This is what catches the failure a status code cannot — a site whose database has gone but whose index still answers…

Одговор

НазивТипОбавезноШта је ово
idstringДа—
urlstringДа—
namestringНе—
statestring<unknown, up, down, paused>Да⛔ unknown is a real state and is not a synonym for up — it means "not checked yet" and is excluded from every uptime percentage.
enabledbooleanДа—
expect_textstringНе—
site_idstringНеSet only when the address happens to be one of this organisation's own sites. Navigation only — the monitor works identically without it, and must, because the product exists to…
last_result_atstringНе—
last_up_atstringНе—
last_down_atstringНе—
created_atstringДа—
summaryUptimeSummaryНе—
historyUptimeHistoryPoint[]Не—
incidentsUptimeIncident[]Не—
vitalsUptimeVitalsPoint[]Не—
migration_offerUptimeMigrationOfferНе—

Грешке које ова крајња тачка може вратити

401 · 403 · 422