asfur 1.0.47 → 1.0.49
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/index.d.ts +56 -169
- package/dist/types.d.ts +9 -9
- package/dist/types.js +3 -3
- package/index.ts +1 -1
- package/package.json +1 -1
- package/types.ts +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -25,181 +25,68 @@
|
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
export * from './types';
|
|
27
27
|
import { Schema } from 'mongoose';
|
|
28
|
-
export declare const MongoDataSchema: Schema<{
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
source_geo?: string | undefined;
|
|
41
|
-
metadata?: Record<string, any> | undefined;
|
|
42
|
-
updated_at?: number | Date | undefined;
|
|
43
|
-
original_text?: string | undefined;
|
|
44
|
-
translated_text?: string | undefined;
|
|
45
|
-
is_reply?: boolean | undefined;
|
|
46
|
-
reply_to_message_id?: string | number | undefined;
|
|
47
|
-
media?: {
|
|
48
|
-
type: "image" | "video" | "audio" | "link";
|
|
49
|
-
url: string;
|
|
50
|
-
caption?: string | undefined;
|
|
51
|
-
}[] | undefined;
|
|
52
|
-
}, import("mongoose").Model<{
|
|
53
|
-
platform: "telegram" | "facebook" | "instagram" | "tiktok" | "website" | "document" | "other";
|
|
54
|
-
source_id: string | number;
|
|
55
|
-
source_public_id: string | number;
|
|
56
|
-
source_name: string;
|
|
57
|
-
created_at: number | Date;
|
|
58
|
-
platform_id: string | number;
|
|
59
|
-
original_text_id: string | number;
|
|
60
|
-
timestamp: number | Date;
|
|
61
|
-
text_geo: string[];
|
|
62
|
-
_id?: string | undefined;
|
|
63
|
-
language?: string | undefined;
|
|
64
|
-
source_geo?: string | undefined;
|
|
65
|
-
metadata?: Record<string, any> | undefined;
|
|
66
|
-
updated_at?: number | Date | undefined;
|
|
67
|
-
original_text?: string | undefined;
|
|
68
|
-
translated_text?: string | undefined;
|
|
69
|
-
is_reply?: boolean | undefined;
|
|
70
|
-
reply_to_message_id?: string | number | undefined;
|
|
71
|
-
media?: {
|
|
72
|
-
type: "image" | "video" | "audio" | "link";
|
|
73
|
-
url: string;
|
|
74
|
-
caption?: string | undefined;
|
|
75
|
-
}[] | undefined;
|
|
76
|
-
}, any, any, any, import("mongoose").Document<unknown, any, {
|
|
77
|
-
platform: "telegram" | "facebook" | "instagram" | "tiktok" | "website" | "document" | "other";
|
|
78
|
-
source_id: string | number;
|
|
79
|
-
source_public_id: string | number;
|
|
80
|
-
source_name: string;
|
|
81
|
-
created_at: number | Date;
|
|
82
|
-
platform_id: string | number;
|
|
83
|
-
original_text_id: string | number;
|
|
84
|
-
timestamp: number | Date;
|
|
85
|
-
text_geo: string[];
|
|
86
|
-
_id?: string | undefined;
|
|
87
|
-
language?: string | undefined;
|
|
88
|
-
source_geo?: string | undefined;
|
|
89
|
-
metadata?: Record<string, any> | undefined;
|
|
90
|
-
updated_at?: number | Date | undefined;
|
|
91
|
-
original_text?: string | undefined;
|
|
92
|
-
translated_text?: string | undefined;
|
|
93
|
-
is_reply?: boolean | undefined;
|
|
94
|
-
reply_to_message_id?: string | number | undefined;
|
|
95
|
-
media?: {
|
|
96
|
-
type: "image" | "video" | "audio" | "link";
|
|
97
|
-
url: string;
|
|
98
|
-
caption?: string | undefined;
|
|
99
|
-
}[] | undefined;
|
|
100
|
-
}, any> & {
|
|
101
|
-
platform: "telegram" | "facebook" | "instagram" | "tiktok" | "website" | "document" | "other";
|
|
102
|
-
source_id: string | number;
|
|
103
|
-
source_public_id: string | number;
|
|
104
|
-
source_name: string;
|
|
105
|
-
created_at: number | Date;
|
|
106
|
-
platform_id: string | number;
|
|
107
|
-
original_text_id: string | number;
|
|
108
|
-
timestamp: number | Date;
|
|
109
|
-
text_geo: string[];
|
|
110
|
-
_id?: string | undefined;
|
|
111
|
-
language?: string | undefined;
|
|
112
|
-
source_geo?: string | undefined;
|
|
113
|
-
metadata?: Record<string, any> | undefined;
|
|
114
|
-
updated_at?: number | Date | undefined;
|
|
115
|
-
original_text?: string | undefined;
|
|
116
|
-
translated_text?: string | undefined;
|
|
117
|
-
is_reply?: boolean | undefined;
|
|
118
|
-
reply_to_message_id?: string | number | undefined;
|
|
119
|
-
media?: {
|
|
120
|
-
type: "image" | "video" | "audio" | "link";
|
|
121
|
-
url: string;
|
|
122
|
-
caption?: string | undefined;
|
|
123
|
-
}[] | undefined;
|
|
124
|
-
} & Required<{
|
|
125
|
-
_id: string;
|
|
126
|
-
}> & {
|
|
127
|
-
__v: number;
|
|
128
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, {
|
|
129
|
-
platform: "telegram" | "facebook" | "instagram" | "tiktok" | "website" | "document" | "other";
|
|
130
|
-
source_id: string | number;
|
|
131
|
-
source_public_id: string | number;
|
|
132
|
-
source_name: string;
|
|
133
|
-
created_at: number | Date;
|
|
134
|
-
platform_id: string | number;
|
|
135
|
-
original_text_id: string | number;
|
|
136
|
-
timestamp: number | Date;
|
|
28
|
+
export declare const MongoDataSchema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, {
|
|
29
|
+
versionKey: false;
|
|
30
|
+
toJSON: {
|
|
31
|
+
virtuals: true;
|
|
32
|
+
};
|
|
33
|
+
toObject: {
|
|
34
|
+
virtuals: true;
|
|
35
|
+
};
|
|
36
|
+
}, {
|
|
37
|
+
created_at: number;
|
|
38
|
+
updated_at: number;
|
|
39
|
+
timestamp: number;
|
|
137
40
|
text_geo: string[];
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
caption?: string | undefined;
|
|
151
|
-
}[] | undefined;
|
|
41
|
+
platform?: string | null | undefined;
|
|
42
|
+
source_id?: string | null | undefined;
|
|
43
|
+
source_public_id?: string | null | undefined;
|
|
44
|
+
source_name?: string | null | undefined;
|
|
45
|
+
source_geo?: string | null | undefined;
|
|
46
|
+
metadata?: any;
|
|
47
|
+
platform_id?: string | null | undefined;
|
|
48
|
+
original_text_id?: string | null | undefined;
|
|
49
|
+
original_text?: string | null | undefined;
|
|
50
|
+
translated_text?: string | null | undefined;
|
|
51
|
+
reply_to_message_id?: string | null | undefined;
|
|
52
|
+
media?: any;
|
|
152
53
|
}, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
source_name: string;
|
|
157
|
-
created_at: number | Date;
|
|
158
|
-
platform_id: string | number;
|
|
159
|
-
original_text_id: string | number;
|
|
160
|
-
timestamp: number | Date;
|
|
54
|
+
created_at: number;
|
|
55
|
+
updated_at: number;
|
|
56
|
+
timestamp: number;
|
|
161
57
|
text_geo: string[];
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
caption?: string | undefined;
|
|
175
|
-
}[] | undefined;
|
|
58
|
+
platform?: string | null | undefined;
|
|
59
|
+
source_id?: string | null | undefined;
|
|
60
|
+
source_public_id?: string | null | undefined;
|
|
61
|
+
source_name?: string | null | undefined;
|
|
62
|
+
source_geo?: string | null | undefined;
|
|
63
|
+
metadata?: any;
|
|
64
|
+
platform_id?: string | null | undefined;
|
|
65
|
+
original_text_id?: string | null | undefined;
|
|
66
|
+
original_text?: string | null | undefined;
|
|
67
|
+
translated_text?: string | null | undefined;
|
|
68
|
+
reply_to_message_id?: string | null | undefined;
|
|
69
|
+
media?: any;
|
|
176
70
|
}>, {}> & import("mongoose").FlatRecord<{
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
source_name: string;
|
|
181
|
-
created_at: number | Date;
|
|
182
|
-
platform_id: string | number;
|
|
183
|
-
original_text_id: string | number;
|
|
184
|
-
timestamp: number | Date;
|
|
71
|
+
created_at: number;
|
|
72
|
+
updated_at: number;
|
|
73
|
+
timestamp: number;
|
|
185
74
|
text_geo: string[];
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
caption?: string | undefined;
|
|
199
|
-
}[] | undefined;
|
|
200
|
-
}> & Required<{
|
|
201
|
-
_id: string;
|
|
75
|
+
platform?: string | null | undefined;
|
|
76
|
+
source_id?: string | null | undefined;
|
|
77
|
+
source_public_id?: string | null | undefined;
|
|
78
|
+
source_name?: string | null | undefined;
|
|
79
|
+
source_geo?: string | null | undefined;
|
|
80
|
+
metadata?: any;
|
|
81
|
+
platform_id?: string | null | undefined;
|
|
82
|
+
original_text_id?: string | null | undefined;
|
|
83
|
+
original_text?: string | null | undefined;
|
|
84
|
+
translated_text?: string | null | undefined;
|
|
85
|
+
reply_to_message_id?: string | null | undefined;
|
|
86
|
+
media?: any;
|
|
202
87
|
}> & {
|
|
88
|
+
_id: import("mongoose").Types.ObjectId;
|
|
89
|
+
} & {
|
|
203
90
|
__v: number;
|
|
204
91
|
}>;
|
|
205
92
|
export declare const MongoInstructionsSchema: Schema<{
|
package/dist/types.d.ts
CHANGED
|
@@ -70,15 +70,15 @@ export declare const zodDataSchema: z.ZodObject<{
|
|
|
70
70
|
original_text_id: z.ZodUnion<[z.ZodString, z.ZodNumber]>;
|
|
71
71
|
original_text: z.ZodOptional<z.ZodString>;
|
|
72
72
|
translated_text: z.ZodOptional<z.ZodString>;
|
|
73
|
-
timestamp: z.
|
|
73
|
+
timestamp: z.ZodNumber;
|
|
74
74
|
language: z.ZodOptional<z.ZodString>;
|
|
75
75
|
text_geo: z.ZodArray<z.ZodString, "many">;
|
|
76
76
|
source_geo: z.ZodOptional<z.ZodString>;
|
|
77
77
|
is_reply: z.ZodOptional<z.ZodBoolean>;
|
|
78
78
|
reply_to_message_id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
|
|
79
79
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
|
|
80
|
-
created_at: z.
|
|
81
|
-
updated_at: z.
|
|
80
|
+
created_at: z.ZodNumber;
|
|
81
|
+
updated_at: z.ZodNumber;
|
|
82
82
|
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
83
83
|
type: z.ZodEnum<["image", "video", "audio", "link"]>;
|
|
84
84
|
url: z.ZodString;
|
|
@@ -97,16 +97,16 @@ export declare const zodDataSchema: z.ZodObject<{
|
|
|
97
97
|
source_id: string | number;
|
|
98
98
|
source_public_id: string | number;
|
|
99
99
|
source_name: string;
|
|
100
|
-
created_at: number
|
|
100
|
+
created_at: number;
|
|
101
|
+
updated_at: number;
|
|
101
102
|
platform_id: string | number;
|
|
102
103
|
original_text_id: string | number;
|
|
103
|
-
timestamp: number
|
|
104
|
+
timestamp: number;
|
|
104
105
|
text_geo: string[];
|
|
105
106
|
_id?: string | undefined;
|
|
106
107
|
language?: string | undefined;
|
|
107
108
|
source_geo?: string | undefined;
|
|
108
109
|
metadata?: Record<string, any> | undefined;
|
|
109
|
-
updated_at?: number | Date | undefined;
|
|
110
110
|
original_text?: string | undefined;
|
|
111
111
|
translated_text?: string | undefined;
|
|
112
112
|
is_reply?: boolean | undefined;
|
|
@@ -121,16 +121,16 @@ export declare const zodDataSchema: z.ZodObject<{
|
|
|
121
121
|
source_id: string | number;
|
|
122
122
|
source_public_id: string | number;
|
|
123
123
|
source_name: string;
|
|
124
|
-
created_at: number
|
|
124
|
+
created_at: number;
|
|
125
|
+
updated_at: number;
|
|
125
126
|
platform_id: string | number;
|
|
126
127
|
original_text_id: string | number;
|
|
127
|
-
timestamp: number
|
|
128
|
+
timestamp: number;
|
|
128
129
|
text_geo: string[];
|
|
129
130
|
_id?: string | undefined;
|
|
130
131
|
language?: string | undefined;
|
|
131
132
|
source_geo?: string | undefined;
|
|
132
133
|
metadata?: Record<string, any> | undefined;
|
|
133
|
-
updated_at?: number | Date | undefined;
|
|
134
134
|
original_text?: string | undefined;
|
|
135
135
|
translated_text?: string | undefined;
|
|
136
136
|
is_reply?: boolean | undefined;
|
package/dist/types.js
CHANGED
|
@@ -48,15 +48,15 @@ exports.zodDataSchema = zod_1.z.object({
|
|
|
48
48
|
original_text_id: zod_1.z.string().or(zod_1.z.number()),
|
|
49
49
|
original_text: zod_1.z.string().optional(),
|
|
50
50
|
translated_text: zod_1.z.string().optional(),
|
|
51
|
-
timestamp: zod_1.z.
|
|
51
|
+
timestamp: zod_1.z.number(),
|
|
52
52
|
language: zod_1.z.string().optional(),
|
|
53
53
|
text_geo: zod_1.z.array(zod_1.z.string()),
|
|
54
54
|
source_geo: zod_1.z.string().optional(),
|
|
55
55
|
is_reply: zod_1.z.boolean().optional(),
|
|
56
56
|
reply_to_message_id: zod_1.z.string().or(zod_1.z.number()).optional(),
|
|
57
57
|
metadata: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
|
|
58
|
-
created_at: zod_1.z.
|
|
59
|
-
updated_at: zod_1.z.
|
|
58
|
+
created_at: zod_1.z.number(),
|
|
59
|
+
updated_at: zod_1.z.number(),
|
|
60
60
|
media: zod_1.z
|
|
61
61
|
.array(zod_1.z.object({
|
|
62
62
|
type: zod_1.z.enum(['image', 'video', 'audio', 'link']),
|
package/index.ts
CHANGED
package/package.json
CHANGED
package/types.ts
CHANGED
|
@@ -50,15 +50,15 @@ export const zodDataSchema = z.object({
|
|
|
50
50
|
original_text_id: z.string().or(z.number()), // message_id
|
|
51
51
|
original_text: z.string().optional(), // original text content
|
|
52
52
|
translated_text: z.string().optional(), // translated text if available - most of the time it will be translated to English
|
|
53
|
-
timestamp: z.
|
|
53
|
+
timestamp: z.number(), // INDEX - date in milliseconds - e.g., 1751210833000
|
|
54
54
|
language: z.string().optional(),
|
|
55
55
|
text_geo: z.array(z.string()), // INDEX - e.g., ["sinjil", "ramallah", "west bank"]
|
|
56
56
|
source_geo: z.string().optional(), // e.g., 'hebron'
|
|
57
57
|
is_reply: z.boolean().optional(), // true if this text is a reply to another text
|
|
58
58
|
reply_to_message_id: z.string().or(z.number()).optional(),
|
|
59
59
|
metadata: z.record(z.string(), z.any()).optional(), // platform-specific fields
|
|
60
|
-
created_at: z.
|
|
61
|
-
updated_at: z.
|
|
60
|
+
created_at: z.number(),
|
|
61
|
+
updated_at: z.number(),
|
|
62
62
|
media: z
|
|
63
63
|
.array(
|
|
64
64
|
z.object({
|