@celestia-island/plana-types 0.1.2 → 0.1.4
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/bindings/gateway.ts +205 -0
- package/index.ts +3 -2
- package/package.json +1 -1
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { JsonValue } from "./serde_json/JsonValue";
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* `device.bootstrap` result: the one-shot payload a freshly flashed
|
|
6
|
+
* device fetches with its enrollment token (parity with the host agent's
|
|
7
|
+
* `BootstrapResponse`).
|
|
8
|
+
*/
|
|
9
|
+
export type DeviceBootstrap = { node_id: string,
|
|
10
|
+
/**
|
|
11
|
+
* Candidate evernight-server endpoints (`ws(s)://…/api/ws`).
|
|
12
|
+
*/
|
|
13
|
+
server_urls: Array<string>, device_secret?: string | null, status?: string | null, };
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* `enrollment.mint` params (parity with the gateway's `EnrollRequest`).
|
|
17
|
+
*/
|
|
18
|
+
export type EnrollmentMintParams = {
|
|
19
|
+
/**
|
|
20
|
+
* Free-form device label stored as the enrollment note.
|
|
21
|
+
*/
|
|
22
|
+
name?: string | null,
|
|
23
|
+
/**
|
|
24
|
+
* Explicit target server override (`ws(s)://…/api/ws`).
|
|
25
|
+
*/
|
|
26
|
+
target_server?: string | null,
|
|
27
|
+
/**
|
|
28
|
+
* Parent signing-certificate flow: when present the gateway prepares
|
|
29
|
+
* the claims and the flasher signs locally with the key bound in the
|
|
30
|
+
* certificate.
|
|
31
|
+
*/
|
|
32
|
+
signing?: SigningRequest | null, };
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* `enrollment.mint` result, parent-chained path (parity with the
|
|
36
|
+
* flasher's `MintParentChained`): the gateway only assigns identifiers
|
|
37
|
+
* and returns the unsigned JOSE signing input; the flasher signs it with
|
|
38
|
+
* the key bound in its parent certificate before burning to media.
|
|
39
|
+
*/
|
|
40
|
+
export type EnrollmentMintParentChained = { serial: string, node_id: string,
|
|
41
|
+
/**
|
|
42
|
+
* Unsigned JOSE signing input (base64url `header.payload`).
|
|
43
|
+
*/
|
|
44
|
+
signing_input: string, parent_jti: string,
|
|
45
|
+
/**
|
|
46
|
+
* Epoch seconds; clamped inside the parent certificate window.
|
|
47
|
+
*/
|
|
48
|
+
expires_at: bigint,
|
|
49
|
+
/**
|
|
50
|
+
* Epoch seconds.
|
|
51
|
+
*/
|
|
52
|
+
created_at: bigint, target_server?: string | null, name?: string | null, };
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* `enrollment.mint` result, legacy gateway-signed path (parity with the
|
|
56
|
+
* flasher's `EnrollmentMint`).
|
|
57
|
+
*/
|
|
58
|
+
export type EnrollmentMinted = { serial: string, node_id: string, enrollment_token: string,
|
|
59
|
+
/**
|
|
60
|
+
* Epoch seconds.
|
|
61
|
+
*/
|
|
62
|
+
expires_at: bigint,
|
|
63
|
+
/**
|
|
64
|
+
* Epoch seconds.
|
|
65
|
+
*/
|
|
66
|
+
created_at: bigint, target_server?: string | null, name?: string | null, };
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* `enrollment.status` result (parity with the flasher's
|
|
70
|
+
* `EnrollmentStatus`; `status` stays a free string — `"pending"`,
|
|
71
|
+
* `"activated"`, `"revoked"`, `"expired"` — until every deployment
|
|
72
|
+
* agrees on the enum).
|
|
73
|
+
*/
|
|
74
|
+
export type EnrollmentStatus = { serial: string, node_id: string, status: string,
|
|
75
|
+
/**
|
|
76
|
+
* Epoch seconds.
|
|
77
|
+
*/
|
|
78
|
+
created_at: bigint, activated_at?: bigint | null, activated_ip?: string | null, revoked_at?: bigint | null,
|
|
79
|
+
/**
|
|
80
|
+
* Epoch seconds.
|
|
81
|
+
*/
|
|
82
|
+
expires_at: bigint, name?: string | null, };
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* `gateway.info` result: capability descriptor served before
|
|
86
|
+
* authentication (replaces the old `rescue_channel_not_configured` +
|
|
87
|
+
* `missing` map dance).
|
|
88
|
+
*/
|
|
89
|
+
export type GatewayServiceInfo = {
|
|
90
|
+
/**
|
|
91
|
+
* Human-readable service identifier, e.g. `"gateway"`.
|
|
92
|
+
*/
|
|
93
|
+
service: string,
|
|
94
|
+
/**
|
|
95
|
+
* Server version.
|
|
96
|
+
*/
|
|
97
|
+
version: string,
|
|
98
|
+
/**
|
|
99
|
+
* Whether the rescue channel is configured and usable.
|
|
100
|
+
*/
|
|
101
|
+
rescue_ready: boolean,
|
|
102
|
+
/**
|
|
103
|
+
* Unset configuration keys that keep `rescue_ready` false.
|
|
104
|
+
*/
|
|
105
|
+
missing?: Array<string>,
|
|
106
|
+
/**
|
|
107
|
+
* Deployment region descriptor (`"XX"` when unknown).
|
|
108
|
+
*/
|
|
109
|
+
region: string, };
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* `enrollment.signing_cert.mint` result (parity with the flasher's
|
|
113
|
+
* `ParentCertIssued`).
|
|
114
|
+
*/
|
|
115
|
+
export type ParentCertIssued = {
|
|
116
|
+
/**
|
|
117
|
+
* The signed certificate JWT.
|
|
118
|
+
*/
|
|
119
|
+
certificate: string, jti: string,
|
|
120
|
+
/**
|
|
121
|
+
* Not-before, epoch seconds (anchored at the operator's last login).
|
|
122
|
+
*/
|
|
123
|
+
nbf: bigint,
|
|
124
|
+
/**
|
|
125
|
+
* Expiry, epoch seconds.
|
|
126
|
+
*/
|
|
127
|
+
exp: bigint, };
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* Quota outlook as adjudicated by the ERP quota service.
|
|
131
|
+
*/
|
|
132
|
+
export type QuotaState = { remaining: bigint, limit: bigint, allowed: boolean, };
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* `rescue.diagnose` params. The diagnostics bundle is opaque to the
|
|
136
|
+
* protocol (the model defines its shape).
|
|
137
|
+
*/
|
|
138
|
+
export type RescueDiagnoseParams = { bundle: JsonValue, };
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* `rescue.diagnose.progress` notification params.
|
|
142
|
+
*/
|
|
143
|
+
export type RescueDiagnoseProgressParams = {
|
|
144
|
+
/**
|
|
145
|
+
* Monotonic 1-based step counter.
|
|
146
|
+
*/
|
|
147
|
+
step: number, };
|
|
148
|
+
|
|
149
|
+
/**
|
|
150
|
+
* `rescue.diagnose` result.
|
|
151
|
+
*/
|
|
152
|
+
export type RescueDiagnoseResult = {
|
|
153
|
+
/**
|
|
154
|
+
* Structured diagnosis as produced by the model (opaque JSON).
|
|
155
|
+
*/
|
|
156
|
+
diagnosis: JsonValue,
|
|
157
|
+
/**
|
|
158
|
+
* Model identifier that produced the diagnosis.
|
|
159
|
+
*/
|
|
160
|
+
model: string,
|
|
161
|
+
/**
|
|
162
|
+
* RFC 3339 timestamp.
|
|
163
|
+
*/
|
|
164
|
+
generated_at: string, };
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* `rescue.open_session` params. The ticket is the one-shot opaque
|
|
168
|
+
* credential issued by the OAuth callback redirect; it is consumed
|
|
169
|
+
* exactly once at session mint.
|
|
170
|
+
*/
|
|
171
|
+
export type RescueOpenSessionParams = { ticket: string, };
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* `rescue.open_session` result. The session handle itself is
|
|
175
|
+
* connection-bound server state and never crosses the wire; the caller
|
|
176
|
+
* learns only how long the bound session lives and the quota outlook.
|
|
177
|
+
*/
|
|
178
|
+
export type RescueSessionOpened = {
|
|
179
|
+
/**
|
|
180
|
+
* Seconds until the bound session expires.
|
|
181
|
+
*/
|
|
182
|
+
expires_in: bigint, quota: QuotaState, };
|
|
183
|
+
|
|
184
|
+
/**
|
|
185
|
+
* `enrollment.signing_cert.mint` params (parity with `SigningCertRequest`).
|
|
186
|
+
*
|
|
187
|
+
* The protocol caps `ttl_days` at 3 years (1095 days): a stolen keystore
|
|
188
|
+
* must die on its own within a bounded horizon.
|
|
189
|
+
*/
|
|
190
|
+
export type SigningCertParams = {
|
|
191
|
+
/**
|
|
192
|
+
* Client-generated Ed25519 public key, base64url raw (the JWK `x`).
|
|
193
|
+
* The private half never leaves the flasher's keystore.
|
|
194
|
+
*/
|
|
195
|
+
public_key: string,
|
|
196
|
+
/**
|
|
197
|
+
* Requested validity in days, window anchored at the operator's last
|
|
198
|
+
* login.
|
|
199
|
+
*/
|
|
200
|
+
ttl_days: bigint, };
|
|
201
|
+
|
|
202
|
+
/**
|
|
203
|
+
* Parent-certificate mint selection inside [`EnrollmentMintParams`].
|
|
204
|
+
*/
|
|
205
|
+
export type SigningRequest = { parent_jti: string, };
|
package/index.ts
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
// OTHER (star-exported) source the earlier line exports, so "first
|
|
15
15
|
// listed source wins" is the deliberate outcome, not an artifact.
|
|
16
16
|
// - Shadowed duplicates stay importable via deep imports
|
|
17
|
-
// (`import type { FileEntry } from "@celestia-island/plana-
|
|
17
|
+
// (`import type { FileEntry } from "@celestia-island/plana-types/bindings/tools/kalos"`).
|
|
18
18
|
//
|
|
19
19
|
// The 6 current collisions (flat winner -> shadowed source):
|
|
20
20
|
//
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
// name must be dropped from the earlier star-exported source.
|
|
36
36
|
export * from "./bindings/engine";
|
|
37
37
|
export * from "./bindings/enums";
|
|
38
|
+
export * from "./bindings/gateway";
|
|
38
39
|
export * from "./bindings/httpTypes";
|
|
39
40
|
export * from "./bindings/mdd";
|
|
40
41
|
export * from "./bindings/model";
|
|
@@ -65,7 +66,7 @@ export * from "./bindings/tools/hubris";
|
|
|
65
66
|
export type { Annotation, FileCreateDirParams, FileDeleteParams, FileDeleteResult, FileEditParams, FileEditResult, FileExistsParams, FileExistsResult, FileGetInfoParams, FileInfoResult, FileListParams, FileListResult, FileReadResult, FileTreeListResult, FileWriteParams, FileWriteResult, ListAnnotationsResult, MkDirResult, ResolveAnnotationResult } from "./bindings/tools/kalos";
|
|
66
67
|
export type { CheckWaitParams, ContainerCreateResult, ContainerFilterCriteria, ContainerForkParams, ContainerForkResult, ContainerInfoParams, ContainerInfoResult, ContainerListItem, ContainerListParams, ContainerListResult, ContainerRemoveParams, ContainerRemoveResult, ContainerSnapshotResult, ContainerStartParams, ContainerStartResult, ContainerStopParams, ContainerStopResult, ExecOnContainerParams, ExecResult, GitPushBranchParams, GitPushResult, NewContainerToolParams, NewContainerVolumeMount, SidecarDeliverResult, SidecarKillParams, SidecarSendParams, SidecarSendResult, SidecarSpawnParams, ToolchainEnsureParams, ToolchainEnsureResult, ToolchainListParams, ToolchainListResult, ToolchainProfileInfo, ToolchainVolumeSpec, VolumeInfo, WaitParams } from "./bindings/tools/neikos";
|
|
67
68
|
export type { AgentIntegrityParams, AskResult, AuditAlignmentParams, AuditAlignmentResult, AuditFinding, AuditLegalityParams, AuditLegalityResult, BlockToolParams, CheckResultItem, ComplianceReportParams, ComplianceReportToolResult, ComplianceRule, ComplianceSummary, InspectToolCallParams, ManageSensitivityRulesParams, ReplyResult, ReportDetail, ReportHumanResult, RuleCheckResult, SecurityAuditParams, SecurityStatusParams, SecuritySuggestionsParams, SensitivityRule, SetNetworkPolicyParams, SetRiskThresholdParams, SetSecurityPolicyParams, StandardCheckParams, StandardCheckResult, StandardRegisterResult, UnblockToolParams } from "./bindings/tools/orexis";
|
|
68
|
-
export type { GrantItem, GrantListResponse, MyPermissions, OAuthProvider, RbacUser, RbacUsersResponse } from "./bindings/httpTypes";
|
|
69
|
+
export type { GrantItem, GrantListResponse, MyPermissions, OAuthProvider, RbacGroupsResponse, RbacUser, RbacUsersResponse } from "./bindings/protocol-core-httpTypes";
|
|
69
70
|
export * from "./bindings/tools/philia";
|
|
70
71
|
export * from "./bindings/tools/polemos";
|
|
71
72
|
export * from "./bindings/tools/skemma";
|