@rodrigobeber/patoai-dtos 2.2.44 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/crm/stage.enum.d.ts +6 -10
  2. package/dist/crm/stage.enum.js +5 -9
  3. package/dist/webchat/crew/index.d.ts +4 -0
  4. package/dist/webchat/crew/index.js +20 -0
  5. package/dist/webchat/crew/webchat-channel.dto.d.ts +7 -0
  6. package/dist/webchat/crew/webchat-channel.dto.js +2 -0
  7. package/dist/webchat/crew/webchat-crew-role.dto.d.ts +5 -0
  8. package/dist/webchat/crew/webchat-crew-role.dto.js +2 -0
  9. package/dist/webchat/crew/webchat-crew.dto.d.ts +11 -0
  10. package/dist/webchat/crew/webchat-crew.dto.js +2 -0
  11. package/dist/webchat/crew/webchat-member.dto.d.ts +7 -0
  12. package/dist/webchat/crew/webchat-member.dto.js +2 -0
  13. package/dist/webchat/crm/index.d.ts +4 -0
  14. package/dist/webchat/crm/index.js +20 -0
  15. package/dist/webchat/crm/webchat-crm.dto.d.ts +6 -0
  16. package/dist/webchat/crm/webchat-crm.dto.js +2 -0
  17. package/dist/webchat/crm/webchat-lead.dto.d.ts +13 -0
  18. package/dist/webchat/crm/webchat-lead.dto.js +2 -0
  19. package/dist/webchat/crm/webchat-stage.dto.d.ts +9 -0
  20. package/dist/webchat/crm/webchat-stage.dto.js +2 -0
  21. package/dist/webchat/crm/webchat-temperature.dto.d.ts +4 -0
  22. package/dist/webchat/crm/webchat-temperature.dto.js +2 -0
  23. package/dist/webchat/index.d.ts +3 -11
  24. package/dist/webchat/index.js +3 -11
  25. package/dist/webchat/thread/index.d.ts +7 -0
  26. package/dist/webchat/thread/index.js +23 -0
  27. package/dist/webchat/thread/webchat-delete-messages.dto.d.ts +4 -0
  28. package/dist/webchat/thread/webchat-delete-messages.dto.js +2 -0
  29. package/dist/webchat/thread/webchat-last-message.dto.d.ts +9 -0
  30. package/dist/webchat/thread/webchat-last-message.dto.js +2 -0
  31. package/dist/webchat/thread/webchat-media.dto.d.ts +9 -0
  32. package/dist/webchat/thread/webchat-media.dto.js +2 -0
  33. package/dist/webchat/thread/webchat-message-create.dto.d.ts +15 -0
  34. package/dist/webchat/thread/webchat-message-create.dto.js +2 -0
  35. package/dist/webchat/thread/webchat-message.dto.d.ts +14 -0
  36. package/dist/webchat/thread/webchat-message.dto.js +2 -0
  37. package/dist/webchat/thread/webchat-set-processed.dto.d.ts +5 -0
  38. package/dist/webchat/thread/webchat-set-processed.dto.js +2 -0
  39. package/dist/webchat/thread/webchat-thread.dto.d.ts +20 -0
  40. package/dist/webchat/thread/webchat-thread.dto.js +2 -0
  41. package/package.json +1 -1
@@ -1,12 +1,8 @@
1
1
  export declare enum StageEnum {
2
- INACTIVE = 1,
3
- DISQUALIFIED = 2,
4
- GAVE_UP = 3,
5
- NO_ANSWER = 4,
6
- NEW = 5,
7
- TALKING_AI = 6,
8
- TALKING_HUMAN = 7,
9
- MEETING_SCHEDULED = 8,
10
- NEGOTIATING = 9,
11
- DEAL_DONE = 10
2
+ INACTIVE = 1,// Inactive thread
3
+ GAVE_UP = 2,// StopFollowUpTool
4
+ NO_ANSWER = 3,// Reached follow up limit without answer
5
+ NEW = 4,// New thread, no sumary yet
6
+ MEETING_SCHEDULED = 5,// Meeting scheduled
7
+ CUSTOM = 100
12
8
  }
@@ -4,13 +4,9 @@ exports.StageEnum = void 0;
4
4
  var StageEnum;
