@zyacreatives/shared 1.0.1 → 1.1.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.
Files changed (46) hide show
  1. package/dist/constants.d.ts +277 -0
  2. package/dist/constants.js +268 -0
  3. package/dist/index.js +17 -1
  4. package/dist/schemas/brand.d.ts +84 -0
  5. package/dist/schemas/brand.js +68 -0
  6. package/dist/schemas/common.d.ts +33 -0
  7. package/dist/schemas/common.js +58 -0
  8. package/dist/schemas/creative.d.ts +113 -0
  9. package/dist/schemas/creative.js +102 -0
  10. package/dist/schemas/user.d.ts +179 -0
  11. package/dist/schemas/user.js +93 -0
  12. package/dist/types/brand.d.ts +24 -0
  13. package/dist/types/brand.js +2 -0
  14. package/dist/types/common.d.ts +10 -0
  15. package/dist/types/common.js +2 -0
  16. package/dist/types/creative.d.ts +28 -0
  17. package/dist/types/creative.js +2 -0
  18. package/dist/types/discipline.d.ts +8 -0
  19. package/dist/types/discipline.js +2 -0
  20. package/dist/types/file.d.ts +12 -0
  21. package/dist/types/file.js +2 -0
  22. package/dist/types/index.d.ts +8 -1
  23. package/dist/types/index.js +24 -1
  24. package/dist/types/investor.d.ts +30 -0
  25. package/dist/types/investor.js +2 -0
  26. package/dist/types/project.d.ts +79 -0
  27. package/dist/types/project.js +2 -0
  28. package/dist/types/user.d.ts +42 -0
  29. package/dist/types/user.js +2 -0
  30. package/package.json +7 -3
  31. package/src/constants.ts +300 -0
  32. package/src/schemas/brand.ts +91 -0
  33. package/src/schemas/common.ts +67 -0
  34. package/src/schemas/creative.ts +125 -0
  35. package/src/schemas/user.ts +125 -0
  36. package/src/types/brand.ts +27 -0
  37. package/src/types/common.ts +11 -0
  38. package/src/types/creative.ts +32 -0
  39. package/src/types/discipline.ts +9 -0
  40. package/src/types/file.ts +13 -0
  41. package/src/types/index.ts +8 -1
  42. package/src/types/investor.ts +38 -0
  43. package/src/types/project.ts +101 -0
  44. package/src/types/user.ts +60 -0
  45. package/tsconfig.json +5 -3
  46. package/src/types/enums.ts +0 -109
@@ -0,0 +1,10 @@
1
+ export type ProjectSocialGraphEntity = {
2
+ noOfLikes?: number;
3
+ noOfComments?: number;
4
+ noOfBookmarks?: number;
5
+ noOfViews?: number;
6
+ };
7
+ export type UserSocialGraphEntity = {
8
+ followerCount?: number;
9
+ followingCount?: number;
10
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,28 @@
1
+ import type { ExperienceLevel } from "../constants";
2
+ import type { MinimalUser } from "./user";
3
+ export type BaseCreativeEntity = {
4
+ id: string;
5
+ userId: string;
6
+ bio?: string;
7
+ location?: string;
8
+ experienceLevel?: ExperienceLevel;
9
+ tags?: string[];
10
+ disciplines?: string[];
11
+ user?: any;
12
+ createdAt: Date;
13
+ updatedAt: Date;
14
+ };
15
+ export type CreativeEntity = BaseCreativeEntity;
16
+ export type CreativeWithUserEntity = CreativeEntity & {
17
+ user: MinimalUser;
18
+ disciplines: string[];
19
+ };
20
+ export type ListCreativesInput = {
21
+ query?: string;
22
+ disciplines?: string[];
23
+ experienceLevels?: string[];
24
+ location?: string;
25
+ tags?: string[];
26
+ page?: number;
27
+ perPage?: number;
28
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,8 @@
1
+ export type DisciplineEntity = {
2
+ slug: string;
3
+ name: string;
4
+ tags?: string[];
5
+ };
6
+ export type DisciplineUpdateOutputEntity = {
7
+ slug: string;
8
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,12 @@
1
+ export type FileEntity = {
2
+ key: string;
3
+ id: string;
4
+ url?: string;
5
+ createdAt: Date;
6
+ updatedAt: Date;
7
+ userId: string;
8
+ mimeType: string;
9
+ };
10
+ export type FileUpdateOutputEntity = {
11
+ id: string;
12
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1 +1,8 @@
1
- export * from "./enums";
1
+ export * from "./brand";
2
+ export * from "./common";
3
+ export * from "./creative";
4
+ export * from "./discipline";
5
+ export * from "./file";
6
+ export * from "./investor";
7
+ export * from "./project";
8
+ export * from "./user";
@@ -1 +1,24 @@
1
- export * from "./enums";
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./brand"), exports);
18
+ __exportStar(require("./common"), exports);
19
+ __exportStar(require("./creative"), exports);
20
+ __exportStar(require("./discipline"), exports);
21
+ __exportStar(require("./file"), exports);
22
+ __exportStar(require("./investor"), exports);
23
+ __exportStar(require("./project"), exports);
24
+ __exportStar(require("./user"), exports);
@@ -0,0 +1,30 @@
1
+ import type { ExperienceLevel, GeographicFocus, InvestmentSize, InvestorType } from "../constants";
2
+ import type { MinimalUser } from "./user";
3
+ export type InvestorEntity = {
4
+ id: string;
5
+ userId: string;
6
+ bio?: string;
7
+ location?: string;
8
+ experienceLevel?: ExperienceLevel;
9
+ geographicFocus?: GeographicFocus;
10
+ investmentSize?: InvestmentSize;
11
+ investorType?: InvestorType;
12
+ websiteURL?: string;
13
+ disciplines?: string[];
14
+ user?: any;
15
+ createdAt: Date;
16
+ updatedAt: Date;
17
+ };
18
+ export type InvestorWithUserEntity = InvestorEntity & {
19
+ user: MinimalUser;
20
+ disciplines: string[];
21
+ };
22
+ export type ListInvestorsInput = {
23
+ query?: string;
24
+ disciplines?: string[];
25
+ experienceLevels?: string[];
26
+ location?: string;
27
+ tags?: string[];
28
+ page?: number;
29
+ perPage?: number;
30
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,79 @@
1
+ import type { ClientType, CommentStatus, Role } from "../constants";
2
+ import type { ProjectSocialGraphEntity } from "./common";
3
+ import type { BaseUserEntity, MinimalUser } from "./user";
4
+ export type ProjectFileEntity = {
5
+ id: string;
6
+ projectId: string;
7
+ fileId: string;
8
+ order: number;
9
+ isPlaceholder: boolean;
10
+ };
11
+ export type ProjectEntity = {
12
+ id: string;
13
+ createdAt: Date;
14
+ updatedAt: Date;
15
+ userId: string;
16
+ title: string;
17
+ description?: string;
18
+ overview?: string;
19
+ url?: string;
20
+ clientId?: string;
21
+ clientType?: ClientType;
22
+ clientName?: string;
23
+ projectCreatorType: Role;
24
+ tags?: string[];
25
+ isFeatured?: boolean;
26
+ startDate?: Date | null;
27
+ imagePlaceholderUrl?: string;
28
+ endDate?: Date | null;
29
+ };
30
+ export type ProjectWithFilesEntity = ProjectEntity & ProjectSocialGraphEntity & {
31
+ projectFiles?: ProjectFileEntity[];
32
+ };
33
+ export type ProjectViewEntity = {
34
+ id: string;
35
+ userId?: string;
36
+ ipAddress?: string;
37
+ userAgent?: string;
38
+ projectId: string;
39
+ sessionId?: string;
40
+ viewedAt: Date;
41
+ viewDate: Date;
42
+ };
43
+ export type ProjectLikeEntity = {
44
+ createdAt: Date;
45
+ userId: string;
46
+ projectId: string;
47
+ };
48
+ export type ProjectCommentEntity = {
49
+ id: string;
50
+ status: CommentStatus;
51
+ createdAt: Date;
52
+ userId: string;
53
+ projectId: string;
54
+ parentCommentId?: string;
55
+ content: string;
56
+ };
57
+ export type ProjectBookmarkEntity = {
58
+ createdAt: Date;
59
+ userId: string;
60
+ projectId: string;
61
+ };
62
+ export type MinimalProject = Pick<ProjectEntity, "id" | "title" | "description" | "tags" | "startDate" | "endDate" | "imagePlaceholderUrl">;
63
+ export type ProjectWithClientEntity = MinimalProject & {
64
+ client: MinimalUser;
65
+ };
66
+ export type ProjectWithUserEntity = MinimalProject & {
67
+ user: Pick<BaseUserEntity, "id" | "name" | "email" | "image" | "username" | "role">;
68
+ projectFiles: (ProjectFileEntity & {
69
+ fileUrl: string;
70
+ })[];
71
+ } & Partial<ProjectSocialGraphEntity>;
72
+ export type ListProjectsDto = {
73
+ query?: string;
74
+ tags?: string[];
75
+ clientName?: string;
76
+ userId?: string;
77
+ page?: number;
78
+ perPage?: number;
79
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,42 @@
1
+ import type { OnboardingPage, Role, UserStatus } from "../constants";
2
+ import type { UserSocialGraphEntity } from "./common";
3
+ import type { ProjectBookmarkEntity, ProjectEntity } from "./project";
4
+ export type BaseUserEntity = {
5
+ id: string;
6
+ email: string;
7
+ emailVerified: boolean;
8
+ name?: string;
9
+ image?: string;
10
+ username?: string;
11
+ displayUsername?: string;
12
+ role: Role;
13
+ status: UserStatus;
14
+ onboardingPage: OnboardingPage;
15
+ createdAt: Date;
16
+ updatedAt: Date;
17
+ };
18
+ export type MinimalUser = Pick<BaseUserEntity, "id" | "name" | "email" | "image" | "username" | "role">;
19
+ export type UserEntity = BaseUserEntity & UserSocialGraphEntity;
20
+ export type UserProfileEntity = UserEntity & {
21
+ profileType?: "creative" | "brand" | "investor";
22
+ bio?: string;
23
+ location?: string;
24
+ experienceLevel?: string;
25
+ disciplines?: any[];
26
+ tags?: any[];
27
+ brandName?: string;
28
+ websiteURL?: string;
29
+ investorType?: string;
30
+ investmentSize?: string;
31
+ geographicFocus?: string;
32
+ };
33
+ export type UserWithProjectsEntity = {
34
+ userId: string;
35
+ projects: Omit<ProjectEntity, "overview">[];
36
+ };
37
+ export type UserWithProjectBookmarksEntity = {
38
+ userId: string;
39
+ projectBookmarks: (ProjectBookmarkEntity & {
40
+ project: Pick<ProjectEntity, "id" | "title" | "description" | "tags" | "startDate" | "endDate" | "imagePlaceholderUrl">;
41
+ })[];
42
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zyacreatives/shared",
3
- "version": "1.0.1",
3
+ "version": "1.1.0",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -13,10 +13,14 @@
13
13
  "author": "",
14
14
  "license": "ISC",
15
15
  "devDependencies": {
16
- "tsup": "^8.5.0",
17
16
  "typescript": "^5.9.3"
18
17
  },
18
+ "dependencies": {
19
+ "@hono/zod-openapi": "^1.1.3",
20
+ "zod": "^4.1.12"
21
+ },
19
22
  "scripts": {
20
- "build": "pnpm tsc"
23
+ "build": "pnpm tsc",
24
+ "p": "pnpm publish --no-git-checks"
21
25
  }
22
26
  }
@@ -0,0 +1,300 @@
1
+ export const ROLES = {
2
+ CREATIVE: "CREATIVE",
3
+ BRAND: "BRAND",
4
+ INVESTOR: "INVESTOR",
5
+ ADMIN: "ADMIN",
6
+ } as const;
7
+
8
+ export const USER_STATUSES = {
9
+ ACTIVE: "ACTIVE",
10
+ SUSPENDED: "SUSPENDED",
11
+ DELETED: "DELETED",
12
+ } as const;
13
+
14
+ export const CLIENT_TYPES = {
15
+ CREATIVE: "CREATIVE",
16
+ BRAND: "BRAND",
17
+ NONE: "NONE",
18
+ } as const;
19
+
20
+ export const EXPERIENCE_LEVELS = {
21
+ YEAR_0_1: "0-1 year",
22
+ YEAR_1_3: "1-3 years",
23
+ YEAR_3_5: "3-5 years",
24
+ YEAR_5_PLUS: "5+ years",
25
+ } as const;
26
+
27
+ export const ONBOARDING_PAGES = {
28
+ EMAIL_VERIFICATION: "EMAIL_VERIFICATION",
29
+ USERNAME_SELECTION: "USERNAME_SELECTION",
30
+ ACCOUNT_TYPE_SELECTION: "ACCOUNT_TYPE_SELECTION",
31
+ CREATIVE_PROFILE_DETAILS: "CREATIVE_PROFILE_DETAILS",
32
+ CREATIVE_PROFILE_CUSTOMIZE_FEED: "CREATIVE_PROFILE_CUSTOMIZE_FEED",
33
+ CREATIVE_PROFILE_PORTFOLIO: "CREATIVE_PROFILE_PORTFOLIO",
34
+ BRAND_PROFILE_DETAILS: "BRAND_PROFILE_DETAILS",
35
+ BRAND_PROFILE_CUSTOMIZE_FEED: "BRAND_PROFILE_CUSTOMIZE_FEED",
36
+ BRAND_PROFILE_PORTFOLIO: "BRAND_PROFILE_PORTFOLIO",
37
+ INVESTOR_PROFILE_DETAILS: "INVESTOR_PROFILE_DETAILS",
38
+ INVESTOR_INVESTMENT_FOCUS: "INVESTOR_INVESTMENT_FOCUS",
39
+ INVESTOR_VERIFICATION: "INVESTOR_VERIFICATION",
40
+ DONE: "DONE",
41
+ } as const;
42
+
43
+ export const INVESTOR_TYPES = {
44
+ ANGEL_INVESTOR: "Angel Investor",
45
+ VENTURE_CAPITALIST: "Venture Capitalist",
46
+ PRIVATE_EQUITY_FIRM: "Private Equity Firm",
47
+ VENTURE_DEBT_PROVIDER: "Venture Debt Provider",
48
+ BANK: "Bank",
49
+ CONVERTIBLE_NOTE_INVESTOR: "Convertible Note Investor",
50
+ REVENUE_BASED_FINANCING_INVESTOR: "Revenue Based Financing Investor",
51
+ CORPORATE_VENTURE_CAPITALIST: "Corporate Venture Capitalist",
52
+ GOVERNMENT: "Government",
53
+ SOCIAL_IMPACT_INVESTOR: "Social Impact Investor",
54
+ } as const;
55
+
56
+ export const INVESTMENT_SIZES = {
57
+ UNDER_5K: "Under 5k USD",
58
+ BETWEEN_5K_25K: "5k - 25k USD",
59
+ BETWEEN_25K_100K: "25k - 100k USD",
60
+ BETWEEN_100K_500K: "100k - 500k USD",
61
+ BETWEEN_500K_1M: "500k - 1M USD",
62
+ OVER_1M: "1M+ USD",
63
+ } as const;
64
+
65
+ export const GEOGRAPHIC_FOCUS = {
66
+ AFRICA: "Africa",
67
+ ASIA: "Asia",
68
+ EUROPE: "Europe",
69
+ NORTH_AMERICA: "North America",
70
+ SOUTH_AMERICA: "South America",
71
+ MIDDLE_EAST: "Middle East",
72
+ OCEANIA: "Oceania",
73
+ UK: "United Kingdom (UK)",
74
+ US: "United States (US)",
75
+ GLOBAL: "Global",
76
+ OTHER: "Other",
77
+ } as const;
78
+
79
+ export const INVESTOR_VERIFICATION_DOCUMENT_STATUSES = {
80
+ PENDING: "PENDING",
81
+ APPROVED: "APPROVED",
82
+ REJECTED: "REJECTED",
83
+ } as const;
84
+
85
+ export const INVESTOR_VERIFICATION_DOCUMENT_TYPES = {
86
+ ID_PROOF: "ID_PROOF",
87
+ BANK_STATEMENT: "BANK_STATEMENT",
88
+ TAX_DOCUMENT: "TAX_DOCUMENT",
89
+ BUSINESS_REGISTRATION: "BUSINESS_REGISTRATION",
90
+ OTHER_CERTIFICATE: "OTHER_CERTIFICATE",
91
+ } as const;
92
+
93
+ export const COMMENT_STATUSES = {
94
+ ACTIVE: "ACTIVE",
95
+ HIDDEN: "HIDDEN",
96
+ DELETED: "DELETED",
97
+ } as const;
98
+
99
+ export const FILE_VISIBILITIES = {
100
+ PUBLIC: "PUBLIC",
101
+ PRIVATE: "PRIVATE",
102
+ } as const;
103
+
104
+ export type Role = (typeof ROLES)[keyof typeof ROLES];
105
+ export type UserStatus = (typeof USER_STATUSES)[keyof typeof USER_STATUSES];
106
+ export type ClientType = (typeof CLIENT_TYPES)[keyof typeof CLIENT_TYPES];
107
+ export type ExperienceLevel =
108
+ (typeof EXPERIENCE_LEVELS)[keyof typeof EXPERIENCE_LEVELS];
109
+ export type OnboardingPage =
110
+ (typeof ONBOARDING_PAGES)[keyof typeof ONBOARDING_PAGES];
111
+ export type InvestorType = (typeof INVESTOR_TYPES)[keyof typeof INVESTOR_TYPES];
112
+ export type InvestmentSize =
113
+ (typeof INVESTMENT_SIZES)[keyof typeof INVESTMENT_SIZES];
114
+ export type GeographicFocus =
115
+ (typeof GEOGRAPHIC_FOCUS)[keyof typeof GEOGRAPHIC_FOCUS];
116
+ export type InvestorVerificationDocumentStatus =
117
+ (typeof INVESTOR_VERIFICATION_DOCUMENT_STATUSES)[keyof typeof INVESTOR_VERIFICATION_DOCUMENT_STATUSES];
118
+ export type InvestorVerificationDocumentType =
119
+ (typeof INVESTOR_VERIFICATION_DOCUMENT_TYPES)[keyof typeof INVESTOR_VERIFICATION_DOCUMENT_TYPES];
120
+ export type CommentStatus =
121
+ (typeof COMMENT_STATUSES)[keyof typeof COMMENT_STATUSES];
122
+ export type FileVisibility =
123
+ (typeof FILE_VISIBILITIES)[keyof typeof FILE_VISIBILITIES];
124
+
125
+ export const API_ROUTES = {
126
+ healthCheck: "/health",
127
+ username: {
128
+ base: "/usernames",
129
+ checkAvailability: "/:username/availability",
130
+ },
131
+ personal: {
132
+ base: "/me",
133
+ getUser: "",
134
+ getProfile: "/profile",
135
+ getProjects: "/projects",
136
+ getProjectBookmarks: "/project-bookmarks",
137
+ getFollowers: "/followers",
138
+ getFollowing: "/following",
139
+ },
140
+ user: {
141
+ base: "/users",
142
+ getUser: "/:value",
143
+ getProfile: "/:value/profile",
144
+ getProjects: "/:value/projects",
145
+ getFollowers: "/:userId/followers",
146
+ getFollowing: "/:userId/following",
147
+ followUser: "/:userId/follow",
148
+ unfollowUser: "/:userId/unfollow",
149
+ reserveUsername: "/reserve-username",
150
+ },
151
+ redirect: {
152
+ base: "/redirect",
153
+ passwordReset: "/password-reset",
154
+ verifiedUser: "/verified-user",
155
+ googleProfile: "/google-profile",
156
+ newGoogleProfile: "/new-google-profile",
157
+ },
158
+ file: {
159
+ base: "/files",
160
+ getPresignedUploadUrl: "/get-upload-url",
161
+ getPresignedDownloadUrl: "/:fileId/download-url",
162
+ getPublicUrl: "/:fileId/public-url",
163
+ createFile: "",
164
+ deleteFile: "/:fileId",
165
+ },
166
+ disciplines: {
167
+ base: "/disciplines",
168
+ getDisciplines: "",
169
+ getSingleDiscipline: "/:slug",
170
+ addDisciplines: "",
171
+ deleteDiscipline: "/:slug",
172
+ },
173
+ creatives: {
174
+ base: "/creatives",
175
+ createCreative: "",
176
+ getCreative: "/:value",
177
+ updateCreative: "",
178
+ },
179
+ brands: {
180
+ base: "/brands",
181
+ createBrand: "",
182
+ getBrand: "/:value",
183
+ updateBrand: "",
184
+ },
185
+ investors: {
186
+ base: "/investors",
187
+ createInvestor: "",
188
+ getInvestor: "/:value",
189
+ updateInvestor: "",
190
+ },
191
+ projects: {
192
+ base: "/projects",
193
+ createProject: "",
194
+ updateProject: "",
195
+ listProjects: "",
196
+ getProject: "/:projectId",
197
+ deleteProject: "/:projectId",
198
+ commentOnProject: "/:projectId/comment",
199
+ deleteCommentOnProject: "/:projectId/comments/:commentId",
200
+ bookmarkProject: "/:projectId/bookmark",
201
+ unbookmarkProject: "/:projectId/unbookmark",
202
+ likeProject: "/:projectId/like",
203
+ unlikeProject: "/:projectId/unlike",
204
+ viewProject: "/:projectId/view",
205
+ getProjectComments: "/:projectId/comments",
206
+ getProjectLikes: "/:projectId/likes",
207
+ getProjectBookmarks: "/:projectId/bookmarks",
208
+ getProjectViews: "/:projectId/views",
209
+ getProjectUser: "/:projectId/user",
210
+ },
211
+ } as const;
212
+
213
+ export const FRONTEND_API_ROUTES = {
214
+ healthCheck: "health",
215
+ username: {
216
+ base: "usernames",
217
+ checkAvailability: (username: string) => `${username}/availability`,
218
+ },
219
+ personal: {
220
+ base: "me",
221
+ getUser: "",
222
+ getProfile: "profile",
223
+ getProjects: "projects",
224
+ getProjectBookmarks: "project-bookmarks",
225
+ getFollowers: "followers",
226
+ getFollowing: "following",
227
+ },
228
+ user: {
229
+ base: "users",
230
+ getUser: (value: string) => `${value}`,
231
+ getProfile: (value: string) => `${value}/profile`,
232
+ getProjects: (value: string) => `${value}/projects`,
233
+ getFollowers: (userId: string) => `${userId}/followers`,
234
+ getFollowing: (userId: string) => `${userId}/following`,
235
+ followUser: (userId: string) => `${userId}/follow`,
236
+ unfollowUser: (userId: string) => `${userId}/unfollow`,
237
+ reserveUsername: "reserve-username",
238
+ },
239
+ redirect: {
240
+ base: "redirect",
241
+ passwordReset: "password-reset",
242
+ verifiedUser: "verified-user",
243
+ googleProfile: "google-profile",
244
+ newGoogleProfile: "new-google-profile",
245
+ },
246
+ file: {
247
+ base: "files",
248
+ getPresignedUploadUrl: "get-upload-url",
249
+ getPresignedDownloadUrl: (fileId: string) => `${fileId}/download-url`,
250
+ getPublicUrl: (fileId: string) => `${fileId}/public-url`,
251
+ createFile: "",
252
+ deleteFile: (fileId: string) => `${fileId}`,
253
+ },
254
+ disciplines: {
255
+ base: "disciplines",
256
+ getDisciplines: "",
257
+ getSingleDiscipline: (slug: string) => `${slug}`,
258
+ addDisciplines: "",
259
+ deleteDiscipline: (slug: string) => `${slug}`,
260
+ },
261
+ creatives: {
262
+ base: "creatives",
263
+ createCreative: "",
264
+ getCreative: (value: string) => `${value}`,
265
+ updateCreative: "",
266
+ },
267
+ brands: {
268
+ base: "brands",
269
+ createBrand: "",
270
+ getBrand: (value: string) => `${value}`,
271
+ updateBrand: "",
272
+ },
273
+ investors: {
274
+ base: "investors",
275
+ createInvestor: "",
276
+ getInvestor: (value: string) => `${value}`,
277
+ updateInvestor: "",
278
+ },
279
+ projects: {
280
+ base: "projects",
281
+ createProject: "",
282
+ updateProject: "",
283
+ listProjects: "",
284
+ getProject: (projectId: string) => `${projectId}`,
285
+ deleteProject: (projectId: string) => `${projectId}`,
286
+ commentOnProject: (projectId: string) => `${projectId}/comment`,
287
+ deleteCommentOnProject: (projectId: string, commentId: string) =>
288
+ `${projectId}/comments/${commentId}`,
289
+ bookmarkProject: (projectId: string) => `${projectId}/bookmark`,
290
+ unbookmarkProject: (projectId: string) => `${projectId}/unbookmark`,
291
+ likeProject: (projectId: string) => `${projectId}/like`,
292
+ unlikeProject: (projectId: string) => `${projectId}/unlike`,
293
+ viewProject: (projectId: string) => `${projectId}/view`,
294
+ getProjectComments: (projectId: string) => `${projectId}/comments`,
295
+ getProjectLikes: (projectId: string) => `${projectId}/likes`,
296
+ getProjectBookmarks: (projectId: string) => `${projectId}/bookmarks`,
297
+ getProjectViews: (projectId: string) => `${projectId}/views`,
298
+ getProjectUser: (projectId: string) => `${projectId}/user`,
299
+ },
300
+ } as const;