asfur 1.0.132 → 1.0.134
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 +46 -0
- package/dist/index.js +17 -1
- package/dist/types.d.ts +38 -0
- package/dist/types.js +14 -1
- package/index.ts +20 -0
- package/package.json +1 -1
- package/types.ts +15 -0
package/dist/index.d.ts
CHANGED
|
@@ -953,3 +953,49 @@ export declare const MongoPolygonSchema: Schema<any, import("mongoose").Model<an
|
|
|
953
953
|
} & {
|
|
954
954
|
__v: number;
|
|
955
955
|
}>;
|
|
956
|
+
export declare const MongoUserRequestSchema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, {
|
|
957
|
+
versionKey: false;
|
|
958
|
+
toJSON: {
|
|
959
|
+
virtuals: true;
|
|
960
|
+
};
|
|
961
|
+
toObject: {
|
|
962
|
+
virtuals: true;
|
|
963
|
+
};
|
|
964
|
+
}, {
|
|
965
|
+
user_id: string;
|
|
966
|
+
created_at: number;
|
|
967
|
+
updated_at: number;
|
|
968
|
+
request_type: string;
|
|
969
|
+
request: string;
|
|
970
|
+
status?: string | null | undefined;
|
|
971
|
+
title?: string | null | undefined;
|
|
972
|
+
user_name?: string | null | undefined;
|
|
973
|
+
file_url?: string | null | undefined;
|
|
974
|
+
admin_notes?: string | null | undefined;
|
|
975
|
+
}, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
|
|
976
|
+
user_id: string;
|
|
977
|
+
created_at: number;
|
|
978
|
+
updated_at: number;
|
|
979
|
+
request_type: string;
|
|
980
|
+
request: string;
|
|
981
|
+
status?: string | null | undefined;
|
|
982
|
+
title?: string | null | undefined;
|
|
983
|
+
user_name?: string | null | undefined;
|
|
984
|
+
file_url?: string | null | undefined;
|
|
985
|
+
admin_notes?: string | null | undefined;
|
|
986
|
+
}>, {}> & import("mongoose").FlatRecord<{
|
|
987
|
+
user_id: string;
|
|
988
|
+
created_at: number;
|
|
989
|
+
updated_at: number;
|
|
990
|
+
request_type: string;
|
|
991
|
+
request: string;
|
|
992
|
+
status?: string | null | undefined;
|
|
993
|
+
title?: string | null | undefined;
|
|
994
|
+
user_name?: string | null | undefined;
|
|
995
|
+
file_url?: string | null | undefined;
|
|
996
|
+
admin_notes?: string | null | undefined;
|
|
997
|
+
}> & {
|
|
998
|
+
_id: import("mongoose").Types.ObjectId;
|
|
999
|
+
} & {
|
|
1000
|
+
__v: number;
|
|
1001
|
+
}>;
|
package/dist/index.js
CHANGED
|
@@ -14,7 +14,7 @@ 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
|
-
exports.MongoPolygonSchema = exports.MongoFavoriteEventSchema = exports.MongoGeoSelectionGroupSchema = exports.MongoPredefinedQuerySchema = exports.MongoSendWhatsappSchema = exports.MongoSendEmailSchema = exports.MongoMessageSchema = exports.MongoHeatmapSchema = exports.MongoScenarioScoreSchema = exports.MongoScenarioSchema = exports.MongoNotificationSchema = exports.MongoReportSchema = exports.MongoApiKeySchema = exports.MongoJobSchema = exports.MongoConversationSchema = exports.MongoUserSettingsSchema = exports.MongoQuerySchema = exports.MongoInstructionsSchema = void 0;
|
|
17
|
+
exports.MongoUserRequestSchema = exports.MongoPolygonSchema = exports.MongoFavoriteEventSchema = exports.MongoGeoSelectionGroupSchema = exports.MongoPredefinedQuerySchema = exports.MongoSendWhatsappSchema = exports.MongoSendEmailSchema = exports.MongoMessageSchema = exports.MongoHeatmapSchema = exports.MongoScenarioScoreSchema = exports.MongoScenarioSchema = exports.MongoNotificationSchema = exports.MongoReportSchema = exports.MongoApiKeySchema = exports.MongoJobSchema = exports.MongoConversationSchema = exports.MongoUserSettingsSchema = exports.MongoQuerySchema = exports.MongoInstructionsSchema = void 0;
|
|
18
18
|
// Export types for consumers
|
|
19
19
|
__exportStar(require("./types"), exports);
|
|
20
20
|
const mongoose_1 = require("mongoose");
|
|
@@ -370,3 +370,19 @@ exports.MongoPolygonSchema = new mongoose_1.Schema({
|
|
|
370
370
|
toJSON: { virtuals: true },
|
|
371
371
|
toObject: { virtuals: true },
|
|
372
372
|
});
|
|
373
|
+
exports.MongoUserRequestSchema = new mongoose_1.Schema({
|
|
374
|
+
user_id: { type: String, required: true },
|
|
375
|
+
user_name: { type: String },
|
|
376
|
+
title: { type: String },
|
|
377
|
+
request_type: { type: String, required: true },
|
|
378
|
+
request: { type: String, required: true },
|
|
379
|
+
file_url: { type: String },
|
|
380
|
+
created_at: { type: Number, default: Date.now },
|
|
381
|
+
updated_at: { type: Number, default: Date.now },
|
|
382
|
+
status: { type: String },
|
|
383
|
+
admin_notes: { type: String }, // internal notes for admins regarding the user request
|
|
384
|
+
}, {
|
|
385
|
+
versionKey: false,
|
|
386
|
+
toJSON: { virtuals: true },
|
|
387
|
+
toObject: { virtuals: true },
|
|
388
|
+
});
|
package/dist/types.d.ts
CHANGED
|
@@ -2325,6 +2325,43 @@ export declare const zodPolygonSchema: z.ZodObject<{
|
|
|
2325
2325
|
description?: string | undefined;
|
|
2326
2326
|
color?: string | undefined;
|
|
2327
2327
|
}>;
|
|
2328
|
+
export declare const zodUserRequestSchema: z.ZodObject<{
|
|
2329
|
+
_id: z.ZodOptional<z.ZodString>;
|
|
2330
|
+
user_id: z.ZodString;
|
|
2331
|
+
user_name: z.ZodOptional<z.ZodString>;
|
|
2332
|
+
request_type: z.ZodString;
|
|
2333
|
+
title: z.ZodOptional<z.ZodString>;
|
|
2334
|
+
request: z.ZodString;
|
|
2335
|
+
file_url: z.ZodOptional<z.ZodString>;
|
|
2336
|
+
created_at: z.ZodOptional<z.ZodNumber>;
|
|
2337
|
+
updated_at: z.ZodOptional<z.ZodNumber>;
|
|
2338
|
+
status: z.ZodOptional<z.ZodString>;
|
|
2339
|
+
admin_notes: z.ZodOptional<z.ZodString>;
|
|
2340
|
+
}, "strip", z.ZodTypeAny, {
|
|
2341
|
+
user_id: string;
|
|
2342
|
+
request_type: string;
|
|
2343
|
+
request: string;
|
|
2344
|
+
status?: string | undefined;
|
|
2345
|
+
title?: string | undefined;
|
|
2346
|
+
_id?: string | undefined;
|
|
2347
|
+
created_at?: number | undefined;
|
|
2348
|
+
updated_at?: number | undefined;
|
|
2349
|
+
user_name?: string | undefined;
|
|
2350
|
+
file_url?: string | undefined;
|
|
2351
|
+
admin_notes?: string | undefined;
|
|
2352
|
+
}, {
|
|
2353
|
+
user_id: string;
|
|
2354
|
+
request_type: string;
|
|
2355
|
+
request: string;
|
|
2356
|
+
status?: string | undefined;
|
|
2357
|
+
title?: string | undefined;
|
|
2358
|
+
_id?: string | undefined;
|
|
2359
|
+
created_at?: number | undefined;
|
|
2360
|
+
updated_at?: number | undefined;
|
|
2361
|
+
user_name?: string | undefined;
|
|
2362
|
+
file_url?: string | undefined;
|
|
2363
|
+
admin_notes?: string | undefined;
|
|
2364
|
+
}>;
|
|
2328
2365
|
/**
|
|
2329
2366
|
* 'approved' - active and approved sources,
|
|
2330
2367
|
* 'back_to_business' - sources that were paused and now resumed,
|
|
@@ -2355,6 +2392,7 @@ export type PredefinedQueryType = z.infer<typeof zodPredefinedQuerySchema>;
|
|
|
2355
2392
|
export type GeoSelectionGroupType = z.infer<typeof zodGeoSelectionGroupSchema>;
|
|
2356
2393
|
export type FavoriteEventType = z.infer<typeof zodFavoriteEventSchema>;
|
|
2357
2394
|
export type PolygonType = z.infer<typeof zodPolygonSchema>;
|
|
2395
|
+
export type UserRequestType = z.infer<typeof zodUserRequestSchema>;
|
|
2358
2396
|
export type UserPublicMetadata = {
|
|
2359
2397
|
is_admin?: boolean;
|
|
2360
2398
|
regions?: {
|
package/dist/types.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.zodPolygonSchema = exports.zodFavoriteEventSchema = exports.zodGeoSelectionGroupSchema = exports.zodPredefinedQuerySchema = exports.zodSendWhatsappSchema = exports.zodSendEmailSchema = exports.zodScenarioSchema = exports.zodScenarioScoreSchema = exports.scenarioScoreTypeList = exports.zodNotificationSchema = exports.notificationPriorityList = exports.zodReportSchema = exports.reportProcessStatusList = exports.zodApiKeySchema = exports.zodCronScheduleResponseSchema = exports.zodMessageSchema = exports.zodHeatmapSchema = exports.zodJobSchema = exports.zodConversationSchema = exports.zodUserSettingsSchema = exports.zodInstructionsSchema = exports.zodQuerySchema = exports.zodAlertSchema = exports.zodAbsoluteTimeRangeSchema = exports.zodRelativeTimeRangeSchema = exports.requestedContentList = exports.relativeTimeRangeList = exports.jobRunStatusList = exports.generalStatusList = void 0;
|
|
3
|
+
exports.zodUserRequestSchema = exports.zodPolygonSchema = exports.zodFavoriteEventSchema = exports.zodGeoSelectionGroupSchema = exports.zodPredefinedQuerySchema = exports.zodSendWhatsappSchema = exports.zodSendEmailSchema = exports.zodScenarioSchema = exports.zodScenarioScoreSchema = exports.scenarioScoreTypeList = exports.zodNotificationSchema = exports.notificationPriorityList = exports.zodReportSchema = exports.reportProcessStatusList = exports.zodApiKeySchema = exports.zodCronScheduleResponseSchema = exports.zodMessageSchema = exports.zodHeatmapSchema = exports.zodJobSchema = exports.zodConversationSchema = exports.zodUserSettingsSchema = exports.zodInstructionsSchema = exports.zodQuerySchema = exports.zodAlertSchema = exports.zodAbsoluteTimeRangeSchema = exports.zodRelativeTimeRangeSchema = exports.requestedContentList = exports.relativeTimeRangeList = exports.jobRunStatusList = exports.generalStatusList = void 0;
|
|
4
4
|
const harvester_sdk_1 = require("harvester_sdk");
|
|
5
5
|
const zod_1 = require("zod");
|
|
6
6
|
exports.generalStatusList = ['active', 'inactive'];
|
|
@@ -341,3 +341,16 @@ exports.zodPolygonSchema = zod_1.z.object({
|
|
|
341
341
|
updated_at: zod_1.z.number().optional(),
|
|
342
342
|
color: zod_1.z.string().optional(), // optional color for displaying the polygon on the map
|
|
343
343
|
});
|
|
344
|
+
exports.zodUserRequestSchema = zod_1.z.object({
|
|
345
|
+
_id: zod_1.z.string().optional(),
|
|
346
|
+
user_id: zod_1.z.string(),
|
|
347
|
+
user_name: zod_1.z.string().optional(),
|
|
348
|
+
request_type: zod_1.z.string(),
|
|
349
|
+
title: zod_1.z.string().optional(),
|
|
350
|
+
request: zod_1.z.string(),
|
|
351
|
+
file_url: zod_1.z.string().url().optional(),
|
|
352
|
+
created_at: zod_1.z.number().optional(),
|
|
353
|
+
updated_at: zod_1.z.number().optional(),
|
|
354
|
+
status: zod_1.z.string().optional(),
|
|
355
|
+
admin_notes: zod_1.z.string().optional(), // internal notes for admins regarding the user request
|
|
356
|
+
});
|
package/index.ts
CHANGED
|
@@ -432,4 +432,24 @@ export const MongoPolygonSchema = new Schema(
|
|
|
432
432
|
},
|
|
433
433
|
);
|
|
434
434
|
|
|
435
|
+
export const MongoUserRequestSchema = new Schema(
|
|
436
|
+
{
|
|
437
|
+
user_id: { type: String, required: true }, // user identifier
|
|
438
|
+
user_name: { type: String }, // optional user name for better understanding of the request context
|
|
439
|
+
title: { type: String }, // optional title for the user request or feedback
|
|
440
|
+
request_type: { type: String, required: true },
|
|
441
|
+
request: { type: String, required: true }, // user request or feedback
|
|
442
|
+
file_url: { type: String }, // optional URL for any file attached to the request
|
|
443
|
+
created_at: { type: Number, default: Date.now }, // creation date
|
|
444
|
+
updated_at: { type: Number, default: Date.now }, // last update date
|
|
445
|
+
status: { type: String }, // status of the user request (e.g., "pending", "in_progress", "resolved")
|
|
446
|
+
admin_notes: { type: String }, // internal notes for admins regarding the user request
|
|
447
|
+
},
|
|
448
|
+
{
|
|
449
|
+
versionKey: false,
|
|
450
|
+
toJSON: { virtuals: true },
|
|
451
|
+
toObject: { virtuals: true },
|
|
452
|
+
},
|
|
453
|
+
);
|
|
454
|
+
|
|
435
455
|
|
package/package.json
CHANGED
package/types.ts
CHANGED
|
@@ -398,6 +398,20 @@ export const zodPolygonSchema = z.object({
|
|
|
398
398
|
color: z.string().optional(), // optional color for displaying the polygon on the map
|
|
399
399
|
});
|
|
400
400
|
|
|
401
|
+
export const zodUserRequestSchema = z.object({
|
|
402
|
+
_id: z.string().optional(),
|
|
403
|
+
user_id: z.string(), // user identifier
|
|
404
|
+
user_name: z.string().optional(), // optional user name for better understanding of the request context
|
|
405
|
+
request_type: z.string(),
|
|
406
|
+
title: z.string().optional(), // optional title for the user request or feedback
|
|
407
|
+
request: z.string(), // user request or feedback
|
|
408
|
+
file_url: z.string().url().optional(), // optional URL for any file attached to the request
|
|
409
|
+
created_at: z.number().optional(), // creation date
|
|
410
|
+
updated_at: z.number().optional(), // last update date
|
|
411
|
+
status: z.string().optional(), // status of the user request (e.g., "pending", "in_progress", "resolved")
|
|
412
|
+
admin_notes: z.string().optional(), // internal notes for admins regarding the user request
|
|
413
|
+
});
|
|
414
|
+
|
|
401
415
|
/**
|
|
402
416
|
* 'approved' - active and approved sources,
|
|
403
417
|
* 'back_to_business' - sources that were paused and now resumed,
|
|
@@ -433,6 +447,7 @@ export type PredefinedQueryType = z.infer<typeof zodPredefinedQuerySchema>;
|
|
|
433
447
|
export type GeoSelectionGroupType = z.infer<typeof zodGeoSelectionGroupSchema>;
|
|
434
448
|
export type FavoriteEventType = z.infer<typeof zodFavoriteEventSchema>;
|
|
435
449
|
export type PolygonType = z.infer<typeof zodPolygonSchema>;
|
|
450
|
+
export type UserRequestType = z.infer<typeof zodUserRequestSchema>;
|
|
436
451
|
|
|
437
452
|
export type UserPublicMetadata = {
|
|
438
453
|
is_admin?: boolean;
|