@rodrigobeber/patoai-dtos 1.2.2 → 1.2.3

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.
@@ -1,6 +1,5 @@
1
- import { MessageInDto } from "./platform.dto";
1
+ import { MessageDto, PlatformEnum } from "./platform.dto";
2
2
  export interface HandleMessageDto {
3
- crewCode: string;
4
- method: string;
5
- messageIn: MessageInDto;
3
+ platform: PlatformEnum;
4
+ message: MessageDto;
6
5
  }
@@ -1,20 +1,25 @@
1
- export declare enum MessageInTypeDto {
1
+ export declare enum PlatformEnum {
2
+ EVOLUTION = "evolution",
3
+ WHATSAPP = "whatsapp",
4
+ TELEGRAM = "telegram",
5
+ MANYCHAT = "manychat"
6
+ }
7
+ export declare enum MessageEnum {
2
8
  TEXT = "text",
3
9
  IMAGE = "image",
4
10
  VOICE = "voice"
5
11
  }
6
- export declare enum MessageLangDto {
7
- PT = "pt",
8
- EN = "en"
12
+ export interface MediaDto {
13
+ mimeType: string;
14
+ fileId: string;
9
15
  }
10
- export interface MessageInDto {
16
+ export interface MessageDto {
17
+ platform: PlatformEnum;
18
+ type: MessageEnum;
19
+ channelId?: string;
11
20
  userId: string;
12
- lang: MessageLangDto;
13
21
  userName: string;
14
- type: MessageInTypeDto;
15
- chatMessageId: string;
16
- idThread?: number;
22
+ messageId: string;
23
+ media?: MediaDto;
17
24
  text?: string;
18
- idAudio?: string;
19
- mimeType?: string;
20
25
  }
@@ -1,14 +1,16 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MessageLangDto = exports.MessageInTypeDto = void 0;
4
- var MessageInTypeDto;
5
- (function (MessageInTypeDto) {
6
- MessageInTypeDto["TEXT"] = "text";
7
- MessageInTypeDto["IMAGE"] = "image";
8
- MessageInTypeDto["VOICE"] = "voice";
9
- })(MessageInTypeDto || (exports.MessageInTypeDto = MessageInTypeDto = {}));
10
- var MessageLangDto;
11
- (function (MessageLangDto) {
12
- MessageLangDto["PT"] = "pt";
13
- MessageLangDto["EN"] = "en";
14
- })(MessageLangDto || (exports.MessageLangDto = MessageLangDto = {}));
3
+ exports.MessageEnum = exports.PlatformEnum = void 0;
4
+ var PlatformEnum;
5
+ (function (PlatformEnum) {
6
+ PlatformEnum["EVOLUTION"] = "evolution";
7
+ PlatformEnum["WHATSAPP"] = "whatsapp";
8
+ PlatformEnum["TELEGRAM"] = "telegram";
9
+ PlatformEnum["MANYCHAT"] = "manychat";
10
+ })(PlatformEnum || (exports.PlatformEnum = PlatformEnum = {}));
11
+ var MessageEnum;
12
+ (function (MessageEnum) {
13
+ MessageEnum["TEXT"] = "text";
14
+ MessageEnum["IMAGE"] = "image";
15
+ MessageEnum["VOICE"] = "voice";
16
+ })(MessageEnum || (exports.MessageEnum = MessageEnum = {}));
@@ -1,4 +1,3 @@
1
- import { MessageLangDto } from "../chat";
2
1
  import { IntegrationDto } from "../chat/integration.dto";
3
2
  import { ThreadDto } from "../chat/thread.dto";
4
3
  export interface RunDto {
@@ -6,5 +5,4 @@ export interface RunDto {
6
5
  aiKey: string;
7
6
  integration: IntegrationDto;
8
7
  thread: ThreadDto;
9
- lang: MessageLangDto;
10
8
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rodrigobeber/patoai-dtos",
3
- "version": "1.2.2",
3
+ "version": "1.2.3",
4
4
  "description": "Data Transfer Objects for the PatoAI system",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",