@d19n/youfibre-odin-sdk 2.0.231 → 2.0.232

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 (45) hide show
  1. package/README.md +12 -2
  2. package/dist/EntityRegistry.d.ts +2 -0
  3. package/dist/EntityRegistry.js +2 -0
  4. package/dist/OdinApiClient.d.ts +4 -0
  5. package/dist/OdinApiClient.js +8 -0
  6. package/dist/OdinDbClient.d.ts +4 -0
  7. package/dist/OdinDbClient.js +8 -0
  8. package/dist/accessors-v2/ModifyServiceRequestAccessor.d.ts +111 -0
  9. package/dist/accessors-v2/ModifyServiceRequestAccessor.js +190 -0
  10. package/dist/accessors-v2/index.d.ts +1 -0
  11. package/dist/accessors-v2/index.js +5 -3
  12. package/dist/actions-v2/CreateModifyServiceRequestDto.d.ts +56 -0
  13. package/dist/actions-v2/CreateModifyServiceRequestDto.js +52 -0
  14. package/dist/actions-v2/CreateOrderConfirmationDto.d.ts +135 -0
  15. package/dist/actions-v2/CreateOrderConfirmationDto.js +59 -0
  16. package/dist/actions-v2/CreateOutboundDialCampaignDto.d.ts +5 -0
  17. package/dist/actions-v2/CreateOutboundDialCampaignDto.js +6 -1
  18. package/dist/actions-v2/CreateoutbounddialcampaigncaseDto.d.ts +5 -0
  19. package/dist/actions-v2/CreateoutbounddialcampaigncaseDto.js +6 -1
  20. package/dist/actions-v2/DefaultCreateOutboundDialCampaignDto.d.ts +112 -0
  21. package/dist/actions-v2/DefaultCreateOutboundDialCampaignDto.js +57 -0
  22. package/dist/actions-v2/DefaultUpdateOutboundDialCampaignDto.d.ts +117 -0
  23. package/dist/actions-v2/DefaultUpdateOutboundDialCampaignDto.js +59 -0
  24. package/dist/actions-v2/UpdateCallOnOutboundCallAnsweredDto.d.ts +8 -1
  25. package/dist/api-sdk-v2/ModifyServiceRequestApi.d.ts +45 -0
  26. package/dist/api-sdk-v2/ModifyServiceRequestApi.js +151 -0
  27. package/dist/db-accessors-v2/ModifyServiceRequestDbAccessor.d.ts +149 -0
  28. package/dist/db-accessors-v2/ModifyServiceRequestDbAccessor.js +227 -0
  29. package/dist/db-accessors-v2/index.d.ts +1 -0
  30. package/dist/db-accessors-v2/index.js +5 -3
  31. package/dist/db-sdk-v2/ModifyServiceRequestDb.d.ts +117 -0
  32. package/dist/db-sdk-v2/ModifyServiceRequestDb.js +200 -0
  33. package/dist/entities-v2/ModifyServiceRequest.d.ts +123 -0
  34. package/dist/entities-v2/ModifyServiceRequest.js +108 -0
  35. package/dist/records-v2/EmailRecord.d.ts +29 -0
  36. package/dist/records-v2/EmailRecord.js +36 -0
  37. package/dist/records-v2/ModifyServiceRequestRecord.d.ts +184 -0
  38. package/dist/records-v2/ModifyServiceRequestRecord.js +243 -0
  39. package/dist/records-v2/OutboundDialCampaignCaseRecord.d.ts +2 -2
  40. package/dist/records-v2/OutboundDialCampaignCaseRecord.js +3 -3
  41. package/dist/records-v2/OutboundDialCampaignRecord.d.ts +59 -2
  42. package/dist/records-v2/OutboundDialCampaignRecord.js +76 -3
  43. package/dist/records-v2/index.d.ts +1 -0
  44. package/dist/records-v2/index.js +6 -3
  45. package/package.json +1 -1
@@ -0,0 +1,117 @@
1
+ import { DbProvider, DbProviderOptions, DbGetQueryOptions } from '@d19n/odin-sdk-generator/dist/db.provider';
2
+ import { OdinSearchV2, OdinRecordCreateDto, OdinRecordUpdateDto } from '@d19n/odin-types/dist/core';
3
+ import { ModifyServiceRequestProperties } from '../entities-v2/ModifyServiceRequest';
4
+ /**
5
+ * @deprecated Use OdinDbClient.
6
+ *
7
+ * Migration:
8
+ * - Old: new ModifyServiceRequestApi(authParams).get(id)
9
+ * - New: new odin.modifyservicerequest.get(id)
10
+ *
11
+ * The new OdinDbClient returns typed record wrappers with action methods.
12
+ *
13
+ * Supports separate query options and provider options:
14
+ * - Constructor level: new ModifyServiceRequestDb(principal, dbService, { omitPermissionsCheck: true })
15
+ * - Method level: await db.getByPrimaryKey(id, { entities: [] }, { omitPermissionsCheck: true })
16
+ */
17
+ export declare class ModifyServiceRequestDb extends DbProvider {
18
+ protected readonly principal: any;
19
+ protected readonly dbService: any;
20
+ private readonly moduleName;
21
+ private readonly entityName;
22
+ private sourceRecord;
23
+ constructor(principal: any, dbService: any, defaultOptions?: DbProviderOptions);
24
+ setRecord(sourceRecord: any): void;
25
+ /**
26
+ * Search records with manual pagination control
27
+ * @param params - Search parameters
28
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
29
+ */
30
+ searchRecords(params: Partial<OdinSearchV2>, providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-types/dist/core/interfaces/v2.db.interfaces").OdinSearchResponse<import("@d19n/odin-types/dist/core").OdinRecord<ModifyServiceRequestProperties>>>;
31
+ /**
32
+ * Search all records with automatic pagination
33
+ * @param params - Search parameters
34
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
35
+ */
36
+ searchAllRecordsAndPaginate(params: Partial<OdinSearchV2>, providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-types/dist/core/interfaces/v2.db.interfaces").OdinSearchResponse<import("@d19n/odin-types/dist/core").OdinRecord<ModifyServiceRequestProperties>>>;
37
+ /**
38
+ * Get a single record by primary key
39
+ * @param modifyServiceRequestId - Record ID
40
+ * @param queryOptions - Query options (WHAT: entities to include)
41
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
42
+ *
43
+ * @example
44
+ * // Simple get
45
+ * const record = await db.getByPrimaryKey(id);
46
+ *
47
+ * // With related entities
48
+ * const record = await db.getByPrimaryKey(id, { entities: ['InvoiceItem', 'Transaction'] });
49
+ *
50
+ * // With permissions bypass
51
+ * const record = await db.getByPrimaryKey(id, {}, { omitPermissionsCheck: true });
52
+ *
53
+ * // Both options
54
+ * const record = await db.getByPrimaryKey(id, { entities: ['Invoice'] }, { omitPermissionsCheck: true });
55
+ */
56
+ getByPrimaryKey(modifyServiceRequestId: string, queryOptions?: DbGetQueryOptions, providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-types/dist/core").OdinRecord<ModifyServiceRequestProperties>>;
57
+ /**
58
+ * Get multiple records by primary keys
59
+ * @param modifyServiceRequestIds - Array of record IDs
60
+ * @param queryOptions - Query options (WHAT: entities to include)
61
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
62
+ */
63
+ getManyByPrimaryKey(modifyServiceRequestIds: string[], queryOptions?: DbGetQueryOptions, providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-types/dist/core").OdinRecord<ModifyServiceRequestProperties>[]>;
64
+ /**
65
+ * Upsert a single record
66
+ * @param upsertDto - Record to upsert
67
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
68
+ */
69
+ upsert(upsertDto: OdinRecordCreateDto, providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-sdk-generator").IDbRecordCreateUpdateRes>;
70
+ /**
71
+ * Upsert multiple records
72
+ * @param upsertDtos - Records to upsert
73
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
74
+ */
75
+ upsertMany(upsertDtos: OdinRecordCreateDto[], providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-sdk-generator").IDbRecordCreateUpdateRes[]>;
76
+ /**
77
+ * Update a single record
78
+ * @param updateDto - Record to update
79
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
80
+ */
81
+ update(updateDto: OdinRecordUpdateDto, providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-sdk-generator").IDbRecordCreateUpdateRes>;
82
+ /**
83
+ * Update multiple records
84
+ * @param updateDtos - Records to update
85
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
86
+ */
87
+ updateMany(updateDtos: OdinRecordUpdateDto[], providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-sdk-generator").IDbRecordCreateUpdateRes[]>;
88
+ /**
89
+ * Delete one or many records
90
+ * @param modifyServiceRequestIds - Record IDs to delete
91
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
92
+ */
93
+ delete(modifyServiceRequestIds: string[], providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-sdk-generator").DbRecordDeleted[]>;
94
+ /**
95
+ * Restore one or many deleted records
96
+ * @param modifyServiceRequestIds - Record IDs to restore
97
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
98
+ */
99
+ restore(modifyServiceRequestIds: string[], providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-sdk-generator").DbRecordRestored[]>;
100
+ /**
101
+ * Apply an action to a record
102
+ * @param actionName - The action key
103
+ * @param dto - The action DTO
104
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
105
+ */
106
+ applyAction(actionName: string, dto: any, providerOptions?: DbProviderOptions): Promise<import("@d19n/odin-sdk-generator").IDbRecordCreateUpdateRes[]>;
107
+ /**
108
+ * Get version history for the current source record
109
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
110
+ */
111
+ getVersions(providerOptions?: DbProviderOptions): Promise<any>;
112
+ /**
113
+ * Get revision timeline for the current source record
114
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
115
+ */
116
+ getRevisionTimeline(providerOptions?: DbProviderOptions): Promise<any>;
117
+ }
@@ -0,0 +1,200 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.ModifyServiceRequestDb = void 0;
13
+ const db_provider_1 = require("@d19n/odin-sdk-generator/dist/db.provider");
14
+ /**
15
+ * @deprecated Use OdinDbClient.
16
+ *
17
+ * Migration:
18
+ * - Old: new ModifyServiceRequestApi(authParams).get(id)
19
+ * - New: new odin.modifyservicerequest.get(id)
20
+ *
21
+ * The new OdinDbClient returns typed record wrappers with action methods.
22
+ *
23
+ * Supports separate query options and provider options:
24
+ * - Constructor level: new ModifyServiceRequestDb(principal, dbService, { omitPermissionsCheck: true })
25
+ * - Method level: await db.getByPrimaryKey(id, { entities: [] }, { omitPermissionsCheck: true })
26
+ */
27
+ class ModifyServiceRequestDb extends db_provider_1.DbProvider {
28
+ // ============================================
29
+ // PRIVATE BACKING FIELDS (Lazy Loading)
30
+ // ============================================
31
+ constructor(principal, dbService, defaultOptions) {
32
+ super(principal, dbService, defaultOptions);
33
+ this.moduleName = 'ServiceModule';
34
+ this.entityName = 'ModifyServiceRequest';
35
+ this.principal = principal;
36
+ this.dbService = dbService;
37
+ // Link managers are lazy-loaded on first access
38
+ }
39
+ // ============================================
40
+ // LAZY-LOADED LINK MANAGERS (Public Getters)
41
+ // ============================================
42
+ // Usage remains identical: db.address.list(recordId)
43
+ // ============================================
44
+ // STANDARD METHODS
45
+ // ============================================
46
+ // Methods support separate query options and provider options for clean API
47
+ setRecord(sourceRecord) {
48
+ this.sourceRecord = sourceRecord;
49
+ }
50
+ /**
51
+ * Search records with manual pagination control
52
+ * @param params - Search parameters
53
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
54
+ */
55
+ searchRecords(params, providerOptions) {
56
+ return __awaiter(this, void 0, void 0, function* () {
57
+ return yield this._searchRecords(this.moduleName, this.entityName, params, providerOptions);
58
+ });
59
+ }
60
+ /**
61
+ * Search all records with automatic pagination
62
+ * @param params - Search parameters
63
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
64
+ */
65
+ searchAllRecordsAndPaginate(params, providerOptions) {
66
+ return __awaiter(this, void 0, void 0, function* () {
67
+ return yield this._searchAllRecordsAndPaginate(this.moduleName, this.entityName, params, 0, providerOptions);
68
+ });
69
+ }
70
+ /**
71
+ * Get a single record by primary key
72
+ * @param modifyServiceRequestId - Record ID
73
+ * @param queryOptions - Query options (WHAT: entities to include)
74
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
75
+ *
76
+ * @example
77
+ * // Simple get
78
+ * const record = await db.getByPrimaryKey(id);
79
+ *
80
+ * // With related entities
81
+ * const record = await db.getByPrimaryKey(id, { entities: ['InvoiceItem', 'Transaction'] });
82
+ *
83
+ * // With permissions bypass
84
+ * const record = await db.getByPrimaryKey(id, {}, { omitPermissionsCheck: true });
85
+ *
86
+ * // Both options
87
+ * const record = await db.getByPrimaryKey(id, { entities: ['Invoice'] }, { omitPermissionsCheck: true });
88
+ */
89
+ getByPrimaryKey(modifyServiceRequestId, queryOptions, providerOptions) {
90
+ return __awaiter(this, void 0, void 0, function* () {
91
+ const res = yield this._getByPrimaryKey(this.moduleName, this.entityName, modifyServiceRequestId, queryOptions, providerOptions);
92
+ if (res)
93
+ this.setRecord(res);
94
+ return res;
95
+ });
96
+ }
97
+ /**
98
+ * Get multiple records by primary keys
99
+ * @param modifyServiceRequestIds - Array of record IDs
100
+ * @param queryOptions - Query options (WHAT: entities to include)
101
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
102
+ */
103
+ getManyByPrimaryKey(modifyServiceRequestIds, queryOptions, providerOptions) {
104
+ return __awaiter(this, void 0, void 0, function* () {
105
+ return yield this._getManyByPrimaryKey(this.moduleName, this.entityName, modifyServiceRequestIds, queryOptions, providerOptions);
106
+ });
107
+ }
108
+ /**
109
+ * Upsert a single record
110
+ * @param upsertDto - Record to upsert
111
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
112
+ */
113
+ upsert(upsertDto, providerOptions) {
114
+ return __awaiter(this, void 0, void 0, function* () {
115
+ const res = yield this._upsert(this.moduleName, this.entityName, [upsertDto], providerOptions);
116
+ return res[0];
117
+ });
118
+ }
119
+ /**
120
+ * Upsert multiple records
121
+ * @param upsertDtos - Records to upsert
122
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
123
+ */
124
+ upsertMany(upsertDtos, providerOptions) {
125
+ return __awaiter(this, void 0, void 0, function* () {
126
+ return yield this._upsert(this.moduleName, this.entityName, upsertDtos, providerOptions);
127
+ });
128
+ }
129
+ /**
130
+ * Update a single record
131
+ * @param updateDto - Record to update
132
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
133
+ */
134
+ update(updateDto, providerOptions) {
135
+ return __awaiter(this, void 0, void 0, function* () {
136
+ const res = yield this._update(this.moduleName, this.entityName, [updateDto], providerOptions);
137
+ return res[0];
138
+ });
139
+ }
140
+ /**
141
+ * Update multiple records
142
+ * @param updateDtos - Records to update
143
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
144
+ */
145
+ updateMany(updateDtos, providerOptions) {
146
+ return __awaiter(this, void 0, void 0, function* () {
147
+ return yield this._update(this.moduleName, this.entityName, updateDtos, providerOptions);
148
+ });
149
+ }
150
+ /**
151
+ * Delete one or many records
152
+ * @param modifyServiceRequestIds - Record IDs to delete
153
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
154
+ */
155
+ delete(modifyServiceRequestIds, providerOptions) {
156
+ return __awaiter(this, void 0, void 0, function* () {
157
+ return yield this._delete(this.moduleName, this.entityName, modifyServiceRequestIds, providerOptions);
158
+ });
159
+ }
160
+ /**
161
+ * Restore one or many deleted records
162
+ * @param modifyServiceRequestIds - Record IDs to restore
163
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
164
+ */
165
+ restore(modifyServiceRequestIds, providerOptions) {
166
+ return __awaiter(this, void 0, void 0, function* () {
167
+ return yield this._restore(this.moduleName, this.entityName, modifyServiceRequestIds, providerOptions);
168
+ });
169
+ }
170
+ /**
171
+ * Apply an action to a record
172
+ * @param actionName - The action key
173
+ * @param dto - The action DTO
174
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
175
+ */
176
+ applyAction(actionName, dto, providerOptions) {
177
+ return __awaiter(this, void 0, void 0, function* () {
178
+ return yield this._applyAction(this.moduleName, this.entityName, dto, providerOptions);
179
+ });
180
+ }
181
+ /**
182
+ * Get version history for the current source record
183
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
184
+ */
185
+ getVersions(providerOptions) {
186
+ return __awaiter(this, void 0, void 0, function* () {
187
+ return yield this._getVersions(this.moduleName, this.entityName, this.sourceRecord.id, providerOptions);
188
+ });
189
+ }
190
+ /**
191
+ * Get revision timeline for the current source record
192
+ * @param providerOptions - Provider options (HOW: omitPermissionsCheck)
193
+ */
194
+ getRevisionTimeline(providerOptions) {
195
+ return __awaiter(this, void 0, void 0, function* () {
196
+ return yield this._getRevisionTimeline(this.moduleName, this.entityName, this.sourceRecord.id, providerOptions);
197
+ });
198
+ }
199
+ }
200
+ exports.ModifyServiceRequestDb = ModifyServiceRequestDb;
@@ -0,0 +1,123 @@
1
+ /**
2
+ * ModifyServiceRequest Entity Definition
3
+ *
4
+ * Current status of a service modification request to a network provider (eg. speed change)
5
+ *
6
+ * @module ServiceModule
7
+ * @entity ModifyServiceRequest
8
+ * @schemaId c33f6215-f398-4d02-a35a-ebcde2ee2669
9
+ *
10
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
11
+ * Generated from Odin schema definition
12
+ */
13
+ import { OdinRecord } from '@d19n/odin-types/dist/core';
14
+ /**
15
+ * Available types for ModifyServiceRequest records
16
+ */
17
+ export declare enum ModifyServiceRequestEntityTypes {
18
+ /** This is the default record type */
19
+ DEFAULT = "DEFAULT"
20
+ }
21
+ /**
22
+ * Pipeline stage names for DEFAULT ModifyServiceRequest
23
+ * Pipeline: ModifyServiceRequestState
24
+ * ModifyServiceRequestState
25
+ */
26
+ export declare enum DefaultModifyServiceRequestStageNames {
27
+ /** Request has not yet been submitted to supplier. (default) */
28
+ NotSent = "NotSent",
29
+ /** Request was sent successfully to supplier, pending response. */
30
+ SentToSupplier = "SentToSupplier",
31
+ /** Request failed to send to supplier. (fail) */
32
+ FailedToSend = "FailedToSend",
33
+ /** The supplier has raised an issue with completing the modification. */
34
+ Held = "Held",
35
+ /** Request was processed successfully by the supplier and they have confirmed the service change. (success) */
36
+ Completed = "Completed",
37
+ /** Request was received by supplier but failed to complete. (fail) */
38
+ Failed = "Failed"
39
+ }
40
+ /**
41
+ * Pipeline stage keys for DEFAULT ModifyServiceRequest
42
+ * Use these keys when transitioning between stages
43
+ */
44
+ export declare enum DefaultModifyServiceRequestStageKeys {
45
+ /** Request has not yet been submitted to supplier. */
46
+ ModifyServiceRequestStateStageNotSent = "ModifyServiceRequestStateStageNotSent",
47
+ /** Request was sent successfully to supplier, pending response. */
48
+ ModifyServiceRequestStateStageSentToSupplier = "ModifyServiceRequestStateStageSentToSupplier",
49
+ /** Request failed to send to supplier. */
50
+ ModifyServiceRequestStateStageFailedToSend = "ModifyServiceRequestStateStageFailedToSend",
51
+ /** The supplier has raised an issue with completing the modification. */
52
+ ModifyServiceRequestStateStageHeld = "ModifyServiceRequestStateStageHeld",
53
+ /** Request was processed successfully by the supplier and they have confirmed the service change. */
54
+ ModifyServiceRequestStateStageCompleted = "ModifyServiceRequestStateStageCompleted",
55
+ /** Request was received by supplier but failed to complete. */
56
+ ModifyServiceRequestStateStageFailed = "ModifyServiceRequestStateStageFailed"
57
+ }
58
+ /**
59
+ * Property keys for ModifyServiceRequest
60
+ * Use these constants instead of string literals for type safety
61
+ */
62
+ export declare enum ModifyServiceRequestPropertyKeys {
63
+ /** The ID of the service being modified */
64
+ ServiceId = "ServiceId",
65
+ /** Time that the modification completed on FNO side. */
66
+ FnoCompletedAt = "FnoCompletedAt",
67
+ /** Time that the modification completed on ISP side. */
68
+ IspCompletedAt = "IspCompletedAt"
69
+ }
70
+ /**
71
+ * Properties for ModifyServiceRequest records
72
+ *
73
+ * @see ServiceModule:ModifyServiceRequest
74
+ */
75
+ export interface ModifyServiceRequestProperties {
76
+ /** The ID of the service being modified
77
+ *
78
+ * @type {TEXT}
79
+ */
80
+ ServiceId: string;
81
+ /** Time that the modification completed on FNO side.
82
+ *
83
+ * @type {DATE_TIME}
84
+ */
85
+ FnoCompletedAt: string;
86
+ /** Time that the modification completed on ISP side.
87
+ *
88
+ * @type {DATE_TIME}
89
+ */
90
+ IspCompletedAt: string;
91
+ }
92
+ /**
93
+ * ModifyServiceRequest entity from ServiceModule
94
+ *
95
+ * Current status of a service modification request to a network provider (eg. speed change)
96
+ *
97
+ * @module ServiceModule
98
+ * @entity ModifyServiceRequest
99
+ * @schemaId c33f6215-f398-4d02-a35a-ebcde2ee2669
100
+ * @capabilities searchable, updateable, undeletable, triggerable
101
+ */
102
+ export declare class ModifyServiceRequest extends OdinRecord<ModifyServiceRequestProperties> {
103
+ entity: 'ServiceModule:ModifyServiceRequest';
104
+ type: ModifyServiceRequestEntityTypes;
105
+ schemaId: 'c33f6215-f398-4d02-a35a-ebcde2ee2669';
106
+ properties: ModifyServiceRequestProperties;
107
+ }
108
+ /**
109
+ * RabbitMQ routing keys for ModifyServiceRequest events
110
+ */
111
+ export declare const ROUTING_KEY_MODIFY_SERVICE_REQUEST_CREATED = "ServiceModule.ModifyServiceRequest.SubDbRecordCreated";
112
+ export declare const ROUTING_KEY_MODIFY_SERVICE_REQUEST_UPDATED = "ServiceModule.ModifyServiceRequest.SubDbRecordUpdated";
113
+ export declare const ROUTING_KEY_MODIFY_SERVICE_REQUEST_DELETED = "ServiceModule.ModifyServiceRequest.SubDbRecordDeleted";
114
+ /**
115
+ * Type-specific routing keys for ModifyServiceRequest events
116
+ * Subscribe to these for events on specific entity types only
117
+ */
118
+ /** This is the default record type created */
119
+ export declare const ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_CREATED = "ServiceModule.ModifyServiceRequest.DEFAULT.SubDbRecordCreated";
120
+ /** This is the default record type updated */
121
+ export declare const ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_UPDATED = "ServiceModule.ModifyServiceRequest.DEFAULT.SubDbRecordUpdated";
122
+ /** This is the default record type deleted */
123
+ export declare const ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_DELETED = "ServiceModule.ModifyServiceRequest.DEFAULT.SubDbRecordDeleted";
@@ -0,0 +1,108 @@
1
+ "use strict";
2
+ /**
3
+ * ModifyServiceRequest Entity Definition
4
+ *
5
+ * Current status of a service modification request to a network provider (eg. speed change)
6
+ *
7
+ * @module ServiceModule
8
+ * @entity ModifyServiceRequest
9
+ * @schemaId c33f6215-f398-4d02-a35a-ebcde2ee2669
10
+ *
11
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
12
+ * Generated from Odin schema definition
13
+ */
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_DELETED = exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_UPDATED = exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_CREATED = exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DELETED = exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_UPDATED = exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_CREATED = exports.ModifyServiceRequest = exports.ModifyServiceRequestPropertyKeys = exports.DefaultModifyServiceRequestStageKeys = exports.DefaultModifyServiceRequestStageNames = exports.ModifyServiceRequestEntityTypes = void 0;
16
+ const core_1 = require("@d19n/odin-types/dist/core");
17
+ /**
18
+ * Available types for ModifyServiceRequest records
19
+ */
20
+ var ModifyServiceRequestEntityTypes;
21
+ (function (ModifyServiceRequestEntityTypes) {
22
+ /** This is the default record type */
23
+ ModifyServiceRequestEntityTypes["DEFAULT"] = "DEFAULT";
24
+ })(ModifyServiceRequestEntityTypes = exports.ModifyServiceRequestEntityTypes || (exports.ModifyServiceRequestEntityTypes = {}));
25
+ /**
26
+ * Pipeline stage names for DEFAULT ModifyServiceRequest
27
+ * Pipeline: ModifyServiceRequestState
28
+ * ModifyServiceRequestState
29
+ */
30
+ var DefaultModifyServiceRequestStageNames;
31
+ (function (DefaultModifyServiceRequestStageNames) {
32
+ /** Request has not yet been submitted to supplier. (default) */
33
+ DefaultModifyServiceRequestStageNames["NotSent"] = "NotSent";
34
+ /** Request was sent successfully to supplier, pending response. */
35
+ DefaultModifyServiceRequestStageNames["SentToSupplier"] = "SentToSupplier";
36
+ /** Request failed to send to supplier. (fail) */
37
+ DefaultModifyServiceRequestStageNames["FailedToSend"] = "FailedToSend";
38
+ /** The supplier has raised an issue with completing the modification. */
39
+ DefaultModifyServiceRequestStageNames["Held"] = "Held";
40
+ /** Request was processed successfully by the supplier and they have confirmed the service change. (success) */
41
+ DefaultModifyServiceRequestStageNames["Completed"] = "Completed";
42
+ /** Request was received by supplier but failed to complete. (fail) */
43
+ DefaultModifyServiceRequestStageNames["Failed"] = "Failed";
44
+ })(DefaultModifyServiceRequestStageNames = exports.DefaultModifyServiceRequestStageNames || (exports.DefaultModifyServiceRequestStageNames = {}));
45
+ /**
46
+ * Pipeline stage keys for DEFAULT ModifyServiceRequest
47
+ * Use these keys when transitioning between stages
48
+ */
49
+ var DefaultModifyServiceRequestStageKeys;
50
+ (function (DefaultModifyServiceRequestStageKeys) {
51
+ /** Request has not yet been submitted to supplier. */
52
+ DefaultModifyServiceRequestStageKeys["ModifyServiceRequestStateStageNotSent"] = "ModifyServiceRequestStateStageNotSent";
53
+ /** Request was sent successfully to supplier, pending response. */
54
+ DefaultModifyServiceRequestStageKeys["ModifyServiceRequestStateStageSentToSupplier"] = "ModifyServiceRequestStateStageSentToSupplier";
55
+ /** Request failed to send to supplier. */
56
+ DefaultModifyServiceRequestStageKeys["ModifyServiceRequestStateStageFailedToSend"] = "ModifyServiceRequestStateStageFailedToSend";
57
+ /** The supplier has raised an issue with completing the modification. */
58
+ DefaultModifyServiceRequestStageKeys["ModifyServiceRequestStateStageHeld"] = "ModifyServiceRequestStateStageHeld";
59
+ /** Request was processed successfully by the supplier and they have confirmed the service change. */
60
+ DefaultModifyServiceRequestStageKeys["ModifyServiceRequestStateStageCompleted"] = "ModifyServiceRequestStateStageCompleted";
61
+ /** Request was received by supplier but failed to complete. */
62
+ DefaultModifyServiceRequestStageKeys["ModifyServiceRequestStateStageFailed"] = "ModifyServiceRequestStateStageFailed";
63
+ })(DefaultModifyServiceRequestStageKeys = exports.DefaultModifyServiceRequestStageKeys || (exports.DefaultModifyServiceRequestStageKeys = {}));
64
+ /**
65
+ * Property keys for ModifyServiceRequest
66
+ * Use these constants instead of string literals for type safety
67
+ */
68
+ var ModifyServiceRequestPropertyKeys;
69
+ (function (ModifyServiceRequestPropertyKeys) {
70
+ /** The ID of the service being modified */
71
+ ModifyServiceRequestPropertyKeys["ServiceId"] = "ServiceId";
72
+ /** Time that the modification completed on FNO side. */
73
+ ModifyServiceRequestPropertyKeys["FnoCompletedAt"] = "FnoCompletedAt";
74
+ /** Time that the modification completed on ISP side. */
75
+ ModifyServiceRequestPropertyKeys["IspCompletedAt"] = "IspCompletedAt";
76
+ })(ModifyServiceRequestPropertyKeys = exports.ModifyServiceRequestPropertyKeys || (exports.ModifyServiceRequestPropertyKeys = {}));
77
+ /**
78
+ * ModifyServiceRequest entity from ServiceModule
79
+ *
80
+ * Current status of a service modification request to a network provider (eg. speed change)
81
+ *
82
+ * @module ServiceModule
83
+ * @entity ModifyServiceRequest
84
+ * @schemaId c33f6215-f398-4d02-a35a-ebcde2ee2669
85
+ * @capabilities searchable, updateable, undeletable, triggerable
86
+ */
87
+ class ModifyServiceRequest extends core_1.OdinRecord {
88
+ }
89
+ exports.ModifyServiceRequest = ModifyServiceRequest;
90
+ // ============================================
91
+ // RABBITMQ EVENT ROUTING KEYS
92
+ // ============================================
93
+ /**
94
+ * RabbitMQ routing keys for ModifyServiceRequest events
95
+ */
96
+ exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_CREATED = 'ServiceModule.ModifyServiceRequest.SubDbRecordCreated';
97
+ exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_UPDATED = 'ServiceModule.ModifyServiceRequest.SubDbRecordUpdated';
98
+ exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DELETED = 'ServiceModule.ModifyServiceRequest.SubDbRecordDeleted';
99
+ /**
100
+ * Type-specific routing keys for ModifyServiceRequest events
101
+ * Subscribe to these for events on specific entity types only
102
+ */
103
+ /** This is the default record type created */
104
+ exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_CREATED = 'ServiceModule.ModifyServiceRequest.DEFAULT.SubDbRecordCreated';
105
+ /** This is the default record type updated */
106
+ exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_UPDATED = 'ServiceModule.ModifyServiceRequest.DEFAULT.SubDbRecordUpdated';
107
+ /** This is the default record type deleted */
108
+ exports.ROUTING_KEY_MODIFY_SERVICE_REQUEST_DEFAULT_DELETED = 'ServiceModule.ModifyServiceRequest.DEFAULT.SubDbRecordDeleted';
@@ -29,6 +29,7 @@ import { CreateCashbackRewardRefereeSuccessEmailProperties } from '../actions-v2
29
29
  import { CreateCashbackRewardReferrerFailedEmailProperties } from '../actions-v2/CreateCashbackRewardReferrerFailedEmailDto';
30
30
  import { CreateCashbackRewardReferrerPendingEmailProperties } from '../actions-v2/CreateCashbackRewardReferrerPendingEmailDto';
31
31
  import { CreateCashbackRewardReferrerSuccessEmailProperties } from '../actions-v2/CreateCashbackRewardReferrerSuccessEmailDto';
32
+ import { CreateOrderConfirmationProperties } from '../actions-v2/CreateOrderConfirmationDto';
32
33
  import { CreateOrderReferralRefereeCancelledEmailProperties } from '../actions-v2/CreateOrderReferralRefereeCancelledEmailDto';
33
34
  import { CreateOrderReferralRefereeNotQualifiedEmailProperties } from '../actions-v2/CreateOrderReferralRefereeNotQualifiedEmailDto';
34
35
  import { CreateOrderReferralRefereePendingEmailProperties } from '../actions-v2/CreateOrderReferralRefereePendingEmailDto';
@@ -552,6 +553,34 @@ export declare class EmailRecord<TProps = EmailProperties> {
552
553
  journeyId?: string;
553
554
  stageKey?: string;
554
555
  }): ActionBuilder;
556
+ /**
557
+ * CreateOrderConfirmation
558
+ *
559
+ * Creates a new Email record with the specified properties.
560
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
561
+ *
562
+ * @remarks Record type: TRANSACTIONAL
563
+ *
564
+ * @param properties - The properties for the new record
565
+ * @param options - Optional settings
566
+ * @param options.journeyId - Associate with a journey
567
+ * @param options.stageKey - Set initial pipeline stage
568
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
569
+ *
570
+ * @example
571
+ * ```typescript
572
+ * // Create with properties
573
+ * const record = odinClient.emails.new();
574
+ * await record.createOrderConfirmation({ ... }).execute();
575
+ *
576
+ * // Dry run (for debugging)
577
+ * const payload = record.createOrderConfirmation({ ... }).dryRun();
578
+ * ```
579
+ */
580
+ createOrderConfirmation(properties?: CreateOrderConfirmationProperties, options?: {
581
+ journeyId?: string;
582
+ stageKey?: string;
583
+ }): ActionBuilder;
555
584
  /**
556
585
  * CreateOrderReferralRefereeCancelledEmail
557
586
  *
@@ -710,6 +710,42 @@ class EmailRecord {
710
710
  };
711
711
  return new ActionBuilder(this._provider, 'NotificationModule', 'Email', payload, () => { this._pendingLinks = []; });
712
712
  }
713
+ /**
714
+ * CreateOrderConfirmation
715
+ *
716
+ * Creates a new Email record with the specified properties.
717
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
718
+ *
719
+ * @remarks Record type: TRANSACTIONAL
720
+ *
721
+ * @param properties - The properties for the new record
722
+ * @param options - Optional settings
723
+ * @param options.journeyId - Associate with a journey
724
+ * @param options.stageKey - Set initial pipeline stage
725
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
726
+ *
727
+ * @example
728
+ * ```typescript
729
+ * // Create with properties
730
+ * const record = odinClient.emails.new();
731
+ * await record.createOrderConfirmation({ ... }).execute();
732
+ *
733
+ * // Dry run (for debugging)
734
+ * const payload = record.createOrderConfirmation({ ... }).dryRun();
735
+ * ```
736
+ */
737
+ createOrderConfirmation(properties, options) {
738
+ const payload = {
739
+ entity: 'NotificationModule:Email',
740
+ type: 'TRANSACTIONAL',
741
+ actionName: 'CreateOrderConfirmation',
742
+ properties: properties || {},
743
+ associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined,
744
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
745
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
746
+ };
747
+ return new ActionBuilder(this._provider, 'NotificationModule', 'Email', payload, () => { this._pendingLinks = []; });
748
+ }
713
749
  /**
714
750
  * CreateOrderReferralRefereeCancelledEmail
715
751
  *