@blue-repository/types 0.3.0 → 0.5.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 (148) hide show
  1. package/README.md +1 -1
  2. package/dist/index.d.ts +1 -0
  3. package/dist/index.d.ts.map +1 -1
  4. package/dist/index.js +1 -0
  5. package/dist/index.js.map +1 -1
  6. package/dist/meta.d.ts +2 -2
  7. package/dist/meta.d.ts.map +1 -1
  8. package/dist/meta.js +1 -0
  9. package/dist/meta.js.map +1 -1
  10. package/dist/packages/common/blue-ids.d.ts +5 -0
  11. package/dist/packages/common/blue-ids.d.ts.map +1 -0
  12. package/dist/packages/common/blue-ids.js +5 -0
  13. package/dist/packages/common/blue-ids.js.map +1 -0
  14. package/dist/packages/common/contents/Timestamp.d.ts +8 -0
  15. package/dist/packages/common/contents/Timestamp.d.ts.map +1 -0
  16. package/dist/packages/common/contents/Timestamp.js +8 -0
  17. package/dist/packages/common/contents/Timestamp.js.map +1 -0
  18. package/dist/packages/common/contents/index.d.ts +11 -0
  19. package/dist/packages/common/contents/index.d.ts.map +1 -0
  20. package/dist/packages/common/contents/index.js +6 -0
  21. package/dist/packages/common/contents/index.js.map +1 -0
  22. package/dist/packages/common/contents.d.ts +3 -0
  23. package/dist/packages/common/contents.d.ts.map +1 -0
  24. package/dist/packages/common/contents.js +3 -0
  25. package/dist/packages/common/contents.js.map +1 -0
  26. package/dist/packages/common/index.d.ts +39 -0
  27. package/dist/packages/common/index.d.ts.map +1 -0
  28. package/dist/packages/common/index.js +6 -0
  29. package/dist/packages/common/index.js.map +1 -0
  30. package/dist/packages/common/meta.d.ts +19 -0
  31. package/dist/packages/common/meta.d.ts.map +1 -0
  32. package/dist/packages/common/meta.js +23 -0
  33. package/dist/packages/common/meta.js.map +1 -0
  34. package/dist/packages/common/schemas/Timestamp.d.ts +8 -0
  35. package/dist/packages/common/schemas/Timestamp.d.ts.map +1 -0
  36. package/dist/packages/common/schemas/Timestamp.js +5 -0
  37. package/dist/packages/common/schemas/Timestamp.js.map +1 -0
  38. package/dist/packages/common/schemas/index.d.ts +9 -0
  39. package/dist/packages/common/schemas/index.d.ts.map +1 -0
  40. package/dist/packages/common/schemas/index.js +6 -0
  41. package/dist/packages/common/schemas/index.js.map +1 -0
  42. package/dist/packages/common/schemas.d.ts +3 -0
  43. package/dist/packages/common/schemas.d.ts.map +1 -0
  44. package/dist/packages/common/schemas.js +3 -0
  45. package/dist/packages/common/schemas.js.map +1 -0
  46. package/dist/packages/index.d.ts +1 -0
  47. package/dist/packages/index.d.ts.map +1 -1
  48. package/dist/packages/index.js +1 -0
  49. package/dist/packages/index.js.map +1 -1
  50. package/dist/packages/paynote/blue-ids.d.ts +9 -0
  51. package/dist/packages/paynote/blue-ids.d.ts.map +1 -1
  52. package/dist/packages/paynote/blue-ids.js +9 -0
  53. package/dist/packages/paynote/blue-ids.js.map +1 -1
  54. package/dist/packages/paynote/contents/CardTransactionDetails.d.ts +29 -0
  55. package/dist/packages/paynote/contents/CardTransactionDetails.d.ts.map +1 -0
  56. package/dist/packages/paynote/contents/CardTransactionDetails.js +29 -0
  57. package/dist/packages/paynote/contents/CardTransactionDetails.js.map +1 -0
  58. package/dist/packages/paynote/contents/PayNoteAcceptedByClient.d.ts +14 -0
  59. package/dist/packages/paynote/contents/PayNoteAcceptedByClient.d.ts.map +1 -0
  60. package/dist/packages/paynote/contents/PayNoteAcceptedByClient.js +14 -0
  61. package/dist/packages/paynote/contents/PayNoteAcceptedByClient.js.map +1 -0
  62. package/dist/packages/paynote/contents/PayNoteClientDecisionDiscarded.d.ts +26 -0
  63. package/dist/packages/paynote/contents/PayNoteClientDecisionDiscarded.d.ts.map +1 -0
  64. package/dist/packages/paynote/contents/PayNoteClientDecisionDiscarded.js +26 -0
  65. package/dist/packages/paynote/contents/PayNoteClientDecisionDiscarded.js.map +1 -0
  66. package/dist/packages/paynote/contents/PayNoteDelivery.d.ts +636 -0
  67. package/dist/packages/paynote/contents/PayNoteDelivery.d.ts.map +1 -0
  68. package/dist/packages/paynote/contents/PayNoteDelivery.js +672 -0
  69. package/dist/packages/paynote/contents/PayNoteDelivery.js.map +1 -0
  70. package/dist/packages/paynote/contents/PayNoteDeliveryBootstrapRequested.d.ts +14 -0
  71. package/dist/packages/paynote/contents/PayNoteDeliveryBootstrapRequested.d.ts.map +1 -0
  72. package/dist/packages/paynote/contents/PayNoteDeliveryBootstrapRequested.js +14 -0
  73. package/dist/packages/paynote/contents/PayNoteDeliveryBootstrapRequested.js.map +1 -0
  74. package/dist/packages/paynote/contents/PayNoteDeliveryFailed.d.ts +14 -0
  75. package/dist/packages/paynote/contents/PayNoteDeliveryFailed.d.ts.map +1 -0
  76. package/dist/packages/paynote/contents/PayNoteDeliveryFailed.js +14 -0
  77. package/dist/packages/paynote/contents/PayNoteDeliveryFailed.js.map +1 -0
  78. package/dist/packages/paynote/contents/PayNoteRejectedByClient.d.ts +20 -0
  79. package/dist/packages/paynote/contents/PayNoteRejectedByClient.d.ts.map +1 -0
  80. package/dist/packages/paynote/contents/PayNoteRejectedByClient.js +20 -0
  81. package/dist/packages/paynote/contents/PayNoteRejectedByClient.js.map +1 -0
  82. package/dist/packages/paynote/contents/TransactionIdentificationFailed.d.ts +14 -0
  83. package/dist/packages/paynote/contents/TransactionIdentificationFailed.d.ts.map +1 -0
  84. package/dist/packages/paynote/contents/TransactionIdentificationFailed.js +14 -0
  85. package/dist/packages/paynote/contents/TransactionIdentificationFailed.js.map +1 -0
  86. package/dist/packages/paynote/contents/TransactionIdentified.d.ts +8 -0
  87. package/dist/packages/paynote/contents/TransactionIdentified.d.ts.map +1 -0
  88. package/dist/packages/paynote/contents/TransactionIdentified.js +8 -0
  89. package/dist/packages/paynote/contents/TransactionIdentified.js.map +1 -0
  90. package/dist/packages/paynote/contents/index.d.ts +775 -0
  91. package/dist/packages/paynote/contents/index.d.ts.map +1 -1
  92. package/dist/packages/paynote/contents/index.js +27 -0
  93. package/dist/packages/paynote/contents/index.js.map +1 -1
  94. package/dist/packages/paynote/index.d.ts +4176 -65
  95. package/dist/packages/paynote/index.d.ts.map +1 -1
  96. package/dist/packages/paynote/meta.d.ts +90 -0
  97. package/dist/packages/paynote/meta.d.ts.map +1 -1
  98. package/dist/packages/paynote/meta.js +99 -0
  99. package/dist/packages/paynote/meta.js.map +1 -1
  100. package/dist/packages/paynote/schemas/CardTransactionDetails.d.ts +25 -0
  101. package/dist/packages/paynote/schemas/CardTransactionDetails.d.ts.map +1 -0
  102. package/dist/packages/paynote/schemas/CardTransactionDetails.js +12 -0
  103. package/dist/packages/paynote/schemas/CardTransactionDetails.js.map +1 -0
  104. package/dist/packages/paynote/schemas/PayNoteAcceptedByClient.d.ts +27 -0
  105. package/dist/packages/paynote/schemas/PayNoteAcceptedByClient.d.ts.map +1 -0
  106. package/dist/packages/paynote/schemas/PayNoteAcceptedByClient.js +11 -0
  107. package/dist/packages/paynote/schemas/PayNoteAcceptedByClient.js.map +1 -0
  108. package/dist/packages/paynote/schemas/PayNoteClientDecisionDiscarded.d.ts +33 -0
  109. package/dist/packages/paynote/schemas/PayNoteClientDecisionDiscarded.d.ts.map +1 -0
  110. package/dist/packages/paynote/schemas/PayNoteClientDecisionDiscarded.js +13 -0
  111. package/dist/packages/paynote/schemas/PayNoteClientDecisionDiscarded.js.map +1 -0
  112. package/dist/packages/paynote/schemas/PayNoteDelivery.d.ts +1363 -0
  113. package/dist/packages/paynote/schemas/PayNoteDelivery.d.ts.map +1 -0
  114. package/dist/packages/paynote/schemas/PayNoteDelivery.js +42 -0
  115. package/dist/packages/paynote/schemas/PayNoteDelivery.js.map +1 -0
  116. package/dist/packages/paynote/schemas/PayNoteDeliveryBootstrapRequested.d.ts +1750 -0
  117. package/dist/packages/paynote/schemas/PayNoteDeliveryBootstrapRequested.d.ts.map +1 -0
  118. package/dist/packages/paynote/schemas/PayNoteDeliveryBootstrapRequested.js +11 -0
  119. package/dist/packages/paynote/schemas/PayNoteDeliveryBootstrapRequested.js.map +1 -0
  120. package/dist/packages/paynote/schemas/PayNoteDeliveryFailed.d.ts +19 -0
  121. package/dist/packages/paynote/schemas/PayNoteDeliveryFailed.d.ts.map +1 -0
  122. package/dist/packages/paynote/schemas/PayNoteDeliveryFailed.js +10 -0
  123. package/dist/packages/paynote/schemas/PayNoteDeliveryFailed.js.map +1 -0
  124. package/dist/packages/paynote/schemas/PayNoteRejectedByClient.d.ts +30 -0
  125. package/dist/packages/paynote/schemas/PayNoteRejectedByClient.d.ts.map +1 -0
  126. package/dist/packages/paynote/schemas/PayNoteRejectedByClient.js +12 -0
  127. package/dist/packages/paynote/schemas/PayNoteRejectedByClient.js.map +1 -0
  128. package/dist/packages/paynote/schemas/TransactionIdentificationFailed.d.ts +19 -0
  129. package/dist/packages/paynote/schemas/TransactionIdentificationFailed.d.ts.map +1 -0
  130. package/dist/packages/paynote/schemas/TransactionIdentificationFailed.js +10 -0
  131. package/dist/packages/paynote/schemas/TransactionIdentificationFailed.js.map +1 -0
  132. package/dist/packages/paynote/schemas/TransactionIdentified.d.ts +16 -0
  133. package/dist/packages/paynote/schemas/TransactionIdentified.d.ts.map +1 -0
  134. package/dist/packages/paynote/schemas/TransactionIdentified.js +9 -0
  135. package/dist/packages/paynote/schemas/TransactionIdentified.js.map +1 -0
  136. package/dist/packages/paynote/schemas/index.d.ts +3441 -177
  137. package/dist/packages/paynote/schemas/index.d.ts.map +1 -1
  138. package/dist/packages/paynote/schemas/index.js +27 -0
  139. package/dist/packages/paynote/schemas/index.js.map +1 -1
  140. package/dist/repository.d.ts +4607 -463
  141. package/dist/repository.d.ts.map +1 -1
  142. package/dist/repository.js +2 -0
  143. package/dist/repository.js.map +1 -1
  144. package/dist/type-aliases.d.ts +3 -0
  145. package/dist/type-aliases.d.ts.map +1 -0
  146. package/dist/type-aliases.js +25 -0
  147. package/dist/type-aliases.js.map +1 -0
  148. package/package.json +10 -2
