@subscribeflow/sdk 1.2.0 → 1.3.0
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/dist/api-types.d.ts +148 -0
- package/dist/api-types.d.ts.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/api-types.d.ts
CHANGED
|
@@ -1910,6 +1910,32 @@ export interface paths {
|
|
|
1910
1910
|
patch?: never;
|
|
1911
1911
|
trace?: never;
|
|
1912
1912
|
};
|
|
1913
|
+
"/api/v1/admin/system-status": {
|
|
1914
|
+
parameters: {
|
|
1915
|
+
query?: never;
|
|
1916
|
+
header?: never;
|
|
1917
|
+
path?: never;
|
|
1918
|
+
cookie?: never;
|
|
1919
|
+
};
|
|
1920
|
+
/**
|
|
1921
|
+
* Worker heartbeat and email-queue backlog status
|
|
1922
|
+
* @description Live worker-heartbeat and email-backlog status for the platform-admin GUI (TF-572).
|
|
1923
|
+
*
|
|
1924
|
+
* ``get_worker_heartbeat_status`` never raises. ``get_email_backlog_status``
|
|
1925
|
+
* can (a DB error propagates), so it's guarded here specifically: this
|
|
1926
|
+
* endpoint exists to surface infrastructure problems and must not itself
|
|
1927
|
+
* 500 because of one — a DB hiccup degrades to an "unknown" backlog status
|
|
1928
|
+
* rather than hiding an otherwise-healthy worker reading behind a 500.
|
|
1929
|
+
*/
|
|
1930
|
+
get: operations["get_system_status_api_v1_admin_system_status_get"];
|
|
1931
|
+
put?: never;
|
|
1932
|
+
post?: never;
|
|
1933
|
+
delete?: never;
|
|
1934
|
+
options?: never;
|
|
1935
|
+
head?: never;
|
|
1936
|
+
patch?: never;
|
|
1937
|
+
trace?: never;
|
|
1938
|
+
};
|
|
1913
1939
|
}
|
|
1914
1940
|
export type webhooks = Record<string, never>;
|
|
1915
1941
|
export interface components {
|
|
@@ -2518,6 +2544,29 @@ export interface components {
|
|
|
2518
2544
|
*/
|
|
2519
2545
|
dns_records: components["schemas"]["DnsRecord"][];
|
|
2520
2546
|
};
|
|
2547
|
+
/**
|
|
2548
|
+
* EmailBacklogStatus
|
|
2549
|
+
* @description Email queue backlog status.
|
|
2550
|
+
*
|
|
2551
|
+
* ``status == "unknown"`` means the backlog query itself failed (e.g. a DB
|
|
2552
|
+
* outage) — distinct from ``stuck_count == 0``, which means the query ran
|
|
2553
|
+
* and found nothing stuck. Conflating the two would let a DB hiccup read as
|
|
2554
|
+
* "no backlog" instead of "we don't know", the same false-all-clear problem
|
|
2555
|
+
* ``WorkerHeartbeatStatus`` guards against.
|
|
2556
|
+
*/
|
|
2557
|
+
EmailBacklogStatus: {
|
|
2558
|
+
/**
|
|
2559
|
+
* Status
|
|
2560
|
+
* @enum {string}
|
|
2561
|
+
*/
|
|
2562
|
+
status: "ok" | "unknown";
|
|
2563
|
+
/** Stuck Count */
|
|
2564
|
+
stuck_count?: number | null;
|
|
2565
|
+
/** Oldest Stuck At */
|
|
2566
|
+
oldest_stuck_at: string | null;
|
|
2567
|
+
/** Threshold Minutes */
|
|
2568
|
+
threshold_minutes: number;
|
|
2569
|
+
};
|
|
2521
2570
|
/**
|
|
2522
2571
|
* EmailSendRequest
|
|
2523
2572
|
* @description Schema for sending a transactional email.
|
|
@@ -3665,6 +3714,14 @@ export interface components {
|
|
|
3665
3714
|
/** Status */
|
|
3666
3715
|
status: string;
|
|
3667
3716
|
};
|
|
3717
|
+
/**
|
|
3718
|
+
* SystemStatusResponse
|
|
3719
|
+
* @description Combined worker-heartbeat and email-backlog status for the admin GUI.
|
|
3720
|
+
*/
|
|
3721
|
+
SystemStatusResponse: {
|
|
3722
|
+
worker: components["schemas"]["WorkerHeartbeatStatus"];
|
|
3723
|
+
email_backlog: components["schemas"]["EmailBacklogStatus"];
|
|
3724
|
+
};
|
|
3668
3725
|
/**
|
|
3669
3726
|
* TagBrief
|
|
3670
3727
|
* @description Brief tag information for subscriber responses.
|
|
@@ -4456,6 +4513,28 @@ export interface components {
|
|
|
4456
4513
|
/** Error */
|
|
4457
4514
|
error?: string | null;
|
|
4458
4515
|
};
|
|
4516
|
+
/**
|
|
4517
|
+
* WorkerHeartbeatStatus
|
|
4518
|
+
* @description Worker/beat heartbeat freshness.
|
|
4519
|
+
*
|
|
4520
|
+
* ``status == "unknown"`` (Redis unreachable, or no heartbeat written yet)
|
|
4521
|
+
* must come with null timestamps, and every other status must come with
|
|
4522
|
+
* real ones — the validator below enforces that pairing so a caller cannot
|
|
4523
|
+
* construct e.g. "healthy" next to a null timestamp, which would render as
|
|
4524
|
+
* a false all-clear on the one page built to catch exactly that kind of
|
|
4525
|
+
* misleading state.
|
|
4526
|
+
*/
|
|
4527
|
+
WorkerHeartbeatStatus: {
|
|
4528
|
+
/**
|
|
4529
|
+
* Status
|
|
4530
|
+
* @enum {string}
|
|
4531
|
+
*/
|
|
4532
|
+
status: "healthy" | "stale" | "unknown";
|
|
4533
|
+
/** Last Heartbeat At */
|
|
4534
|
+
last_heartbeat_at: string | null;
|
|
4535
|
+
/** Seconds Since Heartbeat */
|
|
4536
|
+
seconds_since_heartbeat?: number | null;
|
|
4537
|
+
};
|
|
4459
4538
|
/** @description RFC 7807 Problem Details for HTTP APIs */
|
|
4460
4539
|
ProblemDetail: {
|
|
4461
4540
|
/**
|
|
@@ -13412,5 +13491,74 @@ export interface operations {
|
|
|
13412
13491
|
};
|
|
13413
13492
|
};
|
|
13414
13493
|
};
|
|
13494
|
+
get_system_status_api_v1_admin_system_status_get: {
|
|
13495
|
+
parameters: {
|
|
13496
|
+
query?: never;
|
|
13497
|
+
header?: never;
|
|
13498
|
+
path?: never;
|
|
13499
|
+
cookie?: never;
|
|
13500
|
+
};
|
|
13501
|
+
requestBody?: never;
|
|
13502
|
+
responses: {
|
|
13503
|
+
/** @description Successful Response */
|
|
13504
|
+
200: {
|
|
13505
|
+
headers: {
|
|
13506
|
+
[name: string]: unknown;
|
|
13507
|
+
};
|
|
13508
|
+
content: {
|
|
13509
|
+
"application/json": components["schemas"]["SystemStatusResponse"];
|
|
13510
|
+
};
|
|
13511
|
+
};
|
|
13512
|
+
/** @description Bad Request */
|
|
13513
|
+
400: {
|
|
13514
|
+
headers: {
|
|
13515
|
+
[name: string]: unknown;
|
|
13516
|
+
};
|
|
13517
|
+
content?: never;
|
|
13518
|
+
};
|
|
13519
|
+
/** @description Authentication Required */
|
|
13520
|
+
401: {
|
|
13521
|
+
headers: {
|
|
13522
|
+
[name: string]: unknown;
|
|
13523
|
+
};
|
|
13524
|
+
content?: never;
|
|
13525
|
+
};
|
|
13526
|
+
/** @description Access Denied */
|
|
13527
|
+
403: {
|
|
13528
|
+
headers: {
|
|
13529
|
+
[name: string]: unknown;
|
|
13530
|
+
};
|
|
13531
|
+
content?: never;
|
|
13532
|
+
};
|
|
13533
|
+
/** @description Resource Not Found */
|
|
13534
|
+
404: {
|
|
13535
|
+
headers: {
|
|
13536
|
+
[name: string]: unknown;
|
|
13537
|
+
};
|
|
13538
|
+
content?: never;
|
|
13539
|
+
};
|
|
13540
|
+
/** @description Resource Conflict */
|
|
13541
|
+
409: {
|
|
13542
|
+
headers: {
|
|
13543
|
+
[name: string]: unknown;
|
|
13544
|
+
};
|
|
13545
|
+
content?: never;
|
|
13546
|
+
};
|
|
13547
|
+
/** @description Validation Error */
|
|
13548
|
+
422: {
|
|
13549
|
+
headers: {
|
|
13550
|
+
[name: string]: unknown;
|
|
13551
|
+
};
|
|
13552
|
+
content?: never;
|
|
13553
|
+
};
|
|
13554
|
+
/** @description Internal Server Error */
|
|
13555
|
+
500: {
|
|
13556
|
+
headers: {
|
|
13557
|
+
[name: string]: unknown;
|
|
13558
|
+
};
|
|
13559
|
+
content?: never;
|
|
13560
|
+
};
|
|
13561
|
+
};
|
|
13562
|
+
};
|
|
13415
13563
|
}
|
|
13416
13564
|
//# sourceMappingURL=api-types.d.ts.map
|