@link-assistant/router 0.0.0-stage → 1.25.6

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 (159) hide show
  1. package/README.md +35 -2
  2. package/catalog.json +68422 -0
  3. package/index.d.ts +5932 -0
  4. package/index.js +224 -0
  5. package/native.d.ts +106 -0
  6. package/package.json +61 -4
  7. package/portable/policy.mjs +117 -0
  8. package/schemas/accounts-list.v1.json +323 -0
  9. package/schemas/accounts-pause.v1.json +97 -0
  10. package/schemas/accounts-policy.v1.json +214 -0
  11. package/schemas/accounts-resume.v1.json +97 -0
  12. package/schemas/auth-claude.v1.json +97 -0
  13. package/schemas/auth-clear.v1.json +97 -0
  14. package/schemas/auth-codex.v1.json +97 -0
  15. package/schemas/auth-gh.v1.json +97 -0
  16. package/schemas/auth-import.v1.json +167 -0
  17. package/schemas/auth-status.v1.json +387 -0
  18. package/schemas/cli-error.v1.json +97 -0
  19. package/schemas/clients-backup-create.v1.json +97 -0
  20. package/schemas/clients-backup-list.v1.json +234 -0
  21. package/schemas/clients-backup-restore.v1.json +97 -0
  22. package/schemas/clients-backup-verify.v1.json +125 -0
  23. package/schemas/clients-doctor.v1.json +249 -0
  24. package/schemas/clients-install.v1.json +164 -0
  25. package/schemas/clients-list.v1.json +194 -0
  26. package/schemas/clients-reinstall.v1.json +164 -0
  27. package/schemas/clients-remove.v1.json +97 -0
  28. package/schemas/clients-repair.v1.json +109 -0
  29. package/schemas/clients-reset.v1.json +113 -0
  30. package/schemas/clients-setup.v1.json +97 -0
  31. package/schemas/clients-show.v1.json +191 -0
  32. package/schemas/clients-update.v1.json +164 -0
  33. package/schemas/configure.v1.json +97 -0
  34. package/schemas/contracts.v1.json +106 -0
  35. package/schemas/data-backup.v1.json +32 -0
  36. package/schemas/deploy.v1.json +546 -0
  37. package/schemas/doctor.v1.json +324 -0
  38. package/schemas/local-deployment.v1.json +364 -0
  39. package/schemas/logs-anomalies.v1.json +112 -0
  40. package/schemas/logs-show.v1.json +127 -0
  41. package/schemas/logs-summary.v1.json +129 -0
  42. package/schemas/model-catalog.v1.json +117 -0
  43. package/schemas/models-explain.v1.json +325 -0
  44. package/schemas/preservation.v1.json +47 -0
  45. package/schemas/providers-add.v1.json +185 -0
  46. package/schemas/providers-import.v1.json +97 -0
  47. package/schemas/providers-list.v1.json +182 -0
  48. package/schemas/providers-remove.v1.json +97 -0
  49. package/schemas/providers-show.v1.json +179 -0
  50. package/schemas/serve.v1.json +97 -0
  51. package/schemas/server-claim.v1.json +97 -0
  52. package/schemas/server-reap.v1.json +97 -0
  53. package/schemas/server-remove.v1.json +97 -0
  54. package/schemas/server-start.v1.json +97 -0
  55. package/schemas/server-status.v1.json +197 -0
  56. package/schemas/server-stop.v1.json +97 -0
  57. package/schemas/server-use.v1.json +97 -0
  58. package/schemas/staging.v1.json +47 -0
  59. package/schemas/tls-ca.v1.json +97 -0
  60. package/schemas/tls-generate.v1.json +97 -0
  61. package/schemas/tokens-expire.v1.json +97 -0
  62. package/schemas/tokens-import.v1.json +192 -0
  63. package/schemas/tokens-issue.v1.json +94 -0
  64. package/schemas/tokens-list.v1.json +272 -0
  65. package/schemas/tokens-recover-admin.v1.json +116 -0
  66. package/schemas/tokens-revoke.v1.json +97 -0
  67. package/schemas/tokens-rotate.v1.json +94 -0
  68. package/schemas/tokens-show.v1.json +269 -0
  69. package/schemas/tunnel-down.v1.json +97 -0
  70. package/schemas/tunnel-status.v1.json +165 -0
  71. package/schemas/tunnel-up.v1.json +97 -0
  72. package/schemas/usage.v1.json +621 -0
  73. package/schemas/verification.v1.json +254 -0
  74. package/schemas/verify.v1.json +338 -0
  75. package/schemas/version.v1.json +103 -0
  76. package/schemas/with.v1.json +105 -0
  77. package/src/accounts.mjs +233 -0
  78. package/src/activitypub.mjs +23 -0
  79. package/src/admin-assets.mjs +16 -0
  80. package/src/admin.mjs +108 -0
  81. package/src/affinities.mjs +180 -0
  82. package/src/affinity-schema-descriptor.mjs +2 -0
  83. package/src/affinity-schema.mjs +185 -0
  84. package/src/assets/admin/assets/app.js +1 -0
  85. package/src/assets/admin/assets/react.js +9 -0
  86. package/src/assets/admin/assets/rolldown-runtime.js +1 -0
  87. package/src/assets/admin/assets/ui-vendor.js +3 -0
  88. package/src/assets/admin/index.html +16 -0
  89. package/src/auth-service.mjs +149 -0
  90. package/src/claude-process-session.mjs +26 -0
  91. package/src/cli-output.mjs +21 -0
  92. package/src/cli.mjs +84 -0
  93. package/src/client-ca.mjs +8 -0
  94. package/src/client-catalog.mjs +52 -0
  95. package/src/client-codex-catalog.mjs +18 -0
  96. package/src/client-configure.mjs +72 -0
  97. package/src/client-files.mjs +82 -0
  98. package/src/client-global-repair.mjs +19 -0
  99. package/src/client-global-state.mjs +19 -0
  100. package/src/client-global.mjs +43 -0
  101. package/src/client-json.mjs +54 -0
  102. package/src/client-launch-plan.mjs +28 -0
  103. package/src/client-launch.mjs +35 -0
  104. package/src/client-persistent.mjs +66 -0
  105. package/src/client-process-profile.mjs +52 -0
  106. package/src/client-process-settings.mjs +36 -0
  107. package/src/client-process.mjs +44 -0
  108. package/src/client-profile-backup.mjs +29 -0
  109. package/src/client-remote-health.mjs +7 -0
  110. package/src/client-remote.mjs +55 -0
  111. package/src/client-run-credential.mjs +38 -0
  112. package/src/client-setup.mjs +97 -0
  113. package/src/client-status.mjs +102 -0
  114. package/src/client-toml-cst.mjs +71 -0
  115. package/src/client-transaction.mjs +48 -0
  116. package/src/codex-login.mjs +121 -0
  117. package/src/codex-loopback-transport.mjs +34 -0
  118. package/src/codex-loopback.mjs +60 -0
  119. package/src/config.mjs +198 -0
  120. package/src/core.mjs +198 -0
  121. package/src/credential-operations.mjs +119 -0
  122. package/src/doublets.mjs +157 -0
  123. package/src/emergency-auth.mjs +91 -0
  124. package/src/file-lock.mjs +107 -0
  125. package/src/gemini-protocol.mjs +133 -0
  126. package/src/geolocation.mjs +46 -0
  127. package/src/git-proxy.mjs +52 -0
  128. package/src/github-proxy.mjs +74 -0
  129. package/src/http-management.mjs +36 -0
  130. package/src/http-route-contract.mjs +479 -0
  131. package/src/index.mjs +4 -0
  132. package/src/local-router-discovery.mjs +31 -0
  133. package/src/managed-server.mjs +411 -0
  134. package/src/management-access.mjs +76 -0
  135. package/src/native-service.mjs +392 -0
  136. package/src/oauth.mjs +547 -0
  137. package/src/operation-input.mjs +20 -0
  138. package/src/operations.mjs +378 -0
  139. package/src/protocols.mjs +229 -0
  140. package/src/provider-manifest.mjs +46 -0
  141. package/src/provider-provision.mjs +24 -0
  142. package/src/remote-operations.mjs +166 -0
  143. package/src/request-log.mjs +99 -0
  144. package/src/resources.mjs +290 -0
  145. package/src/response-contracts.mjs +147 -0
  146. package/src/responses.mjs +103 -0
  147. package/src/routing.mjs +40 -0
  148. package/src/sensitive-data-sse.mjs +121 -0
  149. package/src/sensitive-data.mjs +254 -0
  150. package/src/server.mjs +552 -0
  151. package/src/storage.mjs +367 -0
  152. package/src/streams.mjs +232 -0
  153. package/src/token-import.mjs +68 -0
  154. package/src/token-reservation.mjs +8 -0
  155. package/src/tokens.mjs +172 -0
  156. package/src/usage.mjs +54 -0
  157. package/src/websocket-relay.mjs +131 -0
  158. package/testing.d.ts +7 -0
  159. package/testing.js +57 -0
@@ -0,0 +1,47 @@
1
+ {
2
+ "$id": "link-assistant-router/staging/v1",
3
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
4
+ "additionalProperties": false,
5
+ "properties": {
6
+ "access_loss_explicitly_accepted": {},
7
+ "active_port_owners": {},
8
+ "blocker": {},
9
+ "catalog_comparison": {},
10
+ "catalogs": {},
11
+ "checkpoint": {},
12
+ "checkpoint_scope": {},
13
+ "cleanup_scope": {},
14
+ "control_health": {},
15
+ "credential_source": {},
16
+ "credentials_copied": {},
17
+ "data_restore_proven": {},
18
+ "data_retained": {},
19
+ "global_atomic_snapshot": {},
20
+ "issued_bound_tokens": {},
21
+ "mode": {},
22
+ "namespace": {},
23
+ "oauth_copied": {},
24
+ "oauth_ownership": {},
25
+ "oauth_restored": {},
26
+ "origin": {},
27
+ "parity": {},
28
+ "port_ownership": {},
29
+ "previous_checkpoint": {},
30
+ "primary_preservation": {},
31
+ "profiles_projects_sessions": {},
32
+ "real_claude_models_and_picker": {},
33
+ "reason": {},
34
+ "resource_limits": {},
35
+ "rollback_scope": {},
36
+ "root": {},
37
+ "schema": {
38
+ "const": "link-assistant-router/staging/v1"
39
+ },
40
+ "serving_health": {},
41
+ "status": {}
42
+ },
43
+ "required": [
44
+ "schema"
45
+ ],
46
+ "type": "object"
47
+ }
@@ -0,0 +1,97 @@
1
+ {
2
+ "$defs": {},
3
+ "$id": "link-assistant-router/tls-ca/v1",
4
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
5
+ "additionalProperties": false,
6
+ "allOf": [
7
+ {
8
+ "else": {
9
+ "properties": {
10
+ "exit_code": {
11
+ "minimum": 1,
12
+ "type": "integer"
13
+ }
14
+ }
15
+ },
16
+ "if": {
17
+ "properties": {
18
+ "success": {
19
+ "const": true
20
+ }
21
+ }
22
+ },
23
+ "then": {
24
+ "properties": {
25
+ "exit_code": {
26
+ "const": 0
27
+ }
28
+ }
29
+ }
30
+ }
31
+ ],
32
+ "properties": {
33
+ "data": {
34
+ "anyOf": [
35
+ {
36
+ "additionalProperties": false,
37
+ "properties": {
38
+ "output": {
39
+ "items": {
40
+ "type": "string"
41
+ },
42
+ "type": "array"
43
+ }
44
+ },
45
+ "required": [
46
+ "output"
47
+ ],
48
+ "type": "object"
49
+ },
50
+ {
51
+ "additionalProperties": false,
52
+ "properties": {
53
+ "output": {
54
+ "items": {
55
+ "type": "string"
56
+ },
57
+ "type": "array"
58
+ }
59
+ },
60
+ "required": [
61
+ "output"
62
+ ],
63
+ "type": "object"
64
+ }
65
+ ]
66
+ },
67
+ "diagnostics": {
68
+ "items": {
69
+ "type": "string"
70
+ },
71
+ "type": "array"
72
+ },
73
+ "exit_code": {
74
+ "maximum": 255,
75
+ "minimum": 0,
76
+ "type": "integer"
77
+ },
78
+ "operation": {
79
+ "const": "tls.ca"
80
+ },
81
+ "schema": {
82
+ "const": "link-assistant-router/tls-ca/v1"
83
+ },
84
+ "success": {
85
+ "type": "boolean"
86
+ }
87
+ },
88
+ "required": [
89
+ "schema",
90
+ "operation",
91
+ "success",
92
+ "exit_code",
93
+ "data",
94
+ "diagnostics"
95
+ ],
96
+ "type": "object"
97
+ }
@@ -0,0 +1,97 @@
1
+ {
2
+ "$defs": {},
3
+ "$id": "link-assistant-router/tls-generate/v1",
4
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
5
+ "additionalProperties": false,
6
+ "allOf": [
7
+ {
8
+ "else": {
9
+ "properties": {
10
+ "exit_code": {
11
+ "minimum": 1,
12
+ "type": "integer"
13
+ }
14
+ }
15
+ },
16
+ "if": {
17
+ "properties": {
18
+ "success": {
19
+ "const": true
20
+ }
21
+ }
22
+ },
23
+ "then": {
24
+ "properties": {
25
+ "exit_code": {
26
+ "const": 0
27
+ }
28
+ }
29
+ }
30
+ }
31
+ ],
32
+ "properties": {
33
+ "data": {
34
+ "anyOf": [
35
+ {
36
+ "additionalProperties": false,
37
+ "properties": {
38
+ "output": {
39
+ "items": {
40
+ "type": "string"
41
+ },
42
+ "type": "array"
43
+ }
44
+ },
45
+ "required": [
46
+ "output"
47
+ ],
48
+ "type": "object"
49
+ },
50
+ {
51
+ "additionalProperties": false,
52
+ "properties": {
53
+ "output": {
54
+ "items": {
55
+ "type": "string"
56
+ },
57
+ "type": "array"
58
+ }
59
+ },
60
+ "required": [
61
+ "output"
62
+ ],
63
+ "type": "object"
64
+ }
65
+ ]
66
+ },
67
+ "diagnostics": {
68
+ "items": {
69
+ "type": "string"
70
+ },
71
+ "type": "array"
72
+ },
73
+ "exit_code": {
74
+ "maximum": 255,
75
+ "minimum": 0,
76
+ "type": "integer"
77
+ },
78
+ "operation": {
79
+ "const": "tls.generate"
80
+ },
81
+ "schema": {
82
+ "const": "link-assistant-router/tls-generate/v1"
83
+ },
84
+ "success": {
85
+ "type": "boolean"
86
+ }
87
+ },
88
+ "required": [
89
+ "schema",
90
+ "operation",
91
+ "success",
92
+ "exit_code",
93
+ "data",
94
+ "diagnostics"
95
+ ],
96
+ "type": "object"
97
+ }
@@ -0,0 +1,97 @@
1
+ {
2
+ "$defs": {},
3
+ "$id": "link-assistant-router/tokens-expire/v1",
4
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
5
+ "additionalProperties": false,
6
+ "allOf": [
7
+ {
8
+ "else": {
9
+ "properties": {
10
+ "exit_code": {
11
+ "minimum": 1,
12
+ "type": "integer"
13
+ }
14
+ }
15
+ },
16
+ "if": {
17
+ "properties": {
18
+ "success": {
19
+ "const": true
20
+ }
21
+ }
22
+ },
23
+ "then": {
24
+ "properties": {
25
+ "exit_code": {
26
+ "const": 0
27
+ }
28
+ }
29
+ }
30
+ }
31
+ ],
32
+ "properties": {
33
+ "data": {
34
+ "anyOf": [
35
+ {
36
+ "additionalProperties": false,
37
+ "properties": {
38
+ "output": {
39
+ "items": {
40
+ "type": "string"
41
+ },
42
+ "type": "array"
43
+ }
44
+ },
45
+ "required": [
46
+ "output"
47
+ ],
48
+ "type": "object"
49
+ },
50
+ {
51
+ "additionalProperties": false,
52
+ "properties": {
53
+ "output": {
54
+ "items": {
55
+ "type": "string"
56
+ },
57
+ "type": "array"
58
+ }
59
+ },
60
+ "required": [
61
+ "output"
62
+ ],
63
+ "type": "object"
64
+ }
65
+ ]
66
+ },
67
+ "diagnostics": {
68
+ "items": {
69
+ "type": "string"
70
+ },
71
+ "type": "array"
72
+ },
73
+ "exit_code": {
74
+ "maximum": 255,
75
+ "minimum": 0,
76
+ "type": "integer"
77
+ },
78
+ "operation": {
79
+ "const": "tokens.expire"
80
+ },
81
+ "schema": {
82
+ "const": "link-assistant-router/tokens-expire/v1"
83
+ },
84
+ "success": {
85
+ "type": "boolean"
86
+ }
87
+ },
88
+ "required": [
89
+ "schema",
90
+ "operation",
91
+ "success",
92
+ "exit_code",
93
+ "data",
94
+ "diagnostics"
95
+ ],
96
+ "type": "object"
97
+ }
@@ -0,0 +1,192 @@
1
+ {
2
+ "$defs": {
3
+ "TokenImportReport": {
4
+ "additionalProperties": false,
5
+ "description": "The outcome of one import, printed as the command's result.",
6
+ "properties": {
7
+ "added": {
8
+ "description": "Records the target lacked and now holds (or would, in a dry run).",
9
+ "items": {
10
+ "type": "string"
11
+ },
12
+ "type": "array"
13
+ },
14
+ "backup": {
15
+ "description": "Export of the target's records taken before `--replace` wrote.",
16
+ "type": [
17
+ "string",
18
+ "null"
19
+ ]
20
+ },
21
+ "conflicts": {
22
+ "description": "Records that differ and were left as they are.",
23
+ "items": {
24
+ "$ref": "#/$defs/TokenImportReport_Conflict"
25
+ },
26
+ "type": "array"
27
+ },
28
+ "dry_run": {
29
+ "type": "boolean"
30
+ },
31
+ "kept_revoked": {
32
+ "description": "Replaced records that stayed revoked because the target had revoked\nthem: an import never revives a credential.",
33
+ "items": {
34
+ "type": "string"
35
+ },
36
+ "type": "array"
37
+ },
38
+ "missing_from_source": {
39
+ "description": "`--id` values the source does not hold.",
40
+ "items": {
41
+ "type": "string"
42
+ },
43
+ "type": "array"
44
+ },
45
+ "mode": {
46
+ "type": "string"
47
+ },
48
+ "replaced": {
49
+ "description": "Records overwritten by `--replace`.",
50
+ "items": {
51
+ "$ref": "#/$defs/TokenImportReport_Conflict"
52
+ },
53
+ "type": "array"
54
+ },
55
+ "source_records": {
56
+ "format": "uint",
57
+ "minimum": 0,
58
+ "type": "integer"
59
+ },
60
+ "target_records_before": {
61
+ "format": "uint",
62
+ "minimum": 0,
63
+ "type": "integer"
64
+ },
65
+ "unchanged": {
66
+ "description": "Records already identical on both sides.",
67
+ "items": {
68
+ "type": "string"
69
+ },
70
+ "type": "array"
71
+ }
72
+ },
73
+ "required": [
74
+ "mode",
75
+ "dry_run",
76
+ "source_records",
77
+ "target_records_before",
78
+ "added",
79
+ "unchanged",
80
+ "conflicts",
81
+ "replaced",
82
+ "kept_revoked",
83
+ "missing_from_source"
84
+ ],
85
+ "title": "ImportReport",
86
+ "type": "object"
87
+ },
88
+ "TokenImportReport_Conflict": {
89
+ "additionalProperties": false,
90
+ "description": "One record both sides hold with different contents.",
91
+ "properties": {
92
+ "fields": {
93
+ "description": "The record fields whose values differ.",
94
+ "items": {
95
+ "type": "string"
96
+ },
97
+ "type": "array"
98
+ },
99
+ "id": {
100
+ "type": "string"
101
+ }
102
+ },
103
+ "required": [
104
+ "id",
105
+ "fields"
106
+ ],
107
+ "type": "object"
108
+ }
109
+ },
110
+ "$id": "link-assistant-router/tokens-import/v1",
111
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
112
+ "additionalProperties": false,
113
+ "allOf": [
114
+ {
115
+ "else": {
116
+ "properties": {
117
+ "exit_code": {
118
+ "minimum": 1,
119
+ "type": "integer"
120
+ }
121
+ }
122
+ },
123
+ "if": {
124
+ "properties": {
125
+ "success": {
126
+ "const": true
127
+ }
128
+ }
129
+ },
130
+ "then": {
131
+ "properties": {
132
+ "exit_code": {
133
+ "const": 0
134
+ }
135
+ }
136
+ }
137
+ }
138
+ ],
139
+ "properties": {
140
+ "data": {
141
+ "anyOf": [
142
+ {
143
+ "$ref": "#/$defs/TokenImportReport"
144
+ },
145
+ {
146
+ "additionalProperties": false,
147
+ "properties": {
148
+ "output": {
149
+ "items": {
150
+ "type": "string"
151
+ },
152
+ "type": "array"
153
+ }
154
+ },
155
+ "required": [
156
+ "output"
157
+ ],
158
+ "type": "object"
159
+ }
160
+ ]
161
+ },
162
+ "diagnostics": {
163
+ "items": {
164
+ "type": "string"
165
+ },
166
+ "type": "array"
167
+ },
168
+ "exit_code": {
169
+ "maximum": 255,
170
+ "minimum": 0,
171
+ "type": "integer"
172
+ },
173
+ "operation": {
174
+ "const": "tokens.import"
175
+ },
176
+ "schema": {
177
+ "const": "link-assistant-router/tokens-import/v1"
178
+ },
179
+ "success": {
180
+ "type": "boolean"
181
+ }
182
+ },
183
+ "required": [
184
+ "schema",
185
+ "operation",
186
+ "success",
187
+ "exit_code",
188
+ "data",
189
+ "diagnostics"
190
+ ],
191
+ "type": "object"
192
+ }
@@ -0,0 +1,94 @@
1
+ {
2
+ "$defs": {},
3
+ "$id": "link-assistant-router/tokens-issue/v1",
4
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
5
+ "additionalProperties": false,
6
+ "allOf": [
7
+ {
8
+ "else": {
9
+ "properties": {
10
+ "exit_code": {
11
+ "minimum": 1,
12
+ "type": "integer"
13
+ }
14
+ }
15
+ },
16
+ "if": {
17
+ "properties": {
18
+ "success": {
19
+ "const": true
20
+ }
21
+ }
22
+ },
23
+ "then": {
24
+ "properties": {
25
+ "exit_code": {
26
+ "const": 0
27
+ }
28
+ }
29
+ }
30
+ }
31
+ ],
32
+ "properties": {
33
+ "data": {
34
+ "anyOf": [
35
+ {
36
+ "additionalProperties": false,
37
+ "properties": {
38
+ "token": {
39
+ "type": "string"
40
+ }
41
+ },
42
+ "required": [
43
+ "token"
44
+ ],
45
+ "type": "object"
46
+ },
47
+ {
48
+ "additionalProperties": false,
49
+ "properties": {
50
+ "output": {
51
+ "items": {
52
+ "type": "string"
53
+ },
54
+ "type": "array"
55
+ }
56
+ },
57
+ "required": [
58
+ "output"
59
+ ],
60
+ "type": "object"
61
+ }
62
+ ]
63
+ },
64
+ "diagnostics": {
65
+ "items": {
66
+ "type": "string"
67
+ },
68
+ "type": "array"
69
+ },
70
+ "exit_code": {
71
+ "maximum": 255,
72
+ "minimum": 0,
73
+ "type": "integer"
74
+ },
75
+ "operation": {
76
+ "const": "tokens.issue"
77
+ },
78
+ "schema": {
79
+ "const": "link-assistant-router/tokens-issue/v1"
80
+ },
81
+ "success": {
82
+ "type": "boolean"
83
+ }
84
+ },
85
+ "required": [
86
+ "schema",
87
+ "operation",
88
+ "success",
89
+ "exit_code",
90
+ "data",
91
+ "diagnostics"
92
+ ],
93
+ "type": "object"
94
+ }