@leaflow/sdk 0.0.0-dev.113.g5d6fb99 → 0.0.0-dev.15.g2ea7bad

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.
@@ -2,6 +2,8 @@ export type { paths, components, operations, webhooks } from "./schema.js";
2
2
  import type { operations } from "./schema.js";
3
3
  /** `GET /api/v1/incidents` 成功时的响应体。 */
4
4
  export type ListIncidentsResult = operations["list-incidents"]["responses"][200]["content"]["application/json"];
5
+ /** `GET /api/v1/incidents` 的查询参数。 */
6
+ export type ListIncidentsQuery = operations["list-incidents"]["parameters"]["query"];
5
7
  /** `GET /api/v1/incidents/{incidentId}` 成功时的响应体。 */
6
8
  export type GetIncidentResult = operations["get-incident"]["responses"][200]["content"]["application/json"];
7
9
  /** `POST /api/v1/incidents/{incidentId}/acknowledge` 成功时的响应体。 */
@@ -28,6 +30,8 @@ export type SetIncidentFollowingBody = NonNullable<operations["set-incident-foll
28
30
  export type ReopenIncidentResult = operations["reopen-incident"]["responses"][200]["content"]["application/json"];
29
31
  /** `GET /api/v1/incidents/{incidentId}/timeline` 成功时的响应体。 */
30
32
  export type ListIncidentTimelineResult = operations["list-incident-timeline"]["responses"][200]["content"]["application/json"];
33
+ /** `GET /api/v1/incidents/{incidentId}/timeline` 的查询参数。 */
34
+ export type ListIncidentTimelineQuery = operations["list-incident-timeline"]["parameters"]["query"];
31
35
  /** `GET /api/v1/maintenance-windows` 成功时的响应体。 */
32
36
  export type ListMaintenanceWindowsResult = operations["list-maintenance-windows"]["responses"][200]["content"]["application/json"];
33
37
  /** `GET /api/v1/maintenance-windows/{windowId}` 成功时的响应体。 */
@@ -40,16 +44,24 @@ export type PutMaintenanceWindowBody = NonNullable<operations["put-maintenance-w
40
44
  export type GetProjectOverviewResult = operations["get-project-overview"]["responses"][200]["content"]["application/json"];
41
45
  /** `GET /api/v1/servers/{serverId}/items` 成功时的响应体。 */
42
46
  export type ListServerItemsResult = operations["list-server-items"]["responses"][200]["content"]["application/json"];
47
+ /** `GET /api/v1/servers/{serverId}/items` 的查询参数。 */
48
+ export type ListServerItemsQuery = operations["list-server-items"]["parameters"]["query"];
43
49
  /** `GET /api/v1/servers/{serverId}/metrics` 成功时的响应体。 */
44
50
  export type GetServerMetricResult = operations["get-server-metric"]["responses"][200]["content"]["application/json"];
51
+ /** `GET /api/v1/servers/{serverId}/metrics` 的查询参数。 */
52
+ export type GetServerMetricQuery = operations["get-server-metric"]["parameters"]["query"];
45
53
  /** `GET /api/v1/servers/{serverId}/resources` 成功时的响应体。 */
46
54
  export type GetServerResourcesResult = operations["get-server-resources"]["responses"][200]["content"]["application/json"];
47
55
  /** `GET /api/v1/servers/{serverId}/snapshot` 成功时的响应体。 */
48
56
  export type GetServerSnapshotResult = operations["get-server-snapshot"]["responses"][200]["content"]["application/json"];
49
57
  /** `GET /api/v1/top-items` 成功时的响应体。 */
50
58
  export type ListProjectTopItemsResult = operations["list-project-top-items"]["responses"][200]["content"]["application/json"];
59
+ /** `GET /api/v1/top-items` 的查询参数。 */
60
+ export type ListProjectTopItemsQuery = operations["list-project-top-items"]["parameters"]["query"];
51
61
  /** `GET /api/v1/servers` 成功时的响应体。 */
52
62
  export type ListServersResult = operations["list-servers"]["responses"][200]["content"]["application/json"];
63
+ /** `GET /api/v1/servers` 的查询参数。 */
64
+ export type ListServersQuery = operations["list-servers"]["parameters"]["query"];
53
65
  /** `GET /api/v1/servers/{serverId}` 成功时的响应体。 */
54
66
  export type GetServerResult = operations["get-server"]["responses"][200]["content"]["application/json"];
55
67
  /** `PATCH /api/v1/servers/{serverId}` 成功时的响应体。 */
@@ -70,8 +82,12 @@ export type PutWebCheckResult = operations["put-web-check"]["responses"][200]["c
70
82
  export type PutWebCheckBody = NonNullable<operations["put-web-check"]["requestBody"]>["content"]["application/json"];
71
83
  /** `GET /api/v1/web-checks` 成功时的响应体。 */
72
84
  export type ListWebChecksResult = operations["list-web-checks"]["responses"][200]["content"]["application/json"];
85
+ /** `GET /api/v1/web-checks` 的查询参数。 */
86
+ export type ListWebChecksQuery = operations["list-web-checks"]["parameters"]["query"];
73
87
  /** `GET /api/v1/sli-report` 成功时的响应体。 */
74
88
  export type GetSliReportResult = operations["get-sli-report"]["responses"][200]["content"]["application/json"];
89
+ /** `GET /api/v1/sli-report` 的查询参数。 */
90
+ export type GetSliReportQuery = operations["get-sli-report"]["parameters"]["query"];
75
91
  /** `GET /api/v1/slo` 成功时的响应体。 */
76
92
  export type GetSloResult = operations["get-slo"]["responses"][200]["content"]["application/json"];
77
93
  /** `PUT /api/v1/slo` 成功时的响应体。 */
@@ -1014,7 +1014,8 @@ export interface components {
1014
1014
  last_error: string;
1015
1015
  /** Format: int64 */
1016
1016
  response_time_threshold_seconds: number;
1017
- result: components["schemas"]["WebCheckResultResource"];
1017
+ /** @description null 表示这个检查还一轮都没跑过。零值会把「还不知道」显示成「响应 0 秒、状态码 0」 */
1018
+ result: components["schemas"]["WebCheckResultResource"] | null;
1018
1019
  /** Format: int64 */
1019
1020
  retries: number;
1020
1021
  /** Format: uuid */
@@ -2,6 +2,8 @@ export type { paths, components, operations, webhooks } from "./schema.js";
2
2
  import type { operations } from "./schema.js";
3
3
  /** `GET /api/v1/operation-logs` 成功时的响应体。 */
4
4
  export type ListTunnelOperationLogsResult = operations["list-tunnel-operation-logs"]["responses"][200]["content"]["application/json"];
5
+ /** `GET /api/v1/operation-logs` 的查询参数。 */
6
+ export type ListTunnelOperationLogsQuery = operations["list-tunnel-operation-logs"]["parameters"]["query"];
5
7
  /** `GET /api/v1/plans` 成功时的响应体。 */
6
8
  export type ListTunnelPlansResult = operations["list-tunnel-plans"]["responses"][200]["content"]["application/json"];
7
9
  /** `DELETE /api/v1/tunnel` 成功时的响应体。 */
@@ -32,3 +34,5 @@ export type RotateTunnelSubscriptionResult = operations["rotate-tunnel-subscript
32
34
  export type GetTunnelUsageResult = operations["get-tunnel-usage"]["responses"][200]["content"]["application/json"];
33
35
  /** `GET /api/v1/tunnel/usage/series` 成功时的响应体。 */
34
36
  export type ListTunnelUsageSeriesResult = operations["list-tunnel-usage-series"]["responses"][200]["content"]["application/json"];
37
+ /** `GET /api/v1/tunnel/usage/series` 的查询参数。 */
38
+ export type ListTunnelUsageSeriesQuery = operations["list-tunnel-usage-series"]["parameters"]["query"];
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "@leaflow/sdk",
3
- "version": "0.0.0-dev.113.g5d6fb99",
3
+ "version": "0.0.0-dev.15.g2ea7bad",
4
4
  "description": "Leaflow 平台 API 的 TypeScript SDK",
5
5
  "license": "MIT",
6
6
  "repository": {
7
7
  "type": "git",
8
- "url": "git+https://github.com/LeaflowNET/sdk.git"
8
+ "url": "git+https://github.com/leaflowapis/leaflow-ts.git"
9
9
  },
10
10
  "type": "module",
11
11
  "main": "./dist/index.js",
@@ -49,7 +49,7 @@
49
49
  ],
50
50
  "sideEffects": false,
51
51
  "scripts": {
52
- "generate": "node ../scripts/generate-ts.mjs && python3 ../scripts/generate-go.py",
52
+ "generate": "node scripts/generate.mjs",
53
53
  "build": "tsc -p tsconfig.build.json",
54
54
  "typecheck": "tsc -p tsconfig.json --noEmit",
55
55
  "prepublishOnly": "npm run build"
@@ -57,7 +57,8 @@
57
57
  "devDependencies": {
58
58
  "openapi-typescript": "7.13.0",
59
59
  "typescript": "^5.9.3",
60
- "openapi-fetch": "^0.17.0"
60
+ "openapi-fetch": "^0.17.0",
61
+ "yaml": "^2.8.1"
61
62
  },
62
63
  "publishConfig": {
63
64
  "access": "public"