@timardex/cluemart-server-shared 2.5.0 → 3.0.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/{Affiliate-zioeZDyH.d.ts → Affiliate-CpoM9_Bb.d.mts} +7 -1
- package/dist/{Affiliate-DIAzxxfs.d.mts → Affiliate-YoKkDGxN.d.ts} +7 -1
- package/dist/{chunk-TMPPPLIW.mjs → chunk-F54NB7VH.mjs} +1 -1
- package/dist/chunk-F54NB7VH.mjs.map +1 -0
- package/dist/{chunk-T5TP2XMR.mjs → chunk-YMDOR6W2.mjs} +248 -234
- package/dist/chunk-YMDOR6W2.mjs.map +1 -0
- package/dist/{index-CmtBYjpi.d.mts → index-BptxBl9x.d.mts} +8 -1
- package/dist/{index-CmtBYjpi.d.ts → index-BptxBl9x.d.ts} +8 -1
- package/dist/index.cjs +249 -236
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +47 -20
- package/dist/index.d.ts +47 -20
- package/dist/index.mjs +247 -233
- package/dist/index.mjs.map +1 -1
- package/dist/mongoose/index.cjs +249 -236
- package/dist/mongoose/index.cjs.map +1 -1
- package/dist/mongoose/index.d.mts +38 -24
- package/dist/mongoose/index.d.ts +38 -24
- package/dist/mongoose/index.mjs +3 -5
- package/dist/service/index.cjs +247 -228
- package/dist/service/index.cjs.map +1 -1
- package/dist/service/index.d.mts +2 -2
- package/dist/service/index.d.ts +2 -2
- package/dist/service/index.mjs +2 -2
- package/dist/types/index.cjs.map +1 -1
- package/dist/types/index.d.mts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.mjs +1 -1
- package/package.json +2 -2
- package/dist/chunk-T5TP2XMR.mjs.map +0 -1
- package/dist/chunk-TMPPPLIW.mjs.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as _timardex_cluemart_shared from '@timardex/cluemart-shared';
|
|
2
2
|
import { OwnerType, Category, ResourceContactDetailsType, ResourceImageType, RelatedPostType, SocialMediaType, PosterUsageType, SocialShareResourceType, TermsAgreement, DateTimeType, LocationGeoType, LocationType, UserLicenceType, RelationType, RelationDate, StripeSubscription, EnumBillingPeriod, EnumUserLicence, UserActivityEvent, UserType, AffiliateType, AffiliateResourceType, AffiliateRewardType } from '@timardex/cluemart-shared';
|
|
3
3
|
import mongoose__default from 'mongoose';
|
|
4
|
-
import { O as ObjectId } from './index-
|
|
4
|
+
import { O as ObjectId } from './index-BptxBl9x.mjs';
|
|
5
5
|
|
|
6
6
|
type SchemaRelatedPostType = Omit<RelatedPostType, "postId"> & {
|
|
7
7
|
postId: ObjectId;
|
|
@@ -352,6 +352,9 @@ type SchemaUserType = Omit<UserType, "vendor" | "coupon" | "events" | "partner"
|
|
|
352
352
|
events: ObjectId[];
|
|
353
353
|
game: ObjectId;
|
|
354
354
|
partner: ObjectId;
|
|
355
|
+
/** Server-only hashed refresh tokens; never exposed to clients. */
|
|
356
|
+
refreshTokenAdmin?: string | null;
|
|
357
|
+
refreshTokenMobile?: string | null;
|
|
355
358
|
school: ObjectId;
|
|
356
359
|
stripe?: SchemaStripeSubscription;
|
|
357
360
|
vendor: ObjectId;
|
|
@@ -393,6 +396,9 @@ declare const UserModel: mongoose__default.Model<SchemaUserType, {}, {}, {}, mon
|
|
|
393
396
|
events: ObjectId[];
|
|
394
397
|
game: ObjectId;
|
|
395
398
|
partner: ObjectId;
|
|
399
|
+
/** Server-only hashed refresh tokens; never exposed to clients. */
|
|
400
|
+
refreshTokenAdmin?: string | null;
|
|
401
|
+
refreshTokenMobile?: string | null;
|
|
396
402
|
school: ObjectId;
|
|
397
403
|
stripe?: SchemaStripeSubscription;
|
|
398
404
|
vendor: ObjectId;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as _timardex_cluemart_shared from '@timardex/cluemart-shared';
|
|
2
2
|
import { OwnerType, Category, ResourceContactDetailsType, ResourceImageType, RelatedPostType, SocialMediaType, PosterUsageType, SocialShareResourceType, TermsAgreement, DateTimeType, LocationGeoType, LocationType, UserLicenceType, RelationType, RelationDate, StripeSubscription, EnumBillingPeriod, EnumUserLicence, UserActivityEvent, UserType, AffiliateType, AffiliateResourceType, AffiliateRewardType } from '@timardex/cluemart-shared';
|
|
3
3
|
import mongoose__default from 'mongoose';
|
|
4
|
-
import { O as ObjectId } from './index-
|
|
4
|
+
import { O as ObjectId } from './index-BptxBl9x.js';
|
|
5
5
|
|
|
6
6
|
type SchemaRelatedPostType = Omit<RelatedPostType, "postId"> & {
|
|
7
7
|
postId: ObjectId;
|
|
@@ -352,6 +352,9 @@ type SchemaUserType = Omit<UserType, "vendor" | "coupon" | "events" | "partner"
|
|
|
352
352
|
events: ObjectId[];
|
|
353
353
|
game: ObjectId;
|
|
354
354
|
partner: ObjectId;
|
|
355
|
+
/** Server-only hashed refresh tokens; never exposed to clients. */
|
|
356
|
+
refreshTokenAdmin?: string | null;
|
|
357
|
+
refreshTokenMobile?: string | null;
|
|
355
358
|
school: ObjectId;
|
|
356
359
|
stripe?: SchemaStripeSubscription;
|
|
357
360
|
vendor: ObjectId;
|
|
@@ -393,6 +396,9 @@ declare const UserModel: mongoose__default.Model<SchemaUserType, {}, {}, {}, mon
|
|
|
393
396
|
events: ObjectId[];
|
|
394
397
|
game: ObjectId;
|
|
395
398
|
partner: ObjectId;
|
|
399
|
+
/** Server-only hashed refresh tokens; never exposed to clients. */
|
|
400
|
+
refreshTokenAdmin?: string | null;
|
|
401
|
+
refreshTokenMobile?: string | null;
|
|
396
402
|
school: ObjectId;
|
|
397
403
|
stripe?: SchemaStripeSubscription;
|
|
398
404
|
vendor: ObjectId;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/types/index.ts"],"sourcesContent":["import { EnumUserRole } from \"@timardex/cluemart-shared\";\nimport { NotificationCount } from \"@timardex/cluemart-shared/types\";\nimport express from \"express\";\nimport mongoose from \"mongoose\";\n\nimport { SchemaChatType } from \"../mongoose/chat/Chat\";\nimport { SchemaNotificationType } from \"../mongoose/Notification\";\n\n// chnage to export type ObjectId = mongoose.Types.ObjectId;\n// chnage in server when setting decideGameType\nexport type ObjectId = mongoose.Types.ObjectId;\n\nexport enum EnumPubSubEvents {\n GET_CHAT_MESSAGE = \"GET_CHAT_MESSAGE\",\n GET_NOTIFICATIONS = \"GET_NOTIFICATIONS\",\n GET_NOTIFICATIONS_COUNT = \"GET_NOTIFICATIONS_COUNT\",\n USER_TYPING = \"USER_TYPING\",\n}\n\n/** Clients that own their own refresh-token slot on the user document. */\nexport type AuthTokenClient = \"mobile\" | \"admin\";\n\nexport interface AuthUser {\n email: string;\n roles: EnumUserRole[];\n userId: ObjectId;\n /**\n * Which client slot this token belongs to. Absent only on tokens issued\n * before the per-client rollout; those can no longer refresh.\n */\n client?: AuthTokenClient;\n /** Set when this token represents an impersonation session. */\n impersonationSessionId?: string;\n /** The SUPER_ADMIN who started the impersonation session. */\n impersonatorUserId?: ObjectId;\n}\n\nexport interface SubscriptionPayload {\n getChatMessage?: SchemaChatType;\n userTyping?: SchemaChatType; // NOT USED\n getNotifications?: SchemaNotificationType[];\n // Used only for filtering; not part of the GraphQL schema output\n getNotificationsUserId?: ObjectId;\n getNotificationsCount?: NotificationCount & { userId: ObjectId };\n}\n\nexport interface GraphQLContext {\n appVersion: string | null;\n user: AuthUser | null;\n pubsub: {\n publish: (\n eventName: EnumPubSubEvents,\n payload: SubscriptionPayload,\n ) => void;\n subscribe: (eventName: EnumPubSubEvents) => AsyncIterable<any>;\n };\n request: express.Request;\n response: express.Response;\n}\n\nexport { mongoose, express };\n"],"mappings":";AAEA,OAAO,aAAa;AACpB,OAAO,cAAc;AASd,IAAK,mBAAL,kBAAKA,sBAAL;AACL,EAAAA,kBAAA,sBAAmB;AACnB,EAAAA,kBAAA,uBAAoB;AACpB,EAAAA,kBAAA,6BAA0B;AAC1B,EAAAA,kBAAA,iBAAc;AAJJ,SAAAA;AAAA,GAAA;","names":["EnumPubSubEvents"]}
|