@epilot/message-client 1.5.1 → 1.7.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.
- package/dist/openapi.d.ts +20 -124
- package/dist/openapi.json +7 -8
- package/package.json +5 -5
package/dist/openapi.d.ts
CHANGED
|
@@ -209,6 +209,7 @@ declare namespace Components {
|
|
|
209
209
|
type?: "SENT" | "RECEIVED";
|
|
210
210
|
}
|
|
211
211
|
export interface MessageRequestParams {
|
|
212
|
+
[name: string]: any;
|
|
212
213
|
/**
|
|
213
214
|
* Open new thread when sending the very first message in conversation. Thread should contains context related to all messages in it (eg. topic, brand_id, opportunity_id, assigned_to,...).\
|
|
214
215
|
* Thread properties depend on API caller as it's not pre-defined. We do recommend having at least `topic` property for categorizing.\
|
|
@@ -446,6 +447,12 @@ declare namespace Components {
|
|
|
446
447
|
* Latest trash message of thread
|
|
447
448
|
*/
|
|
448
449
|
latest_trash_message?: Message;
|
|
450
|
+
/**
|
|
451
|
+
* The date of the latest message time in the thread
|
|
452
|
+
* example:
|
|
453
|
+
* 2024-02-10T09:14:31.990Z
|
|
454
|
+
*/
|
|
455
|
+
latest_message_at?: string;
|
|
449
456
|
}
|
|
450
457
|
}
|
|
451
458
|
}
|
|
@@ -1098,6 +1105,12 @@ declare namespace Paths {
|
|
|
1098
1105
|
org_read_message?: string[];
|
|
1099
1106
|
latest_message?: Components.Schemas.Message;
|
|
1100
1107
|
latest_trash_message?: Components.Schemas.Message;
|
|
1108
|
+
/**
|
|
1109
|
+
* The date of the latest message time in the thread
|
|
1110
|
+
* example:
|
|
1111
|
+
* 2024-02-10T09:14:31.990Z
|
|
1112
|
+
*/
|
|
1113
|
+
latest_message_at?: string;
|
|
1101
1114
|
}[];
|
|
1102
1115
|
}
|
|
1103
1116
|
export interface $403 {
|
|
@@ -1243,130 +1256,7 @@ declare namespace Paths {
|
|
|
1243
1256
|
}
|
|
1244
1257
|
export type RequestBody = Components.Schemas.MessageRequestParams;
|
|
1245
1258
|
namespace Responses {
|
|
1246
|
-
export
|
|
1247
|
-
/**
|
|
1248
|
-
* Entity ID
|
|
1249
|
-
* example:
|
|
1250
|
-
* 3fa85f64-5717-4562-b3fc-2c963f66afa6
|
|
1251
|
-
*/
|
|
1252
|
-
_id: string;
|
|
1253
|
-
/**
|
|
1254
|
-
* Entity title
|
|
1255
|
-
*/
|
|
1256
|
-
_title: string;
|
|
1257
|
-
/**
|
|
1258
|
-
* Ivy Organization ID the entity belongs to
|
|
1259
|
-
* example:
|
|
1260
|
-
* 206801
|
|
1261
|
-
*/
|
|
1262
|
-
_org: string;
|
|
1263
|
-
/**
|
|
1264
|
-
* URL-friendly identifier for the entity schema
|
|
1265
|
-
* example:
|
|
1266
|
-
* message
|
|
1267
|
-
*/
|
|
1268
|
-
_schema: string;
|
|
1269
|
-
/**
|
|
1270
|
-
* Entity tags
|
|
1271
|
-
* example:
|
|
1272
|
-
* [
|
|
1273
|
-
* "pricing",
|
|
1274
|
-
* "INBOX"
|
|
1275
|
-
* ]
|
|
1276
|
-
*/
|
|
1277
|
-
_tags?: string[];
|
|
1278
|
-
/**
|
|
1279
|
-
* Created date
|
|
1280
|
-
* example:
|
|
1281
|
-
* 2021-02-09T12:41:43.662Z
|
|
1282
|
-
*/
|
|
1283
|
-
_created_at: string; // date-time
|
|
1284
|
-
/**
|
|
1285
|
-
* Updated date
|
|
1286
|
-
* example:
|
|
1287
|
-
* 2021-02-10T09:14:31.990Z
|
|
1288
|
-
*/
|
|
1289
|
-
_updated_at: string; // date-time
|
|
1290
|
-
/**
|
|
1291
|
-
* Message ID which is from email provider. If you provide `message-id`, API overrides by its own value.
|
|
1292
|
-
* example:
|
|
1293
|
-
* <0102017b97a502f8-a67f01c2-68cc-4928-b91b-45853f34e259-000000@eu-west-1.amazonses.com>
|
|
1294
|
-
*/
|
|
1295
|
-
message_id?: string;
|
|
1296
|
-
/**
|
|
1297
|
-
* Ivy User ID of user sends the message.
|
|
1298
|
-
* example:
|
|
1299
|
-
* 206801
|
|
1300
|
-
*/
|
|
1301
|
-
sender?: string;
|
|
1302
|
-
/**
|
|
1303
|
-
* Subject
|
|
1304
|
-
* example:
|
|
1305
|
-
* Request for solar panel price
|
|
1306
|
-
*/
|
|
1307
|
-
subject: string;
|
|
1308
|
-
/**
|
|
1309
|
-
* HTML body
|
|
1310
|
-
* example:
|
|
1311
|
-
* <div>We at ABC GmbH would like to request a price quote for the solar panel.</div>
|
|
1312
|
-
*/
|
|
1313
|
-
html?: string;
|
|
1314
|
-
/**
|
|
1315
|
-
* Text body
|
|
1316
|
-
* example:
|
|
1317
|
-
* We at ABC GmbH would like to request a price quote for the solar panel.
|
|
1318
|
-
*/
|
|
1319
|
-
text?: string;
|
|
1320
|
-
from: Components.Schemas.Address;
|
|
1321
|
-
reply_to?: Components.Schemas.Address;
|
|
1322
|
-
/**
|
|
1323
|
-
* To email addresses
|
|
1324
|
-
*/
|
|
1325
|
-
to?: Components.Schemas.Address[];
|
|
1326
|
-
/**
|
|
1327
|
-
* Cc email addresses
|
|
1328
|
-
*/
|
|
1329
|
-
cc?: Components.Schemas.Address[];
|
|
1330
|
-
/**
|
|
1331
|
-
* Bcc email addresses
|
|
1332
|
-
*/
|
|
1333
|
-
bcc?: Components.Schemas.Address[];
|
|
1334
|
-
file?: /* Message attachments */ Components.Schemas.AttachmentsRelation;
|
|
1335
|
-
/**
|
|
1336
|
-
* References header. Value is the series of `message_id` which is reparated by space to indicate that message has parent.\
|
|
1337
|
-
* The last message ID in references identifies the parent. The first message ID in references identifies the first message in the thread.\
|
|
1338
|
-
* The basic idea is that sender should copy `references` from the parent and append the parent's `message_id` when replying.
|
|
1339
|
-
*
|
|
1340
|
-
* example:
|
|
1341
|
-
* <0102017b97a502f8-a67f01c2-68cc-4928-b91b-45853f34e259-000000@eu-west-1.amazonses.com> <CALHgQpziyxW9NaFUs+nRMykzr6Ljq6vjq4WO9SaihAuMasuDyg@mail.gmail.com>
|
|
1342
|
-
*/
|
|
1343
|
-
references?: string;
|
|
1344
|
-
/**
|
|
1345
|
-
* In-Reply-To header. Value is the `message_id` of parent message.
|
|
1346
|
-
*
|
|
1347
|
-
* example:
|
|
1348
|
-
* <CALHgQpziyxW9NaFUs+nRMykzr6Ljq6vjq4WO9SaihAuMasuDyg@mail.gmail.com>
|
|
1349
|
-
*/
|
|
1350
|
-
in_reply_to?: string;
|
|
1351
|
-
/**
|
|
1352
|
-
* Ivy User ID of user read the message.
|
|
1353
|
-
*/
|
|
1354
|
-
user_read_message?: string[];
|
|
1355
|
-
/**
|
|
1356
|
-
* Ivy Organization ID of organization read the message.
|
|
1357
|
-
*/
|
|
1358
|
-
org_read_message?: string[];
|
|
1359
|
-
/**
|
|
1360
|
-
* Sent message status. The array contains sending message status corresponding to all recipients. For more detail, check `send_status` of each recipient in `to`, `cc`, `bcc`\
|
|
1361
|
-
* Reference at <https://docs.aws.amazon.com/ses/latest/DeveloperGuide/monitor-sending-activity.html>
|
|
1362
|
-
*
|
|
1363
|
-
*/
|
|
1364
|
-
send_status?: ("SEND" | "DELIVERY" | "REJECT" | "COMPLAINT" | "BOUNCE" | "ERROR")[];
|
|
1365
|
-
/**
|
|
1366
|
-
* Message type
|
|
1367
|
-
*/
|
|
1368
|
-
type?: "SENT" | "RECEIVED";
|
|
1369
|
-
}
|
|
1259
|
+
export type $201 = Components.Schemas.MessageRequestParams;
|
|
1370
1260
|
export interface $403 {
|
|
1371
1261
|
}
|
|
1372
1262
|
}
|
|
@@ -1622,6 +1512,12 @@ declare namespace Paths {
|
|
|
1622
1512
|
org_read_message?: string[];
|
|
1623
1513
|
latest_message?: Components.Schemas.Message;
|
|
1624
1514
|
latest_trash_message?: Components.Schemas.Message;
|
|
1515
|
+
/**
|
|
1516
|
+
* The date of the latest message time in the thread
|
|
1517
|
+
* example:
|
|
1518
|
+
* 2024-02-10T09:14:31.990Z
|
|
1519
|
+
*/
|
|
1520
|
+
latest_message_at?: string;
|
|
1625
1521
|
}
|
|
1626
1522
|
export interface $403 {
|
|
1627
1523
|
}
|
package/dist/openapi.json
CHANGED
|
@@ -59,14 +59,7 @@
|
|
|
59
59
|
"content": {
|
|
60
60
|
"application/json": {
|
|
61
61
|
"schema": {
|
|
62
|
-
"
|
|
63
|
-
{
|
|
64
|
-
"$ref": "#/components/schemas/BaseEntity"
|
|
65
|
-
},
|
|
66
|
-
{
|
|
67
|
-
"$ref": "#/components/schemas/Message"
|
|
68
|
-
}
|
|
69
|
-
]
|
|
62
|
+
"$ref": "#/components/schemas/MessageRequestParams"
|
|
70
63
|
}
|
|
71
64
|
}
|
|
72
65
|
}
|
|
@@ -880,6 +873,11 @@
|
|
|
880
873
|
"type": "object",
|
|
881
874
|
"description": "Latest trash message of thread",
|
|
882
875
|
"$ref": "#/components/schemas/Message"
|
|
876
|
+
},
|
|
877
|
+
"latest_message_at": {
|
|
878
|
+
"type": "string",
|
|
879
|
+
"description": "The date of the latest message time in the thread",
|
|
880
|
+
"example": "2024-02-10T09:14:31.990Z"
|
|
883
881
|
}
|
|
884
882
|
}
|
|
885
883
|
},
|
|
@@ -1113,6 +1111,7 @@
|
|
|
1113
1111
|
"subject",
|
|
1114
1112
|
"from"
|
|
1115
1113
|
],
|
|
1114
|
+
"additionalProperties": true,
|
|
1116
1115
|
"properties": {
|
|
1117
1116
|
"thread": {
|
|
1118
1117
|
"type": "object",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epilot/message-client",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"description": "API Client for epilot Message API",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -45,25 +45,25 @@
|
|
|
45
45
|
"author": "epilot GmbH",
|
|
46
46
|
"license": "UNLICENSED",
|
|
47
47
|
"peerDependencies": {
|
|
48
|
-
"axios": "^
|
|
48
|
+
"axios": "^1.6.2"
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"@dazn/lambda-powertools-correlation-ids": "^1.28.1",
|
|
52
52
|
"buffer": "^6.0.3",
|
|
53
53
|
"https-browserify": "^1.0.0",
|
|
54
|
-
"openapi-client-axios": "^7.1
|
|
54
|
+
"openapi-client-axios": "^7.5.1",
|
|
55
55
|
"stream-http": "^3.1.1",
|
|
56
56
|
"url": "^0.11.0",
|
|
57
57
|
"util": "^0.12.3"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
60
|
"@types/jest": "^26.0.20",
|
|
61
|
-
"axios": "^
|
|
61
|
+
"axios": "^1.6.2",
|
|
62
62
|
"copy-webpack-plugin": "^7.0.0",
|
|
63
63
|
"jest": "^26.6.3",
|
|
64
64
|
"json-loader": "^0.5.7",
|
|
65
65
|
"openapi-client-axios-typegen": "^7.4.1",
|
|
66
|
-
"openapicmd": "^1.
|
|
66
|
+
"openapicmd": "^2.1.0",
|
|
67
67
|
"ts-jest": "^26.5.0",
|
|
68
68
|
"ts-loader": "^8.0.14",
|
|
69
69
|
"ts-node": "^10.9.1",
|