@kimdaegyu/babmukdang-shared 1.1.4 → 1.1.11
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/{chunk-U6OQQOPN.js → chunk-4E5E3PFW.js} +6 -2
- package/dist/{chunk-VAWYU5JG.js → chunk-AI2YMBJX.js} +4 -1
- package/dist/{chunk-RLVHDFEV.js → chunk-K3CZKI2F.js} +7 -4
- package/dist/{chunk-J76VB5SE.js → chunk-OJVXYCSH.js} +2 -3
- package/dist/{chunk-M5OSCHMV.js → chunk-PQMEXOPZ.js} +55 -6
- package/dist/{chunk-UJJMW7II.js → chunk-W4C7XHTX.js} +1 -1
- package/dist/{chunk-W3YQYI4R.js → chunk-W4TUW2GY.js} +2 -2
- package/dist/{chunk-23FZ4MAS.js → chunk-WNYCCQM4.js} +49 -33
- package/dist/{chunk-SOHYA6XL.js → chunk-YM7YU7IR.js} +102 -87
- package/dist/{chunk-KRVEQVRC.js → chunk-ZH7D7B2Y.js} +10 -4
- package/dist/domain/article/index.cjs +12 -5
- package/dist/domain/article/index.d.cts +11 -3
- package/dist/domain/article/index.d.ts +11 -3
- package/dist/domain/article/index.js +6 -4
- package/dist/domain/auth/index.cjs +7 -4
- package/dist/domain/auth/index.d.cts +0 -3
- package/dist/domain/auth/index.d.ts +0 -3
- package/dist/domain/auth/index.js +2 -2
- package/dist/domain/common/index.cjs +243 -181
- package/dist/domain/common/index.d.cts +370 -120
- package/dist/domain/common/index.d.ts +370 -120
- package/dist/domain/common/index.js +12 -11
- package/dist/domain/friend/index.cjs +14 -4
- package/dist/domain/friend/index.d.cts +15 -1
- package/dist/domain/friend/index.d.ts +15 -1
- package/dist/domain/friend/index.js +8 -4
- package/dist/domain/index.cjs +261 -183
- package/dist/domain/index.d.cts +315 -13
- package/dist/domain/index.d.ts +315 -13
- package/dist/domain/index.js +51 -35
- package/dist/domain/meal/index.cjs +6 -2
- package/dist/domain/meal/index.js +3 -3
- package/dist/domain/member/index.cjs +12 -6
- package/dist/domain/member/index.d.cts +11 -3
- package/dist/domain/member/index.d.ts +11 -3
- package/dist/domain/member/index.js +7 -5
- package/dist/domain/plan/index.cjs +55 -6
- package/dist/domain/plan/index.d.cts +2 -2
- package/dist/domain/plan/index.d.ts +2 -2
- package/dist/domain/plan/index.js +4 -4
- package/dist/domain/promotion/index.cjs +4 -1
- package/dist/domain/promotion/index.d.cts +49 -5
- package/dist/domain/promotion/index.d.ts +49 -5
- package/dist/domain/promotion/index.js +1 -1
- package/dist/domain/recruit/index.cjs +11 -3
- package/dist/domain/recruit/index.d.cts +160 -76
- package/dist/domain/recruit/index.d.ts +160 -76
- package/dist/domain/recruit/index.js +11 -10
- package/dist/domain/restaurant/index.d.cts +1 -75
- package/dist/domain/restaurant/index.d.ts +1 -75
- package/dist/domain/room/index.cjs +63 -6
- package/dist/domain/room/index.d.cts +1192 -31
- package/dist/domain/room/index.d.ts +1192 -31
- package/dist/domain/room/index.js +11 -3
- package/dist/index.cjs +251 -359
- package/dist/index.d.cts +15 -281
- package/dist/index.d.ts +15 -281
- package/dist/index.js +12 -188
- package/dist/restaurant.schema-CuEcX3S3.d.cts +78 -0
- package/dist/restaurant.schema-CuEcX3S3.d.ts +78 -0
- package/package.json +1 -1
- package/dist/index-CZT6irsm.d.cts +0 -294
- package/dist/index-DDLVbMTB.d.ts +0 -294
package/dist/domain/index.cjs
CHANGED
|
@@ -76,6 +76,8 @@ __export(domain_exports, {
|
|
|
76
76
|
FriendRequestItemResponseSchema: () => FriendRequestItemResponseSchema,
|
|
77
77
|
FriendRequestMemberSchema: () => FriendRequestMemberSchema,
|
|
78
78
|
FriendRequestStatusSchema: () => FriendRequestStatusSchema,
|
|
79
|
+
FriendSearchQuerySchema: () => FriendSearchQuerySchema,
|
|
80
|
+
FriendSearchResponseSchema: () => FriendSearchResponseSchema,
|
|
79
81
|
ISODateStringSchema: () => ISODateStringSchema,
|
|
80
82
|
ISODateTimeStringSchema: () => ISODateTimeStringSchema,
|
|
81
83
|
InvitationIdSchema: () => InvitationIdSchema,
|
|
@@ -87,6 +89,8 @@ __export(domain_exports, {
|
|
|
87
89
|
LocationCandidateVoteUpdateResponseSchema: () => LocationCandidateVoteUpdateResponseSchema,
|
|
88
90
|
LocationIdSchema: () => LocationIdSchema,
|
|
89
91
|
LoginRequestSchema: () => LoginRequestSchema,
|
|
92
|
+
MatchingNotificationKindSchema: () => MatchingNotificationKindSchema,
|
|
93
|
+
MatchingNotificationSchema: () => MatchingNotificationSchema,
|
|
90
94
|
MealStatusActionSchema: () => MealStatusActionSchema,
|
|
91
95
|
MealStatusResponseSchema: () => MealStatusResponseSchema,
|
|
92
96
|
MealStatusSchema: () => MealStatusSchema,
|
|
@@ -122,8 +126,6 @@ __export(domain_exports, {
|
|
|
122
126
|
PlanStatusSchema: () => PlanStatusSchema,
|
|
123
127
|
PlanTypeSchema: () => PlanTypeSchema,
|
|
124
128
|
PositiveIntIdSchema: () => PositiveIntIdSchema,
|
|
125
|
-
PresignArticleResponseSchema: () => PresignArticleResponseSchema,
|
|
126
|
-
PresignProfileResponseSchema: () => PresignProfileResponseSchema,
|
|
127
129
|
ProfileDetailResponseSchema: () => ProfileDetailResponseSchema,
|
|
128
130
|
ReadyStateChangedSchema: () => ReadyStateChangedSchema,
|
|
129
131
|
ReadyStateRequestSchema: () => ReadyStateRequestSchema,
|
|
@@ -140,12 +142,14 @@ __export(domain_exports, {
|
|
|
140
142
|
RestaurantIdSchema: () => RestaurantIdSchema,
|
|
141
143
|
RestaurantPickUpdateResponseSchema: () => RestaurantPickUpdateResponseSchema,
|
|
142
144
|
RestaurantSchema: () => RestaurantSchema,
|
|
145
|
+
RoomAccessResponseSchema: () => RoomAccessResponseSchema,
|
|
143
146
|
RoomAssignedResponseSchema: () => RoomAssignedResponseSchema,
|
|
144
147
|
RoomIdSchema: () => RoomIdSchema,
|
|
145
148
|
RoomInitialStateSchema: () => RoomInitialStateSchema,
|
|
146
149
|
RoomSocketClientEventSchemas: () => RoomSocketClientEventSchemas,
|
|
147
150
|
RoomSocketErrorSchema: () => RoomSocketErrorSchema,
|
|
148
151
|
RoomSocketServerEventSchemas: () => RoomSocketServerEventSchemas,
|
|
152
|
+
RoomTypeSchema: () => RoomTypeSchema,
|
|
149
153
|
SendInvitationResponseSchema: () => SendInvitationResponseSchema,
|
|
150
154
|
SignupRequestSchema: () => SignupRequestSchema,
|
|
151
155
|
SignupResponseSchema: () => SignupResponseSchema,
|
|
@@ -157,6 +161,10 @@ __export(domain_exports, {
|
|
|
157
161
|
UpdateMealStatusRequestSchema: () => UpdateMealStatusRequestSchema,
|
|
158
162
|
UpdatePreferenceRequestSchema: () => UpdatePreferenceRequestSchema,
|
|
159
163
|
UpdateProfileRequestSchema: () => UpdateProfileRequestSchema,
|
|
164
|
+
UploadArticleImageRequestSchema: () => UploadArticleImageRequestSchema,
|
|
165
|
+
UploadArticleImageResponseSchema: () => UploadArticleImageResponseSchema,
|
|
166
|
+
UploadProfileImageRequestSchema: () => UploadProfileImageRequestSchema,
|
|
167
|
+
UploadProfileImageResponseSchema: () => UploadProfileImageResponseSchema,
|
|
160
168
|
UserIdSchema: () => UserIdSchema,
|
|
161
169
|
VoteLocationRequestSchema: () => VoteLocationRequestSchema,
|
|
162
170
|
apiContract: () => apiContract,
|
|
@@ -237,11 +245,14 @@ var import_zod5 = require("zod");
|
|
|
237
245
|
|
|
238
246
|
// src/domain/common/contracts/upload.ts
|
|
239
247
|
var import_zod4 = __toESM(require("zod"), 1);
|
|
240
|
-
var
|
|
248
|
+
var UploadPresignImageResponseSchema = import_zod4.default.object({
|
|
241
249
|
key: import_zod4.default.string(),
|
|
242
250
|
putUrl: import_zod4.default.string().url(),
|
|
243
251
|
cdnUrl: import_zod4.default.string().url()
|
|
244
252
|
});
|
|
253
|
+
var UploadPresignImageRequestSchema = import_zod4.default.object({
|
|
254
|
+
contentType: import_zod4.default.string()
|
|
255
|
+
});
|
|
245
256
|
|
|
246
257
|
// src/domain/member/member.schema.ts
|
|
247
258
|
var MemberRoleSchema = import_zod5.z.enum(["USER", "ADMIN"]);
|
|
@@ -250,7 +261,8 @@ var MemberCoreSchema = import_zod5.z.object({
|
|
|
250
261
|
username: import_zod5.z.string().min(1).max(50),
|
|
251
262
|
profileImageUrl: import_zod5.z.string().url().nullable().optional()
|
|
252
263
|
});
|
|
253
|
-
var
|
|
264
|
+
var UploadProfileImageResponseSchema = UploadPresignImageResponseSchema.extend({});
|
|
265
|
+
var UploadProfileImageRequestSchema = UploadPresignImageRequestSchema.extend({});
|
|
254
266
|
var MemberResponseSchema = MemberCoreSchema.pick({
|
|
255
267
|
memberId: true,
|
|
256
268
|
username: true,
|
|
@@ -319,7 +331,8 @@ var ArticleListQuerySchema = PageQuerySchema.extend({
|
|
|
319
331
|
sortBy: ArticleSortBySchema.optional().default("createdAt"),
|
|
320
332
|
direction: SortDirectionSchema.optional().default("desc")
|
|
321
333
|
});
|
|
322
|
-
var
|
|
334
|
+
var UploadArticleImageResponseSchema = UploadPresignImageResponseSchema.extend({});
|
|
335
|
+
var UploadArticleImageRequestSchema = UploadPresignImageRequestSchema.extend({});
|
|
323
336
|
var FoodAnalysisResultSchema = FoodSchema.extend({
|
|
324
337
|
confidence: import_zod7.z.number().min(0).max(1),
|
|
325
338
|
tsUtc: ISODateTimeStringSchema.optional()
|
|
@@ -371,8 +384,7 @@ var PageArticleSummaryResponseSchema = PageResponseSchema(ArticleSummaryResponse
|
|
|
371
384
|
// src/domain/auth/auth.schema.ts
|
|
372
385
|
var import_zod8 = require("zod");
|
|
373
386
|
var TokenResponseSchema = import_zod8.z.object({
|
|
374
|
-
accessToken: import_zod8.z.string().min(1)
|
|
375
|
-
accessTokenMaxAge: import_zod8.z.number().int().positive()
|
|
387
|
+
accessToken: import_zod8.z.string().min(1)
|
|
376
388
|
});
|
|
377
389
|
var LoginRequestSchema = import_zod8.z.object({
|
|
378
390
|
email: import_zod8.z.string().email(),
|
|
@@ -389,7 +401,7 @@ var SignupResponseSchema = import_zod8.z.object({
|
|
|
389
401
|
});
|
|
390
402
|
|
|
391
403
|
// src/domain/common/contracts/api.ts
|
|
392
|
-
var
|
|
404
|
+
var import_zod20 = require("zod");
|
|
393
405
|
|
|
394
406
|
// src/domain/promotion/challenge.schema.ts
|
|
395
407
|
var import_zod9 = require("zod");
|
|
@@ -404,7 +416,10 @@ var MonthProgressSchema = import_zod9.z.object({
|
|
|
404
416
|
goal: import_zod9.z.number().int().positive()
|
|
405
417
|
});
|
|
406
418
|
var ChallengeStatusResponseSchema = import_zod9.z.object({
|
|
407
|
-
|
|
419
|
+
week: WeekProgressSchema,
|
|
420
|
+
month: MonthProgressSchema,
|
|
421
|
+
weekRewardAvailable: import_zod9.z.boolean(),
|
|
422
|
+
monthRewardAvailable: import_zod9.z.boolean()
|
|
408
423
|
});
|
|
409
424
|
var ClaimChallengeRewardRequestSchema = import_zod9.z.object({
|
|
410
425
|
type: RewardTypeSchema
|
|
@@ -414,9 +429,35 @@ var ClaimChallengeRewardResponseSchema = import_zod9.z.object({
|
|
|
414
429
|
claimed: import_zod9.z.boolean()
|
|
415
430
|
});
|
|
416
431
|
|
|
417
|
-
// src/domain/
|
|
432
|
+
// src/domain/common/schema/envelope.schema.ts
|
|
418
433
|
var import_zod10 = require("zod");
|
|
419
|
-
var
|
|
434
|
+
var NoContentSchema = import_zod10.z.null();
|
|
435
|
+
var ApiSuccessSchema = (data) => import_zod10.z.object({
|
|
436
|
+
success: import_zod10.z.literal(true),
|
|
437
|
+
code: import_zod10.z.number().int(),
|
|
438
|
+
message: import_zod10.z.string(),
|
|
439
|
+
data
|
|
440
|
+
});
|
|
441
|
+
var ApiFailureSchema = import_zod10.z.object({
|
|
442
|
+
success: import_zod10.z.literal(false),
|
|
443
|
+
status: import_zod10.z.number().int(),
|
|
444
|
+
code: import_zod10.z.string(),
|
|
445
|
+
message: import_zod10.z.string()
|
|
446
|
+
});
|
|
447
|
+
var ApiResponseSchema = (data) => import_zod10.z.union([ApiSuccessSchema(data), ApiFailureSchema]);
|
|
448
|
+
var CreatedEntityIdResponseSchema = import_zod10.z.discriminatedUnion("entity", [
|
|
449
|
+
import_zod10.z.object({ entity: import_zod10.z.literal("article"), id: ArticleIdSchema }),
|
|
450
|
+
import_zod10.z.object({ entity: import_zod10.z.literal("comment"), id: CommentIdSchema }),
|
|
451
|
+
import_zod10.z.object({ entity: import_zod10.z.literal("recruit"), id: RecruitIdSchema }),
|
|
452
|
+
import_zod10.z.object({ entity: import_zod10.z.literal("invitation"), id: InvitationIdSchema }),
|
|
453
|
+
import_zod10.z.object({ entity: import_zod10.z.literal("subscription"), id: SubscriptionIdSchema }),
|
|
454
|
+
import_zod10.z.object({ entity: import_zod10.z.literal("coupon"), id: CouponIdSchema }),
|
|
455
|
+
import_zod10.z.object({ entity: import_zod10.z.literal("plan"), id: PlanIdSchema })
|
|
456
|
+
]);
|
|
457
|
+
|
|
458
|
+
// src/domain/friend/friend.schema.ts
|
|
459
|
+
var import_zod11 = require("zod");
|
|
460
|
+
var FriendRequestStatusSchema = import_zod11.z.enum(["PENDING", "ACCEPTED", "REJECTED", "CANCELED"]);
|
|
420
461
|
var FriendListItemResponseSchema = MemberCoreSchema.extend({
|
|
421
462
|
friendSince: ISODateTimeStringSchema
|
|
422
463
|
});
|
|
@@ -424,77 +465,79 @@ var FriendBlockItemResponseSchema = MemberCoreSchema.extend({
|
|
|
424
465
|
blockedAt: ISODateTimeStringSchema
|
|
425
466
|
});
|
|
426
467
|
var FriendRequestMemberSchema = MemberCoreSchema;
|
|
427
|
-
var FriendRequestItemResponseSchema =
|
|
468
|
+
var FriendRequestItemResponseSchema = import_zod11.z.object({
|
|
428
469
|
requestId: FriendRequestIdSchema,
|
|
429
470
|
requester: FriendRequestMemberSchema,
|
|
430
471
|
recipient: FriendRequestMemberSchema,
|
|
431
472
|
status: FriendRequestStatusSchema,
|
|
432
473
|
requestedAt: ISODateTimeStringSchema
|
|
433
474
|
});
|
|
475
|
+
var FriendSearchQuerySchema = import_zod11.z.string().min(1).max(50);
|
|
476
|
+
var FriendSearchResponseSchema = import_zod11.z.array(MemberCoreSchema);
|
|
434
477
|
|
|
435
478
|
// src/domain/invitation/invitation.schema.ts
|
|
436
|
-
var
|
|
437
|
-
var CreateInvitationRequestSchema =
|
|
479
|
+
var import_zod12 = require("zod");
|
|
480
|
+
var CreateInvitationRequestSchema = import_zod12.z.object({
|
|
438
481
|
inviteeId: MemberIdSchema,
|
|
439
|
-
message:
|
|
482
|
+
message: import_zod12.z.string().min(1).max(500)
|
|
440
483
|
});
|
|
441
|
-
var InvitationListItemResponseSchema =
|
|
484
|
+
var InvitationListItemResponseSchema = import_zod12.z.object({
|
|
442
485
|
invitationId: InvitationIdSchema,
|
|
443
|
-
inviterName:
|
|
444
|
-
inviterProfileImageUrl:
|
|
486
|
+
inviterName: import_zod12.z.string(),
|
|
487
|
+
inviterProfileImageUrl: import_zod12.z.string().url().nullable().optional()
|
|
445
488
|
});
|
|
446
|
-
var SendInvitationResponseSchema =
|
|
489
|
+
var SendInvitationResponseSchema = import_zod12.z.object({
|
|
447
490
|
invitationId: InvitationIdSchema
|
|
448
491
|
});
|
|
449
|
-
var AcceptInvitationResponseSchema =
|
|
492
|
+
var AcceptInvitationResponseSchema = import_zod12.z.object({
|
|
450
493
|
invitationId: InvitationIdSchema,
|
|
451
|
-
room:
|
|
452
|
-
type:
|
|
494
|
+
room: import_zod12.z.object({
|
|
495
|
+
type: import_zod12.z.literal("invitation"),
|
|
453
496
|
roomId: RoomIdSchema
|
|
454
497
|
})
|
|
455
498
|
});
|
|
456
499
|
|
|
457
500
|
// src/domain/meal/meal.schema.ts
|
|
458
|
-
var
|
|
459
|
-
var MealStatusResponseSchema =
|
|
460
|
-
hungry:
|
|
461
|
-
label:
|
|
501
|
+
var import_zod13 = require("zod");
|
|
502
|
+
var MealStatusResponseSchema = import_zod13.z.object({
|
|
503
|
+
hungry: import_zod13.z.boolean(),
|
|
504
|
+
label: import_zod13.z.string(),
|
|
462
505
|
updatedAt: ISODateStringSchema,
|
|
463
|
-
secondsToAutoOff:
|
|
506
|
+
secondsToAutoOff: import_zod13.z.number().int().min(0)
|
|
464
507
|
});
|
|
465
|
-
var MealStatusActionSchema =
|
|
466
|
-
var UpdateMealStatusRequestSchema =
|
|
508
|
+
var MealStatusActionSchema = import_zod13.z.enum(["ARTICLE_UPLOAD", "SET_MANNUALY"]);
|
|
509
|
+
var UpdateMealStatusRequestSchema = import_zod13.z.object({
|
|
467
510
|
action: MealStatusActionSchema.optional().default("SET_MANNUALY")
|
|
468
511
|
});
|
|
469
|
-
var MealStatusSchema =
|
|
470
|
-
var FriendMealQuerySchema =
|
|
512
|
+
var MealStatusSchema = import_zod13.z.enum(["ALL", "HUNGRY", "NOT_HUNGRY"]);
|
|
513
|
+
var FriendMealQuerySchema = import_zod13.z.object({
|
|
471
514
|
status: MealStatusSchema.optional().default("ALL")
|
|
472
515
|
});
|
|
473
516
|
var FriendMealItemResponseSchema = MemberCoreSchema.extend({
|
|
474
|
-
hungry:
|
|
475
|
-
label:
|
|
517
|
+
hungry: import_zod13.z.boolean(),
|
|
518
|
+
label: import_zod13.z.string(),
|
|
476
519
|
updatedAt: ISODateStringSchema
|
|
477
520
|
});
|
|
478
521
|
|
|
479
522
|
// src/domain/plan/plan.schema.ts
|
|
480
|
-
var
|
|
523
|
+
var import_zod15 = require("zod");
|
|
481
524
|
|
|
482
525
|
// src/domain/room/schema/room.schema.ts
|
|
483
|
-
var
|
|
526
|
+
var import_zod14 = require("zod");
|
|
484
527
|
var MenuCodeSchema = FoodCodeSchema;
|
|
485
|
-
var LocationIdSchema =
|
|
528
|
+
var LocationIdSchema = import_zod14.z.string().min(1).brand();
|
|
486
529
|
var MenuSchema = FoodSchema.extend({});
|
|
487
|
-
var LocationCandidateSchema =
|
|
530
|
+
var LocationCandidateSchema = import_zod14.z.object({
|
|
488
531
|
locationId: LocationIdSchema,
|
|
489
|
-
placeName:
|
|
490
|
-
lat:
|
|
491
|
-
lng:
|
|
492
|
-
address:
|
|
532
|
+
placeName: import_zod14.z.string(),
|
|
533
|
+
lat: import_zod14.z.number(),
|
|
534
|
+
lng: import_zod14.z.number(),
|
|
535
|
+
address: import_zod14.z.string()
|
|
493
536
|
});
|
|
494
537
|
var ParticipantSchema = MemberCoreSchema.extend({
|
|
495
|
-
ready:
|
|
538
|
+
ready: import_zod14.z.boolean()
|
|
496
539
|
});
|
|
497
|
-
var RecruitRoomStageSchema =
|
|
540
|
+
var RecruitRoomStageSchema = import_zod14.z.enum([
|
|
498
541
|
"waiting",
|
|
499
542
|
"location",
|
|
500
543
|
"location-vote",
|
|
@@ -503,7 +546,8 @@ var RecruitRoomStageSchema = import_zod13.z.enum([
|
|
|
503
546
|
"restaurant",
|
|
504
547
|
"finish"
|
|
505
548
|
]);
|
|
506
|
-
var
|
|
549
|
+
var RoomTypeSchema = import_zod14.z.enum(["recruit", "invitation"]);
|
|
550
|
+
var InvitationRoomStageSchema = import_zod14.z.enum([
|
|
507
551
|
"waiting",
|
|
508
552
|
"date",
|
|
509
553
|
"time",
|
|
@@ -514,74 +558,118 @@ var InvitationRoomStageSchema = import_zod13.z.enum([
|
|
|
514
558
|
"restaurant",
|
|
515
559
|
"finish"
|
|
516
560
|
]);
|
|
517
|
-
var ReadyStateRequestSchema =
|
|
518
|
-
isReady:
|
|
561
|
+
var ReadyStateRequestSchema = import_zod14.z.object({
|
|
562
|
+
isReady: import_zod14.z.boolean()
|
|
519
563
|
});
|
|
520
|
-
var ChatMessageRequestSchema =
|
|
521
|
-
message:
|
|
564
|
+
var ChatMessageRequestSchema = import_zod14.z.object({
|
|
565
|
+
message: import_zod14.z.string().min(1).max(500)
|
|
522
566
|
});
|
|
523
567
|
var AddLocationCandidateRequestSchema = LocationCandidateSchema;
|
|
524
|
-
var VoteLocationRequestSchema =
|
|
525
|
-
var ExcludeMenuRequestSchema =
|
|
526
|
-
var PickMenuRequestSchema =
|
|
527
|
-
var PickRestaurantRequestSchema =
|
|
528
|
-
var PickTimesRequestSchema =
|
|
529
|
-
var PickDateRequestSchema =
|
|
530
|
-
var RoomAssignedResponseSchema =
|
|
568
|
+
var VoteLocationRequestSchema = import_zod14.z.object({ locationId: LocationIdSchema });
|
|
569
|
+
var ExcludeMenuRequestSchema = import_zod14.z.object({ menu: MenuSchema });
|
|
570
|
+
var PickMenuRequestSchema = import_zod14.z.object({ menuCode: MenuCodeSchema });
|
|
571
|
+
var PickRestaurantRequestSchema = import_zod14.z.object({ restaurantId: RestaurantIdSchema });
|
|
572
|
+
var PickTimesRequestSchema = import_zod14.z.object({ times: import_zod14.z.array(import_zod14.z.string().min(1)).min(1) });
|
|
573
|
+
var PickDateRequestSchema = import_zod14.z.object({ dates: import_zod14.z.array(ISODateStringSchema).min(1) });
|
|
574
|
+
var RoomAssignedResponseSchema = import_zod14.z.object({
|
|
531
575
|
roomId: RoomIdSchema
|
|
532
576
|
});
|
|
533
|
-
var
|
|
534
|
-
|
|
535
|
-
|
|
577
|
+
var RoomAccessResponseSchema = import_zod14.z.object({
|
|
578
|
+
roomId: RoomIdSchema,
|
|
579
|
+
roomType: RoomTypeSchema,
|
|
580
|
+
stage: import_zod14.z.union([RecruitRoomStageSchema, InvitationRoomStageSchema]),
|
|
581
|
+
canJoin: import_zod14.z.boolean()
|
|
582
|
+
});
|
|
583
|
+
var MatchingNotificationKindSchema = import_zod14.z.enum(["recruit", "invitation"]);
|
|
584
|
+
var MatchingNotificationSchema = import_zod14.z.object({
|
|
585
|
+
notificationId: import_zod14.z.string().min(1),
|
|
586
|
+
kind: MatchingNotificationKindSchema,
|
|
587
|
+
roomId: RoomIdSchema,
|
|
588
|
+
roomType: RoomTypeSchema,
|
|
589
|
+
title: import_zod14.z.string().min(1),
|
|
590
|
+
message: import_zod14.z.string().min(1),
|
|
591
|
+
createdAt: ISODateTimeStringSchema,
|
|
592
|
+
readAt: ISODateTimeStringSchema.nullable()
|
|
593
|
+
});
|
|
594
|
+
var RoomSocketErrorSchema = import_zod14.z.object({
|
|
595
|
+
code: import_zod14.z.string(),
|
|
596
|
+
message: import_zod14.z.string()
|
|
536
597
|
});
|
|
537
|
-
var ChatMessageResponseSchema =
|
|
538
|
-
messageId:
|
|
598
|
+
var ChatMessageResponseSchema = import_zod14.z.object({
|
|
599
|
+
messageId: import_zod14.z.string(),
|
|
539
600
|
user: MemberCoreSchema,
|
|
540
|
-
message:
|
|
601
|
+
message: import_zod14.z.string(),
|
|
541
602
|
createdAt: ISODateTimeStringSchema
|
|
542
603
|
});
|
|
543
|
-
var ReadyStateChangedSchema =
|
|
544
|
-
readyCount:
|
|
545
|
-
participantCount:
|
|
604
|
+
var ReadyStateChangedSchema = import_zod14.z.object({
|
|
605
|
+
readyCount: import_zod14.z.number().int().min(0),
|
|
606
|
+
participantCount: import_zod14.z.number().int().min(0)
|
|
546
607
|
});
|
|
547
|
-
var FinalStateSchema =
|
|
608
|
+
var FinalStateSchema = import_zod14.z.object({
|
|
548
609
|
location: LocationCandidateSchema.optional(),
|
|
549
|
-
excludeMenu:
|
|
610
|
+
excludeMenu: import_zod14.z.array(MenuSchema).optional(),
|
|
550
611
|
menu: MenuSchema.optional(),
|
|
551
612
|
restaurant: RestaurantSchema.optional(),
|
|
552
|
-
time:
|
|
613
|
+
time: import_zod14.z.string().optional(),
|
|
553
614
|
date: ISODateStringSchema.optional()
|
|
554
615
|
});
|
|
555
|
-
var RoomInitialStateSchema =
|
|
556
|
-
participants:
|
|
557
|
-
chat:
|
|
616
|
+
var RoomInitialStateSchema = import_zod14.z.object({
|
|
617
|
+
participants: import_zod14.z.array(ParticipantSchema),
|
|
618
|
+
chat: import_zod14.z.array(ChatMessageResponseSchema),
|
|
558
619
|
final: FinalStateSchema
|
|
559
620
|
});
|
|
560
|
-
var
|
|
561
|
-
|
|
562
|
-
data: import_zod13.z.unknown()
|
|
563
|
-
});
|
|
564
|
-
var TimePicksUpdateResponseSchema = import_zod13.z.array(
|
|
565
|
-
import_zod13.z.object({ memberId: MemberIdSchema, times: import_zod13.z.array(import_zod13.z.string()) })
|
|
621
|
+
var TimePicksUpdateResponseSchema = import_zod14.z.array(
|
|
622
|
+
import_zod14.z.object({ memberId: MemberIdSchema, times: import_zod14.z.array(import_zod14.z.string()) })
|
|
566
623
|
);
|
|
567
|
-
var DatePicksUpdateResponseSchema =
|
|
568
|
-
|
|
624
|
+
var DatePicksUpdateResponseSchema = import_zod14.z.array(
|
|
625
|
+
import_zod14.z.object({ memberId: MemberIdSchema, dates: import_zod14.z.array(ISODateStringSchema) })
|
|
569
626
|
);
|
|
570
|
-
var LocationCandidateAddUpdateResponseSchema =
|
|
627
|
+
var LocationCandidateAddUpdateResponseSchema = import_zod14.z.array(
|
|
571
628
|
LocationCandidateSchema.extend({ authorMemberId: MemberIdSchema })
|
|
572
629
|
);
|
|
573
|
-
var LocationCandidateVoteUpdateResponseSchema =
|
|
574
|
-
|
|
630
|
+
var LocationCandidateVoteUpdateResponseSchema = import_zod14.z.array(
|
|
631
|
+
import_zod14.z.object({ locationId: LocationIdSchema, votes: import_zod14.z.array(MemberIdSchema) })
|
|
575
632
|
);
|
|
576
|
-
var ExcludeMenuUpdateResponseSchema =
|
|
577
|
-
|
|
633
|
+
var ExcludeMenuUpdateResponseSchema = import_zod14.z.array(
|
|
634
|
+
import_zod14.z.object({ memberId: MemberIdSchema, exclusions: import_zod14.z.array(MenuSchema) })
|
|
578
635
|
);
|
|
579
|
-
var MenuPickUpdateResponseSchema =
|
|
580
|
-
|
|
636
|
+
var MenuPickUpdateResponseSchema = import_zod14.z.array(
|
|
637
|
+
import_zod14.z.object({ menuCode: MenuCodeSchema, selectedMembers: import_zod14.z.array(MemberIdSchema) })
|
|
581
638
|
);
|
|
582
|
-
var RestaurantPickUpdateResponseSchema =
|
|
583
|
-
|
|
639
|
+
var RestaurantPickUpdateResponseSchema = import_zod14.z.array(
|
|
640
|
+
import_zod14.z.object({ restaurantId: RestaurantIdSchema, selectedMembers: import_zod14.z.array(MemberIdSchema) })
|
|
584
641
|
);
|
|
642
|
+
var WaitingPhaseDataSchema = import_zod14.z.object({
|
|
643
|
+
locationInitial: import_zod14.z.string().optional(),
|
|
644
|
+
meetingAt: ISODateTimeStringSchema.optional()
|
|
645
|
+
});
|
|
646
|
+
var LocationVotePhaseDataSchema = import_zod14.z.object({
|
|
647
|
+
locations: LocationCandidateAddUpdateResponseSchema,
|
|
648
|
+
votes: LocationCandidateVoteUpdateResponseSchema
|
|
649
|
+
});
|
|
650
|
+
var ExcludeMenuPhaseDataSchema = import_zod14.z.object({
|
|
651
|
+
recentMenus: import_zod14.z.array(import_zod14.z.object({ userId: import_zod14.z.string(), menuList: import_zod14.z.array(MenuSchema) })),
|
|
652
|
+
excludedMenuList: ExcludeMenuUpdateResponseSchema
|
|
653
|
+
});
|
|
654
|
+
var MenuPhaseDataSchema = import_zod14.z.object({
|
|
655
|
+
initialMenus: import_zod14.z.array(MenuSchema),
|
|
656
|
+
menuPick: MenuPickUpdateResponseSchema
|
|
657
|
+
});
|
|
658
|
+
var RestaurantPhaseDataSchema = import_zod14.z.object({
|
|
659
|
+
initialRestaurants: import_zod14.z.array(RestaurantSchema),
|
|
660
|
+
restaurantUserList: RestaurantPickUpdateResponseSchema
|
|
661
|
+
});
|
|
662
|
+
var PhaseDataBroadcastSchema = import_zod14.z.discriminatedUnion("phase", [
|
|
663
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("waiting"), data: WaitingPhaseDataSchema }),
|
|
664
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("date"), data: DatePicksUpdateResponseSchema }),
|
|
665
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("time"), data: TimePicksUpdateResponseSchema }),
|
|
666
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("location"), data: WaitingPhaseDataSchema }),
|
|
667
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("location-vote"), data: LocationVotePhaseDataSchema }),
|
|
668
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("exclude-menu"), data: ExcludeMenuPhaseDataSchema }),
|
|
669
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("menu"), data: MenuPhaseDataSchema }),
|
|
670
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("restaurant"), data: RestaurantPhaseDataSchema }),
|
|
671
|
+
import_zod14.z.object({ phase: import_zod14.z.literal("finish"), data: WaitingPhaseDataSchema })
|
|
672
|
+
]);
|
|
585
673
|
var RoomSocketClientEventSchemas = {
|
|
586
674
|
"ready-state": ReadyStateRequestSchema,
|
|
587
675
|
"chat-message": ChatMessageRequestSchema,
|
|
@@ -611,94 +699,94 @@ var RoomSocketServerEventSchemas = {
|
|
|
611
699
|
};
|
|
612
700
|
|
|
613
701
|
// src/domain/plan/plan.schema.ts
|
|
614
|
-
var PlanStatusSchema =
|
|
615
|
-
var PlanTypeSchema =
|
|
616
|
-
var PlanResponseSchema =
|
|
702
|
+
var PlanStatusSchema = import_zod15.z.enum(["PLANNING", "COMPLETED"]);
|
|
703
|
+
var PlanTypeSchema = import_zod15.z.enum(["RECRUIT", "INVITATION"]);
|
|
704
|
+
var PlanResponseSchema = import_zod15.z.object({
|
|
617
705
|
planId: PlanIdSchema,
|
|
618
706
|
meetingAt: ISODateTimeStringSchema,
|
|
619
707
|
location: LocationCandidateSchema.nullable(),
|
|
620
708
|
restaurant: RestaurantSchema.nullable(),
|
|
621
709
|
author: MemberCoreSchema,
|
|
622
|
-
participants:
|
|
710
|
+
participants: import_zod15.z.array(MemberCoreSchema),
|
|
623
711
|
status: PlanStatusSchema,
|
|
624
712
|
type: PlanTypeSchema,
|
|
625
713
|
createdAt: ISODateTimeStringSchema,
|
|
626
714
|
updatedAt: ISODateTimeStringSchema
|
|
627
715
|
});
|
|
628
|
-
var PlanListQuerySchema =
|
|
716
|
+
var PlanListQuerySchema = import_zod15.z.object({});
|
|
629
717
|
|
|
630
718
|
// src/domain/recruit/recruit.schema.ts
|
|
631
|
-
var
|
|
632
|
-
var RecruitStatusSchema =
|
|
719
|
+
var import_zod16 = require("zod");
|
|
720
|
+
var RecruitStatusSchema = import_zod16.z.enum(["OPEN", "CLOSED", "EXPIRED"]);
|
|
633
721
|
var RecruitParticipantSchema = MemberCoreSchema.extend({});
|
|
634
|
-
var RecruitSortBySchema =
|
|
722
|
+
var RecruitSortBySchema = import_zod16.z.enum(["createdAt", "deadline", "participantCount"]);
|
|
635
723
|
var RecruitListQuerySchema = PageQuerySchema.extend({
|
|
636
724
|
sortBy: RecruitSortBySchema.default("createdAt"),
|
|
637
725
|
direction: SortDirectionSchema.default("desc")
|
|
638
726
|
});
|
|
639
|
-
var RecruitResponseSchema =
|
|
640
|
-
targetCount:
|
|
727
|
+
var RecruitResponseSchema = import_zod16.z.object({
|
|
728
|
+
targetCount: import_zod16.z.number().int().min(2),
|
|
641
729
|
meetingAt: ISODateTimeStringSchema,
|
|
642
|
-
location:
|
|
643
|
-
message:
|
|
730
|
+
location: import_zod16.z.string().min(1),
|
|
731
|
+
message: import_zod16.z.string().max(500),
|
|
644
732
|
recruitId: RecruitIdSchema,
|
|
645
733
|
status: RecruitStatusSchema,
|
|
646
734
|
createdAt: ISODateTimeStringSchema,
|
|
647
735
|
expiredAt: ISODateTimeStringSchema,
|
|
648
736
|
updatedAt: ISODateTimeStringSchema,
|
|
649
737
|
author: MemberCoreSchema,
|
|
650
|
-
participants:
|
|
738
|
+
participants: import_zod16.z.array(RecruitParticipantSchema)
|
|
651
739
|
});
|
|
652
|
-
var RecruitListResponseSchema =
|
|
653
|
-
var CreateRecruitRequestSchema =
|
|
654
|
-
targetCount:
|
|
740
|
+
var RecruitListResponseSchema = PageResponseSchema(RecruitResponseSchema);
|
|
741
|
+
var CreateRecruitRequestSchema = import_zod16.z.object({
|
|
742
|
+
targetCount: import_zod16.z.number().int().min(2),
|
|
655
743
|
meetingAt: ISODateTimeStringSchema,
|
|
656
|
-
location:
|
|
657
|
-
message:
|
|
744
|
+
location: import_zod16.z.string().min(1),
|
|
745
|
+
message: import_zod16.z.string().max(500)
|
|
658
746
|
});
|
|
659
|
-
var CreateRecruitResponseSchema =
|
|
747
|
+
var CreateRecruitResponseSchema = import_zod16.z.object({
|
|
660
748
|
recruitId: RecruitIdSchema
|
|
661
749
|
});
|
|
662
750
|
|
|
663
751
|
// src/domain/promotion/referral.schema.ts
|
|
664
|
-
var
|
|
665
|
-
var ReferralCreateResponseSchema =
|
|
752
|
+
var import_zod17 = require("zod");
|
|
753
|
+
var ReferralCreateResponseSchema = import_zod17.z.object({
|
|
666
754
|
code: ReferralCodeSchema,
|
|
667
|
-
link:
|
|
755
|
+
link: import_zod17.z.string().url(),
|
|
668
756
|
expiresAt: ISODateTimeStringSchema
|
|
669
757
|
});
|
|
670
|
-
var ReferralItemResponseSchema =
|
|
758
|
+
var ReferralItemResponseSchema = import_zod17.z.object({
|
|
671
759
|
code: ReferralCodeSchema,
|
|
672
760
|
createdAt: ISODateTimeStringSchema,
|
|
673
761
|
expiresAt: ISODateTimeStringSchema,
|
|
674
|
-
used:
|
|
762
|
+
used: import_zod17.z.boolean(),
|
|
675
763
|
usedByMemberId: MemberIdSchema.nullable(),
|
|
676
|
-
usedByUsername:
|
|
764
|
+
usedByUsername: import_zod17.z.string().nullable()
|
|
677
765
|
});
|
|
678
|
-
var RedeemReferralRequestSchema =
|
|
766
|
+
var RedeemReferralRequestSchema = import_zod17.z.object({
|
|
679
767
|
code: ReferralCodeSchema
|
|
680
768
|
});
|
|
681
769
|
|
|
682
770
|
// src/domain/promotion/coupon.schema.ts
|
|
683
|
-
var
|
|
684
|
-
var CouponTypeSchema =
|
|
685
|
-
var CouponStatusSchema =
|
|
686
|
-
var CouponResponseSchema =
|
|
771
|
+
var import_zod18 = require("zod");
|
|
772
|
+
var CouponTypeSchema = import_zod18.z.enum(["DISCOUNT", "SERVICE"]);
|
|
773
|
+
var CouponStatusSchema = import_zod18.z.enum(["UNUSED", "USED"]);
|
|
774
|
+
var CouponResponseSchema = import_zod18.z.object({
|
|
687
775
|
couponId: CouponIdSchema,
|
|
688
|
-
title:
|
|
689
|
-
shopName:
|
|
776
|
+
title: import_zod18.z.string(),
|
|
777
|
+
shopName: import_zod18.z.string(),
|
|
690
778
|
type: CouponTypeSchema,
|
|
691
|
-
condition:
|
|
779
|
+
condition: import_zod18.z.string(),
|
|
692
780
|
expiresAt: ISODateStringSchema,
|
|
693
|
-
used:
|
|
694
|
-
thumbnailUrl:
|
|
781
|
+
used: import_zod18.z.boolean(),
|
|
782
|
+
thumbnailUrl: import_zod18.z.string().url()
|
|
695
783
|
});
|
|
696
784
|
|
|
697
785
|
// src/domain/common/contracts/endpoint.ts
|
|
698
|
-
var
|
|
699
|
-
var NoBodySchema =
|
|
700
|
-
var NoQuerySchema =
|
|
701
|
-
var NoParamsSchema =
|
|
786
|
+
var import_zod19 = require("zod");
|
|
787
|
+
var NoBodySchema = import_zod19.z.undefined();
|
|
788
|
+
var NoQuerySchema = import_zod19.z.undefined();
|
|
789
|
+
var NoParamsSchema = import_zod19.z.undefined();
|
|
702
790
|
var endpoint = (contract) => ({
|
|
703
791
|
method: contract.method,
|
|
704
792
|
path: contract.path,
|
|
@@ -709,28 +797,30 @@ var endpoint = (contract) => ({
|
|
|
709
797
|
});
|
|
710
798
|
|
|
711
799
|
// src/domain/common/contracts/api.ts
|
|
712
|
-
var memberIdParam =
|
|
713
|
-
var articleIdParam =
|
|
714
|
-
var commentIdParam =
|
|
715
|
-
var recruitIdParam =
|
|
716
|
-
var
|
|
717
|
-
var
|
|
718
|
-
var
|
|
719
|
-
var
|
|
800
|
+
var memberIdParam = import_zod20.z.object({ memberId: MemberIdSchema });
|
|
801
|
+
var articleIdParam = import_zod20.z.object({ articleId: ArticleIdSchema });
|
|
802
|
+
var commentIdParam = import_zod20.z.object({ commentId: CommentIdSchema });
|
|
803
|
+
var recruitIdParam = import_zod20.z.object({ recruitId: RecruitIdSchema });
|
|
804
|
+
var roomIdParam = import_zod20.z.object({ roomId: RoomIdSchema });
|
|
805
|
+
var invitationIdParam = import_zod20.z.object({ invitationId: InvitationIdSchema });
|
|
806
|
+
var notificationIdParam = import_zod20.z.object({ notificationId: import_zod20.z.string().min(1) });
|
|
807
|
+
var planIdParam = import_zod20.z.object({ planId: PlanIdSchema });
|
|
808
|
+
var couponIdParam = import_zod20.z.object({ couponId: CouponIdSchema });
|
|
809
|
+
var friendRequestIdParam = import_zod20.z.object({ requestId: FriendRequestIdSchema });
|
|
720
810
|
var apiContract = {
|
|
721
811
|
auth: {
|
|
722
812
|
signup: endpoint({ method: "POST", path: "/auth/signup", body: SignupRequestSchema, response: SignupResponseSchema }),
|
|
723
813
|
login: endpoint({ method: "POST", path: "/auth/login", body: LoginRequestSchema, response: TokenResponseSchema }),
|
|
724
814
|
refresh: endpoint({ method: "POST", path: "/auth/refresh", response: TokenResponseSchema }),
|
|
725
815
|
logout: endpoint({ method: "POST", path: "/auth/logout", response: NoContentSchema })
|
|
726
|
-
// test: endpoint({method: "GET", path: "/auth/test", response: TokenResponseSchema}) TODO: Dev에서만 작동하도록 백엔드에서 수정해야함
|
|
816
|
+
// test: endpoint({method: "GET", path: "/auth/test", response: TokenResponseSchema}) TODO: Dev에서만 작동하도록 백엔드에서 수정해야함
|
|
727
817
|
},
|
|
728
818
|
members: {
|
|
729
819
|
me: endpoint({ method: "GET", path: "/members/me", response: MemberResponseSchema }),
|
|
730
|
-
myProfile: endpoint({ method: "GET", path: "/members/me/
|
|
820
|
+
myProfile: endpoint({ method: "GET", path: "/members/me/profile", response: ProfileDetailResponseSchema }),
|
|
731
821
|
search: endpoint({ method: "GET", path: "/members/search", query: MemberSearchQuerySchema, response: MemberSerachResponseSchema }),
|
|
732
|
-
memberProfile: endpoint({ method: "GET", path: "/members/:memberId", pathParams: memberIdParam, response: ProfileDetailResponseSchema }),
|
|
733
|
-
presignProfileImage: endpoint({ method: "POST", path: "/uploads/presign-profile", response:
|
|
822
|
+
memberProfile: endpoint({ method: "GET", path: "/members/:memberId/profile", pathParams: memberIdParam, response: ProfileDetailResponseSchema }),
|
|
823
|
+
presignProfileImage: endpoint({ method: "POST", path: "/uploads/presign-profile", body: UploadProfileImageRequestSchema, response: UploadProfileImageResponseSchema }),
|
|
734
824
|
createProfile: endpoint({ method: "POST", path: "/members/onboarding", body: CreateProfileRequestSchema, response: NoContentSchema }),
|
|
735
825
|
updateProfile: endpoint({ method: "PATCH", path: "/members/me/profile", body: UpdateProfileRequestSchema, response: NoContentSchema })
|
|
736
826
|
},
|
|
@@ -739,9 +829,9 @@ var apiContract = {
|
|
|
739
829
|
update: endpoint({ method: "PATCH", path: "/preferences/me", body: UpdatePreferenceRequestSchema, response: NoContentSchema })
|
|
740
830
|
},
|
|
741
831
|
mealStatus: {
|
|
742
|
-
my: endpoint({ method: "GET", path: "/meal-status", response: MealStatusResponseSchema }),
|
|
743
|
-
updateMealStatus: endpoint({ method: "PATCH", path: "/meal-status", body: UpdateMealStatusRequestSchema, response: NoContentSchema }),
|
|
744
|
-
friendMealStatus: endpoint({ method: "GET", path: "/
|
|
832
|
+
my: endpoint({ method: "GET", path: "/members/me/meal-status", response: MealStatusResponseSchema }),
|
|
833
|
+
updateMealStatus: endpoint({ method: "PATCH", path: "/members/me/meal-status", body: UpdateMealStatusRequestSchema, response: NoContentSchema }),
|
|
834
|
+
friendMealStatus: endpoint({ method: "GET", path: "/friends/me/meals", query: FriendMealQuerySchema, response: import_zod20.z.array(FriendMealItemResponseSchema) })
|
|
745
835
|
},
|
|
746
836
|
articles: {
|
|
747
837
|
list: endpoint({ method: "GET", path: "/articles/home", query: ArticleListQuerySchema, response: PageArticleSummaryResponseSchema }),
|
|
@@ -751,7 +841,7 @@ var apiContract = {
|
|
|
751
841
|
create: endpoint({ method: "POST", path: "/articles", body: CreateArticleRequestSchema, response: CreatedEntityIdResponseSchema }),
|
|
752
842
|
like: endpoint({ method: "POST", path: "/articles/:articleId/like", pathParams: articleIdParam, response: ArticleLikeResponseSchema }),
|
|
753
843
|
createComment: endpoint({ method: "POST", path: "/articles/:articleId/comments", pathParams: articleIdParam, body: CreateCommentRequestSchema, response: CreatedEntityIdResponseSchema }),
|
|
754
|
-
presignArticleImage: endpoint({ method: "POST", path: "/uploads/presign-article", response:
|
|
844
|
+
presignArticleImage: endpoint({ method: "POST", path: "/uploads/presign-article", body: UploadArticleImageRequestSchema, response: UploadArticleImageResponseSchema }),
|
|
755
845
|
delete: endpoint({ method: "DELETE", path: "/articles/:articleId", pathParams: articleIdParam, response: NoContentSchema }),
|
|
756
846
|
deleteComment: endpoint({ method: "DELETE", path: "/articles/comments/:commentId", pathParams: commentIdParam, response: NoContentSchema })
|
|
757
847
|
// TODO: 게시물 수정 기능
|
|
@@ -760,25 +850,26 @@ var apiContract = {
|
|
|
760
850
|
list: endpoint({ method: "GET", path: "/recruits", query: RecruitListQuerySchema, response: RecruitListResponseSchema }),
|
|
761
851
|
create: endpoint({ method: "POST", path: "/recruits", body: CreateRecruitRequestSchema, response: CreateRecruitResponseSchema }),
|
|
762
852
|
join: endpoint({ method: "POST", path: "/recruits/:recruitId/join", pathParams: recruitIdParam, response: NoContentSchema }),
|
|
763
|
-
close: endpoint({ method: "
|
|
853
|
+
close: endpoint({ method: "POST", path: "/recruits/:recruitId/close", pathParams: recruitIdParam, response: NoContentSchema })
|
|
764
854
|
},
|
|
765
855
|
invitations: {
|
|
766
|
-
list: endpoint({ method: "GET", path: "/invitations", response:
|
|
856
|
+
list: endpoint({ method: "GET", path: "/invitations", response: import_zod20.z.array(InvitationListItemResponseSchema) }),
|
|
767
857
|
// TODO: Invitation Response 정하기 detail: endpoint({ method: "GET", path: "/invitations/:invitationId", pathParams: invitationIdParam, response: InvitationItemDetailResponseSchema }),
|
|
768
|
-
send: endpoint({ method: "POST", path: "/invitations", body: CreateInvitationRequestSchema, response: SendInvitationResponseSchema }),
|
|
858
|
+
send: endpoint({ method: "POST", path: "/invitations/send", body: CreateInvitationRequestSchema, response: SendInvitationResponseSchema }),
|
|
769
859
|
accept: endpoint({ method: "POST", path: "/invitations/:invitationId/accept", pathParams: invitationIdParam, response: AcceptInvitationResponseSchema }),
|
|
770
860
|
reject: endpoint({ method: "POST", path: "/invitations/:invitationId/reject", pathParams: invitationIdParam, response: NoContentSchema })
|
|
771
861
|
},
|
|
772
862
|
plans: {
|
|
773
|
-
list: endpoint({ method: "GET", path: "/plans", query: PlanListQuerySchema, response:
|
|
863
|
+
list: endpoint({ method: "GET", path: "/plans", query: PlanListQuerySchema, response: import_zod20.z.array(PlanResponseSchema) }),
|
|
774
864
|
detail: endpoint({ method: "GET", path: "/plans/:planId", pathParams: planIdParam, response: PlanResponseSchema }),
|
|
775
865
|
cancel: endpoint({ method: "PATCH", path: "/plans/:planId/cancel", pathParams: planIdParam, response: NoContentSchema })
|
|
776
866
|
},
|
|
777
867
|
friends: {
|
|
778
|
-
list: endpoint({ method: "GET", path: "/friends", response:
|
|
779
|
-
blockList: endpoint({ method: "GET", path: "/friends/blocks", response:
|
|
780
|
-
|
|
781
|
-
|
|
868
|
+
list: endpoint({ method: "GET", path: "/friends", response: import_zod20.z.array(FriendListItemResponseSchema) }),
|
|
869
|
+
blockList: endpoint({ method: "GET", path: "/friends/blocks", response: import_zod20.z.array(FriendBlockItemResponseSchema) }),
|
|
870
|
+
search: endpoint({ method: "GET", path: "/friends/search", query: MemberSearchQuerySchema, response: MemberSerachResponseSchema }),
|
|
871
|
+
incomingRequest: endpoint({ method: "GET", path: "/friends/requests/incoming", response: import_zod20.z.array(FriendRequestItemResponseSchema) }),
|
|
872
|
+
outgoingRequest: endpoint({ method: "GET", path: "/friends/requests/outgoing", response: import_zod20.z.array(FriendRequestItemResponseSchema) }),
|
|
782
873
|
sendRequest: endpoint({ method: "POST", path: "/friends/requests/:memberId", pathParams: memberIdParam, response: NoContentSchema }),
|
|
783
874
|
acceptRequest: endpoint({ method: "POST", path: "/friends/requests/:requestId/accept", pathParams: friendRequestIdParam, response: NoContentSchema }),
|
|
784
875
|
rejectRequest: endpoint({ method: "POST", path: "/friends/requests/:requestId/reject", pathParams: friendRequestIdParam, response: NoContentSchema }),
|
|
@@ -788,52 +879,31 @@ var apiContract = {
|
|
|
788
879
|
unfriend: endpoint({ method: "DELETE", path: "/friends/:memberId", pathParams: memberIdParam, response: NoContentSchema })
|
|
789
880
|
},
|
|
790
881
|
coupons: {
|
|
791
|
-
list: endpoint({ method: "GET", path: "/coupons", response:
|
|
792
|
-
use: endpoint({ method: "
|
|
882
|
+
list: endpoint({ method: "GET", path: "/coupons", response: import_zod20.z.array(CouponResponseSchema) }),
|
|
883
|
+
use: endpoint({ method: "POST", path: "/coupons/:couponId/use", pathParams: couponIdParam, response: NoContentSchema })
|
|
793
884
|
},
|
|
794
885
|
challenges: {
|
|
795
886
|
status: endpoint({ method: "GET", path: "/challenges/status", response: ChallengeStatusResponseSchema }),
|
|
796
887
|
claimReward: endpoint({ method: "POST", path: "/challenges/rewards", body: ClaimChallengeRewardRequestSchema, response: NoContentSchema })
|
|
797
888
|
},
|
|
798
889
|
referrals: {
|
|
799
|
-
list: endpoint({ method: "GET", path: "/referrals", response:
|
|
890
|
+
list: endpoint({ method: "GET", path: "/referrals", response: import_zod20.z.array(ReferralItemResponseSchema) }),
|
|
800
891
|
create: endpoint({ method: "POST", path: "/referrals", response: ReferralCreateResponseSchema }),
|
|
801
892
|
redeem: endpoint({ method: "POST", path: "/referrals/redeem", body: RedeemReferralRequestSchema, response: NoContentSchema })
|
|
802
893
|
},
|
|
894
|
+
notifications: {
|
|
895
|
+
list: endpoint({ method: "GET", path: "/notifications", response: import_zod20.z.array(MatchingNotificationSchema) }),
|
|
896
|
+
markRead: endpoint({ method: "PATCH", path: "/notifications/:notificationId/read", pathParams: notificationIdParam, response: MatchingNotificationSchema }),
|
|
897
|
+
delete: endpoint({ method: "DELETE", path: "/notifications/:notificationId", pathParams: notificationIdParam, response: NoContentSchema })
|
|
898
|
+
},
|
|
803
899
|
room: {
|
|
804
|
-
|
|
900
|
+
access: endpoint({ method: "GET", path: "/rooms/:roomId/access", pathParams: roomIdParam, response: RoomAccessResponseSchema })
|
|
805
901
|
},
|
|
806
902
|
health: {
|
|
807
|
-
healthCheck: endpoint({ method: "GET", path: "/", response:
|
|
903
|
+
healthCheck: endpoint({ method: "GET", path: "/", response: import_zod20.z.string() })
|
|
808
904
|
}
|
|
809
905
|
};
|
|
810
906
|
|
|
811
|
-
// src/domain/common/schema/envelope.schema.ts
|
|
812
|
-
var import_zod20 = require("zod");
|
|
813
|
-
var NoContentSchema = import_zod20.z.null();
|
|
814
|
-
var ApiSuccessSchema = (data) => import_zod20.z.object({
|
|
815
|
-
success: import_zod20.z.literal(true),
|
|
816
|
-
code: import_zod20.z.number().int(),
|
|
817
|
-
message: import_zod20.z.string(),
|
|
818
|
-
data
|
|
819
|
-
});
|
|
820
|
-
var ApiFailureSchema = import_zod20.z.object({
|
|
821
|
-
success: import_zod20.z.literal(false),
|
|
822
|
-
status: import_zod20.z.number().int(),
|
|
823
|
-
code: import_zod20.z.string(),
|
|
824
|
-
message: import_zod20.z.string()
|
|
825
|
-
});
|
|
826
|
-
var ApiResponseSchema = (data) => import_zod20.z.union([ApiSuccessSchema(data), ApiFailureSchema]);
|
|
827
|
-
var CreatedEntityIdResponseSchema = import_zod20.z.discriminatedUnion("entity", [
|
|
828
|
-
import_zod20.z.object({ entity: import_zod20.z.literal("article"), id: ArticleIdSchema }),
|
|
829
|
-
import_zod20.z.object({ entity: import_zod20.z.literal("comment"), id: CommentIdSchema }),
|
|
830
|
-
import_zod20.z.object({ entity: import_zod20.z.literal("recruit"), id: RecruitIdSchema }),
|
|
831
|
-
import_zod20.z.object({ entity: import_zod20.z.literal("invitation"), id: InvitationIdSchema }),
|
|
832
|
-
import_zod20.z.object({ entity: import_zod20.z.literal("subscription"), id: SubscriptionIdSchema }),
|
|
833
|
-
import_zod20.z.object({ entity: import_zod20.z.literal("coupon"), id: CouponIdSchema }),
|
|
834
|
-
import_zod20.z.object({ entity: import_zod20.z.literal("plan"), id: PlanIdSchema })
|
|
835
|
-
]);
|
|
836
|
-
|
|
837
907
|
// src/domain/common/contracts/envelope.ts
|
|
838
908
|
var makeApiResponseSchema = ApiResponseSchema;
|
|
839
909
|
var makeApiSuccessSchema = ApiSuccessSchema;
|
|
@@ -899,6 +969,8 @@ var toReferralCode = (value) => ReferralCodeSchema.parse(value);
|
|
|
899
969
|
FriendRequestItemResponseSchema,
|
|
900
970
|
FriendRequestMemberSchema,
|
|
901
971
|
FriendRequestStatusSchema,
|
|
972
|
+
FriendSearchQuerySchema,
|
|
973
|
+
FriendSearchResponseSchema,
|
|
902
974
|
ISODateStringSchema,
|
|
903
975
|
ISODateTimeStringSchema,
|
|
904
976
|
InvitationIdSchema,
|
|
@@ -910,6 +982,8 @@ var toReferralCode = (value) => ReferralCodeSchema.parse(value);
|
|
|
910
982
|
LocationCandidateVoteUpdateResponseSchema,
|
|
911
983
|
LocationIdSchema,
|
|
912
984
|
LoginRequestSchema,
|
|
985
|
+
MatchingNotificationKindSchema,
|
|
986
|
+
MatchingNotificationSchema,
|
|
913
987
|
MealStatusActionSchema,
|
|
914
988
|
MealStatusResponseSchema,
|
|
915
989
|
MealStatusSchema,
|
|
@@ -945,8 +1019,6 @@ var toReferralCode = (value) => ReferralCodeSchema.parse(value);
|
|
|
945
1019
|
PlanStatusSchema,
|
|
946
1020
|
PlanTypeSchema,
|
|
947
1021
|
PositiveIntIdSchema,
|
|
948
|
-
PresignArticleResponseSchema,
|
|
949
|
-
PresignProfileResponseSchema,
|
|
950
1022
|
ProfileDetailResponseSchema,
|
|
951
1023
|
ReadyStateChangedSchema,
|
|
952
1024
|
ReadyStateRequestSchema,
|
|
@@ -963,12 +1035,14 @@ var toReferralCode = (value) => ReferralCodeSchema.parse(value);
|
|
|
963
1035
|
RestaurantIdSchema,
|
|
964
1036
|
RestaurantPickUpdateResponseSchema,
|
|
965
1037
|
RestaurantSchema,
|
|
1038
|
+
RoomAccessResponseSchema,
|
|
966
1039
|
RoomAssignedResponseSchema,
|
|
967
1040
|
RoomIdSchema,
|
|
968
1041
|
RoomInitialStateSchema,
|
|
969
1042
|
RoomSocketClientEventSchemas,
|
|
970
1043
|
RoomSocketErrorSchema,
|
|
971
1044
|
RoomSocketServerEventSchemas,
|
|
1045
|
+
RoomTypeSchema,
|
|
972
1046
|
SendInvitationResponseSchema,
|
|
973
1047
|
SignupRequestSchema,
|
|
974
1048
|
SignupResponseSchema,
|
|
@@ -980,6 +1054,10 @@ var toReferralCode = (value) => ReferralCodeSchema.parse(value);
|
|
|
980
1054
|
UpdateMealStatusRequestSchema,
|
|
981
1055
|
UpdatePreferenceRequestSchema,
|
|
982
1056
|
UpdateProfileRequestSchema,
|
|
1057
|
+
UploadArticleImageRequestSchema,
|
|
1058
|
+
UploadArticleImageResponseSchema,
|
|
1059
|
+
UploadProfileImageRequestSchema,
|
|
1060
|
+
UploadProfileImageResponseSchema,
|
|
983
1061
|
UserIdSchema,
|
|
984
1062
|
VoteLocationRequestSchema,
|
|
985
1063
|
apiContract,
|