5
5
  (function (StageEnum) {
6
6
  StageEnum[StageEnum["INACTIVE"] = 1] = "INACTIVE";
7
- StageEnum[StageEnum["DISQUALIFIED"] = 2] = "DISQUALIFIED";
8
- StageEnum[StageEnum["GAVE_UP"] = 3] = "GAVE_UP";
9
- StageEnum[StageEnum["NO_ANSWER"] = 4] = "NO_ANSWER";
10
- StageEnum[StageEnum["NEW"] = 5] = "NEW";
11
- StageEnum[StageEnum["TALKING_AI"] = 6] = "TALKING_AI";
12
- StageEnum[StageEnum["TALKING_HUMAN"] = 7] = "TALKING_HUMAN";
13
- StageEnum[StageEnum["MEETING_SCHEDULED"] = 8] = "MEETING_SCHEDULED";
14
- StageEnum[StageEnum["NEGOTIATING"] = 9] = "NEGOTIATING";
15
- StageEnum[StageEnum["DEAL_DONE"] = 10] = "DEAL_DONE";
7
+ StageEnum[StageEnum["GAVE_UP"] = 2] = "GAVE_UP";
8
+ StageEnum[StageEnum["NO_ANSWER"] = 3] = "NO_ANSWER";
9
+ StageEnum[StageEnum["NEW"] = 4] = "NEW";
10
+ StageEnum[StageEnum["MEETING_SCHEDULED"] = 5] = "MEETING_SCHEDULED";
11
+ StageEnum[StageEnum["CUSTOM"] = 100] = "CUSTOM";
16
12
  })(StageEnum || (exports.StageEnum = StageEnum = {}));