@@ -0,0 +1,672 @@
1
+ export const PayNoteDelivery = {
2
+ cardTransactionDetails: {
3
+ description: 'Card network identifiers used to match processor and issuer records.',
4
+ type: {
5
+ blueId: 'GZLRe2fEsvs1v7dVcg9kEnCrWEdM3cUZYhFH4XqN5jQT',
6
+ },
7
+ },
8
+ clientAcceptedAt: {
9
+ description: 'Timestamp when the client accepted.',
10
+ type: {
11
+ blueId: 'GQaGqFxHDz64L1c9QkCbz52ths6bMVtpHnw4QDngzQYs',
12
+ },
13
+ },
14
+ clientDecisionStatus: {
15
+ description: 'Client decision (pending, accepted, rejected).',
16
+ type: {
17
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
18
+ },
19
+ },
20
+ clientRejectedAt: {
21
+ description: 'Timestamp when the client rejected.',
22
+ type: {
23
+ blueId: 'GQaGqFxHDz64L1c9QkCbz52ths6bMVtpHnw4QDngzQYs',
24
+ },
25
+ },
26
+ contracts: {
27
+ initialize: {
28
+ channel: {
29
+ type: {
30
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
31
+ },
32
+ value: 'initLifecycleChannel',
33
+ },
34
+ steps: {
35
+ items: [
36
+ {
37
+ changeset: {
38
+ items: [
39
+ {
40
+ op: {
41
+ type: {
42
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
43
+ },
44
+ value: 'replace',
45
+ },
46
+ path: {
47
+ type: {
48
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
49
+ },
50
+ value: '/deliveryStatus',
51
+ },
52
+ val: {
53
+ type: {
54
+ blueId: 'ETAPjwZVyYEfPUWvXkCWAuybBhYUayg4hKC2V7mLXmsv',
55
+ },
56
+ },
57
+ },
58
+ {
59
+ op: {
60
+ type: {
61
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
62
+ },
63
+ value: 'replace',
64
+ },
65
+ path: {
66
+ type: {
67
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
68
+ },
69
+ value: '/transactionIdentificationStatus',
70
+ },
71
+ val: {
72
+ type: {
73
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
74
+ },
75
+ value: 'pending',
76
+ },
77
+ },
78
+ {
79
+ op: {
80
+ type: {
81
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
82
+ },
83
+ value: 'replace',
84
+ },
85
+ path: {
86
+ type: {
87
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
88
+ },
89
+ value: '/clientDecisionStatus',
90
+ },
91
+ val: {
92
+ type: {
93
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
94
+ },
95
+ value: 'pending',
96
+ },
97
+ },
98
+ {
99
+ op: {
100
+ type: {
101
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
102
+ },
103
+ value: 'replace',
104
+ },
105
+ path: {
106
+ type: {
107
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
108
+ },
109
+ value: '/deliveryError',
110
+ },
111
+ val: {
112
+ type: {
113
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
114
+ },
115
+ value: '',
116
+ },
117
+ },
118
+ ],
119
+ },
120
+ name: 'Initialize Delivery State',
121
+ type: {
122
+ blueId: 'BnnNLCnKF49TUJ1bRfZ5rSMaFw8SVfUNfnE4kJFG7HtM',
123
+ },
124
+ },
125
+ ],
126
+ },
127
+ type: {
128
+ blueId: '7X3LkN54Yp88JgZbppPhP6hM3Jqiqv8Z2i4kS7phXtQe',
129
+ },
130
+ },
131
+ initLifecycleChannel: {
132
+ event: {
133
+ type: {
134
+ blueId: 'BrpmpNt5JkapeUvPqYcxgXZrHNZX3R757dRwuXXdfNM2',
135
+ },
136
+ },
137
+ type: {
138
+ blueId: 'H2aCCTUcLMTJozWkn7HPUjyFBFxamraw1q8DyWk87zxr',
139
+ },
140
+ },
141
+ markPayNoteAcceptedByClient: {
142
+ channel: {
143
+ type: {
144
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
145
+ },
146
+ value: 'payNoteDeliverer',
147
+ },
148
+ request: {
149
+ acceptedAt: {
150
+ description: 'Timestamp when the client accepted.',
151
+ type: {
152
+ blueId: 'GQaGqFxHDz64L1c9QkCbz52ths6bMVtpHnw4QDngzQYs',
153
+ },
154
+ },
155
+ },
156
+ type: {
157
+ blueId: 'BoAiqVUZv9Fum3wFqaX2JnQMBHJLxJSo2V9U2UBmCfsC',
158
+ },
159
+ },
160
+ markPayNoteAcceptedByClientImpl: {
161
+ operation: {
162
+ type: {
163
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
164
+ },
165
+ value: 'markPayNoteAcceptedByClient',
166
+ },
167
+ steps: {
168
+ items: [
169
+ {
170
+ code: {
171
+ type: {
172
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
173
+ },
174
+ value: 'const request =\n event && event.message ? event.message.request : null;\nconst acceptedAt =\n request && typeof request.acceptedAt === "string"\n ? request.acceptedAt\n : "";\nconst currentDecisionStatus = document(\'/clientDecisionStatus\');\nconst alreadyAccepted = currentDecisionStatus === "accepted";\nconst alreadyRejected = currentDecisionStatus === "rejected";\nconst alreadyDecided = alreadyAccepted || alreadyRejected;\nconst transactionStatus = document(\'/transactionIdentificationStatus\');\nconst canAccept =\n transactionStatus === "identified" &&\n currentDecisionStatus === "pending";\nconst discardReason = canAccept\n ? ""\n : alreadyDecided\n ? `PayNote already ${currentDecisionStatus}`\n : transactionStatus === "failed"\n ? "Transaction identification failed"\n : "Transaction not identified";\nconst currentAcceptedAt = document(\'/clientAcceptedAt\');\nconst currentDeliveryStatus =\n document.canonical(\'/deliveryStatus\') || {\n type: "Conversation/Status Pending"\n };\nconst currentDeliveryError = document(\'/deliveryError\');\n\nconst nextDecisionStatus = canAccept\n ? "accepted"\n : typeof currentDecisionStatus === "string"\n ? currentDecisionStatus\n : "pending";\nconst nextAcceptedAt = canAccept\n ? acceptedAt\n : typeof currentAcceptedAt === "string"\n ? currentAcceptedAt\n : "";\nconst nextDeliveryStatus = canAccept\n ? { type: "Conversation/Status Completed" }\n : currentDeliveryStatus;\nconst nextDeliveryError = canAccept\n ? ""\n : typeof currentDeliveryError === "string"\n ? currentDeliveryError\n : "";\n\nreturn {\n acceptedAt,\n nextDecisionStatus,\n nextAcceptedAt,\n nextDeliveryStatus,\n nextDeliveryError,\n events: canAccept\n ? [\n {\n type: "PayNote/PayNote Accepted By Client",\n acceptedAt\n }\n ]\n : [\n {\n type: "PayNote/PayNote Client Decision Discarded",\n decision: "accepted",\n reason: discardReason,\n decisionAt: acceptedAt\n }\n ]\n};\n',
175
+ },
176
+ name: 'Capture Acceptance Timestamp',
177
+ type: {
178
+ blueId: '3hYcmWMtMUPAzXBLFLb7BpuG9537tuTJPCr7pxWXvTZK',
179
+ },
180
+ },
181
+ {
182
+ changeset: {
183
+ items: [
184
+ {
185
+ op: {
186
+ type: {
187
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
188
+ },
189
+ value: 'replace',
190
+ },
191
+ path: {
192
+ type: {
193
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
194
+ },
195
+ value: '/clientDecisionStatus',
196
+ },
197
+ val: {
198
+ type: {
199
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
200
+ },
201
+ value: "${steps['Capture Acceptance Timestamp'].nextDecisionStatus}",
202
+ },
203
+ },
204
+ {
205
+ op: {
206
+ type: {
207
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
208
+ },
209
+ value: 'replace',
210
+ },
211
+ path: {
212
+ type: {
213
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
214
+ },
215
+ value: '/clientAcceptedAt',
216
+ },
217
+ val: {
218
+ type: {
219
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
220
+ },
221
+ value: "${steps['Capture Acceptance Timestamp'].nextAcceptedAt}",
222
+ },
223
+ },
224
+ {
225
+ op: {
226
+ type: {
227
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
228
+ },
229
+ value: 'replace',
230
+ },
231
+ path: {
232
+ type: {
233
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
234
+ },
235
+ value: '/deliveryStatus',
236
+ },
237
+ val: {
238
+ type: {
239
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
240
+ },
241
+ value: "${steps['Capture Acceptance Timestamp'].nextDeliveryStatus}",
242
+ },
243
+ },
244
+ {
245
+ op: {
246
+ type: {
247
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
248
+ },
249
+ value: 'replace',
250
+ },
251
+ path: {
252
+ type: {
253
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
254
+ },
255
+ value: '/deliveryError',
256
+ },
257
+ val: {
258
+ type: {
259
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
260
+ },
261
+ value: "${steps['Capture Acceptance Timestamp'].nextDeliveryError}",
262
+ },
263
+ },
264
+ ],
265
+ },
266
+ name: 'Apply Acceptance Update',
267
+ type: {
268
+ blueId: 'BnnNLCnKF49TUJ1bRfZ5rSMaFw8SVfUNfnE4kJFG7HtM',
269
+ },
270
+ },
271
+ ],
272
+ },
273
+ type: {
274
+ blueId: 'CGdxkNjPcsdescqLPz6SNLsMyak6demQQr7RoKNHbCyv',
275
+ },
276
+ },
277
+ markPayNoteRejectedByClient: {
278
+ channel: {
279
+ type: {
280
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
281
+ },
282
+ value: 'payNoteDeliverer',
283
+ },
284
+ request: {
285
+ reason: {
286
+ description: 'Optional rejection reason.',
287
+ type: {
288
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
289
+ },
290
+ },
291
+ rejectedAt: {
292
+ description: 'Timestamp when the client rejected.',
293
+ type: {
294
+ blueId: 'GQaGqFxHDz64L1c9QkCbz52ths6bMVtpHnw4QDngzQYs',
295
+ },
296
+ },
297
+ },
298
+ type: {
299
+ blueId: 'BoAiqVUZv9Fum3wFqaX2JnQMBHJLxJSo2V9U2UBmCfsC',
300
+ },
301
+ },
302
+ markPayNoteRejectedByClientImpl: {
303
+ operation: {
304
+ type: {
305
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
306
+ },
307
+ value: 'markPayNoteRejectedByClient',
308
+ },
309
+ steps: {
310
+ items: [
311
+ {
312
+ code: {
313
+ type: {
314
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
315
+ },
316
+ value: 'const request =\n event && event.message ? event.message.request : null;\nconst safeReason =\n typeof request === "string"\n ? request\n : request && typeof request.reason === "string"\n ? request.reason\n : "";\nconst rejectedAt =\n request && typeof request.rejectedAt === "string"\n ? request.rejectedAt\n : "";\nconst currentDecisionStatus = document(\'/clientDecisionStatus\');\nconst alreadyAccepted = currentDecisionStatus === "accepted";\nconst alreadyRejected = currentDecisionStatus === "rejected";\nconst alreadyDecided = alreadyAccepted || alreadyRejected;\nconst transactionStatus = document(\'/transactionIdentificationStatus\');\nconst canReject =\n transactionStatus === "identified" &&\n currentDecisionStatus === "pending";\nconst discardReason = canReject\n ? ""\n : alreadyDecided\n ? `PayNote already ${currentDecisionStatus}`\n : transactionStatus === "failed"\n ? "Transaction identification failed"\n : "Transaction not identified";\n\nconst currentRejectedAt = document(\'/clientRejectedAt\');\nconst currentDeliveryStatus =\n document.canonical(\'/deliveryStatus\') || {\n type: "Conversation/Status Pending"\n };\nconst currentDeliveryError = document(\'/deliveryError\');\n\nconst nextDecisionStatus = canReject\n ? "rejected"\n : typeof currentDecisionStatus === "string"\n ? currentDecisionStatus\n : "pending";\nconst nextRejectedAt = canReject\n ? rejectedAt\n : typeof currentRejectedAt === "string"\n ? currentRejectedAt\n : "";\nconst nextDeliveryStatus = canReject\n ? { type: "Conversation/Status Failed" }\n : currentDeliveryStatus;\nconst nextDeliveryError = canReject\n ? safeReason\n : typeof currentDeliveryError === "string"\n ? currentDeliveryError\n : "";\n\nreturn {\n reason: safeReason,\n rejectedAt,\n nextDecisionStatus,\n nextRejectedAt,\n nextDeliveryStatus,\n nextDeliveryError,\n events: canReject\n ? [\n {\n type: "PayNote/PayNote Rejected By Client",\n reason: safeReason,\n rejectedAt\n }\n ]\n : [\n {\n type: "PayNote/PayNote Client Decision Discarded",\n decision: "rejected",\n reason: discardReason,\n decisionAt: rejectedAt\n }\n ]\n};\n',
317
+ },
318
+ name: 'Capture Rejection Reason',
319
+ type: {
320
+ blueId: '3hYcmWMtMUPAzXBLFLb7BpuG9537tuTJPCr7pxWXvTZK',
321
+ },
322
+ },
323
+ {
324
+ changeset: {
325
+ items: [
326
+ {
327
+ op: {
328
+ type: {
329
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
330
+ },
331
+ value: 'replace',
332
+ },
333
+ path: {
334
+ type: {
335
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
336
+ },
337
+ value: '/clientDecisionStatus',
338
+ },
339
+ val: {
340
+ type: {
341
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
342
+ },
343
+ value: "${steps['Capture Rejection Reason'].nextDecisionStatus}",
344
+ },
345
+ },
346
+ {
347
+ op: {
348
+ type: {
349
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
350
+ },
351
+ value: 'replace',
352
+ },
353
+ path: {
354
+ type: {
355
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
356
+ },
357
+ value: '/clientRejectedAt',
358
+ },
359
+ val: {
360
+ type: {
361
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
362
+ },
363
+ value: "${steps['Capture Rejection Reason'].nextRejectedAt}",
364
+ },
365
+ },
366
+ {
367
+ op: {
368
+ type: {
369
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
370
+ },
371
+ value: 'replace',
372
+ },
373
+ path: {
374
+ type: {
375
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
376
+ },
377
+ value: '/deliveryStatus',
378
+ },
379
+ val: {
380
+ type: {
381
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
382
+ },
383
+ value: "${steps['Capture Rejection Reason'].nextDeliveryStatus}",
384
+ },
385
+ },
386
+ {
387
+ op: {
388
+ type: {
389
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
390
+ },
391
+ value: 'replace',
392
+ },
393
+ path: {
394
+ type: {
395
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
396
+ },
397
+ value: '/deliveryError',
398
+ },
399
+ val: {
400
+ type: {
401
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
402
+ },
403
+ value: "${steps['Capture Rejection Reason'].nextDeliveryError}",
404
+ },
405
+ },
406
+ ],
407
+ },
408
+ name: 'Apply Rejection Update',
409
+ type: {
410
+ blueId: 'BnnNLCnKF49TUJ1bRfZ5rSMaFw8SVfUNfnE4kJFG7HtM',
411
+ },
412
+ },
413
+ ],
414
+ },
415
+ type: {
416
+ blueId: 'CGdxkNjPcsdescqLPz6SNLsMyak6demQQr7RoKNHbCyv',
417
+ },
418
+ },
419
+ payNoteDeliverer: {
420
+ description: 'Participant delivering and reporting status (e.g., bank).',
421
+ type: {
422
+ blueId: 'HCF8mXnX3dFjQ8osjxb4Wzm2Nm1DoXnTYuA5sPnV7NTs',
423
+ },
424
+ },
425
+ payNoteReceiver: {
426
+ description: 'Participant receiving the PayNote delivery (payer).',
427
+ type: {
428
+ blueId: 'HCF8mXnX3dFjQ8osjxb4Wzm2Nm1DoXnTYuA5sPnV7NTs',
429
+ },
430
+ },
431
+ payNoteSender: {
432
+ description: 'Participant submitting the PayNote delivery (merchant or processor).',
433
+ type: {
434
+ blueId: 'HCF8mXnX3dFjQ8osjxb4Wzm2Nm1DoXnTYuA5sPnV7NTs',
435
+ },
436
+ },
437
+ reportDeliveryError: {
438
+ channel: {
439
+ type: {
440
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
441
+ },
442
+ value: 'payNoteDeliverer',
443
+ },
444
+ request: {
445
+ description: 'Delivery error reason.',
446
+ type: {
447
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
448
+ },
449
+ },
450
+ type: {
451
+ blueId: 'BoAiqVUZv9Fum3wFqaX2JnQMBHJLxJSo2V9U2UBmCfsC',
452
+ },
453
+ },
454
+ reportDeliveryErrorImpl: {
455
+ operation: {
456
+ type: {
457
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
458
+ },
459
+ value: 'reportDeliveryError',
460
+ },
461
+ steps: {
462
+ items: [
463
+ {
464
+ code: {
465
+ type: {
466
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
467
+ },
468
+ value: 'const reason =\n event && event.message ? event.message.request : "";\nconst safeReason = typeof reason === "string" ? reason : "";\n\nreturn {\n reason: safeReason,\n events: [\n {\n type: "PayNote/PayNote Delivery Failed",\n reason: safeReason\n }\n ]\n};\n',
469
+ },
470
+ name: 'Capture Delivery Failure Reason',
471
+ type: {
472
+ blueId: '3hYcmWMtMUPAzXBLFLb7BpuG9537tuTJPCr7pxWXvTZK',
473
+ },
474
+ },
475
+ {
476
+ changeset: {
477
+ items: [
478
+ {
479
+ op: {
480
+ type: {
481
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
482
+ },
483
+ value: 'replace',
484
+ },
485
+ path: {
486
+ type: {
487
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
488
+ },
489
+ value: '/deliveryStatus',
490
+ },
491
+ val: {
492
+ type: {
493
+ blueId: 'Guus3kHbivXvy5G93yhiKs3Pc8sxCc4XVvSo7CqLsQEc',
494
+ },
495
+ },
496
+ },
497
+ {
498
+ op: {
499
+ type: {
500
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
501
+ },
502
+ value: 'replace',
503
+ },
504
+ path: {
505
+ type: {
506
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
507
+ },
508
+ value: '/deliveryError',
509
+ },
510
+ val: {
511
+ type: {
512
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
513
+ },
514
+ value: "${steps['Capture Delivery Failure Reason'].reason}",
515
+ },
516
+ },
517
+ ],
518
+ },
519
+ name: 'Apply Delivery Failure',
520
+ type: {
521
+ blueId: 'BnnNLCnKF49TUJ1bRfZ5rSMaFw8SVfUNfnE4kJFG7HtM',
522
+ },
523
+ },
524
+ ],
525
+ },
526
+ type: {
527
+ blueId: 'CGdxkNjPcsdescqLPz6SNLsMyak6demQQr7RoKNHbCyv',
528
+ },
529
+ },
530
+ updateTransactionIdentificationStatus: {
531
+ channel: {
532
+ type: {
533
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
534
+ },
535
+ value: 'payNoteDeliverer',
536
+ },
537
+ request: {
538
+ description: 'True when the transaction is identified.',
539
+ type: {
540
+ blueId: '4EzhSubEimSQD3zrYHRtobfPPWntUuhEz8YcdxHsi12u',
541
+ },
542
+ },
543
+ type: {
544
+ blueId: 'BoAiqVUZv9Fum3wFqaX2JnQMBHJLxJSo2V9U2UBmCfsC',
545
+ },
546
+ },
547
+ updateTransactionIdentificationStatusImpl: {
548
+ operation: {
549
+ type: {
550
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
551
+ },
552
+ value: 'updateTransactionIdentificationStatus',
553
+ },
554
+ steps: {
555
+ items: [
556
+ {
557
+ code: {
558
+ type: {
559
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
560
+ },
561
+ value: 'const request =\n event && event.message ? event.message.request : null;\nconst identified = request === true;\nconst currentStatus = document(\'/transactionIdentificationStatus\');\nconst canUpdate =\n currentStatus !== "identified" && currentStatus !== "failed";\nconst identificationStatus = canUpdate\n ? identified\n ? "identified"\n : "failed"\n : currentStatus;\nconst currentDeliveryStatus =\n document.canonical(\'/deliveryStatus\') || {\n type: "Conversation/Status Pending"\n };\nconst deliveryStatus = canUpdate\n ? identified\n ? { type: "Conversation/Status In Progress" }\n : { type: "Conversation/Status Failed" }\n : currentDeliveryStatus;\nconst currentDeliveryError = document(\'/deliveryError\');\nconst deliveryError = canUpdate\n ? identified\n ? ""\n : "Transaction identification failed"\n : typeof currentDeliveryError === "string"\n ? currentDeliveryError\n : "";\nconst eventType = identified\n ? "PayNote/Transaction Identified"\n : "PayNote/Transaction Identification Failed";\n\nreturn {\n identificationStatus,\n deliveryStatus,\n deliveryError,\n events: canUpdate ? [{ type: eventType }] : []\n};\n',
562
+ },
563
+ name: 'Classify Identification Result',
564
+ type: {
565
+ blueId: '3hYcmWMtMUPAzXBLFLb7BpuG9537tuTJPCr7pxWXvTZK',
566
+ },
567
+ },
568
+ {
569
+ changeset: {
570
+ items: [
571
+ {
572
+ op: {
573
+ type: {
574
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
575
+ },
576
+ value: 'replace',
577
+ },
578
+ path: {
579
+ type: {
580
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
581
+ },
582
+ value: '/transactionIdentificationStatus',
583
+ },
584
+ val: {
585
+ type: {
586
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
587
+ },
588
+ value: "${steps['Classify Identification Result'].identificationStatus}",
589
+ },
590
+ },
591
+ {
592
+ op: {
593
+ type: {
594
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
595
+ },
596
+ value: 'replace',
597
+ },
598
+ path: {
599
+ type: {
600
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
601
+ },
602
+ value: '/deliveryStatus',
603
+ },
604
+ val: {
605
+ type: {
606
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
607
+ },
608
+ value: "${steps['Classify Identification Result'].deliveryStatus}",
609
+ },
610
+ },
611
+ {
612
+ op: {
613
+ type: {
614
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
615
+ },
616
+ value: 'replace',
617
+ },
618
+ path: {
619
+ type: {
620
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
621
+ },
622
+ value: '/deliveryError',
623
+ },
624
+ val: {
625
+ type: {
626
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
627
+ },
628
+ value: "${steps['Classify Identification Result'].deliveryError}",
629
+ },
630
+ },
631
+ ],
632
+ },
633
+ name: 'Apply Identification Update',
634
+ type: {
635
+ blueId: 'BnnNLCnKF49TUJ1bRfZ5rSMaFw8SVfUNfnE4kJFG7HtM',
636
+ },
637
+ },
638
+ ],
639
+ },
640
+ type: {
641
+ blueId: 'CGdxkNjPcsdescqLPz6SNLsMyak6demQQr7RoKNHbCyv',
642
+ },
643
+ },
644
+ },
645
+ deliveryError: {
646
+ description: 'Error message when delivery fails.',
647
+ type: {
648
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
649
+ },
650
+ },
651
+ deliveryStatus: {
652
+ description: 'High-level delivery status.',
653
+ type: {
654
+ blueId: '58B8orsFkxxy7bWqjLXJmtBs2b5rwnNQNbeoAbGhPkJc',
655
+ },
656
+ },
657
+ description: 'Tracks delivery of a PayNote through a deliverer (e.g., bank) to a receiver (payer).',
658
+ name: 'PayNote Delivery',
659
+ payNote: {
660
+ description: 'PayNote being delivered.',
661
+ type: {
662
+ blueId: 'CDMVLRyodD2WhScu2PPRgGquEArMNGXxvZCYiJXg2YjT',
663
+ },
664
+ },
665
+ transactionIdentificationStatus: {
666
+ description: 'Identification state (pending, identified, failed).',
667
+ type: {
668
+ blueId: 'DLRQwz7MQeCrzjy9bohPNwtCxKEBbKaMK65KBrwjfG6K',
669
+ },
670
+ },
671
+ };
672
+ //# sourceMappingURL=PayNoteDelivery.js.map