@d19n/youfibre-odin-sdk 2.0.366 → 2.0.367

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 (76) hide show
  1. package/README.md +6 -26
  2. package/dist/EntityRegistry.d.ts +0 -8
  3. package/dist/EntityRegistry.js +0 -8
  4. package/dist/OdinApiClient.d.ts +0 -16
  5. package/dist/OdinApiClient.js +0 -32
  6. package/dist/OdinDbClient.d.ts +0 -16
  7. package/dist/OdinDbClient.js +0 -32
  8. package/dist/accessors-v2/index.d.ts +0 -4
  9. package/dist/accessors-v2/index.js +2 -10
  10. package/dist/actions-v2/CancelOrderForEtfPaidDto.d.ts +67 -0
  11. package/dist/actions-v2/CancelOrderForEtfPaidDto.js +59 -0
  12. package/dist/actions-v2/CreateOutboundDialCampaignDto.d.ts +8 -1
  13. package/dist/actions-v2/CreateOutboundDialSessionDto.d.ts +15 -1
  14. package/dist/actions-v2/UpdateOutboundDialSessionDto.d.ts +15 -1
  15. package/dist/actions-v2/UpdateoutbounddialcampaignDto.d.ts +8 -1
  16. package/dist/api-sdk-v2/QaReportAmendmentApi.d.ts +48 -0
  17. package/dist/api-sdk-v2/QaReportAmendmentApi.js +155 -0
  18. package/dist/api-sdk-v2/QaReportApi.d.ts +2 -0
  19. package/dist/api-sdk-v2/QaReportApi.js +6 -0
  20. package/dist/db-accessors-v2/index.d.ts +0 -4
  21. package/dist/db-accessors-v2/index.js +2 -10
  22. package/dist/db-sdk-v2/CrmDatasetDb.d.ts +2 -2
  23. package/dist/db-sdk-v2/CrmDatasetDb.js +4 -4
  24. package/dist/db-sdk-v2/QaReportAmendmentDb.d.ts +120 -0
  25. package/dist/db-sdk-v2/QaReportAmendmentDb.js +204 -0
  26. package/dist/db-sdk-v2/QaReportDb.d.ts +2 -0
  27. package/dist/db-sdk-v2/QaReportDb.js +6 -0
  28. package/dist/entities-v2/HomeMove.d.ts +23 -1
  29. package/dist/entities-v2/HomeMove.js +17 -1
  30. package/dist/entities-v2/OrderItem.d.ts +2 -0
  31. package/dist/entities-v2/OrderItem.js +2 -0
  32. package/dist/entities-v2/OutboundDialCampaign.d.ts +9 -1
  33. package/dist/entities-v2/OutboundDialCampaign.js +2 -0
  34. package/dist/entities-v2/OutboundDialSession.d.ts +17 -1
  35. package/dist/entities-v2/OutboundDialSession.js +4 -0
  36. package/dist/entities-v2/QaReport.d.ts +70 -1
  37. package/dist/entities-v2/QaReport.js +31 -1
  38. package/dist/entities-v2/QaReportAmendment.d.ts +209 -0
  39. package/dist/entities-v2/QaReportAmendment.js +120 -0
  40. package/dist/records-v2/OrderRecord.d.ts +25 -0
  41. package/dist/records-v2/OrderRecord.js +29 -0
  42. package/dist/records-v2/index.d.ts +0 -4
  43. package/dist/records-v2/index.js +2 -14
  44. package/package.json +1 -1
  45. package/dist/accessors-v2/QaAutoFailAccessor.d.ts +0 -112
  46. package/dist/accessors-v2/QaAutoFailAccessor.js +0 -191
  47. package/dist/accessors-v2/QaRubricAccessor.d.ts +0 -112
  48. package/dist/accessors-v2/QaRubricAccessor.js +0 -191
  49. package/dist/accessors-v2/QaRubricItemAccessor.d.ts +0 -112
  50. package/dist/accessors-v2/QaRubricItemAccessor.js +0 -191
  51. package/dist/accessors-v2/QaRubricSectionAccessor.d.ts +0 -112
  52. package/dist/accessors-v2/QaRubricSectionAccessor.js +0 -191
  53. package/dist/actions-v2/UpdateQaAutoFailDto.d.ts +0 -102
  54. package/dist/actions-v2/UpdateQaAutoFailDto.js +0 -56
  55. package/dist/actions-v2/UpdateQaRubricDto.d.ts +0 -103
  56. package/dist/actions-v2/UpdateQaRubricDto.js +0 -56
  57. package/dist/actions-v2/UpdateQaRubricItemDto.d.ts +0 -157
  58. package/dist/actions-v2/UpdateQaRubricItemDto.js +0 -56
  59. package/dist/actions-v2/UpdateQaRubricSectionDto.d.ts +0 -87
  60. package/dist/actions-v2/UpdateQaRubricSectionDto.js +0 -56
  61. package/dist/db-accessors-v2/QaAutoFailDbAccessor.d.ts +0 -180
  62. package/dist/db-accessors-v2/QaAutoFailDbAccessor.js +0 -265
  63. package/dist/db-accessors-v2/QaRubricDbAccessor.d.ts +0 -180
  64. package/dist/db-accessors-v2/QaRubricDbAccessor.js +0 -265
  65. package/dist/db-accessors-v2/QaRubricItemDbAccessor.d.ts +0 -180
  66. package/dist/db-accessors-v2/QaRubricItemDbAccessor.js +0 -265
  67. package/dist/db-accessors-v2/QaRubricSectionDbAccessor.d.ts +0 -180
  68. package/dist/db-accessors-v2/QaRubricSectionDbAccessor.js +0 -265
  69. package/dist/records-v2/QaAutoFailRecord.d.ts +0 -205
  70. package/dist/records-v2/QaAutoFailRecord.js +0 -275
  71. package/dist/records-v2/QaRubricItemRecord.d.ts +0 -205
  72. package/dist/records-v2/QaRubricItemRecord.js +0 -275
  73. package/dist/records-v2/QaRubricRecord.d.ts +0 -225
  74. package/dist/records-v2/QaRubricRecord.js +0 -308
  75. package/dist/records-v2/QaRubricSectionRecord.d.ts +0 -225
  76. package/dist/records-v2/QaRubricSectionRecord.js +0 -308