@@ -0,0 +1,4 @@
1
+ export * from './webchat-channel.dto';
2
+ export * from './webchat-crew-role.dto';
3
+ export * from './webchat-crew.dto';
4
+ export * from './webchat-member.dto';
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./webchat-channel.dto"), exports);
18
+ __exportStar(require("./webchat-crew-role.dto"), exports);
19
+ __exportStar(require("./webchat-crew.dto"), exports);
20
+ __exportStar(require("./webchat-member.dto"), exports);
@@ -0,0 +1,7 @@
1
+ import { PlatformEnum } from "../../uh";
2
+ export interface WebChatChannelDto {
3
+ id: number;
4
+ name: string;
5
+ platform: PlatformEnum;
6
+ channelId: string;
7
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,5 @@
1
+ import { MemberRoleEnum } from "../../organization";
2
+ export interface WebChatCrewRoleDto {
3
+ idCrew: number;
4
+ role: MemberRoleEnum;
5
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,11 @@
1
+ import { WebChatCrmDto } from "../crm";
2
+ import { WebChatChannelDto } from "./webchat-channel.dto";
3
+ import { WebChatMemberDto } from "./webchat-member.dto";
4
+ export interface WebChatCrewDto {
5
+ id: number;
6
+ online: boolean;
7
+ shortName: string;
8
+ channels: WebChatChannelDto[];
9
+ members: WebChatMemberDto[];
10
+ crm?: WebChatCrmDto;
11
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,7 @@
1
+ import { MemberRoleEnum } from "../../organization";
2
+ export interface WebChatMemberDto {
3
+ idHuman: number;
4
+ name: string;
5
+ login: string;
6
+ role: MemberRoleEnum;
7
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,4 @@
1
+ export * from './webchat-crm.dto';
2
+ export * from './webchat-lead.dto';
3
+ export * from './webchat-stage.dto';
4
+ export * from './webchat-temperature.dto';
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./webchat-crm.dto"), exports);
18
+ __exportStar(require("./webchat-lead.dto"), exports);
19
+ __exportStar(require("./webchat-stage.dto"), exports);
20
+ __exportStar(require("./webchat-temperature.dto"), exports);
@@ -0,0 +1,6 @@
1
+ import { WebChatStage } from "./webchat-stage.dto";
2
+ import { WebChatTemperatureDto } from "./webchat-temperature.dto";
3
+ export interface WebChatCrmDto {
4
+ termometer: WebChatTemperatureDto[];
5
+ pipeline: WebChatStage[];
6
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,13 @@
1
+ export interface WebChatLeadDto {
2
+ idLead: number;
3
+ idStage: number;
4
+ dtStage: Date;
5
+ nrTemperature: number;
6
+ idHuman: number | null;
7
+ dsTitle: string | null;
8
+ txSummary: string | null;
9
+ dsEmail: string | null;
10
+ txHuman: string | null;
11
+ dsBudget: string | null;
12
+ dtSummary: Date | null;
13
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,9 @@
1
+ import { StageEnum } from "../../crm";
2
+ export interface WebChatStage {
3
+ id: number;
4
+ order: number;
5
+ type: StageEnum;
6
+ name: string;
7
+ when: string | null;
8
+ isActive: boolean;
9
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,4 @@
1
+ export interface WebChatTemperatureDto {
2
+ score: number;
3
+ description: string;
4
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,11 +1,3 @@
1
- export * from './webchat-channel.dto';
2
- export * from './webchat-crew-role.dto';
3
- export * from './webchat-crew.dto';
4
- export * from './webchat-delete-messages.dto';
5
- export * from './webchat-media.dto';
6
- export * from './webchat-last-message.dto';
7
- export * from './webchat-member.dto';
8
- export * from './webchat-message-create.dto';
9
- export * from './webchat-message.dto';
10
- export * from './webchat-set-processed.dto';
11
- export * from './webchat-thread.dto';
1
+ export * from './crew';
2
+ export * from './crm';
3
+ export * from './thread';
@@ -14,14 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./webchat-channel.dto"), exports);
18
- __exportStar(require("./webchat-crew-role.dto"), exports);
19
- __exportStar(require("./webchat-crew.dto"), exports);
20
- __exportStar(require("./webchat-delete-messages.dto"), exports);
21
- __exportStar(require("./webchat-media.dto"), exports);
22
- __exportStar(require("./webchat-last-message.dto"), exports);
23
- __exportStar(require("./webchat-member.dto"), exports);
24
- __exportStar(require("./webchat-message-create.dto"), exports);
25
- __exportStar(require("./webchat-message.dto"), exports);
26
- __exportStar(require("./webchat-set-processed.dto"), exports);
27
- __exportStar(require("./webchat-thread.dto"), exports);
17
+ __exportStar(require("./crew"), exports);
18
+ __exportStar(require("./crm"), exports);
19
+ __exportStar(require("./thread"), exports);
@@ -0,0 +1,7 @@
1
+ export * from './webchat-delete-messages.dto';
2
+ export * from './webchat-media.dto';
3
+ export * from './webchat-last-message.dto';
4
+ export * from './webchat-message-create.dto';
5
+ export * from './webchat-message.dto';
6
+ export * from './webchat-set-processed.dto';
7
+ export * from './webchat-thread.dto';
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./webchat-delete-messages.dto"), exports);
18
+ __exportStar(require("./webchat-media.dto"), exports);
19
+ __exportStar(require("./webchat-last-message.dto"), exports);
20
+ __exportStar(require("./webchat-message-create.dto"), exports);
21
+ __exportStar(require("./webchat-message.dto"), exports);
22
+ __exportStar(require("./webchat-set-processed.dto"), exports);
23
+ __exportStar(require("./webchat-thread.dto"), exports);
@@ -0,0 +1,4 @@
1
+ export interface WebChatDeleteMessagesDto {
2
+ idThread: number;
3
+ messageIds: string[];
4
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,9 @@
1
+ export interface WebChatLastMessageDto {
2
+ id: number;
3
+ at: Date;
4
+ text: string;
5
+ role: 'user' | 'assistant' | 'owner';
6
+ type: 'audio' | 'image';
7
+ description?: string;
8
+ duration?: number;
9
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,9 @@
1
+ export interface WebChatMediaDto {
2
+ idMessage: number;
3
+ type: 'audio' | 'image';
4
+ mediaId: string;
5
+ mimeType: string;
6
+ size: number;
7
+ duration: number;
8
+ description: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,15 @@
1
+ export interface WebChatMediaCreateDto {
2
+ type: 'audio' | 'image';
3
+ mimeType: string;
4
+ size: number;
5
+ duration?: number;
6
+ }
7
+ export interface WebChatMessageCreateDto {
8
+ tempId: string;
9
+ idThread: number;
10
+ userId: string;
11
+ text: string;
12
+ role: 'owner';
13
+ idReply?: number;
14
+ media?: WebChatMediaCreateDto;
15
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,14 @@
1
+ import { WebChatMediaDto } from "./webchat-media.dto";
2
+ export interface WebChatMessageDto {
3
+ idMessage: number;
4
+ idThread: number;
5
+ text: string;
6
+ role: 'user' | 'system' | 'developer' | 'assistant' | 'owner';
7
+ processed: boolean;
8
+ hidden: boolean;
9
+ messageId: string;
10
+ idReply?: number;
11
+ createdAt: Date;
12
+ media: WebChatMediaDto;
13
+ tempId?: string;
14
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,5 @@
1
+ export interface WebChatSetProcessedDto {
2
+ idThread: number;
3
+ idMessage: number;
4
+ processed: boolean;
5
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,20 @@
1
+ import { WebChatLeadDto } from "../crm/webchat-lead.dto";
2
+ import { WebChatLastMessageDto } from "./webchat-last-message.dto";
3
+ export interface WebChatThreadDto {
4
+ idThread: number;
5
+ idCrew: number;
6
+ idChannel: number;
7
+ idUser: number;
8
+ userId: string;
9
+ userName: string;
10
+ manual: boolean;
11
+ idHuman: number | null;
12
+ reason: string | null;
13
+ toProcess: number;
14
+ processing: Date | null;
15
+ sumarizing: Date | null;
16
+ followUp: number;
17
+ lm?: WebChatLastMessageDto;
18
+ lead?: WebChatLeadDto;
19
+ manualPending?: boolean;
20
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rodrigobeber/patoai-dtos",
3
- "version": "2.2.44",
3
+ "version": "3.0.0",
4
4
  "description": "Data Transfer Objects for PatoAI",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",