@myagentroam/protocol 0.9.62 → 0.9.65

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.
@@ -0,0 +1,505 @@
1
+ import { z } from 'zod';
2
+ export declare const PERSONAL_GIT_NODE_VERSION = "0.9.63";
3
+ /** The credential-bound commit identity payload is incompatible with the 0.9.63 runtime shape. */
4
+ export declare const PERSONAL_GIT_IDENTITY_NODE_VERSION = "0.9.64";
5
+ export declare const personalGitIdentitySchema: z.ZodEffects<z.ZodObject<{
6
+ name: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
7
+ email: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
8
+ }, "strict", z.ZodTypeAny, {
9
+ name: string;
10
+ email: string;
11
+ }, {
12
+ name: string;
13
+ email: string;
14
+ }>, {
15
+ name: string;
16
+ email: string;
17
+ }, {
18
+ name: string;
19
+ email: string;
20
+ }>;
21
+ export type PersonalGitIdentity = z.infer<typeof personalGitIdentitySchema>;
22
+ export declare function normalizeGitHost(value: string): string;
23
+ export declare function normalizeGitPath(value: string): string;
24
+ export interface GitRemoteUrl {
25
+ readonly protocol: 'HTTPS' | 'SSH';
26
+ readonly host: string;
27
+ readonly port: number;
28
+ readonly pathPrefix: string;
29
+ /** SSH remote login; HTTPS authentication continues to use the credential username. */
30
+ readonly username?: string;
31
+ }
32
+ /** Parses the complete HTTPS or SSH remote address accepted by the management form. */
33
+ export declare function parseGitRemoteUrl(value: string): GitRemoteUrl;
34
+ /** Formats a canonical complete remote address without exposing secrets. */
35
+ export declare function formatGitRemoteUrl(credential: Pick<GitCredential, 'protocol' | 'host' | 'port' | 'pathPrefix' | 'username'>): string;
36
+ export declare const gitCredentialInputSchema: z.ZodEffects<z.ZodObject<{
37
+ secret: z.ZodEffects<z.ZodString, string, string>;
38
+ passphrase: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
39
+ name: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
40
+ protocol: z.ZodEnum<["HTTPS", "SSH"]>;
41
+ host: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
42
+ port: z.ZodNumber;
43
+ pathPrefix: z.ZodEffects<z.ZodString, string, string>;
44
+ username: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
45
+ commitName: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
46
+ commitEmail: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
47
+ }, "strict", z.ZodTypeAny, {
48
+ name: string;
49
+ secret: string;
50
+ protocol: "HTTPS" | "SSH";
51
+ host: string;
52
+ port: number;
53
+ pathPrefix: string;
54
+ username: string;
55
+ commitName: string;
56
+ commitEmail: string;
57
+ passphrase?: string | undefined;
58
+ }, {
59
+ name: string;
60
+ secret: string;
61
+ protocol: "HTTPS" | "SSH";
62
+ host: string;
63
+ port: number;
64
+ pathPrefix: string;
65
+ username: string;
66
+ commitName: string;
67
+ commitEmail: string;
68
+ passphrase?: string | undefined;
69
+ }>, {
70
+ name: string;
71
+ secret: string;
72
+ protocol: "HTTPS" | "SSH";
73
+ host: string;
74
+ port: number;
75
+ pathPrefix: string;
76
+ username: string;
77
+ commitName: string;
78
+ commitEmail: string;
79
+ passphrase?: string | undefined;
80
+ }, {
81
+ name: string;
82
+ secret: string;
83
+ protocol: "HTTPS" | "SSH";
84
+ host: string;
85
+ port: number;
86
+ pathPrefix: string;
87
+ username: string;
88
+ commitName: string;
89
+ commitEmail: string;
90
+ passphrase?: string | undefined;
91
+ }>;
92
+ export declare const gitCredentialUpdateSchema: z.ZodEffects<z.ZodObject<{
93
+ secret: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
94
+ passphrase: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodString, string, string>>>;
95
+ name: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
96
+ protocol: z.ZodEnum<["HTTPS", "SSH"]>;
97
+ host: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
98
+ port: z.ZodNumber;
99
+ pathPrefix: z.ZodEffects<z.ZodString, string, string>;
100
+ username: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
101
+ commitName: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
102
+ commitEmail: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
103
+ }, "strict", z.ZodTypeAny, {
104
+ name: string;
105
+ protocol: "HTTPS" | "SSH";
106
+ host: string;
107
+ port: number;
108
+ pathPrefix: string;
109
+ username: string;
110
+ commitName: string;
111
+ commitEmail: string;
112
+ secret?: string | undefined;
113
+ passphrase?: string | null | undefined;
114
+ }, {
115
+ name: string;
116
+ protocol: "HTTPS" | "SSH";
117
+ host: string;
118
+ port: number;
119
+ pathPrefix: string;
120
+ username: string;
121
+ commitName: string;
122
+ commitEmail: string;
123
+ secret?: string | undefined;
124
+ passphrase?: string | null | undefined;
125
+ }>, {
126
+ name: string;
127
+ protocol: "HTTPS" | "SSH";
128
+ host: string;
129
+ port: number;
130
+ pathPrefix: string;
131
+ username: string;
132
+ commitName: string;
133
+ commitEmail: string;
134
+ secret?: string | undefined;
135
+ passphrase?: string | null | undefined;
136
+ }, {
137
+ name: string;
138
+ protocol: "HTTPS" | "SSH";
139
+ host: string;
140
+ port: number;
141
+ pathPrefix: string;
142
+ username: string;
143
+ commitName: string;
144
+ commitEmail: string;
145
+ secret?: string | undefined;
146
+ passphrase?: string | null | undefined;
147
+ }>;
148
+ export declare const gitCredentialSchema: z.ZodEffects<z.ZodObject<{
149
+ id: z.ZodString;
150
+ secret: z.ZodEffects<z.ZodString, string, string>;
151
+ passphrase: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
152
+ name: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
153
+ protocol: z.ZodEnum<["HTTPS", "SSH"]>;
154
+ host: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
155
+ port: z.ZodNumber;
156
+ pathPrefix: z.ZodEffects<z.ZodString, string, string>;
157
+ username: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
158
+ commitName: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
159
+ commitEmail: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
160
+ }, "strict", z.ZodTypeAny, {
161
+ id: string;
162
+ name: string;
163
+ secret: string;
164
+ protocol: "HTTPS" | "SSH";
165
+ host: string;
166
+ port: number;
167
+ pathPrefix: string;
168
+ username: string;
169
+ commitName: string;
170
+ commitEmail: string;
171
+ passphrase?: string | undefined;
172
+ }, {
173
+ id: string;
174
+ name: string;
175
+ secret: string;
176
+ protocol: "HTTPS" | "SSH";
177
+ host: string;
178
+ port: number;
179
+ pathPrefix: string;
180
+ username: string;
181
+ commitName: string;
182
+ commitEmail: string;
183
+ passphrase?: string | undefined;
184
+ }>, {
185
+ id: string;
186
+ name: string;
187
+ secret: string;
188
+ protocol: "HTTPS" | "SSH";
189
+ host: string;
190
+ port: number;
191
+ pathPrefix: string;
192
+ username: string;
193
+ commitName: string;
194
+ commitEmail: string;
195
+ passphrase?: string | undefined;
196
+ }, {
197
+ id: string;
198
+ name: string;
199
+ secret: string;
200
+ protocol: "HTTPS" | "SSH";
201
+ host: string;
202
+ port: number;
203
+ pathPrefix: string;
204
+ username: string;
205
+ commitName: string;
206
+ commitEmail: string;
207
+ passphrase?: string | undefined;
208
+ }>;
209
+ export type GitCredential = z.infer<typeof gitCredentialSchema>;
210
+ export type GitCredentialInput = z.infer<typeof gitCredentialInputSchema>;
211
+ export type GitCredentialUpdate = z.infer<typeof gitCredentialUpdateSchema>;
212
+ export declare const gitCredentialSummarySchema: z.ZodEffects<z.ZodObject<{
213
+ id: z.ZodString;
214
+ hasSecret: z.ZodBoolean;
215
+ hasPassphrase: z.ZodBoolean;
216
+ name: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
217
+ protocol: z.ZodEnum<["HTTPS", "SSH"]>;
218
+ host: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
219
+ port: z.ZodNumber;
220
+ pathPrefix: z.ZodEffects<z.ZodString, string, string>;
221
+ username: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
222
+ commitName: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
223
+ commitEmail: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
224
+ }, "strict", z.ZodTypeAny, {
225
+ id: string;
226
+ name: string;
227
+ protocol: "HTTPS" | "SSH";
228
+ host: string;
229
+ port: number;
230
+ pathPrefix: string;
231
+ username: string;
232
+ commitName: string;
233
+ commitEmail: string;
234
+ hasSecret: boolean;
235
+ hasPassphrase: boolean;
236
+ }, {
237
+ id: string;
238
+ name: string;
239
+ protocol: "HTTPS" | "SSH";
240
+ host: string;
241
+ port: number;
242
+ pathPrefix: string;
243
+ username: string;
244
+ commitName: string;
245
+ commitEmail: string;
246
+ hasSecret: boolean;
247
+ hasPassphrase: boolean;
248
+ }>, {
249
+ id: string;
250
+ name: string;
251
+ protocol: "HTTPS" | "SSH";
252
+ host: string;
253
+ port: number;
254
+ pathPrefix: string;
255
+ username: string;
256
+ commitName: string;
257
+ commitEmail: string;
258
+ hasSecret: boolean;
259
+ hasPassphrase: boolean;
260
+ }, {
261
+ id: string;
262
+ name: string;
263
+ protocol: "HTTPS" | "SSH";
264
+ host: string;
265
+ port: number;
266
+ pathPrefix: string;
267
+ username: string;
268
+ commitName: string;
269
+ commitEmail: string;
270
+ hasSecret: boolean;
271
+ hasPassphrase: boolean;
272
+ }>;
273
+ export type GitCredentialSummary = z.infer<typeof gitCredentialSummarySchema>;
274
+ export declare const personalGitRuntimeSchema: z.ZodEffects<z.ZodObject<{
275
+ credentials: z.ZodArray<z.ZodEffects<z.ZodObject<{
276
+ id: z.ZodString;
277
+ secret: z.ZodEffects<z.ZodString, string, string>;
278
+ passphrase: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
279
+ name: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
280
+ protocol: z.ZodEnum<["HTTPS", "SSH"]>;
281
+ host: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
282
+ port: z.ZodNumber;
283
+ pathPrefix: z.ZodEffects<z.ZodString, string, string>;
284
+ username: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
285
+ commitName: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
286
+ commitEmail: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
287
+ }, "strict", z.ZodTypeAny, {
288
+ id: string;
289
+ name: string;
290
+ secret: string;
291
+ protocol: "HTTPS" | "SSH";
292
+ host: string;
293
+ port: number;
294
+ pathPrefix: string;
295
+ username: string;
296
+ commitName: string;
297
+ commitEmail: string;
298
+ passphrase?: string | undefined;
299
+ }, {
300
+ id: string;
301
+ name: string;
302
+ secret: string;
303
+ protocol: "HTTPS" | "SSH";
304
+ host: string;
305
+ port: number;
306
+ pathPrefix: string;
307
+ username: string;
308
+ commitName: string;
309
+ commitEmail: string;
310
+ passphrase?: string | undefined;
311
+ }>, {
312
+ id: string;
313
+ name: string;
314
+ secret: string;
315
+ protocol: "HTTPS" | "SSH";
316
+ host: string;
317
+ port: number;
318
+ pathPrefix: string;
319
+ username: string;
320
+ commitName: string;
321
+ commitEmail: string;
322
+ passphrase?: string | undefined;
323
+ }, {
324
+ id: string;
325
+ name: string;
326
+ secret: string;
327
+ protocol: "HTTPS" | "SSH";
328
+ host: string;
329
+ port: number;
330
+ pathPrefix: string;
331
+ username: string;
332
+ commitName: string;
333
+ commitEmail: string;
334
+ passphrase?: string | undefined;
335
+ }>, "many">;
336
+ }, "strict", z.ZodTypeAny, {
337
+ credentials: {
338
+ id: string;
339
+ name: string;
340
+ secret: string;
341
+ protocol: "HTTPS" | "SSH";
342
+ host: string;
343
+ port: number;
344
+ pathPrefix: string;
345
+ username: string;
346
+ commitName: string;
347
+ commitEmail: string;
348
+ passphrase?: string | undefined;
349
+ }[];
350
+ }, {
351
+ credentials: {
352
+ id: string;
353
+ name: string;
354
+ secret: string;
355
+ protocol: "HTTPS" | "SSH";
356
+ host: string;
357
+ port: number;
358
+ pathPrefix: string;
359
+ username: string;
360
+ commitName: string;
361
+ commitEmail: string;
362
+ passphrase?: string | undefined;
363
+ }[];
364
+ }>, {
365
+ credentials: {
366
+ id: string;
367
+ name: string;
368
+ secret: string;
369
+ protocol: "HTTPS" | "SSH";
370
+ host: string;
371
+ port: number;
372
+ pathPrefix: string;
373
+ username: string;
374
+ commitName: string;
375
+ commitEmail: string;
376
+ passphrase?: string | undefined;
377
+ }[];
378
+ }, {
379
+ credentials: {
380
+ id: string;
381
+ name: string;
382
+ secret: string;
383
+ protocol: "HTTPS" | "SSH";
384
+ host: string;
385
+ port: number;
386
+ pathPrefix: string;
387
+ username: string;
388
+ commitName: string;
389
+ commitEmail: string;
390
+ passphrase?: string | undefined;
391
+ }[];
392
+ }>;
393
+ export type PersonalGitRuntime = z.infer<typeof personalGitRuntimeSchema>;
394
+ export declare const personalGitSummarySchema: z.ZodObject<{
395
+ credentials: z.ZodArray<z.ZodEffects<z.ZodObject<{
396
+ id: z.ZodString;
397
+ hasSecret: z.ZodBoolean;
398
+ hasPassphrase: z.ZodBoolean;
399
+ name: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
400
+ protocol: z.ZodEnum<["HTTPS", "SSH"]>;
401
+ host: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
402
+ port: z.ZodNumber;
403
+ pathPrefix: z.ZodEffects<z.ZodString, string, string>;
404
+ username: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
405
+ commitName: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
406
+ commitEmail: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
407
+ }, "strict", z.ZodTypeAny, {
408
+ id: string;
409
+ name: string;
410
+ protocol: "HTTPS" | "SSH";
411
+ host: string;
412
+ port: number;
413
+ pathPrefix: string;
414
+ username: string;
415
+ commitName: string;
416
+ commitEmail: string;
417
+ hasSecret: boolean;
418
+ hasPassphrase: boolean;
419
+ }, {
420
+ id: string;
421
+ name: string;
422
+ protocol: "HTTPS" | "SSH";
423
+ host: string;
424
+ port: number;
425
+ pathPrefix: string;
426
+ username: string;
427
+ commitName: string;
428
+ commitEmail: string;
429
+ hasSecret: boolean;
430
+ hasPassphrase: boolean;
431
+ }>, {
432
+ id: string;
433
+ name: string;
434
+ protocol: "HTTPS" | "SSH";
435
+ host: string;
436
+ port: number;
437
+ pathPrefix: string;
438
+ username: string;
439
+ commitName: string;
440
+ commitEmail: string;
441
+ hasSecret: boolean;
442
+ hasPassphrase: boolean;
443
+ }, {
444
+ id: string;
445
+ name: string;
446
+ protocol: "HTTPS" | "SSH";
447
+ host: string;
448
+ port: number;
449
+ pathPrefix: string;
450
+ username: string;
451
+ commitName: string;
452
+ commitEmail: string;
453
+ hasSecret: boolean;
454
+ hasPassphrase: boolean;
455
+ }>, "many">;
456
+ }, "strict", z.ZodTypeAny, {
457
+ credentials: {
458
+ id: string;
459
+ name: string;
460
+ protocol: "HTTPS" | "SSH";
461
+ host: string;
462
+ port: number;
463
+ pathPrefix: string;
464
+ username: string;
465
+ commitName: string;
466
+ commitEmail: string;
467
+ hasSecret: boolean;
468
+ hasPassphrase: boolean;
469
+ }[];
470
+ }, {
471
+ credentials: {
472
+ id: string;
473
+ name: string;
474
+ protocol: "HTTPS" | "SSH";
475
+ host: string;
476
+ port: number;
477
+ pathPrefix: string;
478
+ username: string;
479
+ commitName: string;
480
+ commitEmail: string;
481
+ hasSecret: boolean;
482
+ hasPassphrase: boolean;
483
+ }[];
484
+ }>;
485
+ export type PersonalGitSummary = z.infer<typeof personalGitSummarySchema>;
486
+ export declare const workspaceGitSettingsSchema: z.ZodObject<{
487
+ preserveGitConfig: z.ZodBoolean;
488
+ }, "strict", z.ZodTypeAny, {
489
+ preserveGitConfig: boolean;
490
+ }, {
491
+ preserveGitConfig: boolean;
492
+ }>;
493
+ /** Converts the previous account-level identity record to per-credential identities on read. */
494
+ export declare function migratePersonalGitRuntime(value: unknown): PersonalGitRuntime;
495
+ export declare function gitCredentialScopeKey(credential: Pick<GitCredential, 'protocol' | 'host' | 'port' | 'pathPrefix'>): string;
496
+ export interface GitCredentialTarget {
497
+ readonly protocol: 'HTTPS' | 'SSH';
498
+ readonly host: string;
499
+ readonly port: number;
500
+ readonly path: string;
501
+ }
502
+ export declare function selectGitCredential<T extends Pick<GitCredential, 'protocol' | 'host' | 'port' | 'pathPrefix'>>(credentials: readonly T[], target: GitCredentialTarget): T | undefined;
503
+ export declare function supportsPersonalGit(version: string | undefined): boolean;
504
+ /** Gates forwarding of the credential-bound commit identity runtime payload. */
505
+ export declare function supportsPersonalGitIdentity(version: string | undefined): boolean;