@@ -117,6 +117,19 @@ export declare enum HomeMoveServiceableVia {
117
117
  NONE = "NONE",
118
118
  OPENREACH = "OPENREACH"
119
119
  }
120
+ /**
121
+ * Valid values for HomeMove.NewOrderInstallTimeBlock
122
+ *
123
+ * AM or PM engineer slot for a New Provide move, chosen with NewOrderInstallOrActivationDate from the install calendar. Empty on a Start Order.
124
+ *
125
+ * @remarks Available options:
126
+ * - `AM`
127
+ * - `PM`
128
+ */
129
+ export declare enum HomeMoveNewOrderInstallTimeBlock {
130
+ AM = "AM",
131
+ PM = "PM"
132
+ }
120
133
  /**
121
134
  * Property keys for HomeMove
122
135
  * Use these constants instead of string literals for type safety
@@ -153,7 +166,9 @@ export declare enum HomeMovePropertyKeys {
153
166
  /** True when proof of move arrived in time (ETF Waived). Empty until decided. */
154
167
  EtfWaived = "ETFWaived",
155
168
  /** Which network can serve the new address. Set by the serviceability check at Created. Netomnia and Brsk are one company, so both move now; OPENREACH is a later phase. */
156
- ServiceableVia = "ServiceableVia"
169
+ ServiceableVia = "ServiceableVia",
170
+ /** AM or PM engineer slot for a New Provide move, chosen with NewOrderInstallOrActivationDate from the install calendar. Empty on a Start Order. */
171
+ NewOrderInstallTimeBlock = "NewOrderInstallTimeBlock"
157
172
  }
158
173
  /**
159
174
  * Properties for HomeMove records
@@ -260,6 +275,13 @@ export interface HomeMoveProperties {
260
275
  * @enum {HomeMoveServiceableVia}
261
276
  */
262
277
  ServiceableVia: HomeMoveServiceableVia;
278
+ /** AM or PM engineer slot for a New Provide move, chosen with NewOrderInstallOrActivationDate from the install calendar. Empty on a Start Order.
279
+ *
280
+ * @type {ENUM}
281
+ * @default
282
+ * @enum {HomeMoveNewOrderInstallTimeBlock}
283
+ */
284
+ NewOrderInstallTimeBlock: HomeMoveNewOrderInstallTimeBlock;
263
285
  }
264
286
  /**
265
287
  * HomeMove entity from OrderModule
@@ -12,7 +12,7 @@
12
12
  * Generated from Odin schema definition
13
13
  */
14
14
  Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.ROUTING_KEY_LINK_HOME_MOVE_NOTE_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_NOTE_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_WORK_ORDER_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_WORK_ORDER_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_CASE_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_CASE_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_NEW_ADDRESS_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_NEW_ADDRESS_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_OLD_ORDER_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_OLD_ORDER_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_FILE_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_FILE_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_CONTACT_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_CONTACT_CREATED = exports.ROUTING_KEY_HOME_MOVE_DEFAULT_DELETED = exports.ROUTING_KEY_HOME_MOVE_DEFAULT_UPDATED = exports.ROUTING_KEY_HOME_MOVE_DEFAULT_CREATED = exports.ROUTING_KEY_HOME_MOVE_DELETED = exports.ROUTING_KEY_HOME_MOVE_UPDATED = exports.ROUTING_KEY_HOME_MOVE_CREATED = exports.HomeMove = exports.HomeMovePropertyKeys = exports.HomeMoveServiceableVia = exports.HomeMoveCollectionKitAddress = exports.HomeMoveRouterDeliveryAddress = exports.DefaultHomeMoveStageKeys = exports.DefaultHomeMoveStageNames = exports.HomeMoveEntityTypes = void 0;
