blastengine
Advanced tools
+1
-1
| { | ||
| "name": "blastengine", | ||
| "version": "2.3.5", | ||
| "version": "2.3.6", | ||
| "description": "", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
+6
-6
@@ -11,3 +11,3 @@ import Base from "./base"; | ||
| Unsubscribed, | ||
| SearchAllCondition, | ||
| SearchConditionUnsubscribe, | ||
| } from "../../types/"; | ||
@@ -57,7 +57,7 @@ | ||
| * @async | ||
| * @param {SearchCondition} params - The search conditions. | ||
| * @param {SearchConditionUnsubscribe} params - The search conditions. | ||
| * @return {Promise<(Bulk | Transaction)[]>} - The search results. | ||
| * @static | ||
| */ | ||
| static async find(params?: SearchCondition): | ||
| static async find(params?: SearchConditionUnsubscribe): | ||
| Promise<(Bulk | Transaction)[]> { | ||
@@ -70,3 +70,3 @@ if (params?.delivery_start && params.delivery_start instanceof Date) { | ||
| } | ||
| const url = "/deliveries/all"; | ||
| const url = "/deliveries"; | ||
| const res = await Mail.request.send("get", url, params) as SearchResponse; | ||
@@ -84,3 +84,3 @@ return res.data.map((params) => Mail.fromJson(params)); | ||
| */ | ||
| static async all(params?: SearchAllCondition): | ||
| static async all(params?: SearchCondition): | ||
| Promise<(Bulk | Transaction)[]> { | ||
@@ -93,3 +93,3 @@ if (params?.delivery_start && params.delivery_start instanceof Date) { | ||
| } | ||
| const url = "/deliveries"; | ||
| const url = "/deliveries/all"; | ||
| const res = await Mail.request.send("get", url, params) as SearchResponse; | ||
@@ -96,0 +96,0 @@ return res.data.map((params) => Mail.fromJson(params)); |
@@ -11,3 +11,3 @@ import { BlastEngine, Mail, Bulk } from '../src'; | ||
| test('Search mail', async () => { | ||
| const mails = await Mail.find({ size: 100, delivery_type: ['BULK'], status: ['EDIT'] }) as Bulk[]; | ||
| const mails = await Mail.all({ size: 100, delivery_type: ['BULK'], status: ['EDIT'] }) as Bulk[]; | ||
| for (const bulk of mails) { | ||
@@ -21,5 +21,5 @@ await bulk.delete(); | ||
| test('Search mail', async () => { | ||
| const mails = await Mail.all({ size: 100, list_unsubscribe_mailto: 'moongift' }) as Bulk[]; | ||
| const mails = await Mail.find({ size: 100, list_unsubscribe_mailto: 'moongift' }) as Bulk[]; | ||
| }); | ||
| }); | ||
| }); |
+1
-1
@@ -244,3 +244,3 @@ import Transaction from "../src/libs/transaction"; | ||
| export interface SearchAllCondition extends SearchCondition { | ||
| export interface SearchConditionUnsubscribe extends SearchCondition { | ||
| list_unsubscribe_mailto?: string, | ||
@@ -247,0 +247,0 @@ list_unsubscribe_url?: string, |
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
221703
0.02%