@criticalbridge/brain-client 1.0.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.
Files changed (126) hide show
  1. package/LICENSE +190 -0
  2. package/README.md +23 -0
  3. package/dist/auth.d.ts +2 -0
  4. package/dist/auth.js +21 -0
  5. package/dist/auth.js.map +1 -0
  6. package/dist/client.d.ts +604 -0
  7. package/dist/client.js +1197 -0
  8. package/dist/client.js.map +1 -0
  9. package/dist/errors.d.ts +17 -0
  10. package/dist/errors.js +44 -0
  11. package/dist/errors.js.map +1 -0
  12. package/dist/index.d.ts +52 -0
  13. package/dist/index.js +95 -0
  14. package/dist/index.js.map +1 -0
  15. package/dist/types/a2a.types.d.ts +42 -0
  16. package/dist/types/a2a.types.js +3 -0
  17. package/dist/types/a2a.types.js.map +1 -0
  18. package/dist/types/agent-skill-lifecycle.types.d.ts +46 -0
  19. package/dist/types/agent-skill-lifecycle.types.js +22 -0
  20. package/dist/types/agent-skill-lifecycle.types.js.map +1 -0
  21. package/dist/types/agent.types.d.ts +117 -0
  22. package/dist/types/agent.types.js +3 -0
  23. package/dist/types/agent.types.js.map +1 -0
  24. package/dist/types/ai-knowledge.types.d.ts +180 -0
  25. package/dist/types/ai-knowledge.types.js +3 -0
  26. package/dist/types/ai-knowledge.types.js.map +1 -0
  27. package/dist/types/api.types.d.ts +550 -0
  28. package/dist/types/api.types.js +3 -0
  29. package/dist/types/api.types.js.map +1 -0
  30. package/dist/types/approval-events.types.d.ts +43 -0
  31. package/dist/types/approval-events.types.js +7 -0
  32. package/dist/types/approval-events.types.js.map +1 -0
  33. package/dist/types/best-practices-kg.types.d.ts +112 -0
  34. package/dist/types/best-practices-kg.types.js +3 -0
  35. package/dist/types/best-practices-kg.types.js.map +1 -0
  36. package/dist/types/bias-threshold-policy.types.d.ts +37 -0
  37. package/dist/types/bias-threshold-policy.types.js +3 -0
  38. package/dist/types/bias-threshold-policy.types.js.map +1 -0
  39. package/dist/types/change-approval-gate.types.d.ts +110 -0
  40. package/dist/types/change-approval-gate.types.js +53 -0
  41. package/dist/types/change-approval-gate.types.js.map +1 -0
  42. package/dist/types/connection.types.d.ts +100 -0
  43. package/dist/types/connection.types.js +3 -0
  44. package/dist/types/connection.types.js.map +1 -0
  45. package/dist/types/connector-manifest.types.d.ts +889 -0
  46. package/dist/types/connector-manifest.types.js +118 -0
  47. package/dist/types/connector-manifest.types.js.map +1 -0
  48. package/dist/types/control-profile.types.d.ts +69 -0
  49. package/dist/types/control-profile.types.js +10 -0
  50. package/dist/types/control-profile.types.js.map +1 -0
  51. package/dist/types/corpus.types.d.ts +2584 -0
  52. package/dist/types/corpus.types.js +120 -0
  53. package/dist/types/corpus.types.js.map +1 -0
  54. package/dist/types/credentials.types.d.ts +18 -0
  55. package/dist/types/credentials.types.js +3 -0
  56. package/dist/types/credentials.types.js.map +1 -0
  57. package/dist/types/dashboard.types.d.ts +205 -0
  58. package/dist/types/dashboard.types.js +3 -0
  59. package/dist/types/dashboard.types.js.map +1 -0
  60. package/dist/types/document-ingestion.types.d.ts +30 -0
  61. package/dist/types/document-ingestion.types.js +3 -0
  62. package/dist/types/document-ingestion.types.js.map +1 -0
  63. package/dist/types/domain-event.types.d.ts +21 -0
  64. package/dist/types/domain-event.types.js +3 -0
  65. package/dist/types/domain-event.types.js.map +1 -0
  66. package/dist/types/drift-dashboard.types.d.ts +17 -0
  67. package/dist/types/drift-dashboard.types.js +3 -0
  68. package/dist/types/drift-dashboard.types.js.map +1 -0
  69. package/dist/types/effective-control-profile.types.d.ts +39 -0
  70. package/dist/types/effective-control-profile.types.js +39 -0
  71. package/dist/types/effective-control-profile.types.js.map +1 -0
  72. package/dist/types/entity-kg.types.d.ts +140 -0
  73. package/dist/types/entity-kg.types.js +3 -0
  74. package/dist/types/entity-kg.types.js.map +1 -0
  75. package/dist/types/entity-model-graph.types.d.ts +63 -0
  76. package/dist/types/entity-model-graph.types.js +3 -0
  77. package/dist/types/entity-model-graph.types.js.map +1 -0
  78. package/dist/types/entity-model-sources.types.d.ts +117 -0
  79. package/dist/types/entity-model-sources.types.js +3 -0
  80. package/dist/types/entity-model-sources.types.js.map +1 -0
  81. package/dist/types/entity.types.d.ts +6 -0
  82. package/dist/types/entity.types.js +3 -0
  83. package/dist/types/entity.types.js.map +1 -0
  84. package/dist/types/failure.types.d.ts +22 -0
  85. package/dist/types/failure.types.js +3 -0
  86. package/dist/types/failure.types.js.map +1 -0
  87. package/dist/types/harvest.types.d.ts +662 -0
  88. package/dist/types/harvest.types.js +52 -0
  89. package/dist/types/harvest.types.js.map +1 -0
  90. package/dist/types/incident.types.d.ts +105 -0
  91. package/dist/types/incident.types.js +3 -0
  92. package/dist/types/incident.types.js.map +1 -0
  93. package/dist/types/introspection.types.d.ts +46 -0
  94. package/dist/types/introspection.types.js +3 -0
  95. package/dist/types/introspection.types.js.map +1 -0
  96. package/dist/types/kb-kg.types.d.ts +38 -0
  97. package/dist/types/kb-kg.types.js +3 -0
  98. package/dist/types/kb-kg.types.js.map +1 -0
  99. package/dist/types/managed-agent.types.d.ts +59 -0
  100. package/dist/types/managed-agent.types.js +11 -0
  101. package/dist/types/managed-agent.types.js.map +1 -0
  102. package/dist/types/object-store.types.d.ts +25 -0
  103. package/dist/types/object-store.types.js +8 -0
  104. package/dist/types/object-store.types.js.map +1 -0
  105. package/dist/types/pipeline.types.d.ts +39 -0
  106. package/dist/types/pipeline.types.js +3 -0
  107. package/dist/types/pipeline.types.js.map +1 -0
  108. package/dist/types/policy.types.d.ts +32 -0
  109. package/dist/types/policy.types.js +3 -0
  110. package/dist/types/policy.types.js.map +1 -0
  111. package/dist/types/risk-classification.types.d.ts +71 -0
  112. package/dist/types/risk-classification.types.js +3 -0
  113. package/dist/types/risk-classification.types.js.map +1 -0
  114. package/dist/types/skill-draft.types.d.ts +271 -0
  115. package/dist/types/skill-draft.types.js +48 -0
  116. package/dist/types/skill-draft.types.js.map +1 -0
  117. package/dist/types/source-mapping.types.d.ts +69 -0
  118. package/dist/types/source-mapping.types.js +3 -0
  119. package/dist/types/source-mapping.types.js.map +1 -0
  120. package/dist/types/synthesize.types.d.ts +90 -0
  121. package/dist/types/synthesize.types.js +41 -0
  122. package/dist/types/synthesize.types.js.map +1 -0
  123. package/dist/types/wizard-assistant.types.d.ts +25 -0
  124. package/dist/types/wizard-assistant.types.js +3 -0
  125. package/dist/types/wizard-assistant.types.js.map +1 -0
  126. package/package.json +55 -0
@@ -0,0 +1,112 @@
1
+ export type BPKGRelationshipType = 'RELATES_TO' | 'PREREQUISITE_OF' | 'CONTRADICTS' | 'SUPERSEDES' | 'COMPLEMENTS' | 'PART_OF';
2
+ export type BPKGRelationshipStrength = 'weak' | 'moderate' | 'strong';
3
+ export type BPKGRelationshipStatus = 'active' | 'deprecated' | 'pending_review';
4
+ export interface BPKGRelationship {
5
+ id: string;
6
+ sourcePracticeId: string;
7
+ targetPracticeId: string;
8
+ type: BPKGRelationshipType;
9
+ strength: BPKGRelationshipStrength;
10
+ status: BPKGRelationshipStatus;
11
+ description?: string;
12
+ entityId: string;
13
+ confidenceScore?: number;
14
+ tags?: string[];
15
+ createdAt: string;
16
+ updatedAt: string;
17
+ createdBy?: string;
18
+ }
19
+ export interface BPKGRelationshipWithDetails extends BPKGRelationship {
20
+ sourcePractice: {
21
+ id: string;
22
+ title: string;
23
+ status: string;
24
+ };
25
+ targetPractice: {
26
+ id: string;
27
+ title: string;
28
+ status: string;
29
+ };
30
+ }
31
+ export interface BPKGContradictionRelationship extends BPKGRelationship {
32
+ type: 'CONTRADICTS';
33
+ conflictAreas: string[];
34
+ severity: 'minor' | 'moderate' | 'major' | 'critical';
35
+ resolution?: string;
36
+ applicableContext?: string;
37
+ }
38
+ export interface BPKGGraphTraversalResult {
39
+ practices: Array<{
40
+ id: string;
41
+ title: string;
42
+ status: string;
43
+ depth: number;
44
+ }>;
45
+ relationships: BPKGRelationship[];
46
+ pathLength: number;
47
+ }
48
+ export interface BPKGConflictDetectionResult {
49
+ hasConflicts: boolean;
50
+ conflicts: BPKGContradictionRelationship[];
51
+ overallSeverity: 'none' | 'minor' | 'moderate' | 'major' | 'critical';
52
+ affectedPracticeIds: string[];
53
+ }
54
+ export interface BPKGRecommendation {
55
+ practiceId: string;
56
+ title: string;
57
+ relationshipType: BPKGRelationshipType;
58
+ relevanceScore: number;
59
+ reason: string;
60
+ path?: string[];
61
+ }
62
+ export interface BPKGRecommendationResult {
63
+ sourcePracticeId: string;
64
+ recommendations: BPKGRecommendation[];
65
+ totalRelatedPractices: number;
66
+ executionTimeMs: number;
67
+ }
68
+ export interface BPKGStatistics {
69
+ practiceCount: number;
70
+ relationshipCount: number;
71
+ relationshipsByType: Partial<Record<BPKGRelationshipType, number>>;
72
+ }
73
+ export interface BPKGRelationshipQueryOptions {
74
+ types?: BPKGRelationshipType[];
75
+ minStrength?: BPKGRelationshipStrength;
76
+ status?: BPKGRelationshipStatus;
77
+ limit?: number;
78
+ offset?: number;
79
+ includeDeprecated?: boolean;
80
+ }
81
+ export interface BPKGRecommendationQueryOptions {
82
+ limit?: number;
83
+ relationshipTypes?: BPKGRelationshipType[];
84
+ minRelevanceScore?: number;
85
+ maxDepth?: number;
86
+ excludePracticeIds?: string[];
87
+ }
88
+ export interface BPKGTraverseBody {
89
+ practiceId: string;
90
+ maxDepth?: number;
91
+ relationshipTypes?: BPKGRelationshipType[];
92
+ direction?: 'outgoing' | 'incoming' | 'both';
93
+ }
94
+ export interface BPKGRelationshipsForPracticeBody {
95
+ practiceId: string;
96
+ options?: BPKGRelationshipQueryOptions;
97
+ }
98
+ export interface BPKGRecommendationsBody {
99
+ practiceId: string;
100
+ options?: BPKGRecommendationQueryOptions;
101
+ }
102
+ export interface BPKGShortestPathBody {
103
+ sourcePracticeId: string;
104
+ targetPracticeId: string;
105
+ maxDepth?: number;
106
+ }
107
+ export interface BPKGDetectConflictsBody {
108
+ practiceId: string;
109
+ }
110
+ export interface BPKGResultResponse<T> {
111
+ result: T;
112
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=best-practices-kg.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"best-practices-kg.types.js","sourceRoot":"","sources":["../../src/types/best-practices-kg.types.ts"],"names":[],"mappings":""}
@@ -0,0 +1,37 @@
1
+ import type { RiskTier } from './risk-classification.types';
2
+ export interface BiasThresholdSet {
3
+ disparateImpactRatio: number;
4
+ demographicParityDifference: number;
5
+ equalizedOddsDifference: number;
6
+ equalOpportunityDifference: number;
7
+ calibrationDifference: number;
8
+ proxyCorrelationThreshold: number;
9
+ minimumGroupSize: number;
10
+ significanceLevel: number;
11
+ }
12
+ export interface BiasThresholdRuleWire {
13
+ useCase?: string;
14
+ riskTier?: RiskTier;
15
+ thresholds: BiasThresholdSet;
16
+ requireForPromotion: boolean;
17
+ gateTiers?: RiskTier[];
18
+ }
19
+ export interface BiasThresholdPolicyWire {
20
+ entityId: string;
21
+ version: number;
22
+ rules: BiasThresholdRuleWire[];
23
+ updatedAt: string;
24
+ updatedBy: string;
25
+ }
26
+ export interface GetBiasThresholdPolicyResponse {
27
+ entityId: string;
28
+ policy: BiasThresholdPolicyWire | null;
29
+ }
30
+ export interface UpdateBiasThresholdPolicyBody {
31
+ rules: BiasThresholdRuleWire[];
32
+ updatedBy?: string;
33
+ }
34
+ export interface UpdateBiasThresholdPolicyResponse {
35
+ entityId: string;
36
+ policy: BiasThresholdPolicyWire;
37
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=bias-threshold-policy.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bias-threshold-policy.types.js","sourceRoot":"","sources":["../../src/types/bias-threshold-policy.types.ts"],"names":[],"mappings":""}
@@ -0,0 +1,110 @@
1
+ export type ChangeApprovalRiskTier = 'low' | 'medium' | 'high' | 'critical';
2
+ export declare const CHANGE_APPROVAL_TIERS: readonly ["low", "medium", "high", "critical"];
3
+ export declare const CHANGE_APPROVAL_MAX_JUSTIFICATION_LENGTH: 2048;
4
+ export declare const DEFAULT_CHANGE_APPROVAL_POLICIES: Readonly<Record<ChangeApprovalRiskTier, ChangeApprovalPolicy>>;
5
+ export interface ChangeApprovalPolicy {
6
+ tier: ChangeApprovalRiskTier;
7
+ minHumanApprovers: number;
8
+ requireRationale: boolean;
9
+ distinctApprovers: boolean;
10
+ allowedApproverRoles: string[];
11
+ requireExplicitCriticalAck: boolean;
12
+ approvalTimeoutMinutes: number;
13
+ blockOnAnyReject: boolean;
14
+ }
15
+ export interface ChangeApprovalPolicyOverride {
16
+ entityId: string;
17
+ tier: ChangeApprovalRiskTier;
18
+ overrides: Partial<Omit<ChangeApprovalPolicy, 'tier'>>;
19
+ updatedBy: string;
20
+ updatedAt: string;
21
+ version: number;
22
+ }
23
+ export interface ChangeApprovalPolicyAuditEntry {
24
+ id: string;
25
+ entityId: string;
26
+ tier: ChangeApprovalRiskTier;
27
+ changedBy: string;
28
+ changedAt: string;
29
+ previousVersion: number | null;
30
+ newVersion: number;
31
+ previousOverride: ChangeApprovalPolicyOverride['overrides'] | null;
32
+ newOverride: ChangeApprovalPolicyOverride['overrides'];
33
+ justification: string;
34
+ casLost?: boolean;
35
+ }
36
+ export interface TierPolicyView {
37
+ tier: ChangeApprovalRiskTier;
38
+ effective: ChangeApprovalPolicy;
39
+ override: ChangeApprovalPolicyOverride | null;
40
+ }
41
+ export interface ListChangeApprovalPoliciesResponse {
42
+ entityId: string;
43
+ policies: TierPolicyView[];
44
+ }
45
+ export interface GetChangeApprovalPolicyResponse extends TierPolicyView {
46
+ entityId: string;
47
+ }
48
+ export interface GetChangeApprovalPolicyAuditResponse {
49
+ entityId: string;
50
+ tier: ChangeApprovalRiskTier;
51
+ entries: ChangeApprovalPolicyAuditEntry[];
52
+ }
53
+ export interface SetChangeApprovalPolicyOverrideBody {
54
+ overrides: Partial<Omit<ChangeApprovalPolicy, 'tier'>>;
55
+ justification: string;
56
+ }
57
+ export interface ClearChangeApprovalPolicyOverrideBody {
58
+ justification: string;
59
+ }
60
+ export type ChangeApprovalChangeKind = 'skill' | 'agent';
61
+ export type ChangeApprovalDecisionType = 'approve' | 'reject';
62
+ export interface ChangeApprovalDecision {
63
+ id: string;
64
+ entityId: string;
65
+ changeId: string;
66
+ changeKind: ChangeApprovalChangeKind;
67
+ tier: ChangeApprovalRiskTier;
68
+ approver: string;
69
+ approverRole?: string;
70
+ decision: ChangeApprovalDecisionType;
71
+ rationale: string;
72
+ decidedAt: string;
73
+ acknowledgesCriticalRisk?: boolean;
74
+ policySnapshot: ChangeApprovalPolicy;
75
+ policyVersion: number | null;
76
+ }
77
+ export interface ChangeApprovalGateVerdict {
78
+ passed: boolean;
79
+ reason?: string;
80
+ policy: ChangeApprovalPolicy;
81
+ decisions: ChangeApprovalDecision[];
82
+ effectiveApprovals: number;
83
+ hasRejection: boolean;
84
+ criticalAckSatisfied: boolean;
85
+ }
86
+ export interface RecordChangeApprovalDecisionBody {
87
+ changeKind: ChangeApprovalChangeKind;
88
+ tier: ChangeApprovalRiskTier;
89
+ approver: string;
90
+ approverRole?: string;
91
+ decision: ChangeApprovalDecisionType;
92
+ rationale: string;
93
+ acknowledgesCriticalRisk?: boolean;
94
+ }
95
+ export interface RecordChangeApprovalDecisionResponse {
96
+ entityId: string;
97
+ changeId: string;
98
+ decision: ChangeApprovalDecision;
99
+ }
100
+ export interface ListChangeApprovalDecisionsResponse {
101
+ entityId: string;
102
+ changeId: string;
103
+ decisions: ChangeApprovalDecision[];
104
+ }
105
+ export interface GetChangeApprovalVerdictResponse {
106
+ entityId: string;
107
+ changeId: string;
108
+ tier: ChangeApprovalRiskTier;
109
+ verdict: ChangeApprovalGateVerdict;
110
+ }
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DEFAULT_CHANGE_APPROVAL_POLICIES = exports.CHANGE_APPROVAL_MAX_JUSTIFICATION_LENGTH = exports.CHANGE_APPROVAL_TIERS = void 0;
4
+ exports.CHANGE_APPROVAL_TIERS = [
5
+ 'low',
6
+ 'medium',
7
+ 'high',
8
+ 'critical',
9
+ ];
10
+ exports.CHANGE_APPROVAL_MAX_JUSTIFICATION_LENGTH = 2048;
11
+ exports.DEFAULT_CHANGE_APPROVAL_POLICIES = Object.freeze({
12
+ low: {
13
+ tier: 'low',
14
+ minHumanApprovers: 0,
15
+ requireRationale: false,
16
+ distinctApprovers: false,
17
+ allowedApproverRoles: ['role:compliance-officer'],
18
+ requireExplicitCriticalAck: false,
19
+ approvalTimeoutMinutes: 1440,
20
+ blockOnAnyReject: false,
21
+ },
22
+ medium: {
23
+ tier: 'medium',
24
+ minHumanApprovers: 1,
25
+ requireRationale: true,
26
+ distinctApprovers: false,
27
+ allowedApproverRoles: ['role:compliance-officer'],
28
+ requireExplicitCriticalAck: false,
29
+ approvalTimeoutMinutes: 240,
30
+ blockOnAnyReject: false,
31
+ },
32
+ high: {
33
+ tier: 'high',
34
+ minHumanApprovers: 2,
35
+ requireRationale: true,
36
+ distinctApprovers: true,
37
+ allowedApproverRoles: ['role:compliance-officer', 'role:risk-officer'],
38
+ requireExplicitCriticalAck: false,
39
+ approvalTimeoutMinutes: 60,
40
+ blockOnAnyReject: true,
41
+ },
42
+ critical: {
43
+ tier: 'critical',
44
+ minHumanApprovers: 2,
45
+ requireRationale: true,
46
+ distinctApprovers: true,
47
+ allowedApproverRoles: ['role:compliance-officer', 'role:cfo', 'role:risk-officer'],
48
+ requireExplicitCriticalAck: true,
49
+ approvalTimeoutMinutes: 30,
50
+ blockOnAnyReject: true,
51
+ },
52
+ });
53
+ //# sourceMappingURL=change-approval-gate.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"change-approval-gate.types.js","sourceRoot":"","sources":["../../src/types/change-approval-gate.types.ts"],"names":[],"mappings":";;;AAoCa,QAAA,qBAAqB,GAAG;IACnC,KAAK;IACL,QAAQ;IACR,MAAM;IACN,UAAU;CAC0C,CAAC;AAmB1C,QAAA,wCAAwC,GAAG,IAAa,CAAC;AAuBzD,QAAA,gCAAgC,GAEzC,MAAM,CAAC,MAAM,CAAC;IAChB,GAAG,EAAE;QACH,IAAI,EAAE,KAAK;QACX,iBAAiB,EAAE,CAAC;QACpB,gBAAgB,EAAE,KAAK;QACvB,iBAAiB,EAAE,KAAK;QACxB,oBAAoB,EAAE,CAAC,yBAAyB,CAAC;QACjD,0BAA0B,EAAE,KAAK;QACjC,sBAAsB,EAAE,IAAI;QAC5B,gBAAgB,EAAE,KAAK;KACxB;IACD,MAAM,EAAE;QACN,IAAI,EAAE,QAAQ;QACd,iBAAiB,EAAE,CAAC;QACpB,gBAAgB,EAAE,IAAI;QACtB,iBAAiB,EAAE,KAAK;QACxB,oBAAoB,EAAE,CAAC,yBAAyB,CAAC;QACjD,0BAA0B,EAAE,KAAK;QACjC,sBAAsB,EAAE,GAAG;QAC3B,gBAAgB,EAAE,KAAK;KACxB;IACD,IAAI,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,iBAAiB,EAAE,CAAC;QACpB,gBAAgB,EAAE,IAAI;QACtB,iBAAiB,EAAE,IAAI;QACvB,oBAAoB,EAAE,CAAC,yBAAyB,EAAE,mBAAmB,CAAC;QACtE,0BAA0B,EAAE,KAAK;QACjC,sBAAsB,EAAE,EAAE;QAC1B,gBAAgB,EAAE,IAAI;KACvB;IACD,QAAQ,EAAE;QACR,IAAI,EAAE,UAAU;QAChB,iBAAiB,EAAE,CAAC;QACpB,gBAAgB,EAAE,IAAI;QACtB,iBAAiB,EAAE,IAAI;QACvB,oBAAoB,EAAE,CAAC,yBAAyB,EAAE,UAAU,EAAE,mBAAmB,CAAC;QAClF,0BAA0B,EAAE,IAAI;QAChC,sBAAsB,EAAE,EAAE;QAC1B,gBAAgB,EAAE,IAAI;KACvB;CACF,CAAC,CAAC"}
@@ -0,0 +1,100 @@
1
+ export interface ConnectionMetadata {
2
+ id: string;
3
+ name: string;
4
+ type?: string;
5
+ provider?: string;
6
+ credentials: 'Corporate' | 'Individual';
7
+ protocol?: 'API' | 'MCP' | 'OAuth2' | 'HTTP' | 'REST' | 'GraphQL' | 'WebSocket';
8
+ authentication?: 'none' | 'basic' | 'bearer' | 'oauth2' | 'oauth1' | 'digest' | 'custom' | 'query' | 'header' | 'aws-signature-v4' | 'mtls' | 'hmac' | 'saml' | 'jwt' | 'session' | 'service-account' | 'service-account-dwd' | 'jwt-service-account' | 'OAuth' | 'OAuth2' | 'Service';
9
+ activity?: 'Active' | 'Inactive';
10
+ stage?: 'Development' | 'Staging' | 'Operational';
11
+ status: 'Online' | 'Offline';
12
+ operation?: 'Success' | 'Failed' | 'Error' | 'Not in Use';
13
+ loadControl?: 'auto' | 'manual' | 'disabled';
14
+ endpoint?: string;
15
+ region?: string;
16
+ vaultKeyId?: string;
17
+ tags?: string[];
18
+ source?: 'entity' | 'vendor' | 'criticalbridge';
19
+ sourceName?: string;
20
+ isSystemProvided?: boolean;
21
+ workflowId?: string;
22
+ workflowName?: string;
23
+ nodeId?: string;
24
+ nodeType?: string;
25
+ entityId?: string;
26
+ createdAt: string;
27
+ updatedAt: string;
28
+ createdBy?: string;
29
+ updatedBy?: string;
30
+ lastTested?: string;
31
+ lastError?: string;
32
+ allowedMinters?: ConnectionAllowedMinters;
33
+ reachability?: ConnectionReachability;
34
+ }
35
+ export interface ConnectionAllowedMinters {
36
+ userIds?: string[];
37
+ roles?: string[];
38
+ }
39
+ export type ConnectionReachability = 'cloud-reachable' | 'client-only';
40
+ interface ConnectionWriteFields {
41
+ type?: string;
42
+ provider?: string;
43
+ endpoint?: string;
44
+ region?: string;
45
+ vaultKeyId?: string;
46
+ tags?: string[];
47
+ workflowId?: string;
48
+ workflowName?: string;
49
+ nodeId?: string;
50
+ nodeType?: string;
51
+ isSystemProvided?: boolean;
52
+ allowedMinters?: ConnectionAllowedMinters;
53
+ reachability?: ConnectionReachability;
54
+ }
55
+ export interface ConnectionCreateBody extends ConnectionWriteFields {
56
+ id: string;
57
+ name: string;
58
+ credentials: 'Corporate' | 'Individual';
59
+ status?: 'Online' | 'Offline';
60
+ }
61
+ export interface ConnectionUpdateBody extends ConnectionWriteFields {
62
+ name?: string;
63
+ credentials?: 'Corporate' | 'Individual';
64
+ status?: 'Online' | 'Offline';
65
+ }
66
+ export interface ListConnectionsResponse {
67
+ connections: ConnectionMetadata[];
68
+ entityId: string;
69
+ count: number;
70
+ }
71
+ export interface GetConnectionResponse {
72
+ connection: ConnectionMetadata;
73
+ entityId: string;
74
+ }
75
+ export interface ConnectionWriteResponse {
76
+ connection: ConnectionMetadata;
77
+ entityId: string;
78
+ }
79
+ export interface PutCredentialResponse {
80
+ vaultKeyId: string;
81
+ entityId: string;
82
+ connectionId: string;
83
+ }
84
+ export interface ScopedCredential {
85
+ kind: 'raw' | 'derived';
86
+ value: Record<string, unknown>;
87
+ expiresAt: string;
88
+ scope: {
89
+ entityId: string;
90
+ connectionId: string;
91
+ userId: string;
92
+ };
93
+ }
94
+ export interface RefreshedCredentialResponse {
95
+ vaultKeyId: string;
96
+ entityId: string;
97
+ connectionId: string;
98
+ refreshedAt: string;
99
+ }
100
+ export {};
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=connection.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"connection.types.js","sourceRoot":"","sources":["../../src/types/connection.types.ts"],"names":[],"mappings":""}