15
+ exports.ROUTING_KEY_LINK_HOME_MOVE_NOTE_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_NOTE_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_WORK_ORDER_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_WORK_ORDER_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_CASE_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_CASE_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_NEW_ADDRESS_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_NEW_ADDRESS_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_OLD_ORDER_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_OLD_ORDER_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_FILE_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_FILE_CREATED = exports.ROUTING_KEY_LINK_HOME_MOVE_CONTACT_DELETED = exports.ROUTING_KEY_LINK_HOME_MOVE_CONTACT_CREATED = exports.ROUTING_KEY_HOME_MOVE_DEFAULT_DELETED = exports.ROUTING_KEY_HOME_MOVE_DEFAULT_UPDATED = exports.ROUTING_KEY_HOME_MOVE_DEFAULT_CREATED = exports.ROUTING_KEY_HOME_MOVE_DELETED = exports.ROUTING_KEY_HOME_MOVE_UPDATED = exports.ROUTING_KEY_HOME_MOVE_CREATED = exports.HomeMove = exports.HomeMovePropertyKeys = exports.HomeMoveNewOrderInstallTimeBlock = exports.HomeMoveServiceableVia = exports.HomeMoveCollectionKitAddress = exports.HomeMoveRouterDeliveryAddress = exports.DefaultHomeMoveStageKeys = exports.DefaultHomeMoveStageNames = exports.HomeMoveEntityTypes = void 0;
16
16
  const core_1 = require("@d19n/odin-types/dist/core");
17
17
  /**
18
18
  * Available types for HomeMove records
@@ -119,6 +119,20 @@ var HomeMoveServiceableVia;
119
119
  HomeMoveServiceableVia["NONE"] = "NONE";
120
120
  HomeMoveServiceableVia["OPENREACH"] = "OPENREACH";
121
121
  })(HomeMoveServiceableVia = exports.HomeMoveServiceableVia || (exports.HomeMoveServiceableVia = {}));
122
+ /**
123
+ * Valid values for HomeMove.NewOrderInstallTimeBlock
124
+ *
125
+ * AM or PM engineer slot for a New Provide move, chosen with NewOrderInstallOrActivationDate from the install calendar. Empty on a Start Order.
126
+ *
127
+ * @remarks Available options:
128
+ * - `AM`
129
+ * - `PM`
130
+ */
131
+ var HomeMoveNewOrderInstallTimeBlock;
132
+ (function (HomeMoveNewOrderInstallTimeBlock) {
133
+ HomeMoveNewOrderInstallTimeBlock["AM"] = "AM";
134
+ HomeMoveNewOrderInstallTimeBlock["PM"] = "PM";
135
+ })(HomeMoveNewOrderInstallTimeBlock = exports.HomeMoveNewOrderInstallTimeBlock || (exports.HomeMoveNewOrderInstallTimeBlock = {}));
122
136
  /**
123
137
  * Property keys for HomeMove
124
138
  * Use these constants instead of string literals for type safety
@@ -157,6 +171,8 @@ var HomeMovePropertyKeys;
157
171
  HomeMovePropertyKeys["EtfWaived"] = "ETFWaived";
158
172
  /** Which network can serve the new address. Set by the serviceability check at Created. Netomnia and Brsk are one company, so both move now; OPENREACH is a later phase. */
159
173
  HomeMovePropertyKeys["ServiceableVia"] = "ServiceableVia";
174
+ /** AM or PM engineer slot for a New Provide move, chosen with NewOrderInstallOrActivationDate from the install calendar. Empty on a Start Order. */
175
+ HomeMovePropertyKeys["NewOrderInstallTimeBlock"] = "NewOrderInstallTimeBlock";
160
176
  })(HomeMovePropertyKeys = exports.HomeMovePropertyKeys || (exports.HomeMovePropertyKeys = {}));
161
177
  /**
162
178
  * HomeMove entity from OrderModule
@@ -45,6 +45,7 @@ export declare enum OrderItemEntityTypes {
45
45
  * - `BT`
46
46
  * - `EE`
47
47
  * - `GRAIN` - Grain
48
+ * - `HOME_MOVE` - Home Move
48
49
  * - `LIGHTSPEED` - LightSpeed
49
50
  * - `OTHER` - Other
50
51
  * - `POP_TELECOM` - POP Telecom
@@ -60,6 +61,7 @@ export declare enum OrderItemPriceMatchedTo {
60
61
  BT = "BT",
61
62
  EE = "EE",
62
63
  GRAIN = "GRAIN",
64
+ HOME_MOVE = "HOME_MOVE",
63
65
  LIGHT_SPEED = "LIGHTSPEED",
64
66
  OTHER = "OTHER",
65
67
  POP_TELECOM = "POP_TELECOM",
@@ -32,6 +32,7 @@ var OrderItemEntityTypes;
32
32
  * - `BT`
33
33
  * - `EE`
34
34
  * - `GRAIN` - Grain
35
+ * - `HOME_MOVE` - Home Move
35
36
  * - `LIGHTSPEED` - LightSpeed
36
37
  * - `OTHER` - Other
37
38
  * - `POP_TELECOM` - POP Telecom
@@ -48,6 +49,7 @@ var OrderItemPriceMatchedTo;
48
49
  OrderItemPriceMatchedTo["BT"] = "BT";
49
50
  OrderItemPriceMatchedTo["EE"] = "EE";
50
51
  OrderItemPriceMatchedTo["GRAIN"] = "GRAIN";
52
+ OrderItemPriceMatchedTo["HOME_MOVE"] = "HOME_MOVE";
51
53
  OrderItemPriceMatchedTo["LIGHT_SPEED"] = "LIGHTSPEED";
52
54
  OrderItemPriceMatchedTo["OTHER"] = "OTHER";
53
55
  OrderItemPriceMatchedTo["POP_TELECOM"] = "POP_TELECOM";
@@ -54,7 +54,9 @@ export declare enum OutboundDialCampaignPropertyKeys {
54
54
  /** Inactive campaigns hidden from agents */
