@leaflow/sdk 0.54.4 → 0.56.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.
Files changed (62) hide show
  1. package/dist/account/v1/client.d.ts +4 -0
  2. package/dist/account/v1/client.js +7 -0
  3. package/dist/account/v1/index.d.ts +28 -27
  4. package/dist/account/v1/index.js +4 -4
  5. package/dist/account/v1/schema.d.ts +123 -122
  6. package/dist/assistant/v1/client.d.ts +4 -0
  7. package/dist/assistant/v1/client.js +7 -0
  8. package/dist/assistant/v1/index.d.ts +54 -53
  9. package/dist/assistant/v1/index.js +4 -4
  10. package/dist/assistant/v1/schema.d.ts +4 -0
  11. package/dist/billing/v1/index.d.ts +99 -93
  12. package/dist/billing/v1/index.js +3 -3
  13. package/dist/billing/v1/schema.d.ts +174 -5
  14. package/dist/canopy/v1/client.d.ts +4 -0
  15. package/dist/canopy/v1/client.js +7 -0
  16. package/dist/canopy/v1/index.d.ts +24 -23
  17. package/dist/canopy/v1/index.js +4 -4
  18. package/dist/canopy/v1/schema.d.ts +113 -109
  19. package/dist/compute/v1/client.d.ts +4 -0
  20. package/dist/compute/v1/client.js +7 -0
  21. package/dist/compute/v1/index.d.ts +126 -123
  22. package/dist/compute/v1/index.js +4 -4
  23. package/dist/compute/v1/schema.d.ts +55 -0
  24. package/dist/dns/v1/client.d.ts +4 -0
  25. package/dist/dns/v1/client.js +7 -0
  26. package/dist/dns/v1/index.d.ts +24 -23
  27. package/dist/dns/v1/index.js +4 -4
  28. package/dist/dns/v1/schema.d.ts +4 -0
  29. package/dist/fleet/v1/client.d.ts +4 -0
  30. package/dist/fleet/v1/client.js +7 -0
  31. package/dist/fleet/v1/index.d.ts +7 -0
  32. package/dist/fleet/v1/index.js +5 -0
  33. package/dist/fleet/v1/schema.d.ts +156 -0
  34. package/dist/fleet/v1/schema.js +5 -0
  35. package/dist/iam/v1/client.d.ts +4 -0
  36. package/dist/iam/v1/client.js +7 -0
  37. package/dist/iam/v1/index.d.ts +44 -43
  38. package/dist/iam/v1/index.js +4 -4
  39. package/dist/iam/v1/schema.d.ts +119 -115
  40. package/dist/index.d.ts +12 -11
  41. package/dist/index.js +20 -5
  42. package/dist/monitoring/v1/client.d.ts +4 -0
  43. package/dist/monitoring/v1/client.js +7 -0
  44. package/dist/monitoring/v1/index.d.ts +90 -89
  45. package/dist/monitoring/v1/index.js +4 -4
  46. package/dist/monitoring/v1/schema.d.ts +4 -0
  47. package/dist/notification/v1/client.d.ts +4 -0
  48. package/dist/notification/v1/client.js +7 -0
  49. package/dist/notification/v1/index.d.ts +38 -37
  50. package/dist/notification/v1/index.js +4 -4
  51. package/dist/notification/v1/schema.d.ts +4 -0
  52. package/dist/support/v1/client.d.ts +4 -0
  53. package/dist/support/v1/client.js +7 -0
  54. package/dist/support/v1/index.d.ts +25 -24
  55. package/dist/support/v1/index.js +4 -4
  56. package/dist/support/v1/schema.d.ts +4 -0
  57. package/dist/tunnel/v1/client.d.ts +4 -0
  58. package/dist/tunnel/v1/client.js +7 -0
  59. package/dist/tunnel/v1/index.d.ts +8 -7
  60. package/dist/tunnel/v1/index.js +4 -4
  61. package/dist/tunnel/v1/schema.d.ts +39 -35
  62. package/package.json +6 -4
@@ -0,0 +1,4 @@
1
+ import { type ClientOptions } from "openapi-fetch";
2
+ import type { paths } from "./schema.js";
3
+ /** A client for the fleet service. Pass baseUrl to override the address. */
4
+ export declare function client(options?: ClientOptions): import("openapi-fetch").Client<paths, `${string}/${string}`>;
@@ -0,0 +1,7 @@
1
+ // Code generated from the contract's servers[0]. DO NOT EDIT.
2
+ import createClient, {} from "openapi-fetch";
3
+ const defaultBaseUrl = "https://fleet.leaflow.cloud";
4
+ /** A client for the fleet service. Pass baseUrl to override the address. */
5
+ export function client(options = {}) {
6
+ return createClient({ baseUrl: defaultBaseUrl, ...options });
7
+ }
@@ -0,0 +1,7 @@
1
+ export type { paths, components, operations, webhooks } from "./schema.js";
2
+ export { client } from "./client.js";
3
+ import type { operations } from "./schema.js";
4
+ /** The success response body of `GET /api/v1/regions`. */
5
+ export type ListRegionsResult = operations["list-regions"]["responses"][200]["content"]["application/json"];
6
+ /** The success response body of `GET /api/v1/regions/{regionCode}/availability-zones`. */
7
+ export type ListAvailabilityZonesResult = operations["list-availability-zones"]["responses"][200]["content"]["application/json"];
@@ -0,0 +1,5 @@
1
+ // Code generated by scripts/generate.mjs. DO NOT EDIT.
2
+ //
3
+ // The aliases replace the operations[...] subscript chain with a name. The raw paths /
4
+ // components / operations are exported as well: paths is what createClient<paths>() takes.
5
+ export { client } from "./client.js";
@@ -0,0 +1,156 @@
1
+ /**
2
+ * This file was auto-generated by openapi-typescript.
3
+ * Do not make direct changes to the file.
4
+ */
5
+ export interface paths {
6
+ "/api/v1/regions": {
7
+ parameters: {
8
+ query?: never;
9
+ header?: never;
10
+ path?: never;
11
+ cookie?: never;
12
+ };
13
+ /**
14
+ * List available regions
15
+ * @description Lists every region currently open to new orders, in display order.
16
+ *
17
+ * The list is the same for every caller and changes rarely.
18
+ */
19
+ get: operations["list-regions"];
20
+ put?: never;
21
+ post?: never;
22
+ delete?: never;
23
+ options?: never;
24
+ head?: never;
25
+ patch?: never;
26
+ trace?: never;
27
+ };
28
+ "/api/v1/regions/{regionCode}/availability-zones": {
29
+ parameters: {
30
+ query?: never;
31
+ header?: never;
32
+ path?: never;
33
+ cookie?: never;
34
+ };
35
+ /**
36
+ * List the availability zones of a region
37
+ * @description Lists every availability zone of this region that is currently open to new orders, in display order.
38
+ *
39
+ * Resources are generally required to share an availability zone in order to be attached to one another, so confirm the zone before creating either side.
40
+ *
41
+ * A region that exists but is not open to new orders is reported as not found, exactly as an unknown code is: both mean that nothing can be created there.
42
+ */
43
+ get: operations["list-availability-zones"];
44
+ put?: never;
45
+ post?: never;
46
+ delete?: never;
47
+ options?: never;
48
+ head?: never;
49
+ patch?: never;
50
+ trace?: never;
51
+ };
52
+ }
53
+ export type webhooks = Record<string, never>;
54
+ export interface components {
55
+ schemas: {
56
+ Error: {
57
+ code?: string;
58
+ message: string;
59
+ /**
60
+ * @description What a given `code` carries alongside the message. The keys depend on the code,
61
+ * and a client that does not recognise one ignores it.
62
+ */
63
+ meta?: {
64
+ [key: string]: unknown;
65
+ };
66
+ /** Format: int64 */
67
+ status: number;
68
+ };
69
+ RegionResource: {
70
+ /** @description Stable identifier of the region, used wherever a region has to be named */
71
+ code: string;
72
+ /** @description ISO 3166-1 alpha-2 code of the country this region is in */
73
+ country_code: string;
74
+ name: string;
75
+ };
76
+ AvailabilityZoneResource: {
77
+ /** @description Stable identifier of the availability zone, used wherever an availability zone has to be named */
78
+ code: string;
79
+ name: string;
80
+ };
81
+ RegionListResponseBody: {
82
+ items: components["schemas"]["RegionResource"][] | null;
83
+ };
84
+ AvailabilityZoneListResponseBody: {
85
+ items: components["schemas"]["AvailabilityZoneResource"][] | null;
86
+ };
87
+ };
88
+ responses: never;
89
+ parameters: never;
90
+ requestBodies: never;
91
+ headers: never;
92
+ pathItems: never;
93
+ }
94
+ export type $defs = Record<string, never>;
95
+ export interface operations {
96
+ "list-regions": {
97
+ parameters: {
98
+ query?: never;
99
+ header?: never;
100
+ path?: never;
101
+ cookie?: never;
102
+ };
103
+ requestBody?: never;
104
+ responses: {
105
+ /** @description OK */
106
+ 200: {
107
+ headers: {
108
+ [name: string]: unknown;
109
+ };
110
+ content: {
111
+ "application/json": components["schemas"]["RegionListResponseBody"];
112
+ };
113
+ };
114
+ /** @description Error */
115
+ default: {
116
+ headers: {
117
+ [name: string]: unknown;
118
+ };
119
+ content: {
120
+ "application/json": components["schemas"]["Error"];
121
+ };
122
+ };
123
+ };
124
+ };
125
+ "list-availability-zones": {
126
+ parameters: {
127
+ query?: never;
128
+ header?: never;
129
+ path: {
130
+ regionCode: string;
131
+ };
132
+ cookie?: never;
133
+ };
134
+ requestBody?: never;
135
+ responses: {
136
+ /** @description OK */
137
+ 200: {
138
+ headers: {
139
+ [name: string]: unknown;
140
+ };
141
+ content: {
142
+ "application/json": components["schemas"]["AvailabilityZoneListResponseBody"];
143
+ };
144
+ };
145
+ /** @description Error */
146
+ default: {
147
+ headers: {
148
+ [name: string]: unknown;
149
+ };
150
+ content: {
151
+ "application/json": components["schemas"]["Error"];
152
+ };
153
+ };
154
+ };
155
+ };
156
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by openapi-typescript.
3
+ * Do not make direct changes to the file.
4
+ */
5
+ export {};
@@ -0,0 +1,4 @@
1
+ import { type ClientOptions } from "openapi-fetch";
2
+ import type { paths } from "./schema.js";
3
+ /** A client for the iam service. Pass baseUrl to override the address. */
4
+ export declare function client(options?: ClientOptions): import("openapi-fetch").Client<paths, `${string}/${string}`>;
@@ -0,0 +1,7 @@
1
+ // Code generated from the contract's servers[0]. DO NOT EDIT.
2
+ import createClient, {} from "openapi-fetch";
3
+ const defaultBaseUrl = "https://iam.leaflow.cloud";
4
+ /** A client for the iam service. Pass baseUrl to override the address. */
5
+ export function client(options = {}) {
6
+ return createClient({ baseUrl: defaultBaseUrl, ...options });
7
+ }
@@ -1,84 +1,85 @@
1
1
  export type { paths, components, operations, webhooks } from "./schema.js";
2
+ export { client } from "./client.js";
2
3
  import type { operations } from "./schema.js";
3
- /** `GET /api/v1/permissions` 成功时的响应体。 */
4
+ /** The success response body of `GET /api/v1/permissions`. */
4
5
  export type ListPermissionsResult = operations["list-permissions"]["responses"][200]["content"]["application/json"];
5
- /** `DELETE /api/v1/project` 成功时的响应体。 */
6
- export type DeleteProjectResult = operations["delete-project"]["responses"][200]["content"]["application/json"];
7
- /** `GET /api/v1/project` 成功时的响应体。 */
6
+ /** The success response body of `GET /api/v1/project`. */
8
7
  export type GetProjectResult = operations["get-project"]["responses"][200]["content"]["application/json"];
9
- /** `PATCH /api/v1/project` 成功时的响应体。 */
8
+ /** The success response body of `PATCH /api/v1/project`. */
10
9
  export type UpdateProjectResult = operations["update-project"]["responses"][200]["content"]["application/json"];
11
- /** `PATCH /api/v1/project` 的请求体。 */
10
+ /** The request body of `PATCH /api/v1/project`. */
12
11
  export type UpdateProjectBody = NonNullable<operations["update-project"]["requestBody"]>["content"]["application/json"];
13
- /** `GET /api/v1/membership` 成功时的响应体。 */
12
+ /** The success response body of `DELETE /api/v1/project`. */
13
+ export type DeleteProjectResult = operations["delete-project"]["responses"][200]["content"]["application/json"];
14
+ /** The success response body of `GET /api/v1/membership`. */
14
15
  export type GetProjectMembershipResult = operations["get-project-membership"]["responses"][200]["content"]["application/json"];
15
- /** `GET /api/v1/invitations` 成功时的响应体。 */
16
+ /** The success response body of `GET /api/v1/invitations`. */
16
17
  export type ListProjectInvitationsResult = operations["list-project-invitations"]["responses"][200]["content"]["application/json"];
17
- /** `GET /api/v1/invitations` 的查询参数。 */
18
+ /** The query parameters of `GET /api/v1/invitations`. */
18
19
  export type ListProjectInvitationsQuery = operations["list-project-invitations"]["parameters"]["query"];
19
- /** `POST /api/v1/invitations` 成功时的响应体。 */
20
+ /** The success response body of `POST /api/v1/invitations`. */
20
21
  export type IssueInvitationResult = operations["issue-invitation"]["responses"][201]["content"]["application/json"];
21
- /** `POST /api/v1/invitations` 的请求体。 */
22
+ /** The request body of `POST /api/v1/invitations`. */
22
23
  export type IssueInvitationBody = NonNullable<operations["issue-invitation"]["requestBody"]>["content"]["application/json"];
23
- /** `POST /api/v1/members:batchGet` 成功时的响应体。 */
24
+ /** The success response body of `POST /api/v1/members:batchGet`. */
24
25
  export type BatchGetMembersResult = operations["batch-get-members"]["responses"][200]["content"]["application/json"];
25
- /** `POST /api/v1/members:batchGet` 的请求体。 */
26
+ /** The request body of `POST /api/v1/members:batchGet`. */
26
27
  export type BatchGetMembersBody = NonNullable<operations["batch-get-members"]["requestBody"]>["content"]["application/json"];
27
- /** `GET /api/v1/members` 成功时的响应体。 */
28
+ /** The success response body of `GET /api/v1/members`. */
28
29
  export type ListMembersResult = operations["list-members"]["responses"][200]["content"]["application/json"];
29
- /** `GET /api/v1/members` 的查询参数。 */
30
+ /** The query parameters of `GET /api/v1/members`. */
30
31
  export type ListMembersQuery = operations["list-members"]["parameters"]["query"];
31
- /** `PUT /api/v1/members/{userId}/roles` 成功时的响应体。 */
32
+ /** The success response body of `PUT /api/v1/members/{userId}/roles`. */
32
33
  export type SetMemberRolesResult = operations["set-member-roles"]["responses"][200]["content"]["application/json"];
33
- /** `PUT /api/v1/members/{userId}/roles` 的请求体。 */
34
+ /** The request body of `PUT /api/v1/members/{userId}/roles`. */
34
35
  export type SetMemberRolesBody = NonNullable<operations["set-member-roles"]["requestBody"]>["content"]["application/json"];
35
- /** `PUT /api/v1/members/{userId}/permissions` 成功时的响应体。 */
36
+ /** The success response body of `PUT /api/v1/members/{userId}/permissions`. */
36
37
  export type SetMemberPermissionsResult = operations["set-member-permissions"]["responses"][200]["content"]["application/json"];
37
- /** `PUT /api/v1/members/{userId}/permissions` 的请求体。 */
38
+ /** The request body of `PUT /api/v1/members/{userId}/permissions`. */
38
39
  export type SetMemberPermissionsBody = NonNullable<operations["set-member-permissions"]["requestBody"]>["content"]["application/json"];
39
- /** `GET /api/v1/policies` 成功时的响应体。 */
40
+ /** The success response body of `GET /api/v1/policies`. */
40
41
  export type ListPoliciesResult = operations["list-policies"]["responses"][200]["content"]["application/json"];
41
- /** `GET /api/v1/policies` 的查询参数。 */
42
+ /** The query parameters of `GET /api/v1/policies`. */
42
43
  export type ListPoliciesQuery = operations["list-policies"]["parameters"]["query"];
43
- /** `POST /api/v1/policies` 成功时的响应体。 */
44
+ /** The success response body of `POST /api/v1/policies`. */
44
45
  export type AttachPolicyResult = operations["attach-policy"]["responses"][201]["content"]["application/json"];
45
- /** `POST /api/v1/policies` 的请求体。 */
46
+ /** The request body of `POST /api/v1/policies`. */
46
47
  export type AttachPolicyBody = NonNullable<operations["attach-policy"]["requestBody"]>["content"]["application/json"];
47
- /** `GET /api/v1/policies/{policyId}` 成功时的响应体。 */
48
+ /** The success response body of `GET /api/v1/policies/{policyId}`. */
48
49
  export type GetPolicyResult = operations["get-policy"]["responses"][200]["content"]["application/json"];
49
- /** `PUT /api/v1/policies/{policyId}` 成功时的响应体。 */
50
+ /** The success response body of `PUT /api/v1/policies/{policyId}`. */
50
51
  export type UpdatePolicyResult = operations["update-policy"]["responses"][200]["content"]["application/json"];
51
- /** `PUT /api/v1/policies/{policyId}` 的请求体。 */
52
+ /** The request body of `PUT /api/v1/policies/{policyId}`. */
52
53
  export type UpdatePolicyBody = NonNullable<operations["update-policy"]["requestBody"]>["content"]["application/json"];
53
- /** `POST /api/v1/transfer-ownership` 成功时的响应体。 */
54
+ /** The success response body of `POST /api/v1/transfer-ownership`. */
54
55
  export type TransferProjectOwnershipResult = operations["transfer-project-ownership"]["responses"][200]["content"]["application/json"];
55
- /** `POST /api/v1/transfer-ownership` 的请求体。 */
56
+ /** The request body of `POST /api/v1/transfer-ownership`. */
56
57
  export type TransferProjectOwnershipBody = NonNullable<operations["transfer-project-ownership"]["requestBody"]>["content"]["application/json"];
57
- /** `GET /api/v1/roles` 成功时的响应体。 */
58
+ /** The success response body of `GET /api/v1/roles`. */
58
59
  export type ListRolesResult = operations["list-roles"]["responses"][200]["content"]["application/json"];
59
- /** `POST /api/v1/roles` 成功时的响应体。 */
60
+ /** The success response body of `POST /api/v1/roles`. */
60
61
  export type CreateRoleResult = operations["create-role"]["responses"][201]["content"]["application/json"];
61
- /** `POST /api/v1/roles` 的请求体。 */
62
+ /** The request body of `POST /api/v1/roles`. */
62
63
  export type CreateRoleBody = NonNullable<operations["create-role"]["requestBody"]>["content"]["application/json"];
63
- /** `GET /api/v1/roles/{code}` 成功时的响应体。 */
64
+ /** The success response body of `GET /api/v1/roles/{code}`. */
64
65
  export type GetRoleResult = operations["get-role"]["responses"][200]["content"]["application/json"];
65
- /** `PUT /api/v1/roles/{code}` 成功时的响应体。 */
66
+ /** The success response body of `PUT /api/v1/roles/{code}`. */
66
67
  export type UpdateRoleResult = operations["update-role"]["responses"][200]["content"]["application/json"];
67
- /** `PUT /api/v1/roles/{code}` 的请求体。 */
68
+ /** The request body of `PUT /api/v1/roles/{code}`. */
68
69
  export type UpdateRoleBody = NonNullable<operations["update-role"]["requestBody"]>["content"]["application/json"];
69
- /** `GET /api/v1/ssh-keys` 成功时的响应体。 */
70
+ /** The success response body of `GET /api/v1/ssh-keys`. */
70
71
  export type ListSshKeysResult = operations["list-ssh-keys"]["responses"][200]["content"]["application/json"];
71
- /** `GET /api/v1/ssh-keys` 的查询参数。 */
72
+ /** The query parameters of `GET /api/v1/ssh-keys`. */
72
73
  export type ListSshKeysQuery = operations["list-ssh-keys"]["parameters"]["query"];
73
- /** `POST /api/v1/ssh-keys` 成功时的响应体。 */
74
+ /** The success response body of `POST /api/v1/ssh-keys`. */
74
75
  export type CreateSshKeyResult = operations["create-ssh-key"]["responses"][201]["content"]["application/json"];
75
- /** `POST /api/v1/ssh-keys` 的请求体。 */
76
+ /** The request body of `POST /api/v1/ssh-keys`. */
76
77
  export type CreateSshKeyBody = NonNullable<operations["create-ssh-key"]["requestBody"]>["content"]["application/json"];
77
- /** `DELETE /api/v1/ssh-keys/{keyId}` 成功时的响应体。 */
78
- export type RevokeSshKeyResult = operations["revoke-ssh-key"]["responses"][200]["content"]["application/json"];
79
- /** `GET /api/v1/ssh-keys/{keyId}` 成功时的响应体。 */
78
+ /** The success response body of `GET /api/v1/ssh-keys/{keyId}`. */
80
79
  export type GetSshKeyResult = operations["get-ssh-key"]["responses"][200]["content"]["application/json"];
81
- /** `PATCH /api/v1/ssh-keys/{keyId}` 成功时的响应体。 */
80
+ /** The success response body of `PATCH /api/v1/ssh-keys/{keyId}`. */
82
81
  export type RenameSshKeyResult = operations["rename-ssh-key"]["responses"][200]["content"]["application/json"];
83
- /** `PATCH /api/v1/ssh-keys/{keyId}` 的请求体。 */
82
+ /** The request body of `PATCH /api/v1/ssh-keys/{keyId}`. */
84
83
  export type RenameSshKeyBody = NonNullable<operations["rename-ssh-key"]["requestBody"]>["content"]["application/json"];
84
+ /** The success response body of `DELETE /api/v1/ssh-keys/{keyId}`. */
85
+ export type RevokeSshKeyResult = operations["revoke-ssh-key"]["responses"][200]["content"]["application/json"];
@@ -1,5 +1,5 @@
1
- // scripts/generate-ts.mjs 生成,不要手改。
1
+ // Code generated by scripts/generate.mjs. DO NOT EDIT.
2
2
  //
3
- // 别名把 operations[...] 那串下标换成一个名字。原始的 paths / components / operations
4
- // 一并导出:paths 是给 openapi-fetch createClient<paths>() 用的。
5
- export {};
3
+ // The aliases replace the operations[...] subscript chain with a name. The raw paths /
4
+ // components / operations are exported as well: paths is what createClient<paths>() takes.
5
+ export { client } from "./client.js";