@abapify/adt-server 0.0.0 → 0.4.5

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,1332 @@
1
+ import http from "node:http";
2
+ import { DestinationContextFactory, DestinationContextRegistry, DestinationLeaseProvider, McpInvocationVerifier, ToolContext } from "@abapify/adt-mcp";
3
+ import { AdtClient } from "@abapify/adt-client";
4
+ import { z } from "zod";
5
+ //#region src/rest-schemas.d.ts
6
+ declare const transportSourceManifestBody: z.ZodObject<{
7
+ transports: z.ZodArray<z.ZodString>;
8
+ }, z.core.$strict>;
9
+ /** Canonical ATC target set; an ADT URI is never a REST argument. */
10
+ declare const atcRunBody: z.ZodObject<{
11
+ scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
12
+ kind: z.ZodLiteral<"package">;
13
+ packageName: z.ZodString;
14
+ }, z.core.$strict>, z.ZodObject<{
15
+ kind: z.ZodLiteral<"transport_request">;
16
+ trkorr: z.ZodString;
17
+ }, z.core.$strict>, z.ZodObject<{
18
+ kind: z.ZodLiteral<"objects">;
19
+ objects: z.ZodArray<z.ZodObject<{
20
+ objectType: z.ZodString;
21
+ objectName: z.ZodString;
22
+ }, z.core.$strict>>;
23
+ }, z.core.$strict>], "kind">;
24
+ variant: z.ZodOptional<z.ZodString>;
25
+ }, z.core.$strict>;
26
+ /** Safe, URI-free ATC evidence. Documentation is a sealed capability. */
27
+ declare const atcFindingResponse: z.ZodObject<{
28
+ checkId: z.ZodString;
29
+ checkTitle: z.ZodString;
30
+ messageText: z.ZodString;
31
+ priority: z.ZodNumber;
32
+ objectType: z.ZodString;
33
+ objectName: z.ZodString;
34
+ lineStart: z.ZodOptional<z.ZodNumber>;
35
+ lineEnd: z.ZodOptional<z.ZodNumber>;
36
+ messageId: z.ZodOptional<z.ZodString>;
37
+ packageName: z.ZodOptional<z.ZodString>;
38
+ objectDescription: z.ZodOptional<z.ZodString>;
39
+ contactPerson: z.ZodOptional<z.ZodString>;
40
+ processor: z.ZodOptional<z.ZodString>;
41
+ lastChangedBy: z.ZodOptional<z.ZodString>;
42
+ exemptionKind: z.ZodOptional<z.ZodString>;
43
+ exemptionApproval: z.ZodOptional<z.ZodString>;
44
+ noExemption: z.ZodOptional<z.ZodBoolean>;
45
+ quickfixInfo: z.ZodOptional<z.ZodString>;
46
+ quickfixes: z.ZodOptional<z.ZodObject<{
47
+ manual: z.ZodOptional<z.ZodBoolean>;
48
+ automatic: z.ZodOptional<z.ZodBoolean>;
49
+ pseudo: z.ZodOptional<z.ZodBoolean>;
50
+ }, z.core.$strict>>;
51
+ checksum: z.ZodOptional<z.ZodString>;
52
+ documentationCapability: z.ZodOptional<z.ZodString>;
53
+ }, z.core.$strict>;
54
+ declare function parseTransportSearchQuery(input: unknown): {
55
+ includeTasks?: boolean | "true" | "false" | undefined;
56
+ owner?: string | undefined;
57
+ type?: string | undefined;
58
+ status?: string | undefined;
59
+ target?: string | undefined;
60
+ dateFrom?: string | undefined;
61
+ dateTo?: string | undefined;
62
+ text?: string | undefined;
63
+ };
64
+ declare function parsePackageSearchQuery(input: unknown): {
65
+ criteria: {
66
+ q?: string | undefined;
67
+ maxResults?: number | undefined;
68
+ };
69
+ page: {
70
+ cursor?: string | undefined;
71
+ limit: number;
72
+ };
73
+ };
74
+ declare function parseObjectSearchQuery(input: unknown): {
75
+ criteria: {
76
+ query?: string | undefined;
77
+ packageName?: string | undefined;
78
+ objectType?: string | undefined;
79
+ maxResults?: number | undefined;
80
+ };
81
+ page: {
82
+ cursor?: string | undefined;
83
+ limit: number;
84
+ };
85
+ };
86
+ type TransportSourceManifestInput = z.infer<typeof transportSourceManifestBody>;
87
+ type AtcRunBody = z.infer<typeof atcRunBody>;
88
+ type TransportSearchCriteria = ReturnType<typeof parseTransportSearchQuery>;
89
+ type PackageSearchCriteria = ReturnType<typeof parsePackageSearchQuery>['criteria'];
90
+ type ObjectSearchCriteria = ReturnType<typeof parseObjectSearchQuery>['criteria'];
91
+ //#endregion
92
+ //#region src/atc-documentation-capabilities.d.ts
93
+ interface RestAtcDocumentationCapabilityServiceOptions {
94
+ /** A production deployment shares this secret across all sidecar replicas. */
95
+ secret: string;
96
+ now?: () => number;
97
+ ttlMs?: number;
98
+ }
99
+ /**
100
+ * Issues short-lived encrypted capabilities for one trusted ATC-documentation
101
+ * relation. The ADT URI is neither visible in nor chosen by the REST client.
102
+ */
103
+ declare function createRestAtcDocumentationCapabilityService(options: RestAtcDocumentationCapabilityServiceOptions): {
104
+ issue(input: {
105
+ destination: string;
106
+ documentationUri: string;
107
+ }): string;
108
+ resolve(input: {
109
+ documentationCapability: string;
110
+ destination: string;
111
+ }): {
112
+ documentationUri: string;
113
+ };
114
+ };
115
+ //#endregion
116
+ //#region src/source-capabilities.d.ts
117
+ interface RestSourceCapabilityServiceOptions {
118
+ /** A production deployment shares this secret across all sidecar replicas. */
119
+ secret: string;
120
+ now?: () => number;
121
+ ttlMs?: number;
122
+ }
123
+ /**
124
+ * Issues short-lived encrypted immutable-source capabilities. The source URI
125
+ * is never a client-controlled input and is not readable from the capability.
126
+ */
127
+ declare function createRestSourceCapabilityService(options: RestSourceCapabilityServiceOptions): {
128
+ issue(input: {
129
+ destination: string;
130
+ sourceUri: string;
131
+ }): string;
132
+ resolve(input: {
133
+ sourceCapability: string;
134
+ destination: string;
135
+ }): {
136
+ sourceUri: string;
137
+ };
138
+ };
139
+ //#endregion
140
+ //#region src/page-cursors.d.ts
141
+ interface RestPageCursorServiceOptions {
142
+ /** Production replicas must share a mounted secret; tests may inject one. */
143
+ secret: string;
144
+ now?: () => number;
145
+ }
146
+ /**
147
+ * Creates integrity-protected, query-bound cursors for bounded fresh REST
148
+ * snapshots. Cursors contain no ADT URI, credentials, source or SAP body.
149
+ */
150
+ declare function createRestPageCursorService(options: RestPageCursorServiceOptions): {
151
+ paginate<T>(input: {
152
+ data: readonly T[];
153
+ limit: number;
154
+ cursor?: string;
155
+ fingerprint: string;
156
+ truncated: boolean;
157
+ keyOf: (item: T) => string;
158
+ }): {
159
+ data: T[];
160
+ nextCursor: string | null;
161
+ truncated: boolean;
162
+ observedAt: string;
163
+ };
164
+ };
165
+ //#endregion
166
+ //#region src/request-handler.d.ts
167
+ type RawSourceVersion = {
168
+ sourceUri: string;
169
+ };
170
+ type RawTransportSourceManifest = {
171
+ requestedTransports: unknown;
172
+ scopeTransports: unknown;
173
+ inventory: ReadonlyArray<{
174
+ uri?: string;
175
+ [key: string]: unknown;
176
+ }>;
177
+ entries: ReadonlyArray<{
178
+ component: {
179
+ sourceUri?: string;
180
+ versionsUri?: string;
181
+ };
182
+ base?: RawSourceVersion;
183
+ head?: RawSourceVersion;
184
+ }>;
185
+ };
186
+ type AtcRunOperationResult = {
187
+ checkVariant: string;
188
+ findings: Array<Omit<z.infer<typeof atcFindingResponse>, 'documentationCapability'> & {
189
+ /** Trusted broker-local relation; converted before the REST response. */
190
+ documentationUri?: string;
191
+ }>;
192
+ };
193
+ //#endregion
194
+ //#region src/server.d.ts
195
+ type AtcRunOperationInput = AtcRunBody & {
196
+ destination: string;
197
+ };
198
+ interface DestinationSummary {
199
+ key: string;
200
+ displayName: string;
201
+ systemSids: string[];
202
+ authConfigured: boolean;
203
+ version: number;
204
+ }
205
+ type FrozenSourceResolution = {
206
+ sourceUri: string;
207
+ } | {
208
+ sourceCapability: string;
209
+ };
210
+ type ResolveFrozenSource = (input: {
211
+ destination: string;
212
+ systemSid: string;
213
+ sourceRef: string;
214
+ }) => Promise<FrozenSourceResolution>;
215
+ /** The runtime supplies this from ADT's private broker; it never exposes a connection lease. */
216
+ interface AdtServerOperations {
217
+ listDestinations(): Promise<DestinationSummary[]>;
218
+ listTransports(destination: string, criteria?: TransportSearchCriteria): Promise<unknown>;
219
+ searchPackages(destination: string, criteria?: PackageSearchCriteria): Promise<unknown>;
220
+ /** Reads a bounded hierarchy below one named package; never a global forest. */
221
+ getPackageTree(destination: string, rootPackage: string): Promise<unknown>;
222
+ searchObjects(destination: string, criteria?: ObjectSearchCriteria): Promise<unknown>;
223
+ listPackageObjects(destination: string, packageName: string): Promise<unknown>;
224
+ /** Public canonical metadata projection; raw ADT URIs remain broker-local. */
225
+ getObjectMetadata?(destination: string, objectType: string, objectName: string): Promise<unknown>;
226
+ /** Unified BAdI read — classic SXSD/SXCI (vit/wb) or ENHO/XHH. */
227
+ getBadi?(destination: string, badiName: string, options?: {
228
+ includeImplementations?: boolean;
229
+ }): Promise<unknown>;
230
+ /** Public metadata-only history; immutable source locators remain local. */
231
+ getObjectSourceHistory?(destination: string, objectType: string, objectName: string): Promise<unknown>;
232
+ /** Bounded current/named source selected only by canonical object identity. */
233
+ readObjectSource?(input: {
234
+ destination: string;
235
+ objectType: string;
236
+ objectName: string;
237
+ version?: string;
238
+ }): Promise<{
239
+ bytes: number;
240
+ source: string;
241
+ }>;
242
+ /** Runs ATC from canonical scope selectors; ADT paths remain broker-local. */
243
+ runAtc?(input: AtcRunOperationInput): Promise<AtcRunOperationResult>;
244
+ /** Reads an issued ATC documentation relation under a caller-selected cap. */
245
+ readAtcFindingDocumentation?(input: {
246
+ destination: string;
247
+ documentationUri: string;
248
+ maxBytes: number;
249
+ }): Promise<{
250
+ bytes: number;
251
+ html: string;
252
+ }>;
253
+ /** Public canonical detail; never contains SAP URI fields. */
254
+ getTransportDetail?(destination: string, transport: string): Promise<unknown>;
255
+ /** Public canonical aggregate; never contains SAP URI fields. */
256
+ listTransportObjects?(destination: string, transport: string): Promise<unknown>;
257
+ /** Supplied by the broker adapter when immutable-source REST is enabled. */
258
+ buildTransportSourceManifest?(destination: string, input: TransportSourceManifestInput): Promise<RawTransportSourceManifest>;
259
+ /** Must enforce the requested byte limit before retaining an upstream body. */
260
+ readImmutableSource?(input: {
261
+ destination: string;
262
+ sourceUri: string;
263
+ maxBytes: number;
264
+ }): Promise<{
265
+ bytes: number;
266
+ source: string;
267
+ }>;
268
+ }
269
+ /**
270
+ * The only MCP configuration accepted by the shared ADT Server listener.
271
+ * The sidecar always creates an invocation-authenticated handler; callers
272
+ * cannot select a weaker HTTP authentication mode here.
273
+ */
274
+ interface AdtServerMcpOptions {
275
+ invocationVerifier: McpInvocationVerifier;
276
+ /** Ownership transfers to the running server, which shuts it down on close. */
277
+ destinationRegistry: DestinationContextRegistry;
278
+ /**
279
+ * Private ADT broker resolver for the opaque, signed source capabilities
280
+ * carried only in an AI Review invocation policy.
281
+ */
282
+ resolveFrozenSource: ResolveFrozenSource;
283
+ /** Deployment-owned atomic authorization hook. */
284
+ consumeExecutionAuthorization?: NonNullable<import('@abapify/adt-mcp').ToolContext['consumeExecutionAuthorization']>;
285
+ /** Deployment-owned terminal outcome hook. */
286
+ reportExecutionOutcome?: NonNullable<import('@abapify/adt-mcp').ToolContext['reportExecutionOutcome']>;
287
+ /** Hard-cancellable SAP runtime; safe execution is denied when absent. */
288
+ executeWithDeadline?: NonNullable<import('@abapify/adt-mcp').ToolContext['executeWithDeadline']>;
289
+ allowedHosts?: string[];
290
+ }
291
+ /**
292
+ * Authenticates trusted service-to-service callers of the broker-backed REST
293
+ * compatibility API. The broker credential must never be accepted inbound.
294
+ */
295
+ interface RestServiceAuthorizer {
296
+ authorize(request: http.IncomingMessage): boolean | Promise<boolean>;
297
+ }
298
+ interface AdtServerOptions {
299
+ operations: AdtServerOperations;
300
+ host?: string;
301
+ port?: number;
302
+ mcp?: AdtServerMcpOptions;
303
+ restAuthorizer?: RestServiceAuthorizer;
304
+ /** Production REST uses a deployment-shared secret; tests may use a local one. */
305
+ sourceCapabilities?: ReturnType<typeof createRestSourceCapabilityService>;
306
+ /** Override the default test secret used to create source capabilities. */
307
+ sourceCapabilitiesSecret?: string;
308
+ /** Shares REST state with source capabilities across sidecar replicas. */
309
+ atcDocumentationCapabilities?: ReturnType<typeof createRestAtcDocumentationCapabilityService>;
310
+ /** Override the default test secret used to create ATC documentation capabilities. */
311
+ atcDocumentationCapabilitiesSecret?: string;
312
+ pageCursors?: ReturnType<typeof createRestPageCursorService>;
313
+ /** Override the default test secret used to create page cursors. */
314
+ pageCursorSecret?: string;
315
+ }
316
+ interface RunningAdtServer {
317
+ url: string;
318
+ close(): Promise<void>;
319
+ }
320
+ declare function startAdtServer(options: AdtServerOptions): Promise<RunningAdtServer>;
321
+ //#endregion
322
+ //#region src/openapi.d.ts
323
+ /** Deterministic, owned OpenAPI document. Route schemas are deliberately
324
+ * destination-only; SAP URLs and credentials never occur in this contract. */
325
+ declare const openApiDocument: {
326
+ readonly openapi: "3.1.0";
327
+ readonly info: {
328
+ readonly title: "ADT Server";
329
+ readonly version: "1.0.0";
330
+ };
331
+ readonly paths: {
332
+ readonly '/v1/destinations': {
333
+ readonly get: {
334
+ readonly operationId: "listDestinations";
335
+ readonly responses: {
336
+ readonly '200': {
337
+ readonly description: "Accessible safe destination summaries";
338
+ readonly content: {
339
+ readonly 'application/json': {
340
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
341
+ data: z.ZodArray<z.ZodObject<{
342
+ key: z.ZodString;
343
+ displayName: z.ZodString;
344
+ systemSids: z.ZodArray<z.ZodString>;
345
+ authConfigured: z.ZodBoolean;
346
+ version: z.ZodNumber;
347
+ }, z.core.$strict>>;
348
+ }, z.core.$strict>>;
349
+ };
350
+ };
351
+ };
352
+ };
353
+ };
354
+ };
355
+ readonly '/v1/destinations/{destination}/transports': {
356
+ readonly get: {
357
+ readonly operationId: "listTransports";
358
+ readonly parameters: readonly [{
359
+ readonly $ref: "#/components/parameters/destination";
360
+ }, {
361
+ name: string;
362
+ in: string;
363
+ required: boolean;
364
+ description: string;
365
+ schema: unknown;
366
+ }, {
367
+ name: string;
368
+ in: string;
369
+ required: boolean;
370
+ description: string;
371
+ schema: unknown;
372
+ }, {
373
+ name: string;
374
+ in: string;
375
+ required: boolean;
376
+ description: string;
377
+ schema: unknown;
378
+ }, {
379
+ name: string;
380
+ in: string;
381
+ required: boolean;
382
+ description: string;
383
+ schema: unknown;
384
+ }, {
385
+ name: string;
386
+ in: string;
387
+ required: boolean;
388
+ description: string;
389
+ schema: unknown;
390
+ }, {
391
+ name: string;
392
+ in: string;
393
+ required: boolean;
394
+ description: string;
395
+ schema: unknown;
396
+ }, {
397
+ name: string;
398
+ in: string;
399
+ required: boolean;
400
+ description: string;
401
+ schema: unknown;
402
+ }, {
403
+ name: string;
404
+ in: string;
405
+ required: boolean;
406
+ description: string;
407
+ schema: unknown;
408
+ }];
409
+ readonly responses: {
410
+ readonly '200': {
411
+ readonly description: "Normalized system-wide transport headers";
412
+ readonly content: {
413
+ readonly 'application/json': {
414
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodArray<z.ZodObject<{
415
+ trkorr: z.ZodString;
416
+ owner: z.ZodString;
417
+ description: z.ZodString;
418
+ status: z.ZodString;
419
+ statusRaw: z.ZodOptional<z.ZodString>;
420
+ trFunction: z.ZodOptional<z.ZodString>;
421
+ target: z.ZodOptional<z.ZodString>;
422
+ client: z.ZodOptional<z.ZodString>;
423
+ changedAt: z.ZodOptional<z.ZodString>;
424
+ }, z.core.$strict>>>;
425
+ };
426
+ };
427
+ };
428
+ readonly '400': {
429
+ readonly description: "Invalid request";
430
+ };
431
+ };
432
+ };
433
+ };
434
+ readonly '/v1/destinations/{destination}/transports/{transport}': {
435
+ readonly get: {
436
+ readonly operationId: "getTransportDetail";
437
+ readonly parameters: readonly [{
438
+ readonly $ref: "#/components/parameters/destination";
439
+ }, {
440
+ readonly $ref: "#/components/parameters/transport";
441
+ }];
442
+ readonly responses: {
443
+ readonly '200': {
444
+ readonly description: "Request/task hierarchy with canonical object references";
445
+ readonly content: {
446
+ readonly 'application/json': {
447
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
448
+ trkorr: z.ZodString;
449
+ owner: z.ZodString;
450
+ description: z.ZodString;
451
+ status: z.ZodString;
452
+ statusRaw: z.ZodOptional<z.ZodString>;
453
+ trFunction: z.ZodOptional<z.ZodString>;
454
+ target: z.ZodOptional<z.ZodString>;
455
+ client: z.ZodOptional<z.ZodString>;
456
+ changedAt: z.ZodOptional<z.ZodString>;
457
+ tasks: z.ZodArray<z.ZodObject<{
458
+ trkorr: z.ZodString;
459
+ owner: z.ZodString;
460
+ description: z.ZodString;
461
+ status: z.ZodString;
462
+ statusRaw: z.ZodOptional<z.ZodString>;
463
+ trFunction: z.ZodOptional<z.ZodString>;
464
+ target: z.ZodOptional<z.ZodString>;
465
+ client: z.ZodOptional<z.ZodString>;
466
+ changedAt: z.ZodOptional<z.ZodString>;
467
+ parentTrkorr: z.ZodString;
468
+ objects: z.ZodArray<z.ZodObject<{
469
+ canonicalKey: z.ZodString;
470
+ objectType: z.ZodString;
471
+ objectName: z.ZodString;
472
+ pgmid: z.ZodOptional<z.ZodString>;
473
+ objInfo: z.ZodOptional<z.ZodString>;
474
+ objDesc: z.ZodOptional<z.ZodString>;
475
+ lockStatus: z.ZodOptional<z.ZodString>;
476
+ }, z.core.$strict>>;
477
+ }, z.core.$strict>>;
478
+ objects: z.ZodArray<z.ZodObject<{
479
+ canonicalKey: z.ZodString;
480
+ objectType: z.ZodString;
481
+ objectName: z.ZodString;
482
+ pgmid: z.ZodOptional<z.ZodString>;
483
+ objInfo: z.ZodOptional<z.ZodString>;
484
+ objDesc: z.ZodOptional<z.ZodString>;
485
+ lockStatus: z.ZodOptional<z.ZodString>;
486
+ }, z.core.$strict>>;
487
+ }, z.core.$strict>>;
488
+ };
489
+ };
490
+ };
491
+ readonly '400': {
492
+ readonly description: "Invalid request";
493
+ };
494
+ };
495
+ };
496
+ };
497
+ readonly '/v1/destinations/{destination}/transports/{transport}/objects': {
498
+ readonly get: {
499
+ readonly operationId: "listTransportObjects";
500
+ readonly parameters: readonly [{
501
+ readonly $ref: "#/components/parameters/destination";
502
+ }, {
503
+ readonly $ref: "#/components/parameters/transport";
504
+ }];
505
+ readonly responses: {
506
+ readonly '200': {
507
+ readonly description: "Canonical object references aggregated over request and tasks";
508
+ readonly content: {
509
+ readonly 'application/json': {
510
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodArray<z.ZodObject<{
511
+ canonicalKey: z.ZodString;
512
+ objectType: z.ZodString;
513
+ objectName: z.ZodString;
514
+ pgmid: z.ZodOptional<z.ZodString>;
515
+ objInfo: z.ZodOptional<z.ZodString>;
516
+ objDesc: z.ZodOptional<z.ZodString>;
517
+ lockStatus: z.ZodOptional<z.ZodString>;
518
+ }, z.core.$strict>>>;
519
+ };
520
+ };
521
+ };
522
+ readonly '400': {
523
+ readonly description: "Invalid request";
524
+ };
525
+ };
526
+ };
527
+ };
528
+ readonly '/v1/destinations/{destination}/transport-source-manifests': {
529
+ readonly post: {
530
+ readonly operationId: "buildTransportSourceManifest";
531
+ readonly parameters: readonly [{
532
+ readonly $ref: "#/components/parameters/destination";
533
+ }];
534
+ readonly requestBody: {
535
+ readonly required: true;
536
+ readonly content: {
537
+ readonly 'application/json': {
538
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
539
+ transports: z.ZodArray<z.ZodString>;
540
+ }, z.core.$strict>>;
541
+ };
542
+ };
543
+ };
544
+ readonly responses: {
545
+ readonly '200': {
546
+ readonly description: "Metadata-only transport source manifest with opaque source capabilities";
547
+ readonly content: {
548
+ readonly 'application/json': {
549
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
550
+ requestedTransports: z.ZodArray<z.ZodString>;
551
+ scopeTransports: z.ZodArray<z.ZodString>;
552
+ inventory: z.ZodArray<z.ZodObject<{
553
+ pgmid: z.ZodString;
554
+ type: z.ZodString;
555
+ name: z.ZodString;
556
+ wbtype: z.ZodOptional<z.ZodString>;
557
+ objFunc: z.ZodString;
558
+ sourceTransport: z.ZodString;
559
+ }, z.core.$strict>>;
560
+ entries: z.ZodArray<z.ZodObject<{
561
+ object: z.ZodObject<{
562
+ pgmid: z.ZodString;
563
+ type: z.ZodString;
564
+ name: z.ZodString;
565
+ packageName: z.ZodOptional<z.ZodString>;
566
+ }, z.core.$strict>;
567
+ repositoryObject: z.ZodOptional<z.ZodObject<{
568
+ pgmid: z.ZodString;
569
+ type: z.ZodString;
570
+ name: z.ZodString;
571
+ packageName: z.ZodOptional<z.ZodString>;
572
+ }, z.core.$strict>>;
573
+ component: z.ZodObject<{
574
+ id: z.ZodString;
575
+ }, z.core.$strict>;
576
+ sourceTransport: z.ZodString;
577
+ changeKind: z.ZodEnum<{
578
+ added: "added";
579
+ modified: "modified";
580
+ deleted: "deleted";
581
+ unchanged: "unchanged";
582
+ ambiguous: "ambiguous";
583
+ unsupported: "unsupported";
584
+ failed: "failed";
585
+ }>;
586
+ exact: z.ZodBoolean;
587
+ base: z.ZodOptional<z.ZodObject<{
588
+ id: z.ZodString;
589
+ ordinal: z.ZodNumber;
590
+ title: z.ZodOptional<z.ZodString>;
591
+ contentType: z.ZodOptional<z.ZodString>;
592
+ etag: z.ZodOptional<z.ZodString>;
593
+ updatedAt: z.ZodOptional<z.ZodString>;
594
+ author: z.ZodOptional<z.ZodString>;
595
+ transports: z.ZodArray<z.ZodString>;
596
+ sourceCapability: z.ZodString;
597
+ }, z.core.$strict>>;
598
+ head: z.ZodOptional<z.ZodObject<{
599
+ id: z.ZodString;
600
+ ordinal: z.ZodNumber;
601
+ title: z.ZodOptional<z.ZodString>;
602
+ contentType: z.ZodOptional<z.ZodString>;
603
+ etag: z.ZodOptional<z.ZodString>;
604
+ updatedAt: z.ZodOptional<z.ZodString>;
605
+ author: z.ZodOptional<z.ZodString>;
606
+ transports: z.ZodArray<z.ZodString>;
607
+ sourceCapability: z.ZodString;
608
+ }, z.core.$strict>>;
609
+ diagnostic: z.ZodOptional<z.ZodObject<{
610
+ code: z.ZodString;
611
+ message: z.ZodString;
612
+ }, z.core.$strict>>;
613
+ }, z.core.$strict>>;
614
+ }, z.core.$strict>>;
615
+ };
616
+ };
617
+ };
618
+ readonly '400': {
619
+ readonly description: "Invalid request";
620
+ };
621
+ };
622
+ };
623
+ };
624
+ readonly '/v1/destinations/{destination}/source-versions:read': {
625
+ readonly post: {
626
+ readonly operationId: "readSourceVersion";
627
+ readonly parameters: readonly [{
628
+ readonly $ref: "#/components/parameters/destination";
629
+ }];
630
+ readonly requestBody: {
631
+ readonly required: true;
632
+ readonly content: {
633
+ readonly 'application/json': {
634
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
635
+ sourceCapability: z.ZodString;
636
+ maxBytes: z.ZodNumber;
637
+ }, z.core.$strict>>;
638
+ };
639
+ };
640
+ };
641
+ readonly responses: {
642
+ readonly '200': {
643
+ readonly description: "Complete immutable source body under byte cap";
644
+ readonly content: {
645
+ readonly 'application/json': {
646
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
647
+ bytes: z.ZodNumber;
648
+ source: z.ZodString;
649
+ }, z.core.$strict>>;
650
+ };
651
+ };
652
+ };
653
+ readonly '400': {
654
+ readonly description: "Invalid request";
655
+ };
656
+ readonly '404': {
657
+ readonly description: "Source capability unavailable";
658
+ };
659
+ readonly '413': {
660
+ readonly description: "Source exceeds requested byte cap";
661
+ };
662
+ };
663
+ };
664
+ };
665
+ readonly '/v1/destinations/{destination}/packages': {
666
+ readonly get: {
667
+ readonly operationId: "searchPackages";
668
+ readonly parameters: readonly [{
669
+ readonly $ref: "#/components/parameters/destination";
670
+ }, {
671
+ name: string;
672
+ in: string;
673
+ required: boolean;
674
+ description: string;
675
+ schema: unknown;
676
+ }, {
677
+ name: string;
678
+ in: string;
679
+ required: boolean;
680
+ description: string;
681
+ schema: unknown;
682
+ }, {
683
+ name: string;
684
+ in: string;
685
+ required: boolean;
686
+ description: string;
687
+ schema: unknown;
688
+ }, {
689
+ name: string;
690
+ in: string;
691
+ required: boolean;
692
+ description: string;
693
+ schema: unknown;
694
+ }];
695
+ readonly responses: {
696
+ readonly '200': {
697
+ readonly description: "Bounded canonical package search page";
698
+ readonly content: {
699
+ readonly 'application/json': {
700
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
701
+ data: z.ZodArray<z.ZodObject<{
702
+ name: z.ZodString;
703
+ parent: z.ZodOptional<z.ZodString>;
704
+ description: z.ZodOptional<z.ZodString>;
705
+ }, z.core.$strict>>;
706
+ nextCursor: z.ZodNullable<z.ZodString>;
707
+ truncated: z.ZodBoolean;
708
+ observedAt: z.ZodString;
709
+ }, z.core.$strict>>;
710
+ };
711
+ };
712
+ };
713
+ readonly '400': {
714
+ readonly description: "Invalid request";
715
+ };
716
+ };
717
+ };
718
+ };
719
+ readonly '/v1/destinations/{destination}/packages/tree': {
720
+ readonly get: {
721
+ readonly operationId: "getPackageTree";
722
+ readonly parameters: readonly [{
723
+ readonly $ref: "#/components/parameters/destination";
724
+ }, {
725
+ readonly name: "root";
726
+ readonly in: "query";
727
+ readonly required: true;
728
+ readonly description: "Named package root. The service never enumerates a global package forest.";
729
+ readonly schema: unknown;
730
+ }, {
731
+ readonly name: "limit";
732
+ readonly in: "query";
733
+ readonly required: false;
734
+ readonly description: "Page size, maximum 200";
735
+ readonly schema: unknown;
736
+ }, {
737
+ readonly name: "cursor";
738
+ readonly in: "query";
739
+ readonly required: false;
740
+ readonly description: "Opaque root-bound page cursor";
741
+ readonly schema: unknown;
742
+ }];
743
+ readonly responses: {
744
+ readonly '200': {
745
+ readonly description: "Bounded canonical package subtree rooted at the requested package";
746
+ readonly content: {
747
+ readonly 'application/json': {
748
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
749
+ data: z.ZodArray<z.ZodObject<{
750
+ name: z.ZodString;
751
+ parent: z.ZodOptional<z.ZodString>;
752
+ description: z.ZodOptional<z.ZodString>;
753
+ }, z.core.$strict>>;
754
+ nextCursor: z.ZodNullable<z.ZodString>;
755
+ truncated: z.ZodBoolean;
756
+ observedAt: z.ZodString;
757
+ }, z.core.$strict>>;
758
+ };
759
+ };
760
+ };
761
+ readonly '400': {
762
+ readonly description: "Invalid request";
763
+ };
764
+ };
765
+ };
766
+ };
767
+ readonly '/v1/destinations/{destination}/packages/{package}/objects': {
768
+ readonly get: {
769
+ readonly operationId: "listPackageObjects";
770
+ readonly parameters: readonly [{
771
+ readonly $ref: "#/components/parameters/destination";
772
+ }, {
773
+ readonly $ref: "#/components/parameters/package";
774
+ }, {
775
+ name: string;
776
+ in: string;
777
+ required: boolean;
778
+ description: string;
779
+ schema: unknown;
780
+ }, {
781
+ name: string;
782
+ in: string;
783
+ required: boolean;
784
+ description: string;
785
+ schema: unknown;
786
+ }];
787
+ readonly responses: {
788
+ readonly '200': {
789
+ readonly description: "Bounded direct package objects with canonical identity";
790
+ readonly content: {
791
+ readonly 'application/json': {
792
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
793
+ data: z.ZodArray<z.ZodObject<{
794
+ canonicalKey: z.ZodString;
795
+ objectType: z.ZodString;
796
+ objectName: z.ZodString;
797
+ pgmid: z.ZodOptional<z.ZodString>;
798
+ objInfo: z.ZodOptional<z.ZodString>;
799
+ objDesc: z.ZodOptional<z.ZodString>;
800
+ lockStatus: z.ZodOptional<z.ZodString>;
801
+ packageName: z.ZodOptional<z.ZodString>;
802
+ description: z.ZodOptional<z.ZodString>;
803
+ }, z.core.$strict>>;
804
+ nextCursor: z.ZodNullable<z.ZodString>;
805
+ truncated: z.ZodBoolean;
806
+ observedAt: z.ZodString;
807
+ }, z.core.$strict>>;
808
+ };
809
+ };
810
+ };
811
+ readonly '400': {
812
+ readonly description: "Invalid request";
813
+ };
814
+ };
815
+ };
816
+ };
817
+ readonly '/v1/destinations/{destination}/objects': {
818
+ readonly get: {
819
+ readonly operationId: "searchObjects";
820
+ readonly parameters: readonly [{
821
+ readonly $ref: "#/components/parameters/destination";
822
+ }, {
823
+ name: string;
824
+ in: string;
825
+ required: boolean;
826
+ description: string;
827
+ schema: unknown;
828
+ }, {
829
+ name: string;
830
+ in: string;
831
+ required: boolean;
832
+ description: string;
833
+ schema: unknown;
834
+ }, {
835
+ name: string;
836
+ in: string;
837
+ required: boolean;
838
+ description: string;
839
+ schema: unknown;
840
+ }, {
841
+ name: string;
842
+ in: string;
843
+ required: boolean;
844
+ description: string;
845
+ schema: unknown;
846
+ }, {
847
+ name: string;
848
+ in: string;
849
+ required: boolean;
850
+ description: string;
851
+ schema: unknown;
852
+ }, {
853
+ name: string;
854
+ in: string;
855
+ required: boolean;
856
+ description: string;
857
+ schema: unknown;
858
+ }];
859
+ readonly responses: {
860
+ readonly '200': {
861
+ readonly description: "Bounded canonical repository object search page";
862
+ readonly content: {
863
+ readonly 'application/json': {
864
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
865
+ data: z.ZodArray<z.ZodObject<{
866
+ canonicalKey: z.ZodString;
867
+ objectType: z.ZodString;
868
+ objectName: z.ZodString;
869
+ pgmid: z.ZodOptional<z.ZodString>;
870
+ objInfo: z.ZodOptional<z.ZodString>;
871
+ objDesc: z.ZodOptional<z.ZodString>;
872
+ lockStatus: z.ZodOptional<z.ZodString>;
873
+ packageName: z.ZodOptional<z.ZodString>;
874
+ description: z.ZodOptional<z.ZodString>;
875
+ }, z.core.$strict>>;
876
+ nextCursor: z.ZodNullable<z.ZodString>;
877
+ truncated: z.ZodBoolean;
878
+ observedAt: z.ZodString;
879
+ }, z.core.$strict>>;
880
+ };
881
+ };
882
+ };
883
+ readonly '400': {
884
+ readonly description: "Invalid request";
885
+ };
886
+ };
887
+ };
888
+ };
889
+ readonly '/v1/destinations/{destination}/objects/{type}/{name}': {
890
+ readonly get: {
891
+ readonly operationId: "getObjectMetadata";
892
+ readonly parameters: readonly [{
893
+ readonly $ref: "#/components/parameters/destination";
894
+ }, {
895
+ readonly $ref: "#/components/parameters/objectType";
896
+ }, {
897
+ readonly $ref: "#/components/parameters/objectName";
898
+ }];
899
+ readonly responses: {
900
+ readonly '200': {
901
+ readonly description: "Canonical object metadata, facets and allowlisted relation capabilities";
902
+ readonly content: {
903
+ readonly 'application/json': {
904
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
905
+ object: z.ZodObject<{
906
+ canonicalKey: z.ZodString;
907
+ objectType: z.ZodString;
908
+ objectName: z.ZodString;
909
+ pgmid: z.ZodOptional<z.ZodString>;
910
+ objInfo: z.ZodOptional<z.ZodString>;
911
+ objDesc: z.ZodOptional<z.ZodString>;
912
+ lockStatus: z.ZodOptional<z.ZodString>;
913
+ packageName: z.ZodOptional<z.ZodString>;
914
+ description: z.ZodOptional<z.ZodString>;
915
+ }, z.core.$strict>;
916
+ metadata: z.ZodObject<{
917
+ adtObjectType: z.ZodOptional<z.ZodString>;
918
+ description: z.ZodOptional<z.ZodString>;
919
+ packageName: z.ZodOptional<z.ZodString>;
920
+ }, z.core.$strict>;
921
+ facets: z.ZodArray<z.ZodObject<{
922
+ facet: z.ZodOptional<z.ZodString>;
923
+ name: z.ZodOptional<z.ZodString>;
924
+ displayName: z.ZodOptional<z.ZodString>;
925
+ text: z.ZodOptional<z.ZodString>;
926
+ version: z.ZodOptional<z.ZodString>;
927
+ hasChildrenOfSameFacet: z.ZodOptional<z.ZodBoolean>;
928
+ }, z.core.$strict>>;
929
+ capabilities: z.ZodArray<z.ZodObject<{
930
+ relation: z.ZodString;
931
+ capability: z.ZodEnum<{
932
+ source: "source";
933
+ versions: "versions";
934
+ structure: "structure";
935
+ text_elements: "text_elements";
936
+ enhancement_implementations: "enhancement_implementations";
937
+ enhancement_options: "enhancement_options";
938
+ syntax: "syntax";
939
+ }>;
940
+ title: z.ZodOptional<z.ZodString>;
941
+ mediaType: z.ZodOptional<z.ZodString>;
942
+ etag: z.ZodOptional<z.ZodString>;
943
+ }, z.core.$strict>>;
944
+ }, z.core.$strict>>;
945
+ };
946
+ };
947
+ };
948
+ readonly '400': {
949
+ readonly description: "Invalid request";
950
+ };
951
+ };
952
+ };
953
+ };
954
+ readonly '/v1/destinations/{destination}/badi/{name}': {
955
+ readonly get: {
956
+ readonly operationId: "getBadi";
957
+ readonly parameters: readonly [{
958
+ readonly $ref: "#/components/parameters/destination";
959
+ }, {
960
+ readonly name: "name";
961
+ readonly in: "path";
962
+ readonly required: true;
963
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodString>;
964
+ readonly description: "BAdI name — definition, implementation, or ENHO container";
965
+ }, {
966
+ readonly name: "implementations";
967
+ readonly in: "query";
968
+ readonly required: false;
969
+ readonly schema: {
970
+ readonly type: "boolean";
971
+ };
972
+ readonly description: "When name is a classic definition (SXSD/XD), include its SXCI/XI implementations";
973
+ }];
974
+ readonly responses: {
975
+ readonly '200': {
976
+ readonly description: "Canonical BAdI metadata; kind is resolved from repository type";
977
+ readonly content: {
978
+ readonly 'application/json': {
979
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
980
+ kind: z.ZodEnum<{
981
+ definition: "definition";
982
+ implementation: "implementation";
983
+ enhancement: "enhancement";
984
+ }>;
985
+ name: z.ZodString;
986
+ type: z.ZodString;
987
+ description: z.ZodOptional<z.ZodString>;
988
+ language: z.ZodOptional<z.ZodString>;
989
+ version: z.ZodOptional<z.ZodString>;
990
+ packageName: z.ZodOptional<z.ZodString>;
991
+ packageUri: z.ZodOptional<z.ZodString>;
992
+ responsible: z.ZodOptional<z.ZodString>;
993
+ masterLanguage: z.ZodOptional<z.ZodString>;
994
+ masterSystem: z.ZodOptional<z.ZodString>;
995
+ implementations: z.ZodOptional<z.ZodArray<z.ZodObject<{
996
+ kind: z.ZodLiteral<"implementation">;
997
+ name: z.ZodString;
998
+ type: z.ZodString;
999
+ description: z.ZodOptional<z.ZodString>;
1000
+ language: z.ZodOptional<z.ZodString>;
1001
+ version: z.ZodOptional<z.ZodString>;
1002
+ packageName: z.ZodOptional<z.ZodString>;
1003
+ packageUri: z.ZodOptional<z.ZodString>;
1004
+ responsible: z.ZodOptional<z.ZodString>;
1005
+ masterLanguage: z.ZodOptional<z.ZodString>;
1006
+ masterSystem: z.ZodOptional<z.ZodString>;
1007
+ }, z.core.$strict>>>;
1008
+ }, z.core.$strict>>;
1009
+ };
1010
+ };
1011
+ };
1012
+ readonly '400': {
1013
+ readonly description: "Invalid request";
1014
+ };
1015
+ };
1016
+ };
1017
+ };
1018
+ readonly '/v1/destinations/{destination}/objects/{type}/{name}/source-history': {
1019
+ readonly get: {
1020
+ readonly operationId: "getObjectSourceHistory";
1021
+ readonly parameters: readonly [{
1022
+ readonly $ref: "#/components/parameters/destination";
1023
+ }, {
1024
+ readonly $ref: "#/components/parameters/objectType";
1025
+ }, {
1026
+ readonly $ref: "#/components/parameters/objectName";
1027
+ }];
1028
+ readonly responses: {
1029
+ readonly '200': {
1030
+ readonly description: "Metadata-only canonical object source history";
1031
+ readonly content: {
1032
+ readonly 'application/json': {
1033
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
1034
+ available: z.ZodBoolean;
1035
+ versions: z.ZodArray<z.ZodObject<{
1036
+ id: z.ZodString;
1037
+ ordinal: z.ZodNumber;
1038
+ title: z.ZodOptional<z.ZodString>;
1039
+ contentType: z.ZodOptional<z.ZodString>;
1040
+ etag: z.ZodOptional<z.ZodString>;
1041
+ updatedAt: z.ZodOptional<z.ZodString>;
1042
+ author: z.ZodOptional<z.ZodString>;
1043
+ transports: z.ZodArray<z.ZodString>;
1044
+ }, z.core.$strict>>;
1045
+ }, z.core.$strict>>;
1046
+ };
1047
+ };
1048
+ };
1049
+ readonly '400': {
1050
+ readonly description: "Invalid request";
1051
+ };
1052
+ };
1053
+ };
1054
+ };
1055
+ readonly '/v1/destinations/{destination}/objects/{type}/{name}/source:read': {
1056
+ readonly post: {
1057
+ readonly operationId: "readObjectSource";
1058
+ readonly parameters: readonly [{
1059
+ readonly $ref: "#/components/parameters/destination";
1060
+ }, {
1061
+ readonly $ref: "#/components/parameters/objectType";
1062
+ }, {
1063
+ readonly $ref: "#/components/parameters/objectName";
1064
+ }];
1065
+ readonly requestBody: {
1066
+ readonly required: true;
1067
+ readonly content: {
1068
+ readonly 'application/json': {
1069
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
1070
+ version: z.ZodOptional<z.ZodString>;
1071
+ }, z.core.$strict>>;
1072
+ };
1073
+ };
1074
+ };
1075
+ readonly responses: {
1076
+ readonly '200': {
1077
+ readonly description: "Complete bounded canonical object source body";
1078
+ readonly content: {
1079
+ readonly 'application/json': {
1080
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
1081
+ bytes: z.ZodNumber;
1082
+ source: z.ZodString;
1083
+ }, z.core.$strict>>;
1084
+ };
1085
+ };
1086
+ };
1087
+ readonly '400': {
1088
+ readonly description: "Invalid request";
1089
+ };
1090
+ readonly '413': {
1091
+ readonly description: "Source exceeds the fixed byte cap";
1092
+ };
1093
+ };
1094
+ };
1095
+ };
1096
+ readonly '/v1/destinations/{destination}/atc-runs': {
1097
+ readonly post: {
1098
+ readonly operationId: "runAtc";
1099
+ readonly parameters: readonly [{
1100
+ readonly $ref: "#/components/parameters/destination";
1101
+ }];
1102
+ readonly requestBody: {
1103
+ readonly required: true;
1104
+ readonly content: {
1105
+ readonly 'application/json': {
1106
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
1107
+ scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
1108
+ kind: z.ZodLiteral<"package">;
1109
+ packageName: z.ZodString;
1110
+ }, z.core.$strict>, z.ZodObject<{
1111
+ kind: z.ZodLiteral<"transport_request">;
1112
+ trkorr: z.ZodString;
1113
+ }, z.core.$strict>, z.ZodObject<{
1114
+ kind: z.ZodLiteral<"objects">;
1115
+ objects: z.ZodArray<z.ZodObject<{
1116
+ objectType: z.ZodString;
1117
+ objectName: z.ZodString;
1118
+ }, z.core.$strict>>;
1119
+ }, z.core.$strict>], "kind">;
1120
+ variant: z.ZodOptional<z.ZodString>;
1121
+ }, z.core.$strict>>;
1122
+ };
1123
+ };
1124
+ };
1125
+ readonly responses: {
1126
+ readonly '200': {
1127
+ readonly description: "Normalized ATC findings with opaque documentation capabilities";
1128
+ readonly content: {
1129
+ readonly 'application/json': {
1130
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
1131
+ checkVariant: z.ZodString;
1132
+ findings: z.ZodArray<z.ZodObject<{
1133
+ checkId: z.ZodString;
1134
+ checkTitle: z.ZodString;
1135
+ messageText: z.ZodString;
1136
+ priority: z.ZodNumber;
1137
+ objectType: z.ZodString;
1138
+ objectName: z.ZodString;
1139
+ lineStart: z.ZodOptional<z.ZodNumber>;
1140
+ lineEnd: z.ZodOptional<z.ZodNumber>;
1141
+ messageId: z.ZodOptional<z.ZodString>;
1142
+ packageName: z.ZodOptional<z.ZodString>;
1143
+ objectDescription: z.ZodOptional<z.ZodString>;
1144
+ contactPerson: z.ZodOptional<z.ZodString>;
1145
+ processor: z.ZodOptional<z.ZodString>;
1146
+ lastChangedBy: z.ZodOptional<z.ZodString>;
1147
+ exemptionKind: z.ZodOptional<z.ZodString>;
1148
+ exemptionApproval: z.ZodOptional<z.ZodString>;
1149
+ noExemption: z.ZodOptional<z.ZodBoolean>;
1150
+ quickfixInfo: z.ZodOptional<z.ZodString>;
1151
+ quickfixes: z.ZodOptional<z.ZodObject<{
1152
+ manual: z.ZodOptional<z.ZodBoolean>;
1153
+ automatic: z.ZodOptional<z.ZodBoolean>;
1154
+ pseudo: z.ZodOptional<z.ZodBoolean>;
1155
+ }, z.core.$strict>>;
1156
+ checksum: z.ZodOptional<z.ZodString>;
1157
+ documentationCapability: z.ZodOptional<z.ZodString>;
1158
+ }, z.core.$strict>>;
1159
+ }, z.core.$strict>>;
1160
+ };
1161
+ };
1162
+ };
1163
+ readonly '400': {
1164
+ readonly description: "Invalid request";
1165
+ };
1166
+ };
1167
+ };
1168
+ };
1169
+ readonly '/v1/destinations/{destination}/atc-finding-documentation:read': {
1170
+ readonly post: {
1171
+ readonly operationId: "readAtcFindingDocumentation";
1172
+ readonly parameters: readonly [{
1173
+ readonly $ref: "#/components/parameters/destination";
1174
+ }];
1175
+ readonly requestBody: {
1176
+ readonly required: true;
1177
+ readonly content: {
1178
+ readonly 'application/json': {
1179
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
1180
+ documentationCapability: z.ZodString;
1181
+ maxBytes: z.ZodOptional<z.ZodNumber>;
1182
+ }, z.core.$strict>>;
1183
+ };
1184
+ };
1185
+ };
1186
+ readonly responses: {
1187
+ readonly '200': {
1188
+ readonly description: "Complete bounded ATC documentation HTML";
1189
+ readonly content: {
1190
+ readonly 'application/json': {
1191
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
1192
+ bytes: z.ZodNumber;
1193
+ html: z.ZodString;
1194
+ }, z.core.$strict>>;
1195
+ };
1196
+ };
1197
+ };
1198
+ readonly '400': {
1199
+ readonly description: "Invalid request";
1200
+ };
1201
+ readonly '404': {
1202
+ readonly description: "Documentation capability is unavailable";
1203
+ };
1204
+ readonly '413': {
1205
+ readonly description: "Documentation exceeds the byte cap";
1206
+ };
1207
+ };
1208
+ };
1209
+ };
1210
+ };
1211
+ readonly components: {
1212
+ readonly parameters: {
1213
+ readonly destination: {
1214
+ readonly name: "destination";
1215
+ readonly in: "path";
1216
+ readonly required: true;
1217
+ readonly schema: {
1218
+ readonly type: "string";
1219
+ readonly pattern: "^[a-z][a-z0-9-]{1,62}$";
1220
+ };
1221
+ };
1222
+ readonly transport: {
1223
+ readonly name: "transport";
1224
+ readonly in: "path";
1225
+ readonly required: true;
1226
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodString>;
1227
+ };
1228
+ readonly package: {
1229
+ readonly name: "package";
1230
+ readonly in: "path";
1231
+ readonly required: true;
1232
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodString>;
1233
+ };
1234
+ readonly objectType: {
1235
+ readonly name: "type";
1236
+ readonly in: "path";
1237
+ readonly required: true;
1238
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodString>;
1239
+ };
1240
+ readonly objectName: {
1241
+ readonly name: "name";
1242
+ readonly in: "path";
1243
+ readonly required: true;
1244
+ readonly schema: z.core.ZodStandardJSONSchemaPayload<z.ZodString>;
1245
+ };
1246
+ };
1247
+ };
1248
+ };
1249
+ declare const openApiYaml: () => string;
1250
+ //#endregion
1251
+ //#region src/broker.d.ts
1252
+ interface HttpBrokerOptions {
1253
+ baseUrl: string;
1254
+ tokenFile: string;
1255
+ fetch?: typeof globalThis.fetch;
1256
+ /** Test seam; production derives the client from broker credentials. */
1257
+ createClient?: (connection: BrokerConnection) => Promise<AdtClient>;
1258
+ /**
1259
+ * Optional allow-list of UAA hosts (exact hostnames, no scheme/port) for
1260
+ * BTP service-key OAuth token endpoints. When provided, `uaa.url` must match
1261
+ * one of the listed hosts.
1262
+ */
1263
+ allowedUaaHosts?: string[];
1264
+ }
1265
+ interface BrokerConnection {
1266
+ baseUrl: string;
1267
+ sapClient: string | null;
1268
+ authMethod: 'basic' | 'btp_service_key';
1269
+ authConfig: Record<string, unknown>;
1270
+ }
1271
+ /** ADT-private broker client. It exposes only safe summaries to the public server layer. */
1272
+ declare function createHttpBrokerOperations(options: HttpBrokerOptions): AdtServerOperations;
1273
+ /** Creates the opaque lease/provider pair consumed by shared MCP mode. */
1274
+ declare function createHttpDestinationContexts(options: HttpBrokerOptions): {
1275
+ leaseProvider: DestinationLeaseProvider;
1276
+ contextFactory: DestinationContextFactory;
1277
+ resolveFrozenSource(input: {
1278
+ destination: string;
1279
+ systemSid: string;
1280
+ sourceRef: string;
1281
+ }): Promise<{
1282
+ sourceUri: string;
1283
+ } | {
1284
+ sourceCapability: string;
1285
+ }>;
1286
+ };
1287
+ //#endregion
1288
+ //#region src/mcp-runtime.d.ts
1289
+ type RuntimeEnvironment = Readonly<Record<string, string | undefined>>;
1290
+ interface AdtServerMcpRuntimeOptions {
1291
+ env: RuntimeEnvironment;
1292
+ brokerOptions: HttpBrokerOptions;
1293
+ /** Deployment-owned one-shot authorization consumer. */
1294
+ consumeExecutionAuthorization?: NonNullable<ToolContext['consumeExecutionAuthorization']>;
1295
+ /** Deployment-owned terminal outcome recorder. */
1296
+ reportExecutionOutcome?: NonNullable<ToolContext['reportExecutionOutcome']>;
1297
+ /**
1298
+ * Optional deployment/test override for the execution-scoped abort runtime.
1299
+ */
1300
+ executeWithDeadline?: NonNullable<ToolContext['executeWithDeadline']>;
1301
+ }
1302
+ /**
1303
+ * Aborts all SAP HTTP work in this async execution context at the signed
1304
+ * deadline, then waits for the tool operation to settle before returning.
1305
+ */
1306
+ declare function executeWithDeadlineAndAbort(input: {
1307
+ maxDurationMs: number;
1308
+ operation: () => Promise<unknown>;
1309
+ }): Promise<unknown>;
1310
+ /**
1311
+ * Creates the optional, signed MCP sidecar configuration. A missing complete
1312
+ * configuration keeps MCP unavailable; a partial or invalid configuration
1313
+ * aborts startup rather than risking a weaker authentication mode.
1314
+ */
1315
+ declare function createAdtServerMcpOptions(options: AdtServerMcpRuntimeOptions): Promise<AdtServerMcpOptions | undefined>;
1316
+ //#endregion
1317
+ //#region src/rest-runtime.d.ts
1318
+ interface RestRuntimeSecurityOptions {
1319
+ tokenFile?: string;
1320
+ sourceSecretFile?: string;
1321
+ pageCursorSecretFile?: string;
1322
+ }
1323
+ type RestRuntimeSecurity = Pick<AdtServerOptions, 'restAuthorizer' | 'sourceCapabilities' | 'atcDocumentationCapabilities' | 'pageCursors'>;
1324
+ /**
1325
+ * REST remains disabled without a bearer secret. Once it is explicitly
1326
+ * enabled, its signed state must come from two independent mounted files so
1327
+ * source capabilities and page cursors survive a replica or process restart.
1328
+ */
1329
+ declare function loadRestRuntimeSecurity(options: RestRuntimeSecurityOptions): Promise<RestRuntimeSecurity>;
1330
+ //#endregion
1331
+ export { type AdtServerMcpOptions, type AdtServerMcpRuntimeOptions, type AdtServerOperations, type AdtServerOptions, type DestinationSummary, type HttpBrokerOptions, type RestRuntimeSecurity, type RestRuntimeSecurityOptions, type RestServiceAuthorizer, type RunningAdtServer, createAdtServerMcpOptions, createHttpBrokerOperations, createHttpDestinationContexts, executeWithDeadlineAndAbort, loadRestRuntimeSecurity, openApiDocument, openApiYaml, startAdtServer };
1332
+ //# sourceMappingURL=index.d.mts.map