watchfor 0.16.0 → 0.17.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -1
- package/dist/client.d.ts +12 -0
- package/dist/client.js +8 -0
- package/dist/index.d.ts +1 -1
- package/dist/schema.d.ts +912 -31
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -36,6 +36,12 @@ await wf.alertRules.create(monitor.id!, {
|
|
|
36
36
|
// uptime, SLA, reports and the status page (include() undoes it).
|
|
37
37
|
await wf.incidents.exclude(19351, { reason: "Probe-side DNS hiccup" });
|
|
38
38
|
|
|
39
|
+
// Post-mortem: creates the draft on first use; only the sections you name change.
|
|
40
|
+
await wf.incidents.updatePostmortem(19351, {
|
|
41
|
+
sections: { summary: "Checkout returned 502 for 14 minutes." },
|
|
42
|
+
add_action_items: [{ title: "Validate upstreams in CI" }],
|
|
43
|
+
});
|
|
44
|
+
|
|
39
45
|
// Irreversible: wipe a monitor's checks and incidents; uptime restarts "since reset".
|
|
40
46
|
await wf.monitors.reset(monitor.id!);
|
|
41
47
|
|
|
@@ -193,5 +199,5 @@ WATCHFOR_ORGANIZATION=<organization-id> npx watchfor summary
|
|
|
193
199
|
## Links
|
|
194
200
|
|
|
195
201
|
- API docs: https://watchfor.io/docs/api
|
|
196
|
-
- MCP server for AI agents (
|
|
202
|
+
- MCP server for AI agents (61 tools): https://watchfor.io/docs/api/mcp
|
|
197
203
|
- Create an API key: dashboard → Settings → API keys (`read` or `read+write` scope)
|
package/dist/client.d.ts
CHANGED
|
@@ -37,6 +37,10 @@ export type ScriptVersionSummary = components["schemas"]["ScriptVersionSummary"]
|
|
|
37
37
|
export type Variable = components["schemas"]["Variable"];
|
|
38
38
|
export type VariableDeleted = components["schemas"]["VariableDeleted"];
|
|
39
39
|
export type Incident = components["schemas"]["Incident"];
|
|
40
|
+
/** An incident's post-mortem (plan feature). */
|
|
41
|
+
export type Postmortem = components["schemas"]["Postmortem"];
|
|
42
|
+
/** `incidents.updatePostmortem()` body — omitted fields are kept. */
|
|
43
|
+
export type PostmortemUpdate = components["schemas"]["PostmortemUpdate"];
|
|
40
44
|
export type AlertRule = components["schemas"]["AlertRule"];
|
|
41
45
|
export type Contact = components["schemas"]["Contact"];
|
|
42
46
|
export type ContactGroup = components["schemas"]["ContactGroup"];
|
|
@@ -401,6 +405,14 @@ export declare class WatchFor {
|
|
|
401
405
|
* it (marking again returns the same one); delete that window to
|
|
402
406
|
* undo. */
|
|
403
407
|
markMaintenance: (id: number, idempotencyKey?: string) => Promise<MaintenanceMarking>;
|
|
408
|
+
/** The incident's post-mortem. 404 when it has none yet —
|
|
409
|
+
* `updatePostmortem` creates it. */
|
|
410
|
+
getPostmortem: (id: number) => Promise<Postmortem>;
|
|
411
|
+
/** Create the post-mortem draft on first use, then apply only what is
|
|
412
|
+
* given: `sections` replaces just the sections named; `add_timeline`
|
|
413
|
+
* and `add_action_items` append (repeats skipped). Publishing and
|
|
414
|
+
* deleting stay in the dashboard. */
|
|
415
|
+
updatePostmortem: (id: number, body: PostmortemUpdate) => Promise<Postmortem>;
|
|
404
416
|
};
|
|
405
417
|
readonly statusPages: {
|
|
406
418
|
list: (q?: {
|
package/dist/client.js
CHANGED
|
@@ -318,6 +318,14 @@ export class WatchFor {
|
|
|
318
318
|
markMaintenance: (id, idempotencyKey) => this.request("POST", `/incidents/${id}/mark-maintenance`, {
|
|
319
319
|
idempotencyKey,
|
|
320
320
|
}),
|
|
321
|
+
/** The incident's post-mortem. 404 when it has none yet —
|
|
322
|
+
* `updatePostmortem` creates it. */
|
|
323
|
+
getPostmortem: (id) => this.request("GET", `/incidents/${id}/postmortem`),
|
|
324
|
+
/** Create the post-mortem draft on first use, then apply only what is
|
|
325
|
+
* given: `sections` replaces just the sections named; `add_timeline`
|
|
326
|
+
* and `add_action_items` append (repeats skipped). Publishing and
|
|
327
|
+
* deleting stay in the dashboard. */
|
|
328
|
+
updatePostmortem: (id, body) => this.request("PATCH", `/incidents/${id}/postmortem`, { body }),
|
|
321
329
|
};
|
|
322
330
|
// ── Status pages, on-call, channels ──────────────────────────
|
|
323
331
|
statusPages = {
|
package/dist/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { type ActivityEvent, type AlertingState, type AlertRule, type Announcement, type AnnouncementCreate, type AnnouncementUpdate, type ApiErrorBody, type BatchOperation, type BatchResult, type BulkResult, type Check, type CheckList, type CheckNowAck, type Contact, type ContactGroup, type Deleted, type DiagnosticCatalog, type DiagnosticCatalogEntry, type DiagnosticReport, type DiagnosticRun, type DiagnosticSlug, type Incident, type IncidentStats, type IntegrityBaseline, type IntegrityBaselineAccept, type IntegrityBaselineAcceptPending, type List, type MaintenanceMarking, type MaintenanceWindow, type Me, type Monitor, type MonitorDetail, type MonitorReset, type Notification, ORGANIZATION_HEADER, type Organization, type Plan, type PlaywrightRun, type PlaywrightRunSummary, type PlaywrightTestRun, type PlaywrightTestRunAccepted, type PlaywrightTestRunRequest, type ReportFilters, type ResponseTimeBucket, type ScriptVersion, type ScriptVersionSummary, type StatusPage, type StatusPageComponentCreate, type StatusPageCreate, type StatusPageUpdate, type Summary, type Uptime, type Variable, type VariableDeleted, WatchFor, WatchForError, type WatchForGrade, type WatchForOptions, } from "./client.js";
|
|
1
|
+
export { type ActivityEvent, type AlertingState, type AlertRule, type Announcement, type AnnouncementCreate, type AnnouncementUpdate, type ApiErrorBody, type BatchOperation, type BatchResult, type BulkResult, type Check, type CheckList, type CheckNowAck, type Contact, type ContactGroup, type Deleted, type DiagnosticCatalog, type DiagnosticCatalogEntry, type DiagnosticReport, type DiagnosticRun, type DiagnosticSlug, type Incident, type IncidentStats, type IntegrityBaseline, type IntegrityBaselineAccept, type IntegrityBaselineAcceptPending, type List, type MaintenanceMarking, type MaintenanceWindow, type Me, type Monitor, type MonitorDetail, type MonitorReset, type Notification, ORGANIZATION_HEADER, type Organization, type Plan, type PlaywrightRun, type PlaywrightRunSummary, type PlaywrightTestRun, type PlaywrightTestRunAccepted, type PlaywrightTestRunRequest, type Postmortem, type PostmortemUpdate, type ReportFilters, type ResponseTimeBucket, type ScriptVersion, type ScriptVersionSummary, type StatusPage, type StatusPageComponentCreate, type StatusPageCreate, type StatusPageUpdate, type Summary, type Uptime, type Variable, type VariableDeleted, WatchFor, WatchForError, type WatchForGrade, type WatchForOptions, } from "./client.js";
|
package/dist/schema.d.ts
CHANGED
|
@@ -665,6 +665,30 @@ export interface paths {
|
|
|
665
665
|
patch?: never;
|
|
666
666
|
trace?: never;
|
|
667
667
|
};
|
|
668
|
+
"/incidents/{id}/postmortem": {
|
|
669
|
+
parameters: {
|
|
670
|
+
query?: never;
|
|
671
|
+
header?: never;
|
|
672
|
+
path?: never;
|
|
673
|
+
cookie?: never;
|
|
674
|
+
};
|
|
675
|
+
/**
|
|
676
|
+
* Get the incident's post-mortem
|
|
677
|
+
* @description Plan feature (post-mortems). 404 when the incident is not in this organization, or when it has no post-mortem yet (the message says so — PATCH creates it).
|
|
678
|
+
*/
|
|
679
|
+
get: operations["getIncidentPostmortem"];
|
|
680
|
+
put?: never;
|
|
681
|
+
post?: never;
|
|
682
|
+
delete?: never;
|
|
683
|
+
options?: never;
|
|
684
|
+
head?: never;
|
|
685
|
+
/**
|
|
686
|
+
* Create or update the incident's post-mortem draft
|
|
687
|
+
* @description Creates the post-mortem with the dashboard's template on first use (title from the monitor, severity from the incident), then applies the fields given. Any member may write and complete post-mortems, as in the dashboard; publishing to the status page and deleting stay owner/admin actions in the dashboard. Every change lands in the activity log.
|
|
688
|
+
*/
|
|
689
|
+
patch: operations["updateIncidentPostmortem"];
|
|
690
|
+
trace?: never;
|
|
691
|
+
};
|
|
668
692
|
"/incidents/{id}/mark-maintenance": {
|
|
669
693
|
parameters: {
|
|
670
694
|
query?: never;
|
|
@@ -1036,7 +1060,7 @@ export interface paths {
|
|
|
1036
1060
|
path?: never;
|
|
1037
1061
|
cookie?: never;
|
|
1038
1062
|
};
|
|
1039
|
-
/** One-call org snapshot: monitor status counts, active incidents, open maintenance */
|
|
1063
|
+
/** One-call org snapshot: monitor status counts, active incidents, open maintenance, expiring certificates and domains */
|
|
1040
1064
|
get: operations["getOrgSummary"];
|
|
1041
1065
|
put?: never;
|
|
1042
1066
|
post?: never;
|
|
@@ -1141,6 +1165,660 @@ export interface paths {
|
|
|
1141
1165
|
export type webhooks = Record<string, never>;
|
|
1142
1166
|
export interface components {
|
|
1143
1167
|
schemas: {
|
|
1168
|
+
/** @description ssl monitors — the certificate card. `protocol`/`cipher_suite` are the negotiated connection's. */
|
|
1169
|
+
MonitorLatestSsl: {
|
|
1170
|
+
/**
|
|
1171
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1172
|
+
* @enum {string}
|
|
1173
|
+
*/
|
|
1174
|
+
kind: "ssl";
|
|
1175
|
+
/**
|
|
1176
|
+
* Format: date-time
|
|
1177
|
+
* @description When the check this block describes ran.
|
|
1178
|
+
*/
|
|
1179
|
+
checked_at: string | null;
|
|
1180
|
+
days_until_expiry: number | null;
|
|
1181
|
+
/** Format: date-time */
|
|
1182
|
+
not_after: string | null;
|
|
1183
|
+
/** @description Issuer organisation, else its common name. */
|
|
1184
|
+
issuer: string | null;
|
|
1185
|
+
/** @description e.g. "TLS 1.3". */
|
|
1186
|
+
protocol: string | null;
|
|
1187
|
+
valid: boolean | null;
|
|
1188
|
+
hostname_match: boolean | null;
|
|
1189
|
+
chain_valid: boolean | null;
|
|
1190
|
+
subject: string | null;
|
|
1191
|
+
/** @description Subject alternative names. */
|
|
1192
|
+
sans: string[] | null;
|
|
1193
|
+
cipher_suite: string | null;
|
|
1194
|
+
forward_secrecy: boolean | null;
|
|
1195
|
+
/** @description Daily TLS grade (A+ … F) when the monitor opts into grading; from the latest graded check. */
|
|
1196
|
+
tls_grade: string | null;
|
|
1197
|
+
/**
|
|
1198
|
+
* Format: date-time
|
|
1199
|
+
* @description When that grade was measured.
|
|
1200
|
+
*/
|
|
1201
|
+
tls_graded_at: string | null;
|
|
1202
|
+
};
|
|
1203
|
+
/** @description rdap (domain) monitors — the registration card. Expiry fields come from the latest check that found an expiry (an expired domain included); registrar, status and dates from the latest check that returned them. */
|
|
1204
|
+
MonitorLatestRdap: {
|
|
1205
|
+
/**
|
|
1206
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1207
|
+
* @enum {string}
|
|
1208
|
+
*/
|
|
1209
|
+
kind: "rdap";
|
|
1210
|
+
/**
|
|
1211
|
+
* Format: date-time
|
|
1212
|
+
* @description When the check this block describes ran.
|
|
1213
|
+
*/
|
|
1214
|
+
checked_at: string | null;
|
|
1215
|
+
/** Format: date-time */
|
|
1216
|
+
expires_at: string | null;
|
|
1217
|
+
/** @description Negative once the domain has expired. */
|
|
1218
|
+
days_until_expiry: number | null;
|
|
1219
|
+
registrar: string | null;
|
|
1220
|
+
nameservers: string[];
|
|
1221
|
+
/** @description RDAP/EPP status codes, e.g. "client transfer prohibited". */
|
|
1222
|
+
status: string[];
|
|
1223
|
+
/** @description Registration date — ISO 8601 when parseable, else as the registry reports it. */
|
|
1224
|
+
created_date: string | null;
|
|
1225
|
+
/** @description Last registry update — ISO 8601 when parseable, else as reported. */
|
|
1226
|
+
updated_date: string | null;
|
|
1227
|
+
/** @description The expiry came from the prober's lookup cache rather than a fresh registry query. */
|
|
1228
|
+
cached: boolean | null;
|
|
1229
|
+
};
|
|
1230
|
+
/** @description heartbeat monitors — the last-ping card. */
|
|
1231
|
+
MonitorLatestHeartbeat: {
|
|
1232
|
+
/**
|
|
1233
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1234
|
+
* @enum {string}
|
|
1235
|
+
*/
|
|
1236
|
+
kind: "heartbeat";
|
|
1237
|
+
/**
|
|
1238
|
+
* Format: date-time
|
|
1239
|
+
* @description The latest heartbeat event of any kind (ping, start or miss).
|
|
1240
|
+
*/
|
|
1241
|
+
checked_at: string | null;
|
|
1242
|
+
/**
|
|
1243
|
+
* Format: date-time
|
|
1244
|
+
* @description Last finish/plain ping (starts and scheduler-fired misses do not count).
|
|
1245
|
+
*/
|
|
1246
|
+
last_ping_at: string | null;
|
|
1247
|
+
/**
|
|
1248
|
+
* Format: date-time
|
|
1249
|
+
* @description Period schedules only; null for cron.
|
|
1250
|
+
*/
|
|
1251
|
+
next_expected_at: string | null;
|
|
1252
|
+
missed: boolean;
|
|
1253
|
+
last_exit_code: number | null;
|
|
1254
|
+
};
|
|
1255
|
+
/** @description http monitors — the latest check. */
|
|
1256
|
+
MonitorLatestHttp: {
|
|
1257
|
+
/**
|
|
1258
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1259
|
+
* @enum {string}
|
|
1260
|
+
*/
|
|
1261
|
+
kind: "http";
|
|
1262
|
+
/**
|
|
1263
|
+
* Format: date-time
|
|
1264
|
+
* @description When the check this block describes ran.
|
|
1265
|
+
*/
|
|
1266
|
+
checked_at: string | null;
|
|
1267
|
+
status_code: number | null;
|
|
1268
|
+
ttfb_ms: number | null;
|
|
1269
|
+
redirects_count: number | null;
|
|
1270
|
+
/** @description Days until the certificate the latest check saw expires; null when it saw none (plain text, or failed before TLS). */
|
|
1271
|
+
cert_days_left: number | null;
|
|
1272
|
+
};
|
|
1273
|
+
/** @description api monitors — the latest check. */
|
|
1274
|
+
MonitorLatestApi: {
|
|
1275
|
+
/**
|
|
1276
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1277
|
+
* @enum {string}
|
|
1278
|
+
*/
|
|
1279
|
+
kind: "api";
|
|
1280
|
+
/**
|
|
1281
|
+
* Format: date-time
|
|
1282
|
+
* @description When the check this block describes ran.
|
|
1283
|
+
*/
|
|
1284
|
+
checked_at: string | null;
|
|
1285
|
+
status_code: number | null;
|
|
1286
|
+
response_time_ms: number | null;
|
|
1287
|
+
/** @description Days until the certificate the latest check saw expires; null when it saw none (plain text, or failed before TLS). */
|
|
1288
|
+
cert_days_left: number | null;
|
|
1289
|
+
assertions_total: number | null;
|
|
1290
|
+
assertions_failed: number | null;
|
|
1291
|
+
/** @description The latest check's failing assertions (at most 20), redacted like check payloads. */
|
|
1292
|
+
failed_assertions: {
|
|
1293
|
+
source: string | null;
|
|
1294
|
+
property: string | null;
|
|
1295
|
+
operator: string | null;
|
|
1296
|
+
expected: string | null;
|
|
1297
|
+
actual: string | null;
|
|
1298
|
+
error: string | null;
|
|
1299
|
+
}[];
|
|
1300
|
+
};
|
|
1301
|
+
/** @description tcp monitors — the latest check. */
|
|
1302
|
+
MonitorLatestTcp: {
|
|
1303
|
+
/**
|
|
1304
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1305
|
+
* @enum {string}
|
|
1306
|
+
*/
|
|
1307
|
+
kind: "tcp";
|
|
1308
|
+
/**
|
|
1309
|
+
* Format: date-time
|
|
1310
|
+
* @description When the check this block describes ran.
|
|
1311
|
+
*/
|
|
1312
|
+
checked_at: string | null;
|
|
1313
|
+
connect_ms: number | null;
|
|
1314
|
+
/** @description null without TLS. */
|
|
1315
|
+
tls_handshake_ms: number | null;
|
|
1316
|
+
/** @description Days until the certificate the latest check saw expires; null when it saw none (plain text, or failed before TLS). */
|
|
1317
|
+
cert_days_left: number | null;
|
|
1318
|
+
};
|
|
1319
|
+
/** @description udp monitors — the latest check. */
|
|
1320
|
+
MonitorLatestUdp: {
|
|
1321
|
+
/**
|
|
1322
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1323
|
+
* @enum {string}
|
|
1324
|
+
*/
|
|
1325
|
+
kind: "udp";
|
|
1326
|
+
/**
|
|
1327
|
+
* Format: date-time
|
|
1328
|
+
* @description When the check this block describes ran.
|
|
1329
|
+
*/
|
|
1330
|
+
checked_at: string | null;
|
|
1331
|
+
response_received: boolean | null;
|
|
1332
|
+
bytes_received: number | null;
|
|
1333
|
+
first_byte_ms: number | null;
|
|
1334
|
+
};
|
|
1335
|
+
/** @description icmp (ping) monitors — the latest check. RTTs are null when no reply came back. */
|
|
1336
|
+
MonitorLatestIcmp: {
|
|
1337
|
+
/**
|
|
1338
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1339
|
+
* @enum {string}
|
|
1340
|
+
*/
|
|
1341
|
+
kind: "icmp";
|
|
1342
|
+
/**
|
|
1343
|
+
* Format: date-time
|
|
1344
|
+
* @description When the check this block describes ran.
|
|
1345
|
+
*/
|
|
1346
|
+
checked_at: string | null;
|
|
1347
|
+
rtt_avg_ms: number | null;
|
|
1348
|
+
rtt_min_ms: number | null;
|
|
1349
|
+
rtt_max_ms: number | null;
|
|
1350
|
+
jitter_ms: number | null;
|
|
1351
|
+
packet_loss_pct: number | null;
|
|
1352
|
+
packets_sent: number | null;
|
|
1353
|
+
packets_received: number | null;
|
|
1354
|
+
};
|
|
1355
|
+
/** @description dns monitors — the latest check. */
|
|
1356
|
+
MonitorLatestDns: {
|
|
1357
|
+
/**
|
|
1358
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1359
|
+
* @enum {string}
|
|
1360
|
+
*/
|
|
1361
|
+
kind: "dns";
|
|
1362
|
+
/**
|
|
1363
|
+
* Format: date-time
|
|
1364
|
+
* @description When the check this block describes ran.
|
|
1365
|
+
*/
|
|
1366
|
+
checked_at: string | null;
|
|
1367
|
+
query_type: string | null;
|
|
1368
|
+
/** @description e.g. "NOERROR", "NXDOMAIN". */
|
|
1369
|
+
rcode: string | null;
|
|
1370
|
+
answers_count: number | null;
|
|
1371
|
+
lookup_ms: number | null;
|
|
1372
|
+
};
|
|
1373
|
+
/** @description smtp monitors — the latest check. */
|
|
1374
|
+
MonitorLatestSmtp: {
|
|
1375
|
+
/**
|
|
1376
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1377
|
+
* @enum {string}
|
|
1378
|
+
*/
|
|
1379
|
+
kind: "smtp";
|
|
1380
|
+
/**
|
|
1381
|
+
* Format: date-time
|
|
1382
|
+
* @description When the check this block describes ran.
|
|
1383
|
+
*/
|
|
1384
|
+
checked_at: string | null;
|
|
1385
|
+
connect_ms: number | null;
|
|
1386
|
+
tls_supported: boolean | null;
|
|
1387
|
+
open_relay: boolean | null;
|
|
1388
|
+
ptr_valid: boolean | null;
|
|
1389
|
+
/** @description Days until the certificate the latest check saw expires; null when it saw none (plain text, or failed before TLS). */
|
|
1390
|
+
cert_days_left: number | null;
|
|
1391
|
+
/** @description null = no username configured. */
|
|
1392
|
+
login_ok: boolean | null;
|
|
1393
|
+
};
|
|
1394
|
+
/** @description sitemap monitors — the latest check. */
|
|
1395
|
+
MonitorLatestSitemap: {
|
|
1396
|
+
/**
|
|
1397
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1398
|
+
* @enum {string}
|
|
1399
|
+
*/
|
|
1400
|
+
kind: "sitemap";
|
|
1401
|
+
/**
|
|
1402
|
+
* Format: date-time
|
|
1403
|
+
* @description When the check this block describes ran.
|
|
1404
|
+
*/
|
|
1405
|
+
checked_at: string | null;
|
|
1406
|
+
found: boolean | null;
|
|
1407
|
+
url_count: number | null;
|
|
1408
|
+
broken_urls: number | null;
|
|
1409
|
+
broken_percent: number | null;
|
|
1410
|
+
};
|
|
1411
|
+
/** @description mtr (traceroute) monitors — the latest check. */
|
|
1412
|
+
MonitorLatestMtr: {
|
|
1413
|
+
/**
|
|
1414
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1415
|
+
* @enum {string}
|
|
1416
|
+
*/
|
|
1417
|
+
kind: "mtr";
|
|
1418
|
+
/**
|
|
1419
|
+
* Format: date-time
|
|
1420
|
+
* @description When the check this block describes ran.
|
|
1421
|
+
*/
|
|
1422
|
+
checked_at: string | null;
|
|
1423
|
+
destination_reached: boolean | null;
|
|
1424
|
+
hops: number | null;
|
|
1425
|
+
visible_hops: number | null;
|
|
1426
|
+
unresponsive_hops: number | null;
|
|
1427
|
+
destination_loss_pct: number | null;
|
|
1428
|
+
path_loss_max_pct: number | null;
|
|
1429
|
+
/** @description Destination round trip; null when not reached. */
|
|
1430
|
+
rtt_avg_ms: number | null;
|
|
1431
|
+
};
|
|
1432
|
+
/** @description ntp monitors — the latest check. Clock figures are null when no sample was valid. */
|
|
1433
|
+
MonitorLatestNtp: {
|
|
1434
|
+
/**
|
|
1435
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1436
|
+
* @enum {string}
|
|
1437
|
+
*/
|
|
1438
|
+
kind: "ntp";
|
|
1439
|
+
/**
|
|
1440
|
+
* Format: date-time
|
|
1441
|
+
* @description When the check this block describes ran.
|
|
1442
|
+
*/
|
|
1443
|
+
checked_at: string | null;
|
|
1444
|
+
/** @description Signed clock offset. */
|
|
1445
|
+
offset_ms: number | null;
|
|
1446
|
+
delay_ms: number | null;
|
|
1447
|
+
jitter_ms: number | null;
|
|
1448
|
+
/** @description 1–15 synced, 16 unsynchronised. */
|
|
1449
|
+
stratum: number | null;
|
|
1450
|
+
synced: boolean | null;
|
|
1451
|
+
/** @description The probe's own verdict against the configured offset/delay limits. */
|
|
1452
|
+
check_passed: boolean | null;
|
|
1453
|
+
};
|
|
1454
|
+
/** @description websocket monitors — the latest check. */
|
|
1455
|
+
MonitorLatestWebsocket: {
|
|
1456
|
+
/**
|
|
1457
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1458
|
+
* @enum {string}
|
|
1459
|
+
*/
|
|
1460
|
+
kind: "websocket";
|
|
1461
|
+
/**
|
|
1462
|
+
* Format: date-time
|
|
1463
|
+
* @description When the check this block describes ran.
|
|
1464
|
+
*/
|
|
1465
|
+
checked_at: string | null;
|
|
1466
|
+
connected: boolean;
|
|
1467
|
+
handshake_ms: number | null;
|
|
1468
|
+
/** @description null when the ping check is off. */
|
|
1469
|
+
ping_rtt_ms: number | null;
|
|
1470
|
+
/** @description null when no expect pattern is configured. */
|
|
1471
|
+
message_matched: boolean | null;
|
|
1472
|
+
};
|
|
1473
|
+
/** @description blacklist (DNSBL) monitors — the latest check. */
|
|
1474
|
+
MonitorLatestBlacklist: {
|
|
1475
|
+
/**
|
|
1476
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1477
|
+
* @enum {string}
|
|
1478
|
+
*/
|
|
1479
|
+
kind: "blacklist";
|
|
1480
|
+
/**
|
|
1481
|
+
* Format: date-time
|
|
1482
|
+
* @description When the check this block describes ran.
|
|
1483
|
+
*/
|
|
1484
|
+
checked_at: string | null;
|
|
1485
|
+
listed_count: number | null;
|
|
1486
|
+
checked_count: number | null;
|
|
1487
|
+
clean_count: number | null;
|
|
1488
|
+
timeout_count: number | null;
|
|
1489
|
+
/** @description Blocklists the target is listed on; null when the check stored no per-list detail. */
|
|
1490
|
+
listed_on: string[] | null;
|
|
1491
|
+
};
|
|
1492
|
+
/** @description breach monitors — the latest lookup. Counts are null when the lookup itself failed. */
|
|
1493
|
+
MonitorLatestBreach: {
|
|
1494
|
+
/**
|
|
1495
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1496
|
+
* @enum {string}
|
|
1497
|
+
*/
|
|
1498
|
+
kind: "breach";
|
|
1499
|
+
/**
|
|
1500
|
+
* Format: date-time
|
|
1501
|
+
* @description When the check this block describes ran.
|
|
1502
|
+
*/
|
|
1503
|
+
checked_at: string | null;
|
|
1504
|
+
/** @description Known breaches of the domain, any age. */
|
|
1505
|
+
breach_count: number | null;
|
|
1506
|
+
/** @description Of those, within the last 2 years. */
|
|
1507
|
+
recent_count: number | null;
|
|
1508
|
+
};
|
|
1509
|
+
/** @description email_policy monitors — SPF / DMARC / DKIM as of the latest check (MTA-STS is not checked). */
|
|
1510
|
+
MonitorLatestEmailPolicy: {
|
|
1511
|
+
/**
|
|
1512
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1513
|
+
* @enum {string}
|
|
1514
|
+
*/
|
|
1515
|
+
kind: "email_policy";
|
|
1516
|
+
/**
|
|
1517
|
+
* Format: date-time
|
|
1518
|
+
* @description When the check this block describes ran.
|
|
1519
|
+
*/
|
|
1520
|
+
checked_at: string | null;
|
|
1521
|
+
spf_present: boolean | null;
|
|
1522
|
+
spf_valid: boolean | null;
|
|
1523
|
+
dmarc_present: boolean | null;
|
|
1524
|
+
dmarc_valid: boolean | null;
|
|
1525
|
+
/**
|
|
1526
|
+
* @description null without a DMARC record.
|
|
1527
|
+
* @enum {string|null}
|
|
1528
|
+
*/
|
|
1529
|
+
dmarc_policy: "none" | "quarantine" | "reject" | null;
|
|
1530
|
+
dkim_present: boolean | null;
|
|
1531
|
+
dkim_valid: boolean | null;
|
|
1532
|
+
};
|
|
1533
|
+
/** @description cdn monitors — the latest check. */
|
|
1534
|
+
MonitorLatestCdn: {
|
|
1535
|
+
/**
|
|
1536
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1537
|
+
* @enum {string}
|
|
1538
|
+
*/
|
|
1539
|
+
kind: "cdn";
|
|
1540
|
+
/**
|
|
1541
|
+
* Format: date-time
|
|
1542
|
+
* @description When the check this block describes ran.
|
|
1543
|
+
*/
|
|
1544
|
+
checked_at: string | null;
|
|
1545
|
+
detected: boolean | null;
|
|
1546
|
+
/** @description e.g. "cloudflare". */
|
|
1547
|
+
provider: string | null;
|
|
1548
|
+
/** @description The edge's own cache verdict, e.g. HIT. */
|
|
1549
|
+
cache_status: string | null;
|
|
1550
|
+
/** @description 0–1; null when no request had a verdict. */
|
|
1551
|
+
cache_hit_ratio: number | null;
|
|
1552
|
+
ttfb_ms: number | null;
|
|
1553
|
+
};
|
|
1554
|
+
/** @description cms monitors — the latest detection (no version is stored). */
|
|
1555
|
+
MonitorLatestCms: {
|
|
1556
|
+
/**
|
|
1557
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1558
|
+
* @enum {string}
|
|
1559
|
+
*/
|
|
1560
|
+
kind: "cms";
|
|
1561
|
+
/**
|
|
1562
|
+
* Format: date-time
|
|
1563
|
+
* @description When the check this block describes ran.
|
|
1564
|
+
*/
|
|
1565
|
+
checked_at: string | null;
|
|
1566
|
+
detected: boolean | null;
|
|
1567
|
+
/** @description e.g. "WordPress". */
|
|
1568
|
+
name: string | null;
|
|
1569
|
+
/** @description Which fingerprint matched. */
|
|
1570
|
+
source: string | null;
|
|
1571
|
+
};
|
|
1572
|
+
/** @description brotli monitors — the latest check. */
|
|
1573
|
+
MonitorLatestBrotli: {
|
|
1574
|
+
/**
|
|
1575
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1576
|
+
* @enum {string}
|
|
1577
|
+
*/
|
|
1578
|
+
kind: "brotli";
|
|
1579
|
+
/**
|
|
1580
|
+
* Format: date-time
|
|
1581
|
+
* @description When the check this block describes ran.
|
|
1582
|
+
*/
|
|
1583
|
+
checked_at: string | null;
|
|
1584
|
+
supported: boolean | null;
|
|
1585
|
+
};
|
|
1586
|
+
/** @description favicon monitors — the latest check. */
|
|
1587
|
+
MonitorLatestFavicon: {
|
|
1588
|
+
/**
|
|
1589
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1590
|
+
* @enum {string}
|
|
1591
|
+
*/
|
|
1592
|
+
kind: "favicon";
|
|
1593
|
+
/**
|
|
1594
|
+
* Format: date-time
|
|
1595
|
+
* @description When the check this block describes ran.
|
|
1596
|
+
*/
|
|
1597
|
+
checked_at: string | null;
|
|
1598
|
+
found: boolean | null;
|
|
1599
|
+
bytes: number | null;
|
|
1600
|
+
content_type_ok: boolean | null;
|
|
1601
|
+
};
|
|
1602
|
+
/** @description mcp monitors — the latest check. Counts are null when the handshake failed. */
|
|
1603
|
+
MonitorLatestMcp: {
|
|
1604
|
+
/**
|
|
1605
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1606
|
+
* @enum {string}
|
|
1607
|
+
*/
|
|
1608
|
+
kind: "mcp";
|
|
1609
|
+
/**
|
|
1610
|
+
* Format: date-time
|
|
1611
|
+
* @description When the check this block describes ran.
|
|
1612
|
+
*/
|
|
1613
|
+
checked_at: string | null;
|
|
1614
|
+
handshake_ok: boolean | null;
|
|
1615
|
+
server_name: string | null;
|
|
1616
|
+
server_version: string | null;
|
|
1617
|
+
protocol_version: string | null;
|
|
1618
|
+
tools_count: number | null;
|
|
1619
|
+
resources_count: number | null;
|
|
1620
|
+
prompts_count: number | null;
|
|
1621
|
+
/** @description Days until the certificate the latest check saw expires; null when it saw none (plain text, or failed before TLS). */
|
|
1622
|
+
cert_days_left: number | null;
|
|
1623
|
+
};
|
|
1624
|
+
/** @description browser (Core Web Vitals) monitors — the latest successful audit. Scores are 0–1, like the alert metrics; INP is null when the audit did not measure it. */
|
|
1625
|
+
MonitorLatestBrowser: {
|
|
1626
|
+
/**
|
|
1627
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1628
|
+
* @enum {string}
|
|
1629
|
+
*/
|
|
1630
|
+
kind: "browser";
|
|
1631
|
+
/**
|
|
1632
|
+
* Format: date-time
|
|
1633
|
+
* @description When the check this block describes ran.
|
|
1634
|
+
*/
|
|
1635
|
+
checked_at: string | null;
|
|
1636
|
+
performance_score: number | null;
|
|
1637
|
+
accessibility_score: number | null;
|
|
1638
|
+
seo_score: number | null;
|
|
1639
|
+
best_practices_score: number | null;
|
|
1640
|
+
lcp_ms: number | null;
|
|
1641
|
+
cls: number | null;
|
|
1642
|
+
inp_ms: number | null;
|
|
1643
|
+
fcp_ms: number | null;
|
|
1644
|
+
tbt_ms: number | null;
|
|
1645
|
+
/** @description "mobile" or "desktop". */
|
|
1646
|
+
preset: string | null;
|
|
1647
|
+
};
|
|
1648
|
+
/** @description playwright (browser check) monitors — the latest run that reached the site (infrastructure errors skipped). */
|
|
1649
|
+
MonitorLatestPlaywright: {
|
|
1650
|
+
/**
|
|
1651
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1652
|
+
* @enum {string}
|
|
1653
|
+
*/
|
|
1654
|
+
kind: "playwright";
|
|
1655
|
+
/**
|
|
1656
|
+
* Format: date-time
|
|
1657
|
+
* @description When the check this block describes ran.
|
|
1658
|
+
*/
|
|
1659
|
+
checked_at: string | null;
|
|
1660
|
+
/** @description passed | flaky | failed | timed_out | script_error (see the runs endpoint). */
|
|
1661
|
+
status: string | null;
|
|
1662
|
+
tests_total: number | null;
|
|
1663
|
+
tests_passed: number | null;
|
|
1664
|
+
tests_failed: number | null;
|
|
1665
|
+
steps_total: number | null;
|
|
1666
|
+
/** @description Title of the step the run failed at. */
|
|
1667
|
+
failed_step: string | null;
|
|
1668
|
+
console_errors: number | null;
|
|
1669
|
+
failed_requests: number | null;
|
|
1670
|
+
attempts: number | null;
|
|
1671
|
+
};
|
|
1672
|
+
/** @description integrity (page integrity) monitors — the latest check. */
|
|
1673
|
+
MonitorLatestIntegrity: {
|
|
1674
|
+
/**
|
|
1675
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1676
|
+
* @enum {string}
|
|
1677
|
+
*/
|
|
1678
|
+
kind: "integrity";
|
|
1679
|
+
/**
|
|
1680
|
+
* Format: date-time
|
|
1681
|
+
* @description When the check this block describes ran.
|
|
1682
|
+
*/
|
|
1683
|
+
checked_at: string | null;
|
|
1684
|
+
pages_checked: number | null;
|
|
1685
|
+
pages_changed: number | null;
|
|
1686
|
+
text_change_pct_max: number | null;
|
|
1687
|
+
/** @description New script/iframe/form/link origins, keyword hits, redirect, header and script changes — summed. */
|
|
1688
|
+
security_findings: number | null;
|
|
1689
|
+
/** @description Security headers removed or weakened. */
|
|
1690
|
+
headers_weakened: number | null;
|
|
1691
|
+
};
|
|
1692
|
+
/** @description imap monitors — the latest check. */
|
|
1693
|
+
MonitorLatestImap: {
|
|
1694
|
+
/**
|
|
1695
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1696
|
+
* @enum {string}
|
|
1697
|
+
*/
|
|
1698
|
+
kind: "imap";
|
|
1699
|
+
/**
|
|
1700
|
+
* Format: date-time
|
|
1701
|
+
* @description When the check this block describes ran.
|
|
1702
|
+
*/
|
|
1703
|
+
checked_at: string | null;
|
|
1704
|
+
/** @description null = connection-only check (no username configured). */
|
|
1705
|
+
login_ok: boolean | null;
|
|
1706
|
+
/** @description e.g. "TLS 1.3"; null without TLS. */
|
|
1707
|
+
tls_version: string | null;
|
|
1708
|
+
/** @description Days until the certificate the latest check saw expires; null when it saw none (plain text, or failed before TLS). */
|
|
1709
|
+
cert_days_left: number | null;
|
|
1710
|
+
cert_valid: boolean | null;
|
|
1711
|
+
plaintext_login_allowed: boolean | null;
|
|
1712
|
+
/** @description Mailbox message count; null when not measured. */
|
|
1713
|
+
messages: number | null;
|
|
1714
|
+
};
|
|
1715
|
+
/** @description pop3 monitors — the latest check. */
|
|
1716
|
+
MonitorLatestPop3: {
|
|
1717
|
+
/**
|
|
1718
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1719
|
+
* @enum {string}
|
|
1720
|
+
*/
|
|
1721
|
+
kind: "pop3";
|
|
1722
|
+
/**
|
|
1723
|
+
* Format: date-time
|
|
1724
|
+
* @description When the check this block describes ran.
|
|
1725
|
+
*/
|
|
1726
|
+
checked_at: string | null;
|
|
1727
|
+
/** @description null = connection-only check (no username configured). */
|
|
1728
|
+
login_ok: boolean | null;
|
|
1729
|
+
/** @description e.g. "TLS 1.3"; null without TLS. */
|
|
1730
|
+
tls_version: string | null;
|
|
1731
|
+
/** @description Days until the certificate the latest check saw expires; null when it saw none (plain text, or failed before TLS). */
|
|
1732
|
+
cert_days_left: number | null;
|
|
1733
|
+
cert_valid: boolean | null;
|
|
1734
|
+
plaintext_login_allowed: boolean | null;
|
|
1735
|
+
/** @description Mailbox message count; null when not measured. */
|
|
1736
|
+
messages: number | null;
|
|
1737
|
+
};
|
|
1738
|
+
/** @description ftp monitors — the latest check. */
|
|
1739
|
+
MonitorLatestFtp: {
|
|
1740
|
+
/**
|
|
1741
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1742
|
+
* @enum {string}
|
|
1743
|
+
*/
|
|
1744
|
+
kind: "ftp";
|
|
1745
|
+
/**
|
|
1746
|
+
* Format: date-time
|
|
1747
|
+
* @description When the check this block describes ran.
|
|
1748
|
+
*/
|
|
1749
|
+
checked_at: string | null;
|
|
1750
|
+
connected: boolean | null;
|
|
1751
|
+
login_ok: boolean | null;
|
|
1752
|
+
/** @description FTPS (explicit or implicit TLS). */
|
|
1753
|
+
secure: boolean | null;
|
|
1754
|
+
};
|
|
1755
|
+
/** @description sftp monitors — the latest check. */
|
|
1756
|
+
MonitorLatestSftp: {
|
|
1757
|
+
/**
|
|
1758
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1759
|
+
* @enum {string}
|
|
1760
|
+
*/
|
|
1761
|
+
kind: "sftp";
|
|
1762
|
+
/**
|
|
1763
|
+
* Format: date-time
|
|
1764
|
+
* @description When the check this block describes ran.
|
|
1765
|
+
*/
|
|
1766
|
+
checked_at: string | null;
|
|
1767
|
+
connected: boolean | null;
|
|
1768
|
+
login_ok: boolean | null;
|
|
1769
|
+
};
|
|
1770
|
+
/** @description email_roundtrip monitors — the latest run. Everything read off the received message is null when it was not delivered. */
|
|
1771
|
+
MonitorLatestEmailRoundtrip: {
|
|
1772
|
+
/**
|
|
1773
|
+
* @description discriminator enum property added by openapi-typescript
|
|
1774
|
+
* @enum {string}
|
|
1775
|
+
*/
|
|
1776
|
+
kind: "email_roundtrip";
|
|
1777
|
+
/**
|
|
1778
|
+
* Format: date-time
|
|
1779
|
+
* @description When the check this block describes ran.
|
|
1780
|
+
*/
|
|
1781
|
+
checked_at: string | null;
|
|
1782
|
+
delivered: boolean | null;
|
|
1783
|
+
delivery_ms: number | null;
|
|
1784
|
+
in_spam: boolean | null;
|
|
1785
|
+
spf_pass: boolean | null;
|
|
1786
|
+
dkim_pass: boolean | null;
|
|
1787
|
+
dmarc_pass: boolean | null;
|
|
1788
|
+
spam_score: number | null;
|
|
1789
|
+
};
|
|
1790
|
+
/** @description Type-aware summary of the monitor page's top cards. `kind` is always the monitor's type; every field is present, null when unknown. */
|
|
1791
|
+
MonitorLatest:
|
|
1792
|
+
| components["schemas"]["MonitorLatestSsl"]
|
|
1793
|
+
| components["schemas"]["MonitorLatestRdap"]
|
|
1794
|
+
| components["schemas"]["MonitorLatestHeartbeat"]
|
|
1795
|
+
| components["schemas"]["MonitorLatestHttp"]
|
|
1796
|
+
| components["schemas"]["MonitorLatestApi"]
|
|
1797
|
+
| components["schemas"]["MonitorLatestTcp"]
|
|
1798
|
+
| components["schemas"]["MonitorLatestUdp"]
|
|
1799
|
+
| components["schemas"]["MonitorLatestIcmp"]
|
|
1800
|
+
| components["schemas"]["MonitorLatestDns"]
|
|
1801
|
+
| components["schemas"]["MonitorLatestSmtp"]
|
|
1802
|
+
| components["schemas"]["MonitorLatestSitemap"]
|
|
1803
|
+
| components["schemas"]["MonitorLatestMtr"]
|
|
1804
|
+
| components["schemas"]["MonitorLatestNtp"]
|
|
1805
|
+
| components["schemas"]["MonitorLatestWebsocket"]
|
|
1806
|
+
| components["schemas"]["MonitorLatestBlacklist"]
|
|
1807
|
+
| components["schemas"]["MonitorLatestBreach"]
|
|
1808
|
+
| components["schemas"]["MonitorLatestEmailPolicy"]
|
|
1809
|
+
| components["schemas"]["MonitorLatestCdn"]
|
|
1810
|
+
| components["schemas"]["MonitorLatestCms"]
|
|
1811
|
+
| components["schemas"]["MonitorLatestBrotli"]
|
|
1812
|
+
| components["schemas"]["MonitorLatestFavicon"]
|
|
1813
|
+
| components["schemas"]["MonitorLatestMcp"]
|
|
1814
|
+
| components["schemas"]["MonitorLatestBrowser"]
|
|
1815
|
+
| components["schemas"]["MonitorLatestPlaywright"]
|
|
1816
|
+
| components["schemas"]["MonitorLatestIntegrity"]
|
|
1817
|
+
| components["schemas"]["MonitorLatestImap"]
|
|
1818
|
+
| components["schemas"]["MonitorLatestPop3"]
|
|
1819
|
+
| components["schemas"]["MonitorLatestFtp"]
|
|
1820
|
+
| components["schemas"]["MonitorLatestSftp"]
|
|
1821
|
+
| components["schemas"]["MonitorLatestEmailRoundtrip"];
|
|
1144
1822
|
PlaywrightTestRunRequest: {
|
|
1145
1823
|
/** @description A Playwright Test file (TypeScript or JavaScript). Imports: @playwright/test, otpauth, @faker-js/faker, Node built-ins. Read org variables as process.env.NAME; TARGET_URL is `target`. */
|
|
1146
1824
|
script: string;
|
|
@@ -1790,35 +2468,8 @@ export interface components {
|
|
|
1790
2468
|
region: string;
|
|
1791
2469
|
country_code: string;
|
|
1792
2470
|
}[];
|
|
1793
|
-
/** @description Type-aware summary of the monitor page's top
|
|
1794
|
-
latest?:
|
|
1795
|
-
| {
|
|
1796
|
-
days_until_expiry?: number | null;
|
|
1797
|
-
/** Format: date-time */
|
|
1798
|
-
not_after?: string | null;
|
|
1799
|
-
issuer?: string | null;
|
|
1800
|
-
protocol?: string | null;
|
|
1801
|
-
valid?: boolean | null;
|
|
1802
|
-
}
|
|
1803
|
-
| {
|
|
1804
|
-
/** Format: date-time */
|
|
1805
|
-
expires_at?: string | null;
|
|
1806
|
-
days_until_expiry?: number | null;
|
|
1807
|
-
registrar?: string | null;
|
|
1808
|
-
nameservers?: string[];
|
|
1809
|
-
}
|
|
1810
|
-
| {
|
|
1811
|
-
/** Format: date-time */
|
|
1812
|
-
last_ping_at?: string | null;
|
|
1813
|
-
/**
|
|
1814
|
-
* Format: date-time
|
|
1815
|
-
* @description Period schedules only; null for cron.
|
|
1816
|
-
*/
|
|
1817
|
-
next_expected_at?: string | null;
|
|
1818
|
-
missed?: boolean;
|
|
1819
|
-
last_exit_code?: number | null;
|
|
1820
|
-
}
|
|
1821
|
-
| null;
|
|
2471
|
+
/** @description Type-aware summary of the monitor page's top cards — `kind` is the monitor's type (discriminator). null when the monitor has no check yet, or the analytics store could not be reached (best effort). */
|
|
2472
|
+
latest?: components["schemas"]["MonitorLatest"] | null;
|
|
1822
2473
|
available_metrics: components["schemas"]["CatalogAlertMetric"][];
|
|
1823
2474
|
};
|
|
1824
2475
|
MonitorCreate: {
|
|
@@ -1974,7 +2625,12 @@ export interface components {
|
|
|
1974
2625
|
timestamp?: string;
|
|
1975
2626
|
success?: boolean;
|
|
1976
2627
|
duration_ms?: number;
|
|
2628
|
+
/** @description The probe location's system name */
|
|
1977
2629
|
location?: string;
|
|
2630
|
+
/** @description The location's display name (city), when it is one of WatchFor's locations */
|
|
2631
|
+
location_name?: string;
|
|
2632
|
+
/** @description ISO 3166-1 alpha-2 country of the location */
|
|
2633
|
+
location_country_code?: string;
|
|
1978
2634
|
target?: string;
|
|
1979
2635
|
error?: string | null;
|
|
1980
2636
|
status_code?: number;
|
|
@@ -2411,6 +3067,126 @@ export interface components {
|
|
|
2411
3067
|
incident_id: number;
|
|
2412
3068
|
maintenance_window: components["schemas"]["MaintenanceWindow"];
|
|
2413
3069
|
};
|
|
3070
|
+
/** @description An incident's post-mortem — the same document the dashboard edits. `sections` is `body` split by its template headings; `timeline` holds only the entries authors added (the incident's automatic events are in GET /incidents/{id}). */
|
|
3071
|
+
Postmortem: {
|
|
3072
|
+
/** Format: uuid */
|
|
3073
|
+
id: string;
|
|
3074
|
+
/** @constant */
|
|
3075
|
+
object: "postmortem";
|
|
3076
|
+
incident_id: number;
|
|
3077
|
+
title?: string | null;
|
|
3078
|
+
/** @enum {string} */
|
|
3079
|
+
status: "draft" | "completed";
|
|
3080
|
+
/** @description Published to the status page (owner/admin, dashboard only). Shown publicly only while also completed and the incident is on a status page. */
|
|
3081
|
+
is_public: boolean;
|
|
3082
|
+
/** @enum {string|null} */
|
|
3083
|
+
severity?: "minor" | "major" | "critical" | null;
|
|
3084
|
+
/** @enum {string|null} */
|
|
3085
|
+
root_cause_category?:
|
|
3086
|
+
| "deploy"
|
|
3087
|
+
| "config_change"
|
|
3088
|
+
| "dependency"
|
|
3089
|
+
| "capacity"
|
|
3090
|
+
| "network"
|
|
3091
|
+
| "hardware"
|
|
3092
|
+
| "security"
|
|
3093
|
+
| "human_error"
|
|
3094
|
+
| "unknown"
|
|
3095
|
+
| "other"
|
|
3096
|
+
| null;
|
|
3097
|
+
/** @description Text under each template heading (markdown-lite); "" when empty. */
|
|
3098
|
+
sections: {
|
|
3099
|
+
summary?: string;
|
|
3100
|
+
impact?: string;
|
|
3101
|
+
root_cause?: string;
|
|
3102
|
+
detection?: string;
|
|
3103
|
+
resolution?: string;
|
|
3104
|
+
what_went_well?: string;
|
|
3105
|
+
what_could_have_gone_better?: string;
|
|
3106
|
+
};
|
|
3107
|
+
/** @description The whole document, markdown-lite (## / ### headings, **bold**, *italic*, `code`, - lists) */
|
|
3108
|
+
body: string;
|
|
3109
|
+
timeline: {
|
|
3110
|
+
/** Format: date-time */
|
|
3111
|
+
at: string;
|
|
3112
|
+
text: string;
|
|
3113
|
+
}[];
|
|
3114
|
+
action_items: {
|
|
3115
|
+
/** Format: uuid */
|
|
3116
|
+
id: string;
|
|
3117
|
+
title: string;
|
|
3118
|
+
/** @enum {string} */
|
|
3119
|
+
status: "open" | "done";
|
|
3120
|
+
assignee?: {
|
|
3121
|
+
id?: string;
|
|
3122
|
+
name?: string;
|
|
3123
|
+
} | null;
|
|
3124
|
+
/** Format: date-time */
|
|
3125
|
+
due_date?: string | null;
|
|
3126
|
+
/** Format: date-time */
|
|
3127
|
+
completed_at?: string | null;
|
|
3128
|
+
}[];
|
|
3129
|
+
/** @description The member who started it; null when an API key did */
|
|
3130
|
+
created_by?: {
|
|
3131
|
+
id?: string;
|
|
3132
|
+
name?: string;
|
|
3133
|
+
} | null;
|
|
3134
|
+
/** Format: date-time */
|
|
3135
|
+
created_at: string;
|
|
3136
|
+
/** Format: date-time */
|
|
3137
|
+
updated_at: string;
|
|
3138
|
+
/** Format: date-time */
|
|
3139
|
+
completed_at?: string | null;
|
|
3140
|
+
};
|
|
3141
|
+
/** @description Omitted fields are kept. `sections` replaces only the sections it names ("" empties one; other sections and custom headings stay as written). `add_timeline` and `add_action_items` append — exact repeats (same time and text / same title, case-insensitive) are skipped, so a retry never duplicates. Publishing and deleting are not available here. */
|
|
3142
|
+
PostmortemUpdate: {
|
|
3143
|
+
title?: string;
|
|
3144
|
+
/**
|
|
3145
|
+
* @description Author-assessed impact, independent of the alert severity
|
|
3146
|
+
* @enum {string|null}
|
|
3147
|
+
*/
|
|
3148
|
+
severity?: "minor" | "major" | "critical" | null;
|
|
3149
|
+
/** @enum {string|null} */
|
|
3150
|
+
root_cause_category?:
|
|
3151
|
+
| "deploy"
|
|
3152
|
+
| "config_change"
|
|
3153
|
+
| "dependency"
|
|
3154
|
+
| "capacity"
|
|
3155
|
+
| "network"
|
|
3156
|
+
| "hardware"
|
|
3157
|
+
| "security"
|
|
3158
|
+
| "human_error"
|
|
3159
|
+
| "unknown"
|
|
3160
|
+
| "other"
|
|
3161
|
+
| null;
|
|
3162
|
+
/**
|
|
3163
|
+
* @description completed sets completed_at; draft reopens
|
|
3164
|
+
* @enum {string}
|
|
3165
|
+
*/
|
|
3166
|
+
status?: "draft" | "completed";
|
|
3167
|
+
/** @description Markdown-lite text per section. A `## ` line inside a section becomes `### ` so it cannot split the document. The whole document is capped at 50,000 characters. */
|
|
3168
|
+
sections?: {
|
|
3169
|
+
summary?: string;
|
|
3170
|
+
impact?: string;
|
|
3171
|
+
root_cause?: string;
|
|
3172
|
+
detection?: string;
|
|
3173
|
+
resolution?: string;
|
|
3174
|
+
what_went_well?: string;
|
|
3175
|
+
what_could_have_gone_better?: string;
|
|
3176
|
+
};
|
|
3177
|
+
/** @description Timeline entries to add (a post-mortem holds up to 100) */
|
|
3178
|
+
add_timeline?: {
|
|
3179
|
+
/** Format: date-time */
|
|
3180
|
+
at: string;
|
|
3181
|
+
text: string;
|
|
3182
|
+
}[];
|
|
3183
|
+
/** @description Follow-ups to add, open and unassigned (a post-mortem holds up to 50) */
|
|
3184
|
+
add_action_items?: {
|
|
3185
|
+
title: string;
|
|
3186
|
+
/** Format: date-time */
|
|
3187
|
+
due_date?: string | null;
|
|
3188
|
+
}[];
|
|
3189
|
+
};
|
|
2414
3190
|
MaintenanceWindow: {
|
|
2415
3191
|
/** Format: uuid */
|
|
2416
3192
|
id?: string;
|
|
@@ -2988,6 +3764,32 @@ export interface components {
|
|
|
2988
3764
|
/** @description Active monitors whose alerts would reach nobody (no alert rule with a contact group and no notification group) */
|
|
2989
3765
|
silent_monitors?: number;
|
|
2990
3766
|
};
|
|
3767
|
+
/** @description Certificate (SSL monitors) and domain (RDAP monitors) expiry in one bulk lookup; null when it can't be read right now */
|
|
3768
|
+
expiring?: {
|
|
3769
|
+
certificates?: components["schemas"]["ExpiryCounts"];
|
|
3770
|
+
domains?: components["schemas"]["ExpiryCounts"];
|
|
3771
|
+
/** @description The ten soonest expiries across both kinds, expired first */
|
|
3772
|
+
soonest?: {
|
|
3773
|
+
/** Format: uuid */
|
|
3774
|
+
monitor_id?: string;
|
|
3775
|
+
name?: string;
|
|
3776
|
+
/** @enum {string} */
|
|
3777
|
+
kind?: "certificate" | "domain";
|
|
3778
|
+
target?: string;
|
|
3779
|
+
/** Format: date-time */
|
|
3780
|
+
expires_at?: string;
|
|
3781
|
+
/** @description Negative once expired */
|
|
3782
|
+
days_left?: number;
|
|
3783
|
+
}[];
|
|
3784
|
+
} | null;
|
|
3785
|
+
};
|
|
3786
|
+
ExpiryCounts: {
|
|
3787
|
+
/** @description Monitors with a known expiry */
|
|
3788
|
+
monitored?: number;
|
|
3789
|
+
expired?: number;
|
|
3790
|
+
within_7_days?: number;
|
|
3791
|
+
/** @description 7 to 29 days left (buckets don't overlap) */
|
|
3792
|
+
within_30_days?: number;
|
|
2991
3793
|
};
|
|
2992
3794
|
IncidentStats: {
|
|
2993
3795
|
/** @constant */
|
|
@@ -3202,6 +4004,8 @@ export interface components {
|
|
|
3202
4004
|
/** @description Per-location breakdown for the whole window (not paginated) */
|
|
3203
4005
|
locations?: {
|
|
3204
4006
|
location?: string;
|
|
4007
|
+
location_name?: string;
|
|
4008
|
+
location_country_code?: string;
|
|
3205
4009
|
checks?: number;
|
|
3206
4010
|
success_percent?: number;
|
|
3207
4011
|
/**
|
|
@@ -3482,7 +4286,7 @@ export interface components {
|
|
|
3482
4286
|
};
|
|
3483
4287
|
responses: never;
|
|
3484
4288
|
parameters: {
|
|
3485
|
-
/** @description OAuth tokens only: the id of the organization to act on. The token's user must be a member (otherwise 403 forbidden), and their role there applies — members can read, acknowledge incidents and
|
|
4289
|
+
/** @description OAuth tokens only: the id of the organization to act on. The token's user must be a member (otherwise 403 forbidden), and their role there applies — members can read, acknowledge incidents, run diagnostics and write post-mortems; creating, changing and deleting needs owner or admin, as in the dashboard. Omitted: the user's oldest owned organization, else their oldest membership. With an API key the header may only repeat the key's own organization id (anything else is 403). */
|
|
3486
4290
|
OrganizationHeader: string;
|
|
3487
4291
|
};
|
|
3488
4292
|
requestBodies: never;
|
|
@@ -5050,6 +5854,83 @@ export interface operations {
|
|
|
5050
5854
|
};
|
|
5051
5855
|
};
|
|
5052
5856
|
};
|
|
5857
|
+
getIncidentPostmortem: {
|
|
5858
|
+
parameters: {
|
|
5859
|
+
query?: never;
|
|
5860
|
+
header?: never;
|
|
5861
|
+
path: {
|
|
5862
|
+
/** @description Incident id (integer) */
|
|
5863
|
+
id: string;
|
|
5864
|
+
};
|
|
5865
|
+
cookie?: never;
|
|
5866
|
+
};
|
|
5867
|
+
requestBody?: never;
|
|
5868
|
+
responses: {
|
|
5869
|
+
/** @description OK */
|
|
5870
|
+
200: {
|
|
5871
|
+
headers: {
|
|
5872
|
+
[name: string]: unknown;
|
|
5873
|
+
};
|
|
5874
|
+
content: {
|
|
5875
|
+
"application/json": components["schemas"]["Postmortem"];
|
|
5876
|
+
};
|
|
5877
|
+
};
|
|
5878
|
+
/** @description Error */
|
|
5879
|
+
default: {
|
|
5880
|
+
headers: {
|
|
5881
|
+
[name: string]: unknown;
|
|
5882
|
+
};
|
|
5883
|
+
content: {
|
|
5884
|
+
"application/json": components["schemas"]["Error"];
|
|
5885
|
+
};
|
|
5886
|
+
};
|
|
5887
|
+
};
|
|
5888
|
+
};
|
|
5889
|
+
updateIncidentPostmortem: {
|
|
5890
|
+
parameters: {
|
|
5891
|
+
query?: never;
|
|
5892
|
+
header?: never;
|
|
5893
|
+
path: {
|
|
5894
|
+
/** @description Incident id (integer) */
|
|
5895
|
+
id: string;
|
|
5896
|
+
};
|
|
5897
|
+
cookie?: never;
|
|
5898
|
+
};
|
|
5899
|
+
requestBody?: {
|
|
5900
|
+
content: {
|
|
5901
|
+
"application/json": components["schemas"]["PostmortemUpdate"];
|
|
5902
|
+
};
|
|
5903
|
+
};
|
|
5904
|
+
responses: {
|
|
5905
|
+
/** @description Updated (or unchanged) */
|
|
5906
|
+
200: {
|
|
5907
|
+
headers: {
|
|
5908
|
+
[name: string]: unknown;
|
|
5909
|
+
};
|
|
5910
|
+
content: {
|
|
5911
|
+
"application/json": components["schemas"]["Postmortem"];
|
|
5912
|
+
};
|
|
5913
|
+
};
|
|
5914
|
+
/** @description Created the draft */
|
|
5915
|
+
201: {
|
|
5916
|
+
headers: {
|
|
5917
|
+
[name: string]: unknown;
|
|
5918
|
+
};
|
|
5919
|
+
content: {
|
|
5920
|
+
"application/json": components["schemas"]["Postmortem"];
|
|
5921
|
+
};
|
|
5922
|
+
};
|
|
5923
|
+
/** @description Error */
|
|
5924
|
+
default: {
|
|
5925
|
+
headers: {
|
|
5926
|
+
[name: string]: unknown;
|
|
5927
|
+
};
|
|
5928
|
+
content: {
|
|
5929
|
+
"application/json": components["schemas"]["Error"];
|
|
5930
|
+
};
|
|
5931
|
+
};
|
|
5932
|
+
};
|
|
5933
|
+
};
|
|
5053
5934
|
markIncidentMaintenance: {
|
|
5054
5935
|
parameters: {
|
|
5055
5936
|
query?: never;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "watchfor",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.17.1",
|
|
4
4
|
"description": "Official TypeScript SDK + CLI for WatchFor — uptime & infrastructure monitoring (monitors, alert rules, incidents, maintenance windows) over the REST API.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"watchfor",
|