hosting

POST /v1/uptime/monitors

Start watching a web address.

Todos os endpoints de hosting

Autenticação

Envie uma chave de API como um token bearer. Este endpoint não especifica uma permissão específica na documentação, portanto, conceda à sua chave o mínimo necessário e verifique a resposta em vez de assumir.

Onde vai o ID da sua organização

Este endpoint aceita org_id como parâmetro de consulta. Omita-o e a chamada abrangerá toda a sua subárvore de locatários; envie-o para restringir a chamada a uma única organização.

O ID da sua organização está na tela de chaves de API no seu painel, ao lado da própria chave. É o mesmo ID em todas as chamadas que você fizer.

Experimente

Substitua qualquer item entre colchetes por seus próprios valores e o espaço reservado para a chave por uma chave do seu painel.

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

Conectado? O console da API no seu painel preenche o ID da sua organização real e a sua própria chave, e executa a requisição contra a API de produção para que você possa ver a resposta real. Abra este endpoint no console da API

Detalhes

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.

Parâmetros

NomeTipoObrigatórioO que é
org_id (query)stringNãoWhich 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 writ…

Corpo da requisição

NomeTipoObrigatórioO que é
urlstringSimAny public http(s) address. Stored canonicalised — userinfo stripped, fragment dropped, default port removed — so what is measured, cached and shown are the same string.
namestringNãoWhat 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 th…
expect_textstringNãoText 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 answe…

Resposta

NomeTipoObrigatórioO que é
idstringSim
urlstringSim
namestringNão
statestring<unknown, up, down, paused>Sim⛔ `unknown` is a real state and is not a synonym for `up` — it means "not checked yet" and is excluded from every uptime percentage.
enabledbooleanSim
expect_textstringNão
site_idstringNãoSet 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_atstringNão
last_up_atstringNão
last_down_atstringNão
created_atstringSim
summaryUptimeSummaryNão
historyUptimeHistoryPoint[]Não
incidentsUptimeIncident[]Não
vitalsUptimeVitalsPoint[]Não
migration_offerUptimeMigrationOfferNão

Erros que este endpoint pode retornar

401 · 403 · 422