@registrystack/client 0.41.0 → 0.42.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +30 -18
- package/breg/client.d.ts +173 -336
- package/breg/client.js +32 -106
- package/breg/index.d.ts +72 -141
- package/casework/client.d.ts +111 -282
- package/casework/client.js +20 -28
- package/casework/index.d.ts +17 -26
- package/discovery/client.d.ts +0 -3
- package/discovery/client.js +0 -5
- package/discovery/index.d.ts +0 -2
- package/native.js +1 -1
- package/package.json +6 -6
package/breg/client.d.ts
CHANGED
|
@@ -9,6 +9,10 @@ export type SafeInteger = number
|
|
|
9
9
|
|
|
10
10
|
export type WebhookVerificationRefusalCode =
|
|
11
11
|
| 'missing-header'
|
|
12
|
+
| 'invalid-delivery-time'
|
|
13
|
+
| 'duplicate-header'
|
|
14
|
+
| 'body-too-large'
|
|
15
|
+
| 'invalid-key'
|
|
12
16
|
| 'malformed-signature'
|
|
13
17
|
| 'signature-mismatch'
|
|
14
18
|
| 'unsupported-version'
|
|
@@ -182,7 +186,6 @@ export interface RecordProjectionOptions {
|
|
|
182
186
|
}
|
|
183
187
|
|
|
184
188
|
export interface RecordOptions extends RecordProjectionOptions {
|
|
185
|
-
requestHistoryAfterProposalVersion?: SafeInteger | null
|
|
186
189
|
}
|
|
187
190
|
|
|
188
191
|
export interface ListOptions extends RecordProjectionOptions {
|
|
@@ -246,91 +249,9 @@ export interface RegistryRecord {
|
|
|
246
249
|
recordIdentifier: string
|
|
247
250
|
revisionIdentifier: string
|
|
248
251
|
domainData: Readonly<Record<string, JsonValue>>
|
|
249
|
-
request?: BRegRequestMetadata
|
|
250
252
|
readonly [member: string]: JsonValue | undefined
|
|
251
253
|
}
|
|
252
254
|
|
|
253
|
-
export type BRegRequestResultReferenceData = JsonObject & {
|
|
254
|
-
readonly targetEntityId: string
|
|
255
|
-
readonly targetRecordId: string
|
|
256
|
-
/** Revision written by the application, not a current ETag or precondition. */
|
|
257
|
-
readonly targetRevision: SafeInteger
|
|
258
|
-
}
|
|
259
|
-
export type BRegRequestState = 'draft' | 'submitted' | 'cancelled' | 'applied'
|
|
260
|
-
export type BRegRequestReviewRequirement =
|
|
261
|
-
| Readonly<{ type: 'none' }>
|
|
262
|
-
| Readonly<{ type: 'required'; authority: string; policyId: string }>
|
|
263
|
-
export type BRegExternalReviewStatus = Readonly<{
|
|
264
|
-
submission: Readonly<{
|
|
265
|
-
state: 'pending' | 'accepted' | 'uncertain' | 'cancelling' | 'cancelled' | 'failed'
|
|
266
|
-
authority: string
|
|
267
|
-
requestId?: string
|
|
268
|
-
submissionDigest?: string
|
|
269
|
-
/** Fixed recovery deadline for the durable submission. */
|
|
270
|
-
recoveryDeadline?: string
|
|
271
|
-
policy?: Readonly<{ id: string; version: string; digest: string }>
|
|
272
|
-
}>
|
|
273
|
-
result: Readonly<{
|
|
274
|
-
state: 'pending' | 'approved' | 'rejected' | 'changesRequested' | 'answered' | 'cancelled' | 'superseded'
|
|
275
|
-
resultId?: string
|
|
276
|
-
completedAt?: string
|
|
277
|
-
availableUntil?: string
|
|
278
|
-
}>
|
|
279
|
-
delivery: Readonly<{
|
|
280
|
-
state: 'polling' | 'received' | 'reconciled' | 'unmatched' | 'exhausted'
|
|
281
|
-
eventId?: string
|
|
282
|
-
receivedAt?: string
|
|
283
|
-
}>
|
|
284
|
-
application: Readonly<{
|
|
285
|
-
mode: 'manual' | 'automatic'
|
|
286
|
-
state: 'awaitingReview' | 'ready' | 'queued' | 'applying' | 'applied' | 'blocked' | 'expired'
|
|
287
|
-
executor?: string
|
|
288
|
-
applicationId?: string
|
|
289
|
-
/** Durable automatic-application attempts, from 0 through 1000. */
|
|
290
|
-
attempts?: SafeInteger
|
|
291
|
-
/** Present only while an automatic application is queued or applying. */
|
|
292
|
-
nextAttemptAt?: string
|
|
293
|
-
/** Present when the applied receipt was recovered from already-applied source state. */
|
|
294
|
-
receiptRecovered?: true
|
|
295
|
-
}>
|
|
296
|
-
recovery: Readonly<{
|
|
297
|
-
state: 'none' | 'operatorAttention'
|
|
298
|
-
code?: string
|
|
299
|
-
}>
|
|
300
|
-
}>
|
|
301
|
-
export type BRegRetainedRequestProposal = JsonObject & {
|
|
302
|
-
readonly requestEntityId: string
|
|
303
|
-
readonly requestId: string
|
|
304
|
-
readonly proposalVersion: SafeInteger
|
|
305
|
-
readonly bregState: BRegRequestState
|
|
306
|
-
readonly current: boolean
|
|
307
|
-
readonly contractFingerprint: string
|
|
308
|
-
readonly detailErased: boolean
|
|
309
|
-
readonly applicationId: string | null
|
|
310
|
-
readonly resultLinkCount: SafeInteger
|
|
311
|
-
readonly resultLinks: ReadonlyArray<BRegRequestResultReferenceData>
|
|
312
|
-
readonly effectDigest?: string
|
|
313
|
-
readonly proposal?: Readonly<{ review: BRegRequestReviewRequirement }>
|
|
314
|
-
}
|
|
315
|
-
export type BRegRetainedRequestHistory = JsonObject & {
|
|
316
|
-
readonly proposals: ReadonlyArray<BRegRetainedRequestProposal>
|
|
317
|
-
readonly nextAfterProposalVersion: SafeInteger | null
|
|
318
|
-
}
|
|
319
|
-
export type BRegRequestMetadata = JsonObject & {
|
|
320
|
-
readonly bregState: BRegRequestState
|
|
321
|
-
readonly proposalVersion: SafeInteger
|
|
322
|
-
readonly effectDigest?: string | null
|
|
323
|
-
readonly proposal?: Readonly<{ review: BRegRequestReviewRequirement }> | null
|
|
324
|
-
readonly editable: boolean
|
|
325
|
-
readonly detailErased?: true
|
|
326
|
-
readonly actions?: ReadonlyArray<JsonObject>
|
|
327
|
-
readonly application?: JsonObject | null
|
|
328
|
-
readonly history?: BRegRetainedRequestHistory | null
|
|
329
|
-
readonly review?: BRegExternalReviewStatus
|
|
330
|
-
readonly submitterReference?: string
|
|
331
|
-
readonly applierReference?: string
|
|
332
|
-
}
|
|
333
|
-
|
|
334
255
|
export interface RecordMetadata {
|
|
335
256
|
registryIdentifier: string
|
|
336
257
|
datasetIdentifier: string
|
|
@@ -405,22 +326,6 @@ export interface RemovePatchOperation {
|
|
|
405
326
|
field: string
|
|
406
327
|
}
|
|
407
328
|
|
|
408
|
-
export type LifecycleReceipt = JsonObject & {
|
|
409
|
-
readonly id: string
|
|
410
|
-
readonly revision: SafeInteger
|
|
411
|
-
readonly snapshot: string
|
|
412
|
-
readonly actorReference?: string
|
|
413
|
-
readonly request: BRegLifecycleReceiptRequest
|
|
414
|
-
}
|
|
415
|
-
|
|
416
|
-
export type BRegLifecycleReceiptRequest = JsonObject & {
|
|
417
|
-
readonly bregState: BRegRequestState
|
|
418
|
-
readonly proposalVersion: SafeInteger | null
|
|
419
|
-
readonly effectDigest: string | null
|
|
420
|
-
readonly proposal?: JsonObject | null
|
|
421
|
-
readonly application: JsonObject | null
|
|
422
|
-
}
|
|
423
|
-
|
|
424
329
|
/** Exact validated JSON text, serialized before conversion to JavaScript numbers.
|
|
425
330
|
* Decode with a lossless JSON library if inspecting values outside the safe integer range.
|
|
426
331
|
* Decimal fields remain fixed-scale JSON strings. */
|
|
@@ -465,15 +370,18 @@ export interface BRegFieldDescriptor {
|
|
|
465
370
|
readonly nullable: boolean
|
|
466
371
|
readonly readOnly: boolean
|
|
467
372
|
readonly removable: boolean
|
|
468
|
-
readonly
|
|
373
|
+
readonly referenceTargetRecordType: string | null
|
|
469
374
|
readonly codeLabels: Readonly<Record<string, string>>
|
|
470
375
|
readonly storageValidation: {
|
|
471
376
|
readonly kind: string
|
|
472
377
|
readonly pattern: string
|
|
473
378
|
} | null
|
|
474
379
|
readonly reference: {
|
|
380
|
+
readonly name: string | null
|
|
381
|
+
readonly cardinality: 'one' | 'optional-one' | 'many' | null
|
|
382
|
+
readonly inverseName: string | null
|
|
475
383
|
readonly manualEntry: boolean
|
|
476
|
-
readonly
|
|
384
|
+
readonly targetRecordType: string | null
|
|
477
385
|
readonly operations: ReadonlyArray<{
|
|
478
386
|
readonly operationId: string
|
|
479
387
|
readonly accessProfile: string
|
|
@@ -528,15 +436,14 @@ export interface BRegOperationDescriptor {
|
|
|
528
436
|
readonly method: string
|
|
529
437
|
readonly path: string
|
|
530
438
|
readonly kind: string
|
|
531
|
-
readonly
|
|
532
|
-
readonly
|
|
439
|
+
readonly sourceRecordType: string
|
|
440
|
+
readonly responseRecordType: string
|
|
533
441
|
readonly accessProfile: string
|
|
534
|
-
readonly
|
|
442
|
+
readonly recordTypeLabel: string
|
|
535
443
|
readonly titleFields: ReadonlyArray<string>
|
|
536
444
|
readonly requiredCapabilities: ReadonlyArray<string>
|
|
537
445
|
readonly fields: ReadonlyArray<BRegFieldDescriptor>
|
|
538
446
|
readonly readableFields: ReadonlyArray<string>
|
|
539
|
-
readonly readableRequestFields: ReadonlyArray<string>
|
|
540
447
|
readonly createWritableFields: ReadonlyArray<string>
|
|
541
448
|
readonly patchWritableFields: ReadonlyArray<string>
|
|
542
449
|
readonly query: BRegQueryDescriptor | null
|
|
@@ -561,15 +468,36 @@ export interface BRegOperationDescriptor {
|
|
|
561
468
|
}
|
|
562
469
|
}
|
|
563
470
|
|
|
564
|
-
export interface
|
|
471
|
+
export interface BRegProposalActionDescriptor {
|
|
472
|
+
readonly actionId: string
|
|
473
|
+
readonly accessProfile: string
|
|
474
|
+
readonly operations: ReadonlyArray<string>
|
|
475
|
+
readonly readableInputs: ReadonlyArray<string>
|
|
476
|
+
}
|
|
477
|
+
|
|
478
|
+
export interface BRegActionAttachmentDescriptor {
|
|
479
|
+
readonly id: string
|
|
480
|
+
readonly required: boolean
|
|
481
|
+
readonly contentTypes: ReadonlyArray<string>
|
|
482
|
+
readonly maximumBytes: SafeInteger
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
export interface BRegActionDescriptor {
|
|
486
|
+
readonly attachments: ReadonlyArray<BRegActionAttachmentDescriptor>
|
|
487
|
+
readonly apiName: string
|
|
488
|
+
readonly revision: string
|
|
489
|
+
readonly display: Readonly<{label?: string; description?: string}>
|
|
490
|
+
readonly mode: 'immediate' | 'proposal'
|
|
565
491
|
readonly id: string
|
|
566
|
-
readonly contractFingerprint: string
|
|
567
492
|
readonly inputMode: string | null
|
|
568
493
|
readonly maximumInputStringBytes: SafeInteger | null
|
|
569
494
|
readonly inputs: ReadonlyArray<{
|
|
570
495
|
readonly id: string
|
|
571
496
|
readonly apiName: string
|
|
572
497
|
readonly fieldTypeJson: string
|
|
498
|
+
readonly label: string
|
|
499
|
+
readonly description: string | null
|
|
500
|
+
readonly schemaJson: string
|
|
573
501
|
readonly required: boolean
|
|
574
502
|
readonly nullable: boolean | null
|
|
575
503
|
readonly classification: string
|
|
@@ -577,17 +505,18 @@ export interface BRegImmediateActionDescriptor {
|
|
|
577
505
|
readonly referenceInputs: ReadonlyArray<{
|
|
578
506
|
readonly input: string
|
|
579
507
|
readonly apiName: string
|
|
580
|
-
readonly
|
|
508
|
+
readonly targetRecordType: string
|
|
581
509
|
}>
|
|
582
510
|
readonly requiredConditionKeys: ReadonlyArray<string>
|
|
583
511
|
readonly resultEffects: ReadonlyArray<{
|
|
584
512
|
readonly effect: string
|
|
585
|
-
readonly
|
|
513
|
+
readonly recordType: string
|
|
586
514
|
readonly operation: string
|
|
587
515
|
}>
|
|
588
516
|
readonly accessProfile: string
|
|
589
|
-
readonly invokePath: string
|
|
517
|
+
readonly invokePath: string | null
|
|
590
518
|
readonly targetConditionsPath: string | null
|
|
519
|
+
readonly availabilityPath: string | null
|
|
591
520
|
readonly bounds: {
|
|
592
521
|
readonly maximumTargets: SafeInteger
|
|
593
522
|
readonly maximumFieldMutations: SafeInteger
|
|
@@ -599,12 +528,18 @@ export interface BRegActionReceipt {
|
|
|
599
528
|
readonly action: string
|
|
600
529
|
readonly applicationId: string
|
|
601
530
|
readonly results: Readonly<Record<string, {
|
|
602
|
-
readonly
|
|
531
|
+
readonly recordType: string
|
|
603
532
|
readonly recordId: string
|
|
604
533
|
readonly revision: SafeInteger
|
|
605
534
|
}>>
|
|
606
535
|
}
|
|
607
536
|
|
|
537
|
+
export type BRegActionAvailability =
|
|
538
|
+
| { readonly available: true; readonly observedRevision: number }
|
|
539
|
+
| { readonly available: false; readonly observedRevision: number; readonly reason: 'guard-not-satisfied'; readonly recovery: 'none' }
|
|
540
|
+
| { readonly available: null; readonly observedRevision: number; readonly reason: 'input-required'; readonly recovery: 'correct-input'; readonly missingInputs: ReadonlyArray<string> }
|
|
541
|
+
| { readonly available: null; readonly observedRevision: null; readonly reason: 'not-disclosed'; readonly recovery: 'none' }
|
|
542
|
+
|
|
608
543
|
export interface BRegBatchCreateItem {
|
|
609
544
|
readonly operation: 'create'
|
|
610
545
|
readonly data: JsonObject
|
|
@@ -674,7 +609,7 @@ export interface BRegIngestionRunInput {
|
|
|
674
609
|
export interface BRegIngestionRunListInput {
|
|
675
610
|
accessProfile?: string | null
|
|
676
611
|
limit?: SafeInteger | null
|
|
677
|
-
|
|
612
|
+
cursor?: string | null
|
|
678
613
|
status?: BRegIngestionRunStatus | null
|
|
679
614
|
inputDigest?: string | null
|
|
680
615
|
}
|
|
@@ -689,7 +624,7 @@ export interface BRegIngestionRun {
|
|
|
689
624
|
readonly runId: string
|
|
690
625
|
readonly status: BRegIngestionRunStatus
|
|
691
626
|
readonly blockedReason: string | null
|
|
692
|
-
readonly
|
|
627
|
+
readonly recordType: string
|
|
693
628
|
readonly operation: BRegIngestionOperation
|
|
694
629
|
readonly profileId: string
|
|
695
630
|
readonly packageRevision: string
|
|
@@ -713,7 +648,7 @@ export interface BRegIngestionRun {
|
|
|
713
648
|
export interface BRegIngestionRunPage {
|
|
714
649
|
readonly runs: ReadonlyArray<BRegIngestionRun>
|
|
715
650
|
readonly hasMore: boolean
|
|
716
|
-
readonly
|
|
651
|
+
readonly nextCursor: string | null
|
|
717
652
|
}
|
|
718
653
|
|
|
719
654
|
export interface BRegIngestionReceiptBatch {
|
|
@@ -770,121 +705,6 @@ export declare function encodeIngestionChunk(
|
|
|
770
705
|
prefixDigest: string,
|
|
771
706
|
): BRegIngestionChunk
|
|
772
707
|
|
|
773
|
-
/**
|
|
774
|
-
* Where a change-request target or value comes from, present only when the
|
|
775
|
-
* caller may read it: a request-entity field, or the record another effect
|
|
776
|
-
* of the same request creates.
|
|
777
|
-
*/
|
|
778
|
-
export type BRegChangeRequestBinding =
|
|
779
|
-
| { readonly fromField: string; readonly fromEffect?: never }
|
|
780
|
-
| { readonly fromEffect: string; readonly fromField?: never }
|
|
781
|
-
| { readonly fromField?: never; readonly fromEffect?: never }
|
|
782
|
-
|
|
783
|
-
export type BRegChangeRequestTarget = { readonly entity: string } & BRegChangeRequestBinding
|
|
784
|
-
|
|
785
|
-
/**
|
|
786
|
-
* One declared change-request effect on an entity the caller may read. Only
|
|
787
|
-
* target fields the caller may read are named; the value is descriptive and
|
|
788
|
-
* cannot create target-write authority.
|
|
789
|
-
*/
|
|
790
|
-
export interface BRegChangeRequestEffect {
|
|
791
|
-
readonly id: string
|
|
792
|
-
readonly operation: 'create' | 'patch'
|
|
793
|
-
readonly target: BRegChangeRequestTarget
|
|
794
|
-
readonly set: ReadonlyArray<{ readonly field: string } & BRegChangeRequestBinding>
|
|
795
|
-
readonly clear: ReadonlyArray<string>
|
|
796
|
-
}
|
|
797
|
-
|
|
798
|
-
/** One declared planner write, filtered to fields the caller may read. */
|
|
799
|
-
export interface BRegChangeRequestPlannerWrite {
|
|
800
|
-
/** A planner write targets a stored record, never another effect. */
|
|
801
|
-
readonly target: { readonly entity: string; readonly fromField?: string; readonly fromEffect?: never }
|
|
802
|
-
readonly operation: 'create' | 'patch'
|
|
803
|
-
readonly fields: ReadonlyArray<string>
|
|
804
|
-
}
|
|
805
|
-
|
|
806
|
-
export interface BRegChangeRequestCapability {
|
|
807
|
-
readonly planner: {
|
|
808
|
-
readonly kind: 'declarative' | 'rhai'
|
|
809
|
-
readonly abi: string | null
|
|
810
|
-
readonly limits: {
|
|
811
|
-
readonly maximumTargets: SafeInteger
|
|
812
|
-
readonly maximumFieldMutations: SafeInteger
|
|
813
|
-
readonly maximumSnapshotBytes: SafeInteger
|
|
814
|
-
readonly maximumSourceBytes: SafeInteger
|
|
815
|
-
readonly maximumOperations: SafeInteger
|
|
816
|
-
readonly maximumCallDepth: SafeInteger
|
|
817
|
-
readonly maximumExpressionDepth: SafeInteger
|
|
818
|
-
readonly maximumStringBytes: SafeInteger
|
|
819
|
-
readonly maximumArrayItems: SafeInteger
|
|
820
|
-
readonly maximumMapEntries: SafeInteger
|
|
821
|
-
readonly maximumModules: SafeInteger
|
|
822
|
-
} | null
|
|
823
|
-
readonly possibleWriteCount: SafeInteger | null
|
|
824
|
-
readonly possibleWriteOperations: ReadonlyArray<string>
|
|
825
|
-
readonly writes: ReadonlyArray<BRegChangeRequestPlannerWrite>
|
|
826
|
-
}
|
|
827
|
-
readonly effects: ReadonlyArray<BRegChangeRequestEffect>
|
|
828
|
-
readonly review: BRegRequestReviewRequirement
|
|
829
|
-
readonly onApproved: {
|
|
830
|
-
readonly mode: 'manual' | 'automatic'
|
|
831
|
-
readonly executor: string | null
|
|
832
|
-
}
|
|
833
|
-
readonly application: {
|
|
834
|
-
readonly preconditions: JsonValue | null
|
|
835
|
-
}
|
|
836
|
-
}
|
|
837
|
-
|
|
838
|
-
export type BRegAttachmentVerificationStatus = 'notRequired' | 'pending' | 'approved' | 'rejected'
|
|
839
|
-
|
|
840
|
-
export type BRegAttachmentClassification = 'public' | 'internal' | 'restricted'
|
|
841
|
-
|
|
842
|
-
/** Engine-owned state of one filled slot, read from a record's domain data. */
|
|
843
|
-
export interface BRegAttachmentState {
|
|
844
|
-
readonly slotIdentifier: string
|
|
845
|
-
readonly proposalVersion: SafeInteger
|
|
846
|
-
readonly erased: boolean
|
|
847
|
-
readonly byteSize: SafeInteger
|
|
848
|
-
readonly sha256: string
|
|
849
|
-
readonly contentType: string | null
|
|
850
|
-
readonly uploadedAt: string | null
|
|
851
|
-
readonly uploadedBy: string | null
|
|
852
|
-
readonly verificationStatus: BRegAttachmentVerificationStatus | null
|
|
853
|
-
}
|
|
854
|
-
|
|
855
|
-
/** What one record projection says about one slot. */
|
|
856
|
-
export type BRegAttachmentSlotValue =
|
|
857
|
-
| { readonly kind: 'not-selected'; readonly value: null }
|
|
858
|
-
| { readonly kind: 'empty'; readonly value: null }
|
|
859
|
-
| { readonly kind: 'filled'; readonly value: BRegAttachmentState }
|
|
860
|
-
|
|
861
|
-
/** Opaque bytes already accepted by one slot's served upload policy. */
|
|
862
|
-
export declare class BRegAttachmentUpload {
|
|
863
|
-
private constructor()
|
|
864
|
-
private readonly __opaque: void
|
|
865
|
-
readonly contentType: string
|
|
866
|
-
readonly byteSize: SafeInteger
|
|
867
|
-
}
|
|
868
|
-
|
|
869
|
-
/** Opaque governed attachment slot selected from metadata fetched by this client source. */
|
|
870
|
-
export declare class BRegAttachmentSlot {
|
|
871
|
-
private constructor()
|
|
872
|
-
private readonly __opaque: void
|
|
873
|
-
readonly slotIdentifier: string
|
|
874
|
-
readonly entityIdentifier: string
|
|
875
|
-
readonly accessProfile: string
|
|
876
|
-
readonly requiredForSubmit: boolean
|
|
877
|
-
readonly maximumBytes: SafeInteger
|
|
878
|
-
readonly contentTypes: ReadonlyArray<string>
|
|
879
|
-
readonly classification: BRegAttachmentClassification
|
|
880
|
-
readonly canDownload: boolean
|
|
881
|
-
readonly canUpload: boolean
|
|
882
|
-
readonly canRemove: boolean
|
|
883
|
-
acceptsContentType(contentType: string): boolean
|
|
884
|
-
prepareUpload(contentType: string, body: Buffer): BRegAttachmentUpload
|
|
885
|
-
valueIn(record: RecordEnvelope, format?: RecordFormat | null): BRegAttachmentSlotValue
|
|
886
|
-
}
|
|
887
|
-
|
|
888
708
|
/** Opaque write authority selected from metadata fetched by this client source. */
|
|
889
709
|
export declare class BRegCreateBinding {
|
|
890
710
|
private constructor()
|
|
@@ -896,7 +716,7 @@ export declare class BRegPatchBinding {
|
|
|
896
716
|
private readonly __opaque: void
|
|
897
717
|
}
|
|
898
718
|
/** Opaque authority for one metadata-selected immediate action. */
|
|
899
|
-
export declare class
|
|
719
|
+
export declare class BRegActionBinding {
|
|
900
720
|
private constructor()
|
|
901
721
|
private readonly __opaque: void
|
|
902
722
|
}
|
|
@@ -918,61 +738,6 @@ export declare class BRegBatchBinding {
|
|
|
918
738
|
private constructor()
|
|
919
739
|
private readonly __opaque: void
|
|
920
740
|
}
|
|
921
|
-
/** Opaque lifecycle authority selected from metadata fetched by this client source. */
|
|
922
|
-
export declare class BRegLifecycleAuthority {
|
|
923
|
-
private constructor()
|
|
924
|
-
private readonly __opaque: void
|
|
925
|
-
}
|
|
926
|
-
|
|
927
|
-
/** Inert caller-visible target provenance. It grants no read authority. */
|
|
928
|
-
export declare class BRegRequestResultReference {
|
|
929
|
-
private constructor()
|
|
930
|
-
private readonly __opaque: void
|
|
931
|
-
readonly targetEntityIdentifier: string
|
|
932
|
-
readonly targetRecordIdentifier: string
|
|
933
|
-
/** Revision written by the application, not a current ETag or precondition. */
|
|
934
|
-
readonly targetRevision: SafeInteger
|
|
935
|
-
toString(): string
|
|
936
|
-
}
|
|
937
|
-
|
|
938
|
-
/** One exact retained proposal from an explicitly loaded history page. */
|
|
939
|
-
export declare class BRegRetainedRequestProposalView {
|
|
940
|
-
private constructor()
|
|
941
|
-
private readonly __opaque: void
|
|
942
|
-
readonly requestEntityIdentifier: string
|
|
943
|
-
readonly requestIdentifier: string
|
|
944
|
-
readonly proposalVersion: SafeInteger
|
|
945
|
-
readonly bregState: BRegRequestState
|
|
946
|
-
readonly current: boolean
|
|
947
|
-
readonly detailErased: boolean
|
|
948
|
-
readonly applicationIdentifier: string | null
|
|
949
|
-
/** Caller-visible count, never an undisclosed application total. */
|
|
950
|
-
readonly resultLinkCount: SafeInteger
|
|
951
|
-
readonly resultReferences: ReadonlyArray<BRegRequestResultReference>
|
|
952
|
-
toString(): string
|
|
953
|
-
}
|
|
954
|
-
|
|
955
|
-
/** One page only. Call getRecord with its cursor to load another page. */
|
|
956
|
-
export declare class BRegRetainedRequestHistoryPage {
|
|
957
|
-
private constructor()
|
|
958
|
-
private readonly __opaque: void
|
|
959
|
-
readonly proposals: ReadonlyArray<BRegRetainedRequestProposalView>
|
|
960
|
-
readonly nextAfterProposalVersion: SafeInteger | null
|
|
961
|
-
findProposal(requestEntityIdentifier: string, requestIdentifier: string, proposalVersion: SafeInteger): BRegRetainedRequestProposalView | null
|
|
962
|
-
findApplication(requestEntityIdentifier: string, requestIdentifier: string, proposalVersion: SafeInteger, applicationIdentifier: string): BRegRetainedRequestProposalView | null
|
|
963
|
-
toString(): string
|
|
964
|
-
}
|
|
965
|
-
|
|
966
|
-
/** Opaque executable action promoted from a metadata authority and one record. */
|
|
967
|
-
export declare class BRegLifecycleAction {
|
|
968
|
-
withReason(reason: string): BRegLifecycleAction
|
|
969
|
-
private constructor()
|
|
970
|
-
private readonly __opaque: void
|
|
971
|
-
readonly operation: string
|
|
972
|
-
readonly href: string
|
|
973
|
-
readonly bodyJson: string
|
|
974
|
-
readonly body: JsonObject
|
|
975
|
-
}
|
|
976
741
|
|
|
977
742
|
/**
|
|
978
743
|
* Inert bounded immediate-action evidence: inputs, saved target conditions,
|
|
@@ -994,14 +759,6 @@ export declare class BRegPreparedCreate {
|
|
|
994
759
|
toBytes(): Buffer
|
|
995
760
|
}
|
|
996
761
|
|
|
997
|
-
/** Inert bounded lifecycle evidence. Persist these bytes with owner-only access. */
|
|
998
|
-
export declare class BRegPreparedLifecycle {
|
|
999
|
-
private constructor()
|
|
1000
|
-
private readonly __opaque: void
|
|
1001
|
-
static fromBytes(bytes: Buffer): BRegPreparedLifecycle
|
|
1002
|
-
toBytes(): Buffer
|
|
1003
|
-
}
|
|
1004
|
-
|
|
1005
762
|
/** Revalidated action invocation and key. It still requires fresh metadata authority to send. */
|
|
1006
763
|
export declare class BRegRecoveredAction {
|
|
1007
764
|
private constructor()
|
|
@@ -1014,18 +771,17 @@ export declare class BRegRecoveredCreate {
|
|
|
1014
771
|
private readonly __opaque: void
|
|
1015
772
|
}
|
|
1016
773
|
|
|
1017
|
-
/** Revalidated lifecycle action. It remains inert until explicitly sent. */
|
|
1018
|
-
export declare class BRegRecoveredLifecycle {
|
|
1019
|
-
private constructor()
|
|
1020
|
-
private readonly __opaque: void
|
|
1021
|
-
}
|
|
1022
|
-
|
|
1023
774
|
/** Caller-filtered metadata bound to the exact client source that fetched it. */
|
|
1024
775
|
export declare class BRegMetadata {
|
|
776
|
+
selectProposals(profile: string): BRegProposalCollection
|
|
777
|
+
selectProposalGet(profile: string): BRegProposalGetBinding
|
|
778
|
+
selectProposalReviewContext(profile: string, action: string): BRegProposalReviewBinding
|
|
779
|
+
selectProposalReviewStatus(profile: string, action: string): BRegProposalReviewBinding
|
|
1025
780
|
private constructor()
|
|
1026
781
|
private readonly __opaque: void
|
|
1027
782
|
readonly operations: ReadonlyArray<BRegOperationDescriptor>
|
|
1028
|
-
readonly
|
|
783
|
+
readonly proposalActions: ReadonlyArray<BRegProposalActionDescriptor>
|
|
784
|
+
readonly actions: ReadonlyArray<BRegActionDescriptor>
|
|
1029
785
|
readonly actionsJson: string | null
|
|
1030
786
|
/** Validated caller-filtered inert descriptions. They never grant entity authority. */
|
|
1031
787
|
readonly statisticalDatasets: ReadonlyArray<BRegStatisticalDatasetDescriptor> | null
|
|
@@ -1034,23 +790,33 @@ export declare class BRegMetadata {
|
|
|
1034
790
|
readonly registryRevision: string
|
|
1035
791
|
readonly traceId: string
|
|
1036
792
|
readonly etag: string | null
|
|
1037
|
-
changeRequestCapability(entityIdentifier: string): BRegChangeRequestCapability | null
|
|
1038
793
|
selectCreate(operationIdentifier: string, expectedProfile: string): BRegCreateBinding
|
|
1039
794
|
selectPatch(operationIdentifier: string, expectedProfile: string): BRegPatchBinding
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
795
|
+
selectAction(actionIdentifier: string, expectedProfile: string): BRegActionBinding
|
|
796
|
+
selectTombstone(recordTypeIdentifier: string, expectedProfile: string): BRegTombstoneBinding
|
|
797
|
+
selectBatch(recordTypeIdentifier: string, expectedProfile: string): BRegBatchBinding
|
|
798
|
+
}
|
|
799
|
+
|
|
800
|
+
/** Bounded declared identifiers; absent when any referenced field is unreadable. */
|
|
801
|
+
export type BRegConstraintViolation = {
|
|
802
|
+
readonly recordType: string
|
|
803
|
+
readonly constraintId: string
|
|
804
|
+
} & ({
|
|
805
|
+
readonly constraintKind: 'compare'
|
|
806
|
+
readonly left: string
|
|
807
|
+
readonly right: string
|
|
808
|
+
} | {
|
|
809
|
+
readonly constraintKind: 'int-range' | 'vocabulary'
|
|
810
|
+
readonly field: string
|
|
811
|
+
})
|
|
1046
812
|
|
|
1047
813
|
export interface BaseRegistryClientFailure extends Error {
|
|
1048
814
|
readonly kind: string
|
|
1049
815
|
readonly code?: string
|
|
1050
|
-
readonly planRefusal?: string
|
|
1051
816
|
readonly refusalCode?: string
|
|
1052
817
|
readonly reasonCode?: string
|
|
1053
818
|
readonly fieldPath?: string
|
|
819
|
+
readonly constraint?: BRegConstraintViolation
|
|
1054
820
|
readonly status?: number
|
|
1055
821
|
readonly traceId?: string
|
|
1056
822
|
readonly transportKind?: string
|
|
@@ -1074,10 +840,10 @@ export interface BaseRegistryClientFailure extends Error {
|
|
|
1074
840
|
export declare class BaseRegistryClientError extends Error implements BaseRegistryClientFailure {
|
|
1075
841
|
readonly kind: string
|
|
1076
842
|
readonly code?: string
|
|
1077
|
-
readonly planRefusal?: string
|
|
1078
843
|
readonly refusalCode?: string
|
|
1079
844
|
readonly reasonCode?: string
|
|
1080
845
|
readonly fieldPath?: string
|
|
846
|
+
readonly constraint?: BRegConstraintViolation
|
|
1081
847
|
readonly status?: number
|
|
1082
848
|
readonly traceId?: string
|
|
1083
849
|
readonly transportKind?: string
|
|
@@ -1099,6 +865,15 @@ export declare class BaseRegistryClientError extends Error implements BaseRegist
|
|
|
1099
865
|
}
|
|
1100
866
|
|
|
1101
867
|
export declare class BaseRegistryClient {
|
|
868
|
+
startProposal(binding: BRegActionBinding, inputsJson: string, key: string): Promise<BRegProposal>
|
|
869
|
+
getProposal(binding: BRegProposalGetBinding, id: string): Promise<BRegProposal>
|
|
870
|
+
readProposal(proposal: BRegProposal): Promise<BRegProposal>
|
|
871
|
+
/** Read one retained submission version under the access profile of the Proposal's self link. */
|
|
872
|
+
readProposalSubmission(proposal: BRegProposal, version: number): Promise<CompleteOutcome<BRegProposalSubmission>>
|
|
873
|
+
listProposals(collection: BRegProposalCollection, queryJson: string): Promise<BRegProposalPage>
|
|
874
|
+
prepareProposal(proposal: BRegProposal, operation: BRegProposalTransition, bodyJson: string, key: string): BRegPreparedProposal
|
|
875
|
+
recoverProposal(proposal: BRegProposal, attempt: BRegPreparedProposal): BRegPreparedProposal
|
|
876
|
+
executeProposal(attempt: BRegPreparedProposal): Promise<BRegProposal>
|
|
1102
877
|
constructor(config: BaseRegistryClientConfig)
|
|
1103
878
|
health(): Promise<CompleteOutcome<ProbeStatus>>
|
|
1104
879
|
ready(): Promise<CompleteOutcome<ProbeStatus>>
|
|
@@ -1112,7 +887,7 @@ export declare class BaseRegistryClient {
|
|
|
1112
887
|
statisticsPublish(dataset: string, period: string, status: StatisticsReleaseStatus, accessProfile: string, idempotencyKey: string): Promise<RawOutcome>
|
|
1113
888
|
statisticsWithdraw(dataset: string, period: string, version: SafeInteger, reason: StatisticsWithdrawalReason, accessProfile: string, idempotencyKey: string): Promise<RawOutcome>
|
|
1114
889
|
registryContract(accessProfile?: string | null): Promise<BRegMetadata>
|
|
1115
|
-
entitySchema(
|
|
890
|
+
entitySchema(recordTypeIdentifier: string, accessProfile?: string | null): Promise<RawOutcome>
|
|
1116
891
|
recordRevisions(entityRoute: string, recordIdentifier: string, accessProfile?: string | null): Promise<RawOutcome>
|
|
1117
892
|
getRecordRevision(entityRoute: string, recordIdentifier: string, revision: SafeInteger, options?: RecordProjectionOptions | null): Promise<RawOutcome>
|
|
1118
893
|
getRecord(entityRoute: string, recordIdentifier: string, options?: RecordOptions | null): Promise<CompleteOutcome<RecordEnvelope>>
|
|
@@ -1130,18 +905,29 @@ export declare class BaseRegistryClient {
|
|
|
1130
905
|
listRelationshipRecords(entityRoute: string, recordIdentifier: string, pathRoute: string, options?: CollectionOptions | null): Promise<PageOutcome<RecordCollection, RelationshipListContinuation>>
|
|
1131
906
|
continueRelationshipList(continuation: RelationshipListContinuation): Promise<PageOutcome<RecordCollection, RelationshipListContinuation>>
|
|
1132
907
|
lookupRecord(entityRoute: string, selector: string, values?: JsonObject | null, options?: RecordProjectionOptions | null): Promise<CompleteOutcome<RecordEnvelope>>
|
|
1133
|
-
actionTargetConditions(binding:
|
|
1134
|
-
actionTargetConditionsJson(binding:
|
|
1135
|
-
|
|
1136
|
-
|
|
908
|
+
actionTargetConditions(binding: BRegActionBinding, inputs: JsonObject): Promise<BRegActionTargetConditions>
|
|
909
|
+
actionTargetConditionsJson(binding: BRegActionBinding, inputsJson: string): Promise<BRegActionTargetConditions>
|
|
910
|
+
actionAvailability(binding: BRegActionBinding, targetInput: string, inputs: JsonObject): Promise<CompleteOutcome<BRegActionAvailability>>
|
|
911
|
+
actionAvailabilityJson(binding: BRegActionBinding, targetInput: string, inputsJson: string): Promise<JsonOutcome>
|
|
912
|
+
invokeAction(binding: BRegActionBinding, inputs: JsonObject, idempotencyKey: string, conditions?: BRegActionTargetConditions | null): Promise<CompleteOutcome<BRegActionReceipt>>
|
|
913
|
+
invokeActionJson(binding: BRegActionBinding, inputsJson: string, idempotencyKey: string, conditions?: BRegActionTargetConditions | null): Promise<JsonOutcome>
|
|
1137
914
|
/** Validate and retain one invocation before any I/O, for recovery after a lost response. */
|
|
1138
|
-
prepareAction(binding:
|
|
1139
|
-
prepareActionJson(binding:
|
|
915
|
+
prepareAction(binding: BRegActionBinding, inputs: JsonObject, idempotencyKey: string, conditions?: BRegActionTargetConditions | null): BRegPreparedAction
|
|
916
|
+
prepareActionJson(binding: BRegActionBinding, inputsJson: string, idempotencyKey: string, conditions?: BRegActionTargetConditions | null): BRegPreparedAction
|
|
1140
917
|
/** Revalidate saved evidence against fresh authority and the original inputs and key. Performs no I/O. */
|
|
1141
|
-
recoverAction(binding:
|
|
1142
|
-
recoverActionJson(binding:
|
|
1143
|
-
executeRecoveredAction(binding:
|
|
1144
|
-
|
|
918
|
+
recoverAction(binding: BRegActionBinding, prepared: BRegPreparedAction, inputs: JsonObject, idempotencyKey: string): BRegRecoveredAction
|
|
919
|
+
recoverActionJson(binding: BRegActionBinding, prepared: BRegPreparedAction, inputsJson: string, idempotencyKey: string): BRegRecoveredAction
|
|
920
|
+
executeRecoveredAction(binding: BRegActionBinding, recovered: BRegRecoveredAction): Promise<CompleteOutcome<BRegActionReceipt>>
|
|
921
|
+
executeRecoveredProposalStart(binding: BRegActionBinding, recovered: BRegRecoveredAction): Promise<BRegProposal>
|
|
922
|
+
downloadProposalAttachment(proposal: BRegProposal, slot: string): Promise<RawOutcome>
|
|
923
|
+
readProposalReviewStatus(proposal: BRegProposal): Promise<CompleteOutcome<BRegProposalReviewDocument>>
|
|
924
|
+
readProposalReviewContext(proposal: BRegProposal): Promise<CompleteOutcome<BRegProposalReviewDocument>>
|
|
925
|
+
readProposalReviewContextBatch(binding: BRegProposalReviewBinding, ids: string[]): Promise<CompleteOutcome<Array<BRegProposalReviewDocument | null>>>
|
|
926
|
+
readProposalReviewById(binding: BRegProposalReviewBinding, id: string): Promise<CompleteOutcome<BRegProposalReviewDocument>>
|
|
927
|
+
downloadProposalReviewDocument(binding: BRegProposalReviewBinding, context: BRegProposalReviewDocument, field: string): Promise<RawOutcome>
|
|
928
|
+
uploadProposalAttachment(proposal: BRegProposal, slot: string, contentType: string, bytes: Buffer, key: string): Promise<BRegProposal>
|
|
929
|
+
deleteProposalAttachment(proposal: BRegProposal, slot: string, key: string): Promise<BRegProposal>
|
|
930
|
+
executeRecoveredActionJson(binding: BRegActionBinding, recovered: BRegRecoveredAction): Promise<JsonOutcome>
|
|
1145
931
|
createRecord(binding: BRegCreateBinding, data: JsonObject, idempotencyKey: string, format?: RecordFormat | null): Promise<CompleteOutcome<RecordEnvelope>>
|
|
1146
932
|
prepareCreate(binding: BRegCreateBinding, data: JsonObject, idempotencyKey: string, format?: RecordFormat | null): BRegPreparedCreate
|
|
1147
933
|
prepareCreateJson(binding: BRegCreateBinding, dataJson: string, idempotencyKey: string, format?: RecordFormat | null): BRegPreparedCreate
|
|
@@ -1159,17 +945,6 @@ export declare class BaseRegistryClient {
|
|
|
1159
945
|
ingestionChunkReceipt(entityRoute: string, runId: string, chunkIndex: SafeInteger, profileId: string): Promise<CompleteOutcome<BRegIngestionChunkReceipt>>
|
|
1160
946
|
tombstoneRecord(binding: BRegTombstoneBinding, recordIdentifier: string, etag: string, idempotencyKey: string, format?: RecordFormat | null): Promise<CompleteOutcome<RecordEnvelope>>
|
|
1161
947
|
tombstoneRecordJson(binding: BRegTombstoneBinding, recordIdentifier: string, etag: string, idempotencyKey: string, format?: RecordFormat | null): Promise<JsonOutcome>
|
|
1162
|
-
lifecycleActions(authority: BRegLifecycleAuthority, record: RecordEnvelope, format?: RecordFormat | null): ReadonlyArray<BRegLifecycleAction>
|
|
1163
|
-
/** Pure typed projection of one already loaded page. Performs no I/O. */
|
|
1164
|
-
requestHistory(record: RecordEnvelope, format?: RecordFormat | null): BRegRetainedRequestHistoryPage | null
|
|
1165
|
-
prepareLifecycleAction(authority: BRegLifecycleAuthority, record: RecordEnvelope, action: BRegLifecycleAction, idempotencyKey: string, format?: RecordFormat | null): BRegPreparedLifecycle
|
|
1166
|
-
prepareLifecycleActionJson(authority: BRegLifecycleAuthority, recordJson: string, action: BRegLifecycleAction, idempotencyKey: string, format?: RecordFormat | null): BRegPreparedLifecycle
|
|
1167
|
-
recoverLifecycleAction(authority: BRegLifecycleAuthority, prepared: BRegPreparedLifecycle): BRegRecoveredLifecycle
|
|
1168
|
-
executeRecoveredLifecycleAction(recovered: BRegRecoveredLifecycle): Promise<CompleteOutcome<LifecycleReceipt>>
|
|
1169
|
-
executeRecoveredLifecycleActionJson(recovered: BRegRecoveredLifecycle): Promise<JsonOutcome>
|
|
1170
|
-
uploadAttachment(slot: BRegAttachmentSlot, recordIdentifier: string, etag: string, upload: BRegAttachmentUpload, idempotencyKey: string, format?: RecordFormat | null): Promise<CompleteOutcome<RecordEnvelope>>
|
|
1171
|
-
downloadAttachment(slot: BRegAttachmentSlot, recordIdentifier: string, proposalVersion: SafeInteger): Promise<RawOutcome>
|
|
1172
|
-
deleteAttachment(slot: BRegAttachmentSlot, recordIdentifier: string, etag: string, idempotencyKey: string, format?: RecordFormat | null): Promise<CompleteOutcome<RecordEnvelope>>
|
|
1173
948
|
getRecordJson(entityRoute: string, recordIdentifier: string, options?: RecordOptions | null): Promise<JsonOutcome>
|
|
1174
949
|
listRecordsJson(entityRoute: string, options?: ListOptions | null): Promise<JsonOutcome>
|
|
1175
950
|
continueListJson(continuation: ListContinuation): Promise<JsonOutcome>
|
|
@@ -1187,9 +962,71 @@ export declare class BaseRegistryClient {
|
|
|
1187
962
|
lookupRecordJson(entityRoute: string, selector: string, valuesJson?: string | null, options?: RecordProjectionOptions | null): Promise<JsonOutcome>
|
|
1188
963
|
createRecordJson(binding: BRegCreateBinding, dataJson: string, idempotencyKey: string, format?: RecordFormat | null): Promise<JsonOutcome>
|
|
1189
964
|
patchRecordJson(binding: BRegPatchBinding, recordIdentifier: string, etag: string, operationsJson: string, idempotencyKey: string, format?: RecordFormat | null): Promise<JsonOutcome>
|
|
1190
|
-
uploadAttachmentJson(slot: BRegAttachmentSlot, recordIdentifier: string, etag: string, upload: BRegAttachmentUpload, idempotencyKey: string, format?: RecordFormat | null): Promise<JsonOutcome>
|
|
1191
|
-
deleteAttachmentJson(slot: BRegAttachmentSlot, recordIdentifier: string, etag: string, idempotencyKey: string, format?: RecordFormat | null): Promise<JsonOutcome>
|
|
1192
|
-
lifecycleActionsJson(authority: BRegLifecycleAuthority, recordJson: string, format?: RecordFormat | null): ReadonlyArray<BRegLifecycleAction>
|
|
1193
|
-
executeLifecycleActionJson(action: BRegLifecycleAction, idempotencyKey: string): Promise<JsonOutcome>
|
|
1194
|
-
executeLifecycleAction(action: BRegLifecycleAction, idempotencyKey: string): Promise<CompleteOutcome<LifecycleReceipt>>
|
|
1195
965
|
}
|
|
966
|
+
|
|
967
|
+
export type BRegProposalTransition = 'edit' | 'submit' | 'revise' | 'rebase' | 'retry' | 'cancel' | 'apply'
|
|
968
|
+
export type BRegAvailabilityReason = 'pending-review' | 'review-rejected' | 'review-changes-requested' | 'review-ended' | 'stale-revision' | 'contract-changed' | 'dependency-outage' | 'invalid-input' | 'already-applied'
|
|
969
|
+
export type BRegRecoveryHint = 'refresh' | 'revise' | 'retry' | 'correct-input' | 'receipt-only'
|
|
970
|
+
export type BRegAvailability =
|
|
971
|
+
| { readonly available: true; readonly observedRevision: number }
|
|
972
|
+
| { readonly available: false; readonly observedRevision: number; readonly reason: BRegAvailabilityReason; readonly recovery: BRegRecoveryHint }
|
|
973
|
+
export interface BRegProposalLink { readonly method: 'GET' | 'POST'; readonly path: string; readonly accessProfile: string; readonly operation: string; readonly ifMatch?: string; readonly availability?: BRegAvailability }
|
|
974
|
+
export interface BRegProposalAttachment {
|
|
975
|
+
readonly id: string; readonly required: boolean; readonly maximumBytes: number
|
|
976
|
+
readonly contentTypes: ReadonlyArray<string>; readonly classification: 'public' | 'internal' | 'restricted'
|
|
977
|
+
readonly links: Readonly<Partial<Record<'download' | 'upload' | 'remove', Omit<BRegProposalLink, 'method'> & {readonly method: 'GET' | 'PATCH' | 'DELETE'}>>>
|
|
978
|
+
readonly value?: {readonly submissionVersion: number; readonly sha256: string; readonly contentType: string; readonly byteSize: number; readonly uploadedAt?: string; readonly verificationStatus: 'notRequired' | 'pending' | 'approved' | 'rejected'}
|
|
979
|
+
}
|
|
980
|
+
export interface BRegProposalApplication {
|
|
981
|
+
readonly applicationId: string; readonly submissionVersion: number; readonly effectDigest: string
|
|
982
|
+
readonly appliedBy?: string; readonly appliedAt?: string
|
|
983
|
+
readonly resultLinks: ReadonlyArray<{readonly recordType: string; readonly recordId: string; readonly revision: number}>
|
|
984
|
+
}
|
|
985
|
+
export interface BRegProposalApplicationStatus {
|
|
986
|
+
readonly state: 'awaiting-review' | 'pending' | 'applying' | 'blocked' | 'applied' | 'cancelled' | 'rejected'
|
|
987
|
+
readonly mode: 'automatic' | 'manual'
|
|
988
|
+
readonly reason?: 'contract-changed' | 'dependency-outage' | 'lease-expired' | 'application-refused' | 'attempts-exhausted'
|
|
989
|
+
readonly recovery?: 'retry' | 'correct-input'
|
|
990
|
+
readonly automaticRetry?: {readonly scheduled: boolean; readonly attempts: number; readonly maximumAttempts: number}
|
|
991
|
+
}
|
|
992
|
+
export interface BRegProposalReviewDocument {
|
|
993
|
+
readonly id: string; readonly actionId: string; readonly actionRevision: string
|
|
994
|
+
readonly submissionVersion: number; readonly revision: number; readonly effectDigest: string; readonly reviewable: boolean
|
|
995
|
+
readonly subject: {readonly source: string; readonly subjectType: 'proposal'; readonly id: string; readonly version: string; readonly digest: string}
|
|
996
|
+
readonly context: {readonly reference: string; readonly contract?: {readonly id: string; readonly revision: string; readonly schemaDigest: string}; readonly fields?: Readonly<Record<string, JsonValue>>}
|
|
997
|
+
readonly requestId?: string
|
|
998
|
+
readonly authority?: string; readonly policy?: {readonly id: string; readonly version: string; readonly digest: string}
|
|
999
|
+
readonly result?: {readonly state: 'pending' | 'approved' | 'rejected' | 'changes-requested' | 'answered' | 'cancelled' | 'superseded' | 'expired'; readonly resultId?: string; readonly completedAt?: string; readonly availableUntil?: string}
|
|
1000
|
+
}
|
|
1001
|
+
/** Who is expected to act next, derived by BReg. */
|
|
1002
|
+
export type BRegProposalTurn = 'party' | 'official' | 'nobody'
|
|
1003
|
+
/** The review decision on one submission. The public reason is the only reviewer text BReg serves. */
|
|
1004
|
+
export interface BRegProposalDecision { readonly status: 'approved' | 'rejected' | 'changes-requested' | 'answered'; readonly decidedAt: string; readonly publicReason?: string }
|
|
1005
|
+
export interface BRegProposalSubmission {
|
|
1006
|
+
readonly id: string; readonly actionId: string; readonly submissionVersion: number; readonly current: boolean; readonly effectDigest: string
|
|
1007
|
+
readonly review: NonNullable<BRegProposalReviewDocument['result']> | null
|
|
1008
|
+
readonly application: (Omit<BRegProposalApplicationStatus, 'mode'> & {readonly mode?: BRegProposalApplicationStatus['mode']; readonly applicationId?: string; readonly appliedBy?: string; readonly appliedAt?: string}) | null
|
|
1009
|
+
readonly decision?: BRegProposalDecision
|
|
1010
|
+
}
|
|
1011
|
+
export interface BRegProposalDocument { readonly id: string; readonly actionId: string; readonly actionRevision: string; readonly submissionVersion: number; readonly revision: number; readonly state: 'draft' | 'submitted' | 'cancelled' | 'applied' | 'rejected'; readonly turn?: BRegProposalTurn; readonly decision?: BRegProposalDecision; readonly title?: string; readonly input?: JsonObject; readonly blockedReason?: 'package-changed'; readonly effectDigest?: string; readonly application?: BRegProposalApplication; readonly applicationStatus?: BRegProposalApplicationStatus; readonly links: Readonly<Partial<Record<BRegProposalTransition | 'self' | 'reviewContext' | 'reviewStatus', BRegProposalLink>>>; readonly attachments?: Readonly<Record<string, BRegProposalAttachment>> }
|
|
1012
|
+
export declare class BRegProposal { private constructor(); private readonly __opaque: void; readonly identifier: string; readonly actionIdentifier: string; readonly documentJson: string; readonly inputJson?: string | null }
|
|
1013
|
+
export declare class BRegProposalGetBinding { private constructor(); private readonly __opaque: void }
|
|
1014
|
+
export declare class BRegProposalReviewBinding { private constructor(); private readonly __opaque: void }
|
|
1015
|
+
|
|
1016
|
+
/** Inert document value projected by an authored Review context field. */
|
|
1017
|
+
export interface BRegProposalReviewAttachment {
|
|
1018
|
+
readonly type: 'document'
|
|
1019
|
+
readonly slotId: string
|
|
1020
|
+
readonly sha256: string
|
|
1021
|
+
readonly contentType: string
|
|
1022
|
+
readonly byteSize: number
|
|
1023
|
+
readonly download: {
|
|
1024
|
+
readonly method: 'GET'
|
|
1025
|
+
readonly operation: 'get-review-context'
|
|
1026
|
+
readonly accessProfile: string
|
|
1027
|
+
readonly path: string
|
|
1028
|
+
}
|
|
1029
|
+
}
|
|
1030
|
+
export declare class BRegProposalCollection { private constructor(); private readonly __opaque: void }
|
|
1031
|
+
export interface BRegProposalPage { readonly items: ReadonlyArray<BRegProposal>; readonly nextCursor?: string }
|
|
1032
|
+
export declare class BRegPreparedProposal { private constructor(); private readonly __opaque: void; static fromBytes(bytes: Buffer): BRegPreparedProposal; toBytes(): Buffer }
|