본문으로 건너뛰기

API 레퍼런스

Monitors API

모니터 생성, 목록 조회, 수정, 삭제 endpoint의 기본 계약입니다.

Endpoint

Method

Path

Scope

GET

/api/v1/monitors?projectSlug=

admin:read 또는 status:read

POST

/api/v1/monitors

admin:write

PATCH

/api/v1/monitors/:id

admin:write

DELETE

/api/v1/monitors/:id

admin:write

생성

bash
curl -X POST https://devstage.app/api/v1/monitors \
  -H "Authorization: Bearer $THESEEKER_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{"projectSlug":"payments","slug":"checkout-api","name":"Checkout API","intervalSec":60,"degradedAfter":120,"downAfter":240}'

성공 status는 201이고 { "monitor": ... }를 반환합니다. slug는 프로젝트에서 유일해야 합니다.

목록

bash
curl 'https://devstage.app/api/v1/monitors?projectSlug=payments' \
  -H "Authorization: Bearer $THESEEKER_API_KEY"

성공 응답은 { "monitors": [...] }입니다. API 키의 조직 또는 프로젝트 범위에 따라 결과가 제한됩니다.

오류

검증 실패는 400, 권한 부족은 403, 없는 monitor는 404, slug 충돌은 409입니다. 상태 이벤트는 프로젝트 키로 ingest endpoint에 보내며, 이 관리 endpoint와 같은 키를 혼용하지 마세요.

응답 형태

목록 응답의 최상위 키는 monitors이고 생성 응답의 최상위 키는 monitor입니다. 날짜 값은 API 응답에서 ISO 형식 문자열로 직렬화됩니다.

이 페이지가 도움이 되었나요?