@sylphx/contract 0.2.0 → 0.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/CHANGELOG.md +6 -0
- package/dist/endpoint.d.ts +13 -1
- package/dist/endpoint.d.ts.map +1 -1
- package/dist/endpoints/admin-ai-playground.d.ts +3 -3
- package/dist/endpoints/admin-ai-playground.js +6 -6
- package/dist/endpoints/admin-anomalies.d.ts +7 -7
- package/dist/endpoints/admin-anomalies.js +14 -14
- package/dist/endpoints/admin-apm.d.ts +6 -6
- package/dist/endpoints/admin-apm.js +12 -12
- package/dist/endpoints/admin-audit.d.ts +185 -52
- package/dist/endpoints/admin-audit.d.ts.map +1 -1
- package/dist/endpoints/admin-audit.js +113 -113
- package/dist/endpoints/admin-billing.d.ts +19 -19
- package/dist/endpoints/admin-billing.js +38 -38
- package/dist/endpoints/admin-bootstrap.d.ts +1 -1
- package/dist/endpoints/admin-bootstrap.js +2 -2
- package/dist/endpoints/admin-broadcasts.d.ts +5 -5
- package/dist/endpoints/admin-broadcasts.js +10 -10
- package/dist/endpoints/admin-builds.d.ts +1 -1
- package/dist/endpoints/admin-builds.js +2 -2
- package/dist/endpoints/admin-config.d.ts +11 -11
- package/dist/endpoints/admin-config.js +22 -22
- package/dist/endpoints/admin-consent.d.ts +38 -14
- package/dist/endpoints/admin-consent.d.ts.map +1 -1
- package/dist/endpoints/admin-consent.js +27 -27
- package/dist/endpoints/admin-env-services.d.ts +1 -1
- package/dist/endpoints/admin-env-services.js +2 -2
- package/dist/endpoints/admin-impersonation.d.ts +9 -9
- package/dist/endpoints/admin-impersonation.js +18 -18
- package/dist/endpoints/admin-invitations.d.ts +5 -5
- package/dist/endpoints/admin-invitations.js +10 -10
- package/dist/endpoints/admin-jwt-keys.d.ts +6 -6
- package/dist/endpoints/admin-jwt-keys.js +12 -12
- package/dist/endpoints/admin-logs.d.ts +7 -7
- package/dist/endpoints/admin-logs.js +14 -14
- package/dist/endpoints/admin-plans.d.ts +4 -4
- package/dist/endpoints/admin-plans.js +8 -8
- package/dist/endpoints/admin-project-users.d.ts +8 -8
- package/dist/endpoints/admin-project-users.js +16 -16
- package/dist/endpoints/admin-projects.d.ts +36 -7
- package/dist/endpoints/admin-projects.d.ts.map +1 -1
- package/dist/endpoints/admin-projects.js +44 -15
- package/dist/endpoints/admin-quotas.d.ts +6 -6
- package/dist/endpoints/admin-quotas.js +12 -12
- package/dist/endpoints/admin-rate-limits.d.ts +2 -2
- package/dist/endpoints/admin-rate-limits.js +4 -4
- package/dist/endpoints/admin-reconcile.d.ts +1 -1
- package/dist/endpoints/admin-reconcile.js +2 -2
- package/dist/endpoints/admin-resources.d.ts +2 -2
- package/dist/endpoints/admin-resources.js +4 -4
- package/dist/endpoints/admin-secrets.d.ts +2 -2
- package/dist/endpoints/admin-secrets.js +4 -4
- package/dist/endpoints/admin-services.d.ts +1 -1
- package/dist/endpoints/admin-services.js +2 -2
- package/dist/endpoints/admin-tasks.d.ts +6 -6
- package/dist/endpoints/admin-tasks.js +12 -12
- package/dist/endpoints/admin-tenants.d.ts +1 -1
- package/dist/endpoints/admin-tenants.js +2 -2
- package/dist/endpoints/admin-traces.d.ts +5 -5
- package/dist/endpoints/admin-traces.js +10 -10
- package/dist/endpoints/admin-users.d.ts +8 -8
- package/dist/endpoints/admin-users.js +16 -16
- package/dist/endpoints/admin-webhook-signature-versions.d.ts +3 -3
- package/dist/endpoints/admin-webhook-signature-versions.js +6 -6
- package/dist/endpoints/auth.d.ts +6 -0
- package/dist/endpoints/auth.d.ts.map +1 -1
- package/dist/endpoints/auth.js +12 -1
- package/dist/endpoints/branch-databases.d.ts +27 -28
- package/dist/endpoints/branch-databases.d.ts.map +1 -1
- package/dist/endpoints/branch-databases.js +7 -7
- package/dist/endpoints/databases.d.ts +253 -3
- package/dist/endpoints/databases.d.ts.map +1 -1
- package/dist/endpoints/databases.js +19 -12
- package/dist/endpoints/environments.d.ts +9 -0
- package/dist/endpoints/environments.d.ts.map +1 -1
- package/dist/endpoints/organizations.d.ts +11 -0
- package/dist/endpoints/organizations.d.ts.map +1 -1
- package/dist/endpoints/organizations.js +8 -1
- package/dist/endpoints/project-manifest.d.ts +42 -34
- package/dist/endpoints/project-manifest.d.ts.map +1 -1
- package/dist/endpoints/secrets.d.ts +6 -6
- package/dist/endpoints/secrets.d.ts.map +1 -1
- package/dist/endpoints/secrets.js +6 -5
- package/dist/endpoints/storage.d.ts +4 -6
- package/dist/endpoints/storage.d.ts.map +1 -1
- package/dist/endpoints/storage.js +1 -12
- package/dist/hono-app.d.ts +206 -0
- package/dist/hono-app.d.ts.map +1 -0
- package/dist/hono-app.js +62 -0
- package/dist/index.d.ts +503 -278
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +10 -4
- package/dist/schemas/admin-audit.d.ts +183 -0
- package/dist/schemas/admin-audit.d.ts.map +1 -1
- package/dist/schemas/admin-audit.js +144 -0
- package/dist/schemas/admin-consent.d.ts +32 -3
- package/dist/schemas/admin-consent.d.ts.map +1 -1
- package/dist/schemas/admin-consent.js +28 -1
- package/dist/schemas/admin-projects.d.ts +20 -0
- package/dist/schemas/admin-projects.d.ts.map +1 -1
- package/dist/schemas/admin-projects.js +17 -0
- package/dist/schemas/auth.d.ts +11 -0
- package/dist/schemas/auth.d.ts.map +1 -1
- package/dist/schemas/auth.js +10 -0
- package/dist/schemas/branch-database.d.ts +20 -19
- package/dist/schemas/branch-database.d.ts.map +1 -1
- package/dist/schemas/branch-database.js +9 -7
- package/dist/schemas/environment.d.ts +6 -0
- package/dist/schemas/environment.d.ts.map +1 -1
- package/dist/schemas/environment.js +2 -0
- package/dist/schemas/ids.d.ts +2 -0
- package/dist/schemas/ids.d.ts.map +1 -1
- package/dist/schemas/ids.js +1 -0
- package/dist/schemas/organization.d.ts +24 -2
- package/dist/schemas/organization.d.ts.map +1 -1
- package/dist/schemas/organization.js +13 -1
- package/dist/schemas/project-manifest.d.ts +59 -37
- package/dist/schemas/project-manifest.d.ts.map +1 -1
- package/dist/schemas/project-manifest.js +11 -3
- package/dist/schemas/secret.d.ts +1 -1
- package/dist/schemas/secret.js +2 -2
- package/dist/schemas/storage.d.ts +4 -5
- package/dist/schemas/storage.d.ts.map +1 -1
- package/dist/schemas/storage.js +5 -4
- package/package.json +16 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @sylphx/contract
|
|
2
2
|
|
|
3
|
+
## 0.3.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`03dbd29`](https://github.com/SylphxAI/platform/commit/03dbd2986024fa650378e10958890d6ac063f516) Thanks [@shtse8](https://github.com/shtse8)! - Add a privacy-preserving public auth resend-verification contract and SDK helper.
|
|
8
|
+
|
|
3
9
|
## 0.2.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
package/dist/endpoint.d.ts
CHANGED
|
@@ -46,6 +46,12 @@ export interface Endpoint<Method extends HttpMethod = HttpMethod, Path extends s
|
|
|
46
46
|
* that customers never consume (super-admin platform administration).
|
|
47
47
|
*/
|
|
48
48
|
readonly plane?: 'management' | 'baas' | 'admin';
|
|
49
|
+
/**
|
|
50
|
+
* OpenAPI security requirements. Omit for the default bearerAuth contract;
|
|
51
|
+
* use an empty array for deliberately public endpoints such as sign-in and
|
|
52
|
+
* email verification resend.
|
|
53
|
+
*/
|
|
54
|
+
readonly security?: readonly string[];
|
|
49
55
|
/** LLM-targeted description emitted as `x-agent-hint` (OpenAPI 4 forward-compat). */
|
|
50
56
|
readonly agentHint?: string;
|
|
51
57
|
}
|
|
@@ -60,6 +66,12 @@ export declare const defineEndpoint: <Method extends HttpMethod, Path extends st
|
|
|
60
66
|
/**
|
|
61
67
|
* A record of endpoints grouped by a capability namespace — e.g. the object
|
|
62
68
|
* exported from `endpoints/projects.ts`.
|
|
69
|
+
*
|
|
70
|
+
* Some capability namespaces are nested (`organizations.billing`,
|
|
71
|
+
* `security.passkeys`, etc.). Keep that hierarchy in the contract and let
|
|
72
|
+
* derivations such as `HonoAppFromEndpoints` recursively flatten it.
|
|
63
73
|
*/
|
|
64
|
-
export
|
|
74
|
+
export interface EndpointGroup {
|
|
75
|
+
readonly [key: string]: Endpoint | EndpointGroup;
|
|
76
|
+
}
|
|
65
77
|
//# sourceMappingURL=endpoint.d.ts.map
|
package/dist/endpoint.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"endpoint.d.ts","sourceRoot":"","sources":["../src/endpoint.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAEpC,qDAAqD;AACrD,MAAM,MAAM,UAAU,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAA;AAEpE;;;;;;;;GAQG;AACH,MAAM,WAAW,QAAQ,CACxB,MAAM,SAAS,UAAU,GAAG,UAAU,EACtC,IAAI,SAAS,MAAM,GAAG,MAAM,EAE5B,MAAM,SAAS,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC,GAAG,SAAS,GAAG,GAAG,EAE/D,KAAK,SAAS,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC,GAAG,SAAS,GAAG,GAAG,EAE9D,IAAI,SAAS,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC,GAAG,SAAS,GAAG,GAAG,EAE7D,QAAQ,SAAS,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC;IAEhF,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,IAAI,EAAE,IAAI,CAAA;IACnB,QAAQ,CAAC,MAAM,CAAC,EAAE,M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,MAAM,CAAA;IAC7B,QAAQ,CAAC,IAAI,CAAC,EAAE,SAAS,MAAM,EAAE,CAAA;IACjC;;;;;;;;;OASG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,YAAY,GAAG,MAAM,GAAG,OAAO,CAAA;IAChD;;;;OAIG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,SAAS,MAAM,EAAE,CAAA;IACrC,qFAAqF;IACrF,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAC3B;AAED;;;;;;GAMG;AACH,eAAO,MAAM,cAAc,GAC1B,MAAM,SAAS,UAAU,EACzB,IAAI,SAAS,MAAM,EACnB,MAAM,SAAS,MAAM,CAAC,MAAM,CAAC,YAAY,GAAG,SAAS,EACrD,KAAK,SAAS,MAAM,CAAC,MAAM,CAAC,YAAY,GAAG,SAAS,EACpD,IAAI,SAAS,MAAM,CAAC,MAAM,CAAC,YAAY,GAAG,SAAS,EACnD,QAAQ,SAAS,MAAM,CAAC,MAAM,CAAC,YAAY,EAE3C,UAAU,QAAQ,CAAC,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,CAAC,KAC7D,QAAQ,CAAC,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,CAAa,CAAA;AAEpE;;;;;;;GAOG;AACH,MAAM,WAAW,aAAa;IAC7B,QAAQ,EAAE,GAAG,EAAE,MAAM,GAAG,QAAQ,GAAG,aAAa,CAAA;CAChD"}
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* handler-side only — it emits `text/event-stream`, not JSON.
|
|
7
7
|
*/
|
|
8
8
|
export declare const adminAiPlaygroundEndpoints: {
|
|
9
|
-
readonly listModels: import("../endpoint.js").Endpoint<"GET", "/
|
|
9
|
+
readonly listModels: import("../endpoint.js").Endpoint<"GET", "/operator/ai-playground/models", import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
10
10
|
models: import("effect/Schema").Array$<import("effect/Schema").Struct<{
|
|
11
11
|
id: typeof import("effect/Schema").String;
|
|
12
12
|
name: typeof import("effect/Schema").String;
|
|
@@ -22,7 +22,7 @@ export declare const adminAiPlaygroundEndpoints: {
|
|
|
22
22
|
outputCostPer1M: typeof import("effect/Schema").Number;
|
|
23
23
|
}>>;
|
|
24
24
|
}>>;
|
|
25
|
-
readonly chat: import("../endpoint.js").Endpoint<"POST", "/
|
|
25
|
+
readonly chat: import("../endpoint.js").Endpoint<"POST", "/operator/ai-playground/chat", import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
26
26
|
projectId: typeof import("effect/Schema").String;
|
|
27
27
|
model: typeof import("effect/Schema").String;
|
|
28
28
|
messages: import("effect/Schema").Array$<import("effect/Schema").Struct<{
|
|
@@ -62,7 +62,7 @@ export declare const adminAiPlaygroundEndpoints: {
|
|
|
62
62
|
arguments: import("effect/Schema").Record$<typeof import("effect/Schema").String, typeof import("effect/Schema").Unknown>;
|
|
63
63
|
}>>>;
|
|
64
64
|
}>>;
|
|
65
|
-
readonly chatStream: import("../endpoint.js").Endpoint<"POST", "/
|
|
65
|
+
readonly chatStream: import("../endpoint.js").Endpoint<"POST", "/operator/ai-playground/chat/stream", import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
66
66
|
projectId: typeof import("effect/Schema").String;
|
|
67
67
|
model: typeof import("effect/Schema").String;
|
|
68
68
|
messages: import("effect/Schema").Array$<import("effect/Schema").Struct<{
|
|
@@ -10,27 +10,27 @@ import { AdminListModelsResult, AdminPlaygroundChatInput, AdminPlaygroundChatRes
|
|
|
10
10
|
export const adminAiPlaygroundEndpoints = {
|
|
11
11
|
listModels: defineEndpoint({
|
|
12
12
|
method: 'GET',
|
|
13
|
-
path: '/
|
|
13
|
+
path: '/operator/ai-playground/models',
|
|
14
14
|
response: AdminListModelsResult,
|
|
15
|
-
plane: '
|
|
15
|
+
plane: 'management',
|
|
16
16
|
summary: 'List AI models available in the playground',
|
|
17
17
|
tags: ['admin-ai-playground'],
|
|
18
18
|
}),
|
|
19
19
|
chat: defineEndpoint({
|
|
20
20
|
method: 'POST',
|
|
21
|
-
path: '/
|
|
21
|
+
path: '/operator/ai-playground/chat',
|
|
22
22
|
body: AdminPlaygroundChatInput,
|
|
23
23
|
response: AdminPlaygroundChatResult,
|
|
24
|
-
plane: '
|
|
24
|
+
plane: 'management',
|
|
25
25
|
summary: 'Non-streaming chat completion in playground',
|
|
26
26
|
tags: ['admin-ai-playground'],
|
|
27
27
|
}),
|
|
28
28
|
chatStream: defineEndpoint({
|
|
29
29
|
method: 'POST',
|
|
30
|
-
path: '/
|
|
30
|
+
path: '/operator/ai-playground/chat/stream',
|
|
31
31
|
body: AdminPlaygroundChatInput,
|
|
32
32
|
response: AdminPlaygroundStreamResult,
|
|
33
|
-
plane: '
|
|
33
|
+
plane: 'management',
|
|
34
34
|
summary: 'Initialise a streaming chat completion (returns streamId)',
|
|
35
35
|
tags: ['admin-ai-playground'],
|
|
36
36
|
}),
|
|
@@ -5,14 +5,14 @@
|
|
|
5
5
|
* Production mount: `/admin/anomalies/*`.
|
|
6
6
|
*/
|
|
7
7
|
export declare const adminAnomaliesEndpoints: {
|
|
8
|
-
readonly stats: import("../endpoint.js").Endpoint<"GET", "/
|
|
8
|
+
readonly stats: import("../endpoint.js").Endpoint<"GET", "/operator/anomalies/stats", import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
9
9
|
open: typeof import("effect/Schema").Number;
|
|
10
10
|
acknowledged: typeof import("effect/Schema").Number;
|
|
11
11
|
resolved: typeof import("effect/Schema").Number;
|
|
12
12
|
dismissed: typeof import("effect/Schema").Number;
|
|
13
13
|
total: typeof import("effect/Schema").Number;
|
|
14
14
|
}>>;
|
|
15
|
-
readonly list: import("../endpoint.js").Endpoint<"GET", "/
|
|
15
|
+
readonly list: import("../endpoint.js").Endpoint<"GET", "/operator/anomalies/", import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
16
16
|
page: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
17
17
|
limit: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
18
18
|
status: import("effect/Schema").optional<import("effect/Schema").Literal<["all", "open", "acknowledged", "resolved", "dismissed"]>>;
|
|
@@ -41,7 +41,7 @@ export declare const adminAnomaliesEndpoints: {
|
|
|
41
41
|
totalPages: typeof import("effect/Schema").Number;
|
|
42
42
|
}>;
|
|
43
43
|
}>>;
|
|
44
|
-
readonly get: import("../endpoint.js").Endpoint<"GET", "/
|
|
44
|
+
readonly get: import("../endpoint.js").Endpoint<"GET", "/operator/anomalies/:anomalyId", import("effect/Schema").Struct<{
|
|
45
45
|
anomalyId: typeof import("effect/Schema").String;
|
|
46
46
|
}>, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
47
47
|
id: typeof import("effect/Schema").String;
|
|
@@ -59,19 +59,19 @@ export declare const adminAnomaliesEndpoints: {
|
|
|
59
59
|
resolutionNotes: import("effect/Schema").NullOr<typeof import("effect/Schema").String>;
|
|
60
60
|
createdAt: typeof import("effect/Schema").String;
|
|
61
61
|
}>>;
|
|
62
|
-
readonly acknowledge: import("../endpoint.js").Endpoint<"POST", "/
|
|
62
|
+
readonly acknowledge: import("../endpoint.js").Endpoint<"POST", "/operator/anomalies/:anomalyId/acknowledge", import("effect/Schema").Struct<{
|
|
63
63
|
anomalyId: typeof import("effect/Schema").String;
|
|
64
64
|
}>, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
65
65
|
success: typeof import("effect/Schema").Boolean;
|
|
66
66
|
status: import("effect/Schema").Literal<["open", "acknowledged", "resolved", "dismissed"]>;
|
|
67
67
|
}>>;
|
|
68
|
-
readonly dismiss: import("../endpoint.js").Endpoint<"POST", "/
|
|
68
|
+
readonly dismiss: import("../endpoint.js").Endpoint<"POST", "/operator/anomalies/:anomalyId/dismiss", import("effect/Schema").Struct<{
|
|
69
69
|
anomalyId: typeof import("effect/Schema").String;
|
|
70
70
|
}>, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
71
71
|
success: typeof import("effect/Schema").Boolean;
|
|
72
72
|
status: import("effect/Schema").Literal<["open", "acknowledged", "resolved", "dismissed"]>;
|
|
73
73
|
}>>;
|
|
74
|
-
readonly resolve: import("../endpoint.js").Endpoint<"POST", "/
|
|
74
|
+
readonly resolve: import("../endpoint.js").Endpoint<"POST", "/operator/anomalies/:anomalyId/resolve", import("effect/Schema").Struct<{
|
|
75
75
|
anomalyId: typeof import("effect/Schema").String;
|
|
76
76
|
}>, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
77
77
|
notes: typeof import("effect/Schema").String;
|
|
@@ -79,7 +79,7 @@ export declare const adminAnomaliesEndpoints: {
|
|
|
79
79
|
success: typeof import("effect/Schema").Boolean;
|
|
80
80
|
status: import("effect/Schema").Literal<["open", "acknowledged", "resolved", "dismissed"]>;
|
|
81
81
|
}>>;
|
|
82
|
-
readonly errorsOverview: import("../endpoint.js").Endpoint<"GET", "/
|
|
82
|
+
readonly errorsOverview: import("../endpoint.js").Endpoint<"GET", "/operator/anomalies/errors/overview", import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Schema.AnyNoContext | undefined, import("effect/Schema").Struct<{
|
|
83
83
|
total: typeof import("effect/Schema").Number;
|
|
84
84
|
unresolved: typeof import("effect/Schema").Number;
|
|
85
85
|
bySeverity: import("effect/Schema").Record$<typeof import("effect/Schema").String, typeof import("effect/Schema").Number>;
|
|
@@ -9,63 +9,63 @@ import { AdminAnomalyActionResult, AdminAnomalyIdParams, AdminAnomalyStatsResult
|
|
|
9
9
|
export const adminAnomaliesEndpoints = {
|
|
10
10
|
stats: defineEndpoint({
|
|
11
11
|
method: 'GET',
|
|
12
|
-
path: '/
|
|
12
|
+
path: '/operator/anomalies/stats',
|
|
13
13
|
response: AdminAnomalyStatsResult,
|
|
14
|
-
plane: '
|
|
14
|
+
plane: 'management',
|
|
15
15
|
summary: 'Anomaly counts by status',
|
|
16
16
|
tags: ['admin-anomalies'],
|
|
17
17
|
}),
|
|
18
18
|
list: defineEndpoint({
|
|
19
19
|
method: 'GET',
|
|
20
|
-
path: '/
|
|
20
|
+
path: '/operator/anomalies/',
|
|
21
21
|
query: AdminListAnomaliesQuery,
|
|
22
22
|
response: AdminListAnomaliesResult,
|
|
23
|
-
plane: '
|
|
23
|
+
plane: 'management',
|
|
24
24
|
summary: 'List spending anomalies with filters + pagination',
|
|
25
25
|
tags: ['admin-anomalies'],
|
|
26
26
|
}),
|
|
27
27
|
get: defineEndpoint({
|
|
28
28
|
method: 'GET',
|
|
29
|
-
path: '/
|
|
29
|
+
path: '/operator/anomalies/:anomalyId',
|
|
30
30
|
params: AdminAnomalyIdParams,
|
|
31
31
|
response: AdminGetAnomalyResult,
|
|
32
|
-
plane: '
|
|
32
|
+
plane: 'management',
|
|
33
33
|
summary: 'Get a single anomaly by ID',
|
|
34
34
|
tags: ['admin-anomalies'],
|
|
35
35
|
}),
|
|
36
36
|
acknowledge: defineEndpoint({
|
|
37
37
|
method: 'POST',
|
|
38
|
-
path: '/
|
|
38
|
+
path: '/operator/anomalies/:anomalyId/acknowledge',
|
|
39
39
|
params: AdminAnomalyIdParams,
|
|
40
40
|
response: AdminAnomalyActionResult,
|
|
41
|
-
plane: '
|
|
41
|
+
plane: 'management',
|
|
42
42
|
summary: 'Mark an anomaly as acknowledged',
|
|
43
43
|
tags: ['admin-anomalies'],
|
|
44
44
|
}),
|
|
45
45
|
dismiss: defineEndpoint({
|
|
46
46
|
method: 'POST',
|
|
47
|
-
path: '/
|
|
47
|
+
path: '/operator/anomalies/:anomalyId/dismiss',
|
|
48
48
|
params: AdminAnomalyIdParams,
|
|
49
49
|
response: AdminAnomalyActionResult,
|
|
50
|
-
plane: '
|
|
50
|
+
plane: 'management',
|
|
51
51
|
summary: 'Dismiss an anomaly as a false positive',
|
|
52
52
|
tags: ['admin-anomalies'],
|
|
53
53
|
}),
|
|
54
54
|
resolve: defineEndpoint({
|
|
55
55
|
method: 'POST',
|
|
56
|
-
path: '/
|
|
56
|
+
path: '/operator/anomalies/:anomalyId/resolve',
|
|
57
57
|
params: AdminAnomalyIdParams,
|
|
58
58
|
body: AdminResolveAnomalyInput,
|
|
59
59
|
response: AdminAnomalyActionResult,
|
|
60
|
-
plane: '
|
|
60
|
+
plane: 'management',
|
|
61
61
|
summary: 'Resolve an anomaly with notes',
|
|
62
62
|
tags: ['admin-anomalies'],
|
|
63
63
|
}),
|
|
64
64
|
errorsOverview: defineEndpoint({
|
|
65
65
|
method: 'GET',
|
|
66
|
-
path: '/
|
|
66
|
+
path: '/operator/anomalies/errors/overview',
|
|
67
67
|
response: AdminErrorsOverviewResult,
|
|
68
|
-
plane: '
|
|
68
|
+
plane: 'management',
|
|
69
69
|
summary: 'Cross-project error monitoring overview',
|
|
70
70
|
tags: ['admin-anomalies'],
|
|
71
71
|
}),
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Production mount: `/admin/apm/*`.
|
|
6
6
|
*/
|
|
7
7
|
export declare const adminApmEndpoints: {
|
|
8
|
-
readonly overview: import("../endpoint.js").Endpoint<"GET", "/
|
|
8
|
+
readonly overview: import("../endpoint.js").Endpoint<"GET", "/operator/apm/:projectId/overview", import("effect/Schema").Struct<{
|
|
9
9
|
projectId: typeof import("effect/Schema").String;
|
|
10
10
|
}>, import("effect/Schema").Struct<{
|
|
11
11
|
startDate: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
@@ -24,7 +24,7 @@ export declare const adminApmEndpoints: {
|
|
|
24
24
|
end: typeof import("effect/Schema").String;
|
|
25
25
|
}>;
|
|
26
26
|
}>>;
|
|
27
|
-
readonly endpoints: import("../endpoint.js").Endpoint<"GET", "/
|
|
27
|
+
readonly endpoints: import("../endpoint.js").Endpoint<"GET", "/operator/apm/:projectId/endpoints", import("effect/Schema").Struct<{
|
|
28
28
|
projectId: typeof import("effect/Schema").String;
|
|
29
29
|
}>, import("effect/Schema").Struct<{
|
|
30
30
|
startDate: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
@@ -46,7 +46,7 @@ export declare const adminApmEndpoints: {
|
|
|
46
46
|
total: typeof import("effect/Schema").Number;
|
|
47
47
|
hasMore: typeof import("effect/Schema").Boolean;
|
|
48
48
|
}>>;
|
|
49
|
-
readonly endpointTrend: import("../endpoint.js").Endpoint<"GET", "/
|
|
49
|
+
readonly endpointTrend: import("../endpoint.js").Endpoint<"GET", "/operator/apm/:projectId/endpoints/trend", import("effect/Schema").Struct<{
|
|
50
50
|
projectId: typeof import("effect/Schema").String;
|
|
51
51
|
}>, import("effect/Schema").Struct<{
|
|
52
52
|
startDate: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
@@ -62,7 +62,7 @@ export declare const adminApmEndpoints: {
|
|
|
62
62
|
p95Ms: typeof import("effect/Schema").Number;
|
|
63
63
|
p99Ms: typeof import("effect/Schema").Number;
|
|
64
64
|
}>>>;
|
|
65
|
-
readonly slowestEndpoints: import("../endpoint.js").Endpoint<"GET", "/
|
|
65
|
+
readonly slowestEndpoints: import("../endpoint.js").Endpoint<"GET", "/operator/apm/:projectId/endpoints/slowest", import("effect/Schema").Struct<{
|
|
66
66
|
projectId: typeof import("effect/Schema").String;
|
|
67
67
|
}>, import("effect/Schema").Struct<{
|
|
68
68
|
startDate: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
@@ -75,7 +75,7 @@ export declare const adminApmEndpoints: {
|
|
|
75
75
|
p95Ms: typeof import("effect/Schema").Number;
|
|
76
76
|
requestCount: typeof import("effect/Schema").Number;
|
|
77
77
|
}>>>;
|
|
78
|
-
readonly errorEndpoints: import("../endpoint.js").Endpoint<"GET", "/
|
|
78
|
+
readonly errorEndpoints: import("../endpoint.js").Endpoint<"GET", "/operator/apm/:projectId/endpoints/errors", import("effect/Schema").Struct<{
|
|
79
79
|
projectId: typeof import("effect/Schema").String;
|
|
80
80
|
}>, import("effect/Schema").Struct<{
|
|
81
81
|
startDate: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
@@ -88,7 +88,7 @@ export declare const adminApmEndpoints: {
|
|
|
88
88
|
errorRate: typeof import("effect/Schema").Number;
|
|
89
89
|
requestCount: typeof import("effect/Schema").Number;
|
|
90
90
|
}>>>;
|
|
91
|
-
readonly hourlyVolume: import("../endpoint.js").Endpoint<"GET", "/
|
|
91
|
+
readonly hourlyVolume: import("../endpoint.js").Endpoint<"GET", "/operator/apm/:projectId/volume", import("effect/Schema").Struct<{
|
|
92
92
|
projectId: typeof import("effect/Schema").String;
|
|
93
93
|
}>, import("effect/Schema").Struct<{
|
|
94
94
|
startDate: import("effect/Schema").optional<typeof import("effect/Schema").String>;
|
|
@@ -9,61 +9,61 @@ import { AdminApmDateRangeQuery, AdminApmEndpointsQuery, AdminApmEndpointsResult
|
|
|
9
9
|
export const adminApmEndpoints = {
|
|
10
10
|
overview: defineEndpoint({
|
|
11
11
|
method: 'GET',
|
|
12
|
-
path: '/
|
|
12
|
+
path: '/operator/apm/:projectId/overview',
|
|
13
13
|
params: AdminApmProjectParams,
|
|
14
14
|
query: AdminApmDateRangeQuery,
|
|
15
15
|
response: AdminApmOverviewResult,
|
|
16
|
-
plane: '
|
|
16
|
+
plane: 'management',
|
|
17
17
|
summary: 'APM overview — totals, error rate, latency percentiles',
|
|
18
18
|
tags: ['admin-apm'],
|
|
19
19
|
}),
|
|
20
20
|
endpoints: defineEndpoint({
|
|
21
21
|
method: 'GET',
|
|
22
|
-
path: '/
|
|
22
|
+
path: '/operator/apm/:projectId/endpoints',
|
|
23
23
|
params: AdminApmProjectParams,
|
|
24
24
|
query: AdminApmEndpointsQuery,
|
|
25
25
|
response: AdminApmEndpointsResult,
|
|
26
|
-
plane: '
|
|
26
|
+
plane: 'management',
|
|
27
27
|
summary: 'Per-endpoint metrics breakdown with pagination',
|
|
28
28
|
tags: ['admin-apm'],
|
|
29
29
|
}),
|
|
30
30
|
endpointTrend: defineEndpoint({
|
|
31
31
|
method: 'GET',
|
|
32
|
-
path: '/
|
|
32
|
+
path: '/operator/apm/:projectId/endpoints/trend',
|
|
33
33
|
params: AdminApmProjectParams,
|
|
34
34
|
query: AdminApmEndpointTrendQuery,
|
|
35
35
|
response: AdminApmEndpointTrendResult,
|
|
36
|
-
plane: '
|
|
36
|
+
plane: 'management',
|
|
37
37
|
summary: 'Time series trend for a single endpoint',
|
|
38
38
|
tags: ['admin-apm'],
|
|
39
39
|
}),
|
|
40
40
|
slowestEndpoints: defineEndpoint({
|
|
41
41
|
method: 'GET',
|
|
42
|
-
path: '/
|
|
42
|
+
path: '/operator/apm/:projectId/endpoints/slowest',
|
|
43
43
|
params: AdminApmProjectParams,
|
|
44
44
|
query: AdminApmTopEndpointsQuery,
|
|
45
45
|
response: AdminApmSlowestEndpointsResult,
|
|
46
|
-
plane: '
|
|
46
|
+
plane: 'management',
|
|
47
47
|
summary: 'Endpoints with highest average latency',
|
|
48
48
|
tags: ['admin-apm'],
|
|
49
49
|
}),
|
|
50
50
|
errorEndpoints: defineEndpoint({
|
|
51
51
|
method: 'GET',
|
|
52
|
-
path: '/
|
|
52
|
+
path: '/operator/apm/:projectId/endpoints/errors',
|
|
53
53
|
params: AdminApmProjectParams,
|
|
54
54
|
query: AdminApmTopEndpointsQuery,
|
|
55
55
|
response: AdminApmErrorEndpointsResult,
|
|
56
|
-
plane: '
|
|
56
|
+
plane: 'management',
|
|
57
57
|
summary: 'Endpoints with highest error rates',
|
|
58
58
|
tags: ['admin-apm'],
|
|
59
59
|
}),
|
|
60
60
|
hourlyVolume: defineEndpoint({
|
|
61
61
|
method: 'GET',
|
|
62
|
-
path: '/
|
|
62
|
+
path: '/operator/apm/:projectId/volume',
|
|
63
63
|
params: AdminApmProjectParams,
|
|
64
64
|
query: AdminApmDateRangeQuery,
|
|
65
65
|
response: AdminApmHourlyVolumeResult,
|
|
66
|
-
plane: '
|
|
66
|
+
plane: 'management',
|
|
67
67
|
summary: 'Hourly request + error volume for charts',
|
|
68
68
|
tags: ['admin-apm'],
|
|
69
69
|
}),
|