55
55
  IsActive = "IsActive",
56
56
  /** Override Twilio CLI Outbound number in case needed for different campaigns */
57
- CallerId = "CallerId"
57
+ CallerId = "CallerId",
58
+ /** How cases reach agents: SELF_SELECT (agents pick from the queue) or ROUND_ROBIN (the dialler hands new cases to agents in turn, CASES-1984). Empty means SELF_SELECT. */
59
+ DistributionMode = "DistributionMode"
58
60
  }
59
61
  /**
60
62
  * Properties for OutboundDialCampaign records
@@ -102,6 +104,12 @@ export interface OutboundDialCampaignProperties {
102
104
  * @type {PHONE_NUMBER}
103
105
  */
104
106
  CallerId: string;
107
+ /** How cases reach agents: SELF_SELECT (agents pick from the queue) or ROUND_ROBIN (the dialler hands new cases to agents in turn, CASES-1984). Empty means SELF_SELECT.
108
+ *
109
+ * @type {TEXT}
110
+ * @default
111
+ */
112
+ DistributionMode: string;
105
113
  }
106
114
  /**
107
115
  * OutboundDialCampaign entity from SupportModule
@@ -56,6 +56,8 @@ var OutboundDialCampaignPropertyKeys;
56
56
  OutboundDialCampaignPropertyKeys["IsActive"] = "IsActive";
57
57
  /** Override Twilio CLI Outbound number in case needed for different campaigns */
58
58
  OutboundDialCampaignPropertyKeys["CallerId"] = "CallerId";
59
+ /** How cases reach agents: SELF_SELECT (agents pick from the queue) or ROUND_ROBIN (the dialler hands new cases to agents in turn, CASES-1984). Empty means SELF_SELECT. */
60
+ OutboundDialCampaignPropertyKeys["DistributionMode"] = "DistributionMode";
59
61
  })(OutboundDialCampaignPropertyKeys = exports.OutboundDialCampaignPropertyKeys || (exports.OutboundDialCampaignPropertyKeys = {}));
60
62
  /**
61
63
  * OutboundDialCampaign entity from SupportModule
@@ -86,7 +86,11 @@ export declare enum OutboundDialSessionPropertyKeys {
86
86
  /** Dial attempts in this session that ended BUSY. Previously folded into NoAnswerCount (CASES-1830). Sibling of AttemptsCount / ConnectedCount / MachineCount / NoAnswerCount; zeroed at session creation like them. */
87
87
  BusyCount = "BusyCount",
88
88
  /** Dial attempts in this session that ended FAILED (carrier failure / cancelled). Previously folded into NoAnswerCount (CASES-1830). Sibling of AttemptsCount / ConnectedCount / MachineCount / NoAnswerCount; zeroed at session creation like them. */
89
- FailedCount = "FailedCount"
89
+ FailedCount = "FailedCount",
90
+ /** New (previously unassigned) cases the dialler has handed this session on a ROUND_ROBIN campaign. The turn rule gives the next new case to the session with the fewest (CASES-1984). */
91
+ CasesAssigned = "CasesAssigned",
92
+ /** When the agent last asked for their next case. A session that has not asked for 5 minutes is left out of the round-robin turn rule until it asks again (CASES-1984). */
93
+ LastCaseRequestAt = "LastCaseRequestAt"
90
94
  }
91
95
  /**
92
96
  * Properties for OutboundDialSession records
@@ -168,6 +172,18 @@ export interface OutboundDialSessionProperties {
168
172
  * @default
169
173
  */
170
174
  FailedCount: number;
175
+ /** New (previously unassigned) cases the dialler has handed this session on a ROUND_ROBIN campaign. The turn rule gives the next new case to the session with the fewest (CASES-1984).
176
+ *
177
+ * @type {NUMBER}
178
+ * @default 0
179
+ */
180
+ CasesAssigned: number;
181
+ /** When the agent last asked for their next case. A session that has not asked for 5 minutes is left out of the round-robin turn rule until it asks again (CASES-1984).
182
+ *
183
+ * @type {DATE_TIME}
184
+ * @default
185
+ */
186
+ LastCaseRequestAt: string;
171
187
  }
172
188
  /**
173
189
  * OutboundDialSession entity from SupportModule
@@ -90,6 +90,10 @@ var OutboundDialSessionPropertyKeys;
90
90
  OutboundDialSessionPropertyKeys["BusyCount"] = "BusyCount";
91
91
  /** Dial attempts in this session that ended FAILED (carrier failure / cancelled). Previously folded into NoAnswerCount (CASES-1830). Sibling of AttemptsCount / ConnectedCount / MachineCount / NoAnswerCount; zeroed at session creation like them. */
92
92
  OutboundDialSessionPropertyKeys["FailedCount"] = "FailedCount";
93
+ /** New (previously unassigned) cases the dialler has handed this session on a ROUND_ROBIN campaign. The turn rule gives the next new case to the session with the fewest (CASES-1984). */
94
+ OutboundDialSessionPropertyKeys["CasesAssigned"] = "CasesAssigned";
95
+ /** When the agent last asked for their next case. A session that has not asked for 5 minutes is left out of the round-robin turn rule until it asks again (CASES-1984). */
96
+ OutboundDialSessionPropertyKeys["LastCaseRequestAt"] = "LastCaseRequestAt";
93
97
  })(OutboundDialSessionPropertyKeys = exports.OutboundDialSessionPropertyKeys || (exports.OutboundDialSessionPropertyKeys = {}));
94
98
  /**
95
99
  * OutboundDialSession entity from SupportModule
@@ -12,6 +12,7 @@
12
12
  */
13
13
  import { OdinRecord, OdinLink, LinkedOdinRecord } from '@d19n/odin-types/dist/core';
14
14
  import { CaseProperties } from './Case';
15
+ import { QaReportAmendmentProperties } from './QaReportAmendment';
15
16
  /**
16
17
  * Available types for QaReport records
17
18
  */
@@ -85,6 +86,19 @@ export declare enum QaReportStatus {
85
86
  FAILED = "FAILED",
86
87
  PENDING = "PENDING"
87
88
  }
89
+ /**
90
+ * Valid values for QaReport.AmendedResult
91
+ *
92
+ * PASS or FAIL after the amendment, from the benchmark and the auto-fails as amended.
93
+ *
94
+ * @remarks Available options:
95
+ * - `FAIL` - Fail
96
+ * - `PASS` - Pass
97
+ */
98
+ export declare enum QaReportAmendedResult {
99
+ FAIL = "FAIL",
100
+ PASS = "PASS"
101
+ }
88
102
  /**
89
103
  * Property keys for QaReport
90
104
  * Use these constants instead of string literals for type safety
@@ -135,7 +149,19 @@ export declare enum QaReportPropertyKeys {
135
149
  /** Display name of the person who pressed Generate. */
136
150
  RequestedBy = "RequestedBy",
137
151
  /** When Generate was pressed. The report is written against this row when the worker finishes. */
138
- RequestedAt = "RequestedAt"
152
+ RequestedAt = "RequestedAt",
153
+ /** The score after a manager corrected the model, recomputed by the same rule. Empty when the report has not been amended. */
154
+ AmendedScore = "AmendedScore",
155
+ /** PASS or FAIL after the amendment, from the benchmark and the auto-fails as amended. */
156
+ AmendedResult = "AmendedResult",
157
+ /** When the live amendment was made. */
158
+ AmendedAt = "AmendedAt",
159
+ /** Display name of the manager who made the live amendment. */
160
+ AmendedBy = "AmendedBy",
161
+ /** S3 URL of the amended result JSON: the same shape as QaResultUrl, with the amendment applied and recorded inside it. */
162
+ AmendedResultUrl = "AmendedResultUrl",
163
+ /** Optional note from the manager about the amendment as a whole. */
164
+ AmendmentNote = "AmendmentNote"
139
165
  }
140
166
  /**
141
167
  * Properties for QaReport records
@@ -286,6 +312,43 @@ export interface QaReportProperties {
286
312
  * @default
287
313
  */
288
314
  RequestedAt: string;
315
+ /** The score after a manager corrected the model, recomputed by the same rule. Empty when the report has not been amended.
316
+ *
317
+ * @type {NUMBER}
318
+ * @default
319
+ */
320
+ AmendedScore: number;
321
+ /** PASS or FAIL after the amendment, from the benchmark and the auto-fails as amended.
322
+ *
323
+ * @type {ENUM}
324
+ * @default
325
+ * @enum {QaReportAmendedResult}
326
+ */
327
+ AmendedResult: QaReportAmendedResult;
328
+ /** When the live amendment was made.
329
+ *
330
+ * @type {DATE_TIME}
331
+ * @default
332
+ */
333
+ AmendedAt: string;
334
+ /** Display name of the manager who made the live amendment.
335
+ *
336
+ * @type {TEXT}
337
+ * @default
338
+ */
339
+ AmendedBy: string;
340
+ /** S3 URL of the amended result JSON: the same shape as QaResultUrl, with the amendment applied and recorded inside it.
341
+ *
342
+ * @type {TEXT}
343
+ * @default
344
+ */
345
+ AmendedResultUrl: string;
346
+ /** Optional note from the manager about the amendment as a whole.
347
+ *
348
+ * @type {TEXT}
349
+ * @default
350
+ */
351
+ AmendmentNote: string;
289
352
  }
290
353
  /**
291
354
  * QaReport entity from SupportModule
@@ -305,6 +368,8 @@ export declare class QaReport extends OdinRecord<QaReportProperties> {
305
368
  properties: QaReportProperties;
306
369
  /** Linked Case records (Case__QaReport) */
307
370
  Case: OdinLink<LinkedOdinRecord<CaseProperties>>;
371
+ /** Linked QaReportAmendment records (QaReport__Amendment) */
372
+ QaReportAmendment: OdinLink<LinkedOdinRecord<QaReportAmendmentProperties>>;
308
373
  }
309
374
  /**
310
375
  * RabbitMQ routing keys for QaReport events
@@ -322,3 +387,7 @@ export declare const ROUTING_KEY_QA_REPORT_DEFAULT_CREATED = "SupportModule.QaRe
322
387
  export declare const ROUTING_KEY_QA_REPORT_DEFAULT_UPDATED = "SupportModule.QaReport.DEFAULT.SubDbRecordUpdated";
323
388
  /** This is the default record type deleted */
324
389
  export declare const ROUTING_KEY_QA_REPORT_DEFAULT_DELETED = "SupportModule.QaReport.DEFAULT.SubDbRecordDeleted";
390
+ /** Event: QaReport__Amendment link created */
391
+ export declare const ROUTING_KEY_LINK_QA_REPORT_AMENDMENT_CREATED = "SupportModule.QaReport.QaReportAmendment.SubDbRecordAssociationCreated";
392
+ /** Event: QaReport__Amendment link deleted */
393
+ export declare const ROUTING_KEY_LINK_QA_REPORT_AMENDMENT_DELETED = "SupportModule.QaReport.QaReportAmendment.SubDbRecordAssociationDeleted";
@@ -12,7 +12,7 @@
12
12
  * Generated from Odin schema definition
13
13
  */
14
14
  Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.ROUTING_KEY_QA_REPORT_DEFAULT_DELETED = exports.ROUTING_KEY_QA_REPORT_DEFAULT_UPDATED = exports.ROUTING_KEY_QA_REPORT_DEFAULT_CREATED = exports.ROUTING_KEY_QA_REPORT_DELETED = exports.ROUTING_KEY_QA_REPORT_UPDATED = exports.ROUTING_KEY_QA_REPORT_CREATED = exports.QaReport = exports.QaReportPropertyKeys = exports.QaReportStatus = exports.QaReportFeedbackReason = exports.QaReportFeedbackAccuracy = exports.QaReportChannel = exports.QaReportEntityTypes = void 0;
15
+ exports.ROUTING_KEY_LINK_QA_REPORT_AMENDMENT_DELETED = exports.ROUTING_KEY_LINK_QA_REPORT_AMENDMENT_CREATED = exports.ROUTING_KEY_QA_REPORT_DEFAULT_DELETED = exports.ROUTING_KEY_QA_REPORT_DEFAULT_UPDATED = exports.ROUTING_KEY_QA_REPORT_DEFAULT_CREATED = exports.ROUTING_KEY_QA_REPORT_DELETED = exports.ROUTING_KEY_QA_REPORT_UPDATED = exports.ROUTING_KEY_QA_REPORT_CREATED = exports.QaReport = exports.QaReportPropertyKeys = exports.QaReportAmendedResult = exports.QaReportStatus = exports.QaReportFeedbackReason = exports.QaReportFeedbackAccuracy = exports.QaReportChannel = exports.QaReportEntityTypes = void 0;
16
16
  const core_1 = require("@d19n/odin-types/dist/core");
17
17
  /**
18
18
  * Available types for QaReport records
@@ -92,6 +92,20 @@ var QaReportStatus;
92
92
  QaReportStatus["FAILED"] = "FAILED";
93
93
  QaReportStatus["PENDING"] = "PENDING";
94
94
  })(QaReportStatus = exports.QaReportStatus || (exports.QaReportStatus = {}));
95
+ /**
96
+ * Valid values for QaReport.AmendedResult
97
+ *
98
+ * PASS or FAIL after the amendment, from the benchmark and the auto-fails as amended.
99
+ *
100
+ * @remarks Available options:
101
+ * - `FAIL` - Fail
102
+ * - `PASS` - Pass
103
+ */
104
+ var QaReportAmendedResult;
105
+ (function (QaReportAmendedResult) {
106
+ QaReportAmendedResult["FAIL"] = "FAIL";
107
+ QaReportAmendedResult["PASS"] = "PASS";
108
+ })(QaReportAmendedResult = exports.QaReportAmendedResult || (exports.QaReportAmendedResult = {}));
95
109
  /**
96
110
  * Property keys for QaReport
97
111
  * Use these constants instead of string literals for type safety
@@ -144,6 +158,18 @@ var QaReportPropertyKeys;
144
158
  QaReportPropertyKeys["RequestedBy"] = "RequestedBy";
145
159
  /** When Generate was pressed. The report is written against this row when the worker finishes. */
146
160
  QaReportPropertyKeys["RequestedAt"] = "RequestedAt";
161
+ /** The score after a manager corrected the model, recomputed by the same rule. Empty when the report has not been amended. */
162
+ QaReportPropertyKeys["AmendedScore"] = "AmendedScore";
163
+ /** PASS or FAIL after the amendment, from the benchmark and the auto-fails as amended. */
164
+ QaReportPropertyKeys["AmendedResult"] = "AmendedResult";
165
+ /** When the live amendment was made. */
166
+ QaReportPropertyKeys["AmendedAt"] = "AmendedAt";
167
+ /** Display name of the manager who made the live amendment. */
168
+ QaReportPropertyKeys["AmendedBy"] = "AmendedBy";
169
+ /** S3 URL of the amended result JSON: the same shape as QaResultUrl, with the amendment applied and recorded inside it. */
170
+ QaReportPropertyKeys["AmendedResultUrl"] = "AmendedResultUrl";
171
+ /** Optional note from the manager about the amendment as a whole. */
172
+ QaReportPropertyKeys["AmendmentNote"] = "AmendmentNote";
147
173
  })(QaReportPropertyKeys = exports.QaReportPropertyKeys || (exports.QaReportPropertyKeys = {}));
148
174
  /**
149
175
  * QaReport entity from SupportModule
@@ -178,3 +204,7 @@ exports.ROUTING_KEY_QA_REPORT_DEFAULT_CREATED = 'SupportModule.QaReport.DEFAULT.
178
204
  exports.ROUTING_KEY_QA_REPORT_DEFAULT_UPDATED = 'SupportModule.QaReport.DEFAULT.SubDbRecordUpdated';
179
205
  /** This is the default record type deleted */
180
206
  exports.ROUTING_KEY_QA_REPORT_DEFAULT_DELETED = 'SupportModule.QaReport.DEFAULT.SubDbRecordDeleted';
207
+ /** Event: QaReport__Amendment link created */
208
+ exports.ROUTING_KEY_LINK_QA_REPORT_AMENDMENT_CREATED = 'SupportModule.QaReport.QaReportAmendment.SubDbRecordAssociationCreated';
209
+ /** Event: QaReport__Amendment link deleted */
210
+ exports.ROUTING_KEY_LINK_QA_REPORT_AMENDMENT_DELETED = 'SupportModule.QaReport.QaReportAmendment.SubDbRecordAssociationDeleted';
@@ -0,0 +1,209 @@
1
+ /**
2
+ * QaReportAmendment Entity Definition
3
+ *
4
+ * One change a manager made to a QA report: an item verdict or an auto-fail ruling, with the model's original beside it, the recomputed points, the reason, who and when. Written only by the amend route in youfibre-api-support; never edited by hand.
5
+ *
6
+ * @module SupportModule
7
+ * @entity QaReportAmendment
8
+ * @schemaId 295e0792-d5cb-44ba-8cbc-f78105341ab5
9
+ *
10
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
11
+ * Generated from Odin schema definition
12
+ */
13
+ import { OdinRecord, OdinLink, LinkedOdinRecord } from '@d19n/odin-types/dist/core';
14
+ import { QaReportProperties } from './QaReport';
15
+ /**
16
+ * Available types for QaReportAmendment records
17
+ */
18
+ export declare enum QaReportAmendmentEntityTypes {
19
+ /** This is the default record type */
20
+ DEFAULT = "DEFAULT"
21
+ }
22
+ /**
23
+ * Valid values for QaReportAmendment.Kind
24
+ *
25
+ * ITEM for a scored rubric item, AUTO_FAIL for an auto-fail ruling.
26
+ *
27
+ * @remarks Available options:
28
+ * - `AUTO_FAIL` - Auto-fail
29
+ * - `ITEM` - Item
30
+ */
31
+ export declare enum QaReportAmendmentKind {
32
+ AUTO_FAIL = "AUTO_FAIL",
33
+ ITEM = "ITEM"
34
+ }
35
+ /**
36
+ * Valid values for QaReportAmendment.Superseded
37
+ *
38
+ * NO while this change is the live one; YES once a later amendment or a restore replaced it. Rows are never deleted.
39
+ *
40
+ * @remarks Available options:
41
+ * - `NO` - No
42
+ * - `YES` - Yes
43
+ */
44
+ export declare enum QaReportAmendmentSuperseded {
45
+ NO = "NO",
46
+ YES = "YES"
47
+ }
48
+ /**
49
+ * Property keys for QaReportAmendment
50
+ * Use these constants instead of string literals for type safety
51
+ */
52
+ export declare enum QaReportAmendmentPropertyKeys {
53
+ /** The QA report this change belongs to. */
54
+ ReportId = "ReportId",
55
+ /** ITEM for a scored rubric item, AUTO_FAIL for an auto-fail ruling. */
56
+ Kind = "Kind",
57
+ /** The rubric item key (e.g. chat.standard_greeting) or the auto-fail code (e.g. AF4). */
58
+ ItemKey = "ItemKey",
59
+ /** The item number in the report. Empty for an auto-fail. */
60
+ ItemNumber = "ItemNumber",
61
+ /** What the model said: YES, PARTIAL, NO or NA for an item; TRIGGERED or RULED_OUT for an auto-fail. */
62
+ AiVerdict = "AiVerdict",
63
+ /** The points the model awarded the item. Empty for an auto-fail. */
64
+ AiPoints = "AiPoints",
65
+ /** The verdict after the amendment, same vocabulary as the model verdict. */
66
+ Verdict = "Verdict",
67
+ /** The points after the amendment, recomputed by the scoring rule. Empty for an auto-fail. */
68
+ Points = "Points",
69
+ /** The evidence text after the amendment, when the manager changed it. Empty when the model's text was kept. */
70
+ Evidence = "Evidence",
71
+ /** The rationale text after the amendment, when the manager changed it. Empty when the model's text was kept. */
72
+ Rationale = "Rationale",
73
+ /** Why the model was wrong, in the manager's words. Required by the route. */
74
+ Reason = "Reason",
75
+ /** Display name of the manager. */
76
+ AmendedBy = "AmendedBy",
77
+ /** When the change was made. */
78
+ AmendedAt = "AmendedAt",
79
+ /** NO while this change is the live one; YES once a later amendment or a restore replaced it. Rows are never deleted. */
80
+ Superseded = "Superseded"
81
+ }
82
+ /**
83
+ * Properties for QaReportAmendment records
84
+ *
85
+ * @see SupportModule:QaReportAmendment
86
+ */
87
+ export interface QaReportAmendmentProperties {
88
+ /** The QA report this change belongs to.
89
+ *
90
+ * @type {LOOKUP}
91
+ * @default
92
+ */
93
+ ReportId: string;
94
+ /** ITEM for a scored rubric item, AUTO_FAIL for an auto-fail ruling.
95
+ *
96
+ * @type {ENUM}
97
+ * @default
98
+ * @enum {QaReportAmendmentKind}
99
+ */
100
+ Kind: QaReportAmendmentKind;
101
+ /** The rubric item key (e.g. chat.standard_greeting) or the auto-fail code (e.g. AF4).
102
+ *
103
+ * @type {TEXT}
104
+ * @default
105
+ */
106
+ ItemKey: string;
107
+ /** The item number in the report. Empty for an auto-fail.
108
+ *
109
+ * @type {NUMBER}
110
+ * @default
111
+ */
112
+ ItemNumber: number;
113
+ /** What the model said: YES, PARTIAL, NO or NA for an item; TRIGGERED or RULED_OUT for an auto-fail.
114
+ *
115
+ * @type {TEXT}
116
+ * @default
117
+ */
118
+ AiVerdict: string;
119
+ /** The points the model awarded the item. Empty for an auto-fail.
120
+ *
121
+ * @type {NUMBER}
122
+ * @default
123
+ */
124
+ AiPoints: number;
125
+ /** The verdict after the amendment, same vocabulary as the model verdict.
126
+ *
127
+ * @type {TEXT}
128
+ * @default
129
+ */
130
+ Verdict: string;
131
+ /** The points after the amendment, recomputed by the scoring rule. Empty for an auto-fail.
132
+ *
133
+ * @type {NUMBER}
134
+ * @default
135
+ */
136
+ Points: number;
137
+ /** The evidence text after the amendment, when the manager changed it. Empty when the model's text was kept.
138
+ *
139
+ * @type {TEXT_LONG}
140
+ * @default
141
+ */
142
+ Evidence: string;
143
+ /** The rationale text after the amendment, when the manager changed it. Empty when the model's text was kept.
144
+ *
145
+ * @type {TEXT_LONG}
146
+ * @default
147
+ */
148
+ Rationale: string;
149
+ /** Why the model was wrong, in the manager's words. Required by the route.
150
+ *
151
+ * @type {TEXT_LONG}
152
+ * @default
153
+ */
154
+ Reason: string;
155
+ /** Display name of the manager.
156
+ *
157
+ * @type {TEXT}
158
+ * @default
159
+ */
160
+ AmendedBy: string;
161
+ /** When the change was made.
162
+ *
163
+ * @type {DATE_TIME}
164
+ * @default
165
+ */
166
+ AmendedAt: string;
167
+ /** NO while this change is the live one; YES once a later amendment or a restore replaced it. Rows are never deleted.
168
+ *
169
+ * @type {ENUM}
170
+ * @default NO
171
+ * @enum {QaReportAmendmentSuperseded}
172
+ */
173
+ Superseded: QaReportAmendmentSuperseded;
174
+ }
175
+ /**
176
+ * QaReportAmendment entity from SupportModule
177
+ *
178
+ * One change a manager made to a QA report: an item verdict or an auto-fail ruling, with the model's original beside it, the recomputed points, the reason, who and when. Written only by the amend route in youfibre-api-support; never edited by hand.
179
+ *
180
+ * @module SupportModule
181
+ * @entity QaReportAmendment
182
+ * @schemaId 295e0792-d5cb-44ba-8cbc-f78105341ab5
183
+ * @recordPrefix QRA
184
+ * @capabilities searchable, updateable, undeletable, triggerable
185
+ */
186
+ export declare class QaReportAmendment extends OdinRecord<QaReportAmendmentProperties> {
187
+ entity: 'SupportModule:QaReportAmendment';
188
+ type: QaReportAmendmentEntityTypes;
189
+ schemaId: '295e0792-d5cb-44ba-8cbc-f78105341ab5';
190
+ properties: QaReportAmendmentProperties;
191
+ /** Linked QaReport records (QaReport__Amendment) */
192
+ QaReport: OdinLink<LinkedOdinRecord<QaReportProperties>>;
193
+ }
194
+ /**
195
+ * RabbitMQ routing keys for QaReportAmendment events
196
+ */
197
+ export declare const ROUTING_KEY_QA_REPORT_AMENDMENT_CREATED = "SupportModule.QaReportAmendment.SubDbRecordCreated";
198
+ export declare const ROUTING_KEY_QA_REPORT_AMENDMENT_UPDATED = "SupportModule.QaReportAmendment.SubDbRecordUpdated";
199
+ export declare const ROUTING_KEY_QA_REPORT_AMENDMENT_DELETED = "SupportModule.QaReportAmendment.SubDbRecordDeleted";
200
+ /**
201
+ * Type-specific routing keys for QaReportAmendment events
202
+ * Subscribe to these for events on specific entity types only
203
+ */
204
+ /** This is the default record type created */
205
+ export declare const ROUTING_KEY_QA_REPORT_AMENDMENT_DEFAULT_CREATED = "SupportModule.QaReportAmendment.DEFAULT.SubDbRecordCreated";
206
+ /** This is the default record type updated */
207
+ export declare const ROUTING_KEY_QA_REPORT_AMENDMENT_DEFAULT_UPDATED = "SupportModule.QaReportAmendment.DEFAULT.SubDbRecordUpdated";
208
+ /** This is the default record type deleted */
209
+ export declare const ROUTING_KEY_QA_REPORT_AMENDMENT_DEFAULT_DELETED = "SupportModule.QaReportAmendment.DEFAULT.SubDbRecordDeleted";