@sublay/js 7.8.0 → 7.9.1

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 (268) hide show
  1. package/LICENSE +202 -0
  2. package/NOTICE +9 -0
  3. package/README.md +23 -14
  4. package/dist/index.d.mts +374 -21
  5. package/dist/index.d.ts +4364 -31
  6. package/dist/index.js +53 -19
  7. package/dist/index.mjs +53 -19
  8. package/package.json +29 -18
  9. package/dist/core/client.d.ts +0 -64
  10. package/dist/core/multipart.d.ts +0 -22
  11. package/dist/core/spaceReputationParams.d.ts +0 -57
  12. package/dist/interfaces/AppNotification.d.ts +0 -258
  13. package/dist/interfaces/ChatMessage.d.ts +0 -32
  14. package/dist/interfaces/Collection.d.ts +0 -10
  15. package/dist/interfaces/Comment.d.ts +0 -42
  16. package/dist/interfaces/Connection.d.ts +0 -67
  17. package/dist/interfaces/Conversation.d.ts +0 -27
  18. package/dist/interfaces/ConversationMember.d.ts +0 -17
  19. package/dist/interfaces/Entity.d.ts +0 -55
  20. package/dist/interfaces/Event.d.ts +0 -66
  21. package/dist/interfaces/File.d.ts +0 -39
  22. package/dist/interfaces/Follow.d.ts +0 -19
  23. package/dist/interfaces/HostedApp.d.ts +0 -11
  24. package/dist/interfaces/IPaginatedResponse.d.ts +0 -11
  25. package/dist/interfaces/ImageProcessing.d.ts +0 -62
  26. package/dist/interfaces/Mention.d.ts +0 -12
  27. package/dist/interfaces/OAuthIdentity.d.ts +0 -14
  28. package/dist/interfaces/Project.d.ts +0 -14
  29. package/dist/interfaces/Push.d.ts +0 -74
  30. package/dist/interfaces/Reaction.d.ts +0 -23
  31. package/dist/interfaces/Report.d.ts +0 -38
  32. package/dist/interfaces/Rule.d.ts +0 -22
  33. package/dist/interfaces/Space.d.ts +0 -130
  34. package/dist/interfaces/SpaceMember.d.ts +0 -29
  35. package/dist/interfaces/SpaceReputation.d.ts +0 -100
  36. package/dist/interfaces/Table.d.ts +0 -63
  37. package/dist/interfaces/User.d.ts +0 -46
  38. package/dist/interfaces/UserSearch.d.ts +0 -13
  39. package/dist/interfaces/Workspace.d.ts +0 -148
  40. package/dist/modules/app-notifications/countUnreadNotifications.d.ts +0 -2
  41. package/dist/modules/app-notifications/fetchNotifications.d.ts +0 -8
  42. package/dist/modules/app-notifications/index.d.ts +0 -4
  43. package/dist/modules/app-notifications/markAllNotificationsAsRead.d.ts +0 -5
  44. package/dist/modules/app-notifications/markNotificationAsRead.d.ts +0 -5
  45. package/dist/modules/auth/changePassword.d.ts +0 -34
  46. package/dist/modules/auth/confirmAccountDeletion.d.ts +0 -11
  47. package/dist/modules/auth/index.d.ts +0 -13
  48. package/dist/modules/auth/requestAccountDeletion.d.ts +0 -14
  49. package/dist/modules/auth/requestNewAccessToken.d.ts +0 -16
  50. package/dist/modules/auth/requestPasswordReset.d.ts +0 -5
  51. package/dist/modules/auth/resetPassword.d.ts +0 -6
  52. package/dist/modules/auth/sendVerificationEmail.d.ts +0 -13
  53. package/dist/modules/auth/setPassword.d.ts +0 -9
  54. package/dist/modules/auth/signIn.d.ts +0 -12
  55. package/dist/modules/auth/signOut.d.ts +0 -103
  56. package/dist/modules/auth/signUp.d.ts +0 -24
  57. package/dist/modules/auth/verifyEmail.d.ts +0 -5
  58. package/dist/modules/auth/verifyExternalUser.d.ts +0 -11
  59. package/dist/modules/chat/addMember.d.ts +0 -8
  60. package/dist/modules/chat/changeMemberRole.d.ts +0 -9
  61. package/dist/modules/chat/createDirectConversation.d.ts +0 -7
  62. package/dist/modules/chat/createGroupConversation.d.ts +0 -10
  63. package/dist/modules/chat/deleteConversation.d.ts +0 -8
  64. package/dist/modules/chat/deleteMessage.d.ts +0 -11
  65. package/dist/modules/chat/editMessage.d.ts +0 -14
  66. package/dist/modules/chat/getConversation.d.ts +0 -6
  67. package/dist/modules/chat/getMessage.d.ts +0 -8
  68. package/dist/modules/chat/getUnreadCount.d.ts +0 -6
  69. package/dist/modules/chat/index.d.ts +0 -21
  70. package/dist/modules/chat/leaveConversation.d.ts +0 -7
  71. package/dist/modules/chat/listConversations.d.ts +0 -17
  72. package/dist/modules/chat/listMembers.d.ts +0 -11
  73. package/dist/modules/chat/listMessages.d.ts +0 -40
  74. package/dist/modules/chat/listReactions.d.ts +0 -24
  75. package/dist/modules/chat/markAsRead.d.ts +0 -9
  76. package/dist/modules/chat/muteConversation.d.ts +0 -23
  77. package/dist/modules/chat/removeMember.d.ts +0 -9
  78. package/dist/modules/chat/reportMessage.d.ts +0 -12
  79. package/dist/modules/chat/sendMessage.d.ts +0 -22
  80. package/dist/modules/chat/toggleReaction.d.ts +0 -16
  81. package/dist/modules/chat/updateConversation.d.ts +0 -12
  82. package/dist/modules/collections/addEntityToCollection.d.ts +0 -13
  83. package/dist/modules/collections/createNewCollection.d.ts +0 -8
  84. package/dist/modules/collections/deleteCollection.d.ts +0 -5
  85. package/dist/modules/collections/fetchCollectionEntities.d.ts +0 -13
  86. package/dist/modules/collections/fetchRootCollection.d.ts +0 -3
  87. package/dist/modules/collections/fetchSubCollections.d.ts +0 -6
  88. package/dist/modules/collections/index.d.ts +0 -8
  89. package/dist/modules/collections/removeEntityFromCollection.d.ts +0 -7
  90. package/dist/modules/collections/updateCollection.d.ts +0 -7
  91. package/dist/modules/comments/addReaction.d.ts +0 -8
  92. package/dist/modules/comments/createComment.d.ts +0 -15
  93. package/dist/modules/comments/deleteComment.d.ts +0 -5
  94. package/dist/modules/comments/fetchComment.d.ts +0 -8
  95. package/dist/modules/comments/fetchCommentByForeignId.d.ts +0 -7
  96. package/dist/modules/comments/fetchManyComments.d.ts +0 -26
  97. package/dist/modules/comments/fetchReactions.d.ts +0 -16
  98. package/dist/modules/comments/getUserReaction.d.ts +0 -9
  99. package/dist/modules/comments/index.d.ts +0 -10
  100. package/dist/modules/comments/removeReaction.d.ts +0 -6
  101. package/dist/modules/comments/updateComment.d.ts +0 -10
  102. package/dist/modules/connections/acceptConnection.d.ts +0 -6
  103. package/dist/modules/connections/declineConnection.d.ts +0 -6
  104. package/dist/modules/connections/fetchConnections.d.ts +0 -9
  105. package/dist/modules/connections/fetchConnectionsCount.d.ts +0 -3
  106. package/dist/modules/connections/fetchReceivedPendingConnections.d.ts +0 -8
  107. package/dist/modules/connections/fetchSentPendingConnections.d.ts +0 -8
  108. package/dist/modules/connections/index.d.ts +0 -7
  109. package/dist/modules/connections/removeConnection.d.ts +0 -5
  110. package/dist/modules/entities/addReaction.d.ts +0 -8
  111. package/dist/modules/entities/createEntity.d.ts +0 -23
  112. package/dist/modules/entities/deleteEntity.d.ts +0 -5
  113. package/dist/modules/entities/fetchDrafts.d.ts +0 -11
  114. package/dist/modules/entities/fetchEntity.d.ts +0 -8
  115. package/dist/modules/entities/fetchEntityByForeignId.d.ts +0 -8
  116. package/dist/modules/entities/fetchEntityByShortId.d.ts +0 -7
  117. package/dist/modules/entities/fetchManyEntities.d.ts +0 -65
  118. package/dist/modules/entities/fetchReactions.d.ts +0 -16
  119. package/dist/modules/entities/fetchTopComment.d.ts +0 -6
  120. package/dist/modules/entities/getUserReaction.d.ts +0 -9
  121. package/dist/modules/entities/index.d.ts +0 -15
  122. package/dist/modules/entities/isEntitySaved.d.ts +0 -12
  123. package/dist/modules/entities/publishDraft.d.ts +0 -6
  124. package/dist/modules/entities/removeReaction.d.ts +0 -6
  125. package/dist/modules/entities/updateEntity.d.ts +0 -18
  126. package/dist/modules/events/addHost.d.ts +0 -8
  127. package/dist/modules/events/addInvite.d.ts +0 -8
  128. package/dist/modules/events/cancelEvent.d.ts +0 -6
  129. package/dist/modules/events/createEvent.d.ts +0 -49
  130. package/dist/modules/events/deleteEvent.d.ts +0 -5
  131. package/dist/modules/events/fetchEvent.d.ts +0 -8
  132. package/dist/modules/events/fetchEventRsvps.d.ts +0 -19
  133. package/dist/modules/events/fetchInvitees.d.ts +0 -12
  134. package/dist/modules/events/fetchManyEvents.d.ts +0 -42
  135. package/dist/modules/events/index.d.ts +0 -14
  136. package/dist/modules/events/removeHost.d.ts +0 -8
  137. package/dist/modules/events/removeInvite.d.ts +0 -8
  138. package/dist/modules/events/setRsvp.d.ts +0 -7
  139. package/dist/modules/events/updateEvent.d.ts +0 -43
  140. package/dist/modules/events/withdrawRsvp.d.ts +0 -6
  141. package/dist/modules/follows/deleteFollow.d.ts +0 -5
  142. package/dist/modules/follows/fetchFollowers.d.ts +0 -9
  143. package/dist/modules/follows/fetchFollowersCount.d.ts +0 -5
  144. package/dist/modules/follows/fetchFollowing.d.ts +0 -9
  145. package/dist/modules/follows/fetchFollowingCount.d.ts +0 -5
  146. package/dist/modules/follows/index.d.ts +0 -5
  147. package/dist/modules/oauth/authorize.d.ts +0 -25
  148. package/dist/modules/oauth/index.d.ts +0 -4
  149. package/dist/modules/oauth/linkIdentity.d.ts +0 -14
  150. package/dist/modules/oauth/listIdentities.d.ts +0 -4
  151. package/dist/modules/oauth/unlinkIdentity.d.ts +0 -12
  152. package/dist/modules/push/getNotificationPreferences.d.ts +0 -11
  153. package/dist/modules/push/index.d.ts +0 -2
  154. package/dist/modules/push/updateNotificationPreferences.d.ts +0 -16
  155. package/dist/modules/reports/createReport.d.ts +0 -9
  156. package/dist/modules/reports/fetchModeratedReports.d.ts +0 -13
  157. package/dist/modules/reports/index.d.ts +0 -2
  158. package/dist/modules/search/askContent.d.ts +0 -58
  159. package/dist/modules/search/index.d.ts +0 -5
  160. package/dist/modules/search/matchUsers.d.ts +0 -36
  161. package/dist/modules/search/searchContent.d.ts +0 -24
  162. package/dist/modules/search/searchSpaces.d.ts +0 -11
  163. package/dist/modules/search/searchUsers.d.ts +0 -11
  164. package/dist/modules/spaces/approveMembership.d.ts +0 -7
  165. package/dist/modules/spaces/banMember.d.ts +0 -13
  166. package/dist/modules/spaces/checkMyMembership.d.ts +0 -6
  167. package/dist/modules/spaces/checkSlugAvailability.d.ts +0 -8
  168. package/dist/modules/spaces/createRule.d.ts +0 -8
  169. package/dist/modules/spaces/createSpace.d.ts +0 -29
  170. package/dist/modules/spaces/declineMembership.d.ts +0 -7
  171. package/dist/modules/spaces/deleteRule.d.ts +0 -7
  172. package/dist/modules/spaces/deleteSpace.d.ts +0 -6
  173. package/dist/modules/spaces/fetchChildSpaces.d.ts +0 -11
  174. package/dist/modules/spaces/fetchDigestConfig.d.ts +0 -6
  175. package/dist/modules/spaces/fetchManyRules.d.ts +0 -6
  176. package/dist/modules/spaces/fetchManySpaces.d.ts +0 -17
  177. package/dist/modules/spaces/fetchMutualSpaces.d.ts +0 -11
  178. package/dist/modules/spaces/fetchRule.d.ts +0 -7
  179. package/dist/modules/spaces/fetchSpace.d.ts +0 -6
  180. package/dist/modules/spaces/fetchSpaceBreadcrumb.d.ts +0 -6
  181. package/dist/modules/spaces/fetchSpaceByShortId.d.ts +0 -6
  182. package/dist/modules/spaces/fetchSpaceBySlug.d.ts +0 -6
  183. package/dist/modules/spaces/fetchSpaceMembers.d.ts +0 -11
  184. package/dist/modules/spaces/fetchSpaceTeam.d.ts +0 -7
  185. package/dist/modules/spaces/fetchUserSpaces.d.ts +0 -17
  186. package/dist/modules/spaces/getSpaceConversation.d.ts +0 -6
  187. package/dist/modules/spaces/handleCommentReport.d.ts +0 -14
  188. package/dist/modules/spaces/handleEntityReport.d.ts +0 -17
  189. package/dist/modules/spaces/handleSpaceChatReport.d.ts +0 -18
  190. package/dist/modules/spaces/index.d.ts +0 -36
  191. package/dist/modules/spaces/joinSpace.d.ts +0 -6
  192. package/dist/modules/spaces/leaveSpace.d.ts +0 -6
  193. package/dist/modules/spaces/moderateSpaceChatMessage.d.ts +0 -12
  194. package/dist/modules/spaces/moderateSpaceComment.d.ts +0 -9
  195. package/dist/modules/spaces/moderateSpaceEntity.d.ts +0 -12
  196. package/dist/modules/spaces/reorderRules.d.ts +0 -7
  197. package/dist/modules/spaces/setSpaceEntityNsfw.d.ts +0 -16
  198. package/dist/modules/spaces/unbanMember.d.ts +0 -13
  199. package/dist/modules/spaces/updateDigestConfig.d.ts +0 -11
  200. package/dist/modules/spaces/updateMemberRole.d.ts +0 -8
  201. package/dist/modules/spaces/updateRule.d.ts +0 -9
  202. package/dist/modules/spaces/updateSpace.d.ts +0 -22
  203. package/dist/modules/storage/deleteFile.d.ts +0 -5
  204. package/dist/modules/storage/getFile.d.ts +0 -34
  205. package/dist/modules/storage/index.d.ts +0 -4
  206. package/dist/modules/storage/uploadFile.d.ts +0 -30
  207. package/dist/modules/storage/uploadImage.d.ts +0 -42
  208. package/dist/modules/tables/bulkCreate.d.ts +0 -4
  209. package/dist/modules/tables/bulkDelete.d.ts +0 -7
  210. package/dist/modules/tables/create.d.ts +0 -4
  211. package/dist/modules/tables/createTableAccessor.d.ts +0 -9
  212. package/dist/modules/tables/deleteRow.d.ts +0 -9
  213. package/dist/modules/tables/find.d.ts +0 -8
  214. package/dist/modules/tables/findOne.d.ts +0 -7
  215. package/dist/modules/tables/index.d.ts +0 -9
  216. package/dist/modules/tables/restore.d.ts +0 -6
  217. package/dist/modules/tables/update.d.ts +0 -4
  218. package/dist/modules/users/checkUsernameAvailability.d.ts +0 -8
  219. package/dist/modules/users/createBlock.d.ts +0 -19
  220. package/dist/modules/users/createFollow.d.ts +0 -7
  221. package/dist/modules/users/deleteBlock.d.ts +0 -13
  222. package/dist/modules/users/deleteFollow.d.ts +0 -6
  223. package/dist/modules/users/fetchBlockStatus.d.ts +0 -23
  224. package/dist/modules/users/fetchBlockedUsers.d.ts +0 -19
  225. package/dist/modules/users/fetchConnectionStatus.d.ts +0 -10
  226. package/dist/modules/users/fetchConnectionsByUserId.d.ts +0 -11
  227. package/dist/modules/users/fetchConnectionsCountByUserId.d.ts +0 -6
  228. package/dist/modules/users/fetchFollowStatus.d.ts +0 -14
  229. package/dist/modules/users/fetchFollowersByUserId.d.ts +0 -11
  230. package/dist/modules/users/fetchFollowersCountByUserId.d.ts +0 -8
  231. package/dist/modules/users/fetchFollowingByUserId.d.ts +0 -11
  232. package/dist/modules/users/fetchFollowingCountByUserId.d.ts +0 -8
  233. package/dist/modules/users/fetchUserByForeignId.d.ts +0 -8
  234. package/dist/modules/users/fetchUserById.d.ts +0 -8
  235. package/dist/modules/users/fetchUserByUsername.d.ts +0 -8
  236. package/dist/modules/users/fetchUserSuggestions.d.ts +0 -7
  237. package/dist/modules/users/index.d.ts +0 -22
  238. package/dist/modules/users/removeConnectionByUserId.d.ts +0 -10
  239. package/dist/modules/users/requestConnection.d.ts +0 -11
  240. package/dist/modules/users/updateUser.d.ts +0 -32
  241. package/dist/modules/workspaces/acceptInvite.d.ts +0 -13
  242. package/dist/modules/workspaces/acceptWorkspaceInvite.d.ts +0 -13
  243. package/dist/modules/workspaces/createInvite.d.ts +0 -17
  244. package/dist/modules/workspaces/createWorkspace.d.ts +0 -12
  245. package/dist/modules/workspaces/createWorkspaceInvite.d.ts +0 -17
  246. package/dist/modules/workspaces/declineInvite.d.ts +0 -12
  247. package/dist/modules/workspaces/declineWorkspaceInvite.d.ts +0 -14
  248. package/dist/modules/workspaces/deleteWorkspace.d.ts +0 -13
  249. package/dist/modules/workspaces/fetchManyWorkspaces.d.ts +0 -13
  250. package/dist/modules/workspaces/fetchMembers.d.ts +0 -13
  251. package/dist/modules/workspaces/fetchMyInvites.d.ts +0 -11
  252. package/dist/modules/workspaces/fetchMyWorkspaceInvites.d.ts +0 -15
  253. package/dist/modules/workspaces/fetchWorkspace.d.ts +0 -7
  254. package/dist/modules/workspaces/fetchWorkspaceAuthority.d.ts +0 -11
  255. package/dist/modules/workspaces/fetchWorkspaceInvites.d.ts +0 -17
  256. package/dist/modules/workspaces/fetchWorkspaceMemberStanding.d.ts +0 -11
  257. package/dist/modules/workspaces/fetchWorkspaceMembers.d.ts +0 -13
  258. package/dist/modules/workspaces/getAuthority.d.ts +0 -11
  259. package/dist/modules/workspaces/index.d.ts +0 -21
  260. package/dist/modules/workspaces/leaveWorkspace.d.ts +0 -11
  261. package/dist/modules/workspaces/removeWorkspaceMember.d.ts +0 -12
  262. package/dist/modules/workspaces/removeWorkspaceMemberFromSubtree.d.ts +0 -16
  263. package/dist/modules/workspaces/resendWorkspaceInvite.d.ts +0 -12
  264. package/dist/modules/workspaces/revokeWorkspaceInvite.d.ts +0 -13
  265. package/dist/modules/workspaces/transferWorkspaceOwnership.d.ts +0 -15
  266. package/dist/modules/workspaces/updateWorkspace.d.ts +0 -12
  267. package/dist/modules/workspaces/updateWorkspaceInheritFlag.d.ts +0 -13
  268. package/dist/modules/workspaces/updateWorkspaceMember.d.ts +0 -17
@@ -1,258 +0,0 @@
1
- type AppNotificationType = "system" | "entity-comment" | "comment-reply" | "entity-mention" | "comment-mention" | "entity-upvote" | "comment-upvote" | "entity-reaction" | "comment-reaction" | "entity-reaction-milestone-specific" | "entity-reaction-milestone-total" | "comment-reaction-milestone-specific" | "comment-reaction-milestone-total" | "new-follow" | "connection-request" | "connection-accepted" | "space-membership-approved";
2
- interface BaseAppNotification {
3
- id: string;
4
- userId: string;
5
- type: AppNotificationType;
6
- isRead: boolean;
7
- metadata: Record<string, any>;
8
- createdAt: string;
9
- }
10
- export interface SystemNotification extends BaseAppNotification {
11
- type: "system";
12
- action: string;
13
- metadata: {
14
- title?: string;
15
- content?: string;
16
- buttonData: {
17
- text: string;
18
- url: string;
19
- } | null;
20
- };
21
- }
22
- export interface EntityCommentNotification extends BaseAppNotification {
23
- type: "entity-comment";
24
- action: "open-comment";
25
- metadata: {
26
- entityId: string;
27
- entityShortId: string;
28
- entityTitle: string | null | undefined;
29
- entityContent: string | null | undefined;
30
- commentId: string;
31
- commentContent: string | null | undefined;
32
- initiatorId: string;
33
- initiatorName: string | null | undefined;
34
- initiatorUsername: string | null | undefined;
35
- initiatorAvatar: string | null | undefined;
36
- };
37
- }
38
- export interface CommentReplyNotification extends BaseAppNotification {
39
- type: "comment-reply";
40
- action: "open-comment";
41
- metadata: {
42
- entityId: string;
43
- entityShortId: string;
44
- entityTitle: string | null | undefined;
45
- entityContent: string | null | undefined;
46
- commentId: string;
47
- commentContent: string | null | undefined;
48
- replyId: string;
49
- replyContent: string | null | undefined;
50
- initiatorId: string;
51
- initiatorName: string | null | undefined;
52
- initiatorUsername: string | null | undefined;
53
- initiatorAvatar: string | null | undefined;
54
- };
55
- }
56
- export interface EntityMentionNotification extends BaseAppNotification {
57
- type: "entity-mention";
58
- action: "open-entity";
59
- metadata: {
60
- entityId: string;
61
- entityShortId: string;
62
- entityTitle: string | null | undefined;
63
- entityContent: string | null | undefined;
64
- initiatorId: string;
65
- initiatorName: string | null | undefined;
66
- initiatorUsername: string | null | undefined;
67
- initiatorAvatar: string | null | undefined;
68
- };
69
- }
70
- export interface CommentMentionNotification extends BaseAppNotification {
71
- type: "comment-mention";
72
- action: "open-comment";
73
- metadata: {
74
- entityId: string;
75
- entityShortId: string;
76
- entityTitle: string | null | undefined;
77
- entityContent: string | null | undefined;
78
- commentId: string;
79
- commentContent: string | null | undefined;
80
- initiatorId: string;
81
- initiatorName: string | null | undefined;
82
- initiatorUsername: string | null | undefined;
83
- initiatorAvatar: string | null | undefined;
84
- };
85
- }
86
- export interface EntityUpvoteNotification extends BaseAppNotification {
87
- type: "entity-upvote";
88
- action: "open-entity";
89
- metadata: {
90
- entityId: string;
91
- entityShortId: string;
92
- entityTitle: string | null | undefined;
93
- entityContent: string | null | undefined;
94
- initiatorId: string;
95
- initiatorName: string | null | undefined;
96
- initiatorUsername: string | null | undefined;
97
- initiatorAvatar: string | null | undefined;
98
- };
99
- }
100
- export interface CommentUpvoteNotification extends BaseAppNotification {
101
- type: "comment-upvote";
102
- action: "open-comment";
103
- metadata: {
104
- entityId: string;
105
- entityShortId: string;
106
- entityTitle: string | null | undefined;
107
- entityContent: string | null | undefined;
108
- commentId: string;
109
- commentContent: string | null | undefined;
110
- initiatorId: string;
111
- initiatorName: string | null | undefined;
112
- initiatorUsername: string | null | undefined;
113
- initiatorAvatar: string | null | undefined;
114
- };
115
- }
116
- export interface EntityReactionNotification extends BaseAppNotification {
117
- type: "entity-reaction";
118
- action: "open-entity";
119
- metadata: {
120
- entityId: string;
121
- entityShortId: string;
122
- entityTitle: string | null | undefined;
123
- entityContent: string | null | undefined;
124
- reactionType: string;
125
- initiatorId: string;
126
- initiatorName: string | null | undefined;
127
- initiatorUsername: string | null | undefined;
128
- initiatorAvatar: string | null | undefined;
129
- };
130
- }
131
- export interface CommentReactionNotification extends BaseAppNotification {
132
- type: "comment-reaction";
133
- action: "open-comment";
134
- metadata: {
135
- entityId: string;
136
- entityShortId: string;
137
- entityTitle: string | null | undefined;
138
- entityContent: string | null | undefined;
139
- commentId: string;
140
- commentContent: string | null | undefined;
141
- reactionType: string;
142
- initiatorId: string;
143
- initiatorName: string | null | undefined;
144
- initiatorUsername: string | null | undefined;
145
- initiatorAvatar: string | null | undefined;
146
- };
147
- }
148
- interface MilestoneUser {
149
- id: string;
150
- name: string | null | undefined;
151
- username: string | null | undefined;
152
- avatar: string | null | undefined;
153
- }
154
- export interface EntityReactionMilestoneSpecificNotification extends BaseAppNotification {
155
- type: "entity-reaction-milestone-specific";
156
- action: "open-entity";
157
- metadata: {
158
- entityId: string;
159
- entityShortId: string;
160
- entityTitle: string | null | undefined;
161
- entityContent: string | null | undefined;
162
- reactionType: string;
163
- milestoneCount: number;
164
- lastThreeUsers: MilestoneUser[];
165
- };
166
- }
167
- export interface EntityReactionMilestoneTotalNotification extends BaseAppNotification {
168
- type: "entity-reaction-milestone-total";
169
- action: "open-entity";
170
- metadata: {
171
- entityId: string;
172
- entityShortId: string;
173
- entityTitle: string | null | undefined;
174
- entityContent: string | null | undefined;
175
- milestoneCount: number;
176
- reactionCounts: Record<string, number>;
177
- lastThreeUsers: MilestoneUser[];
178
- };
179
- }
180
- export interface CommentReactionMilestoneSpecificNotification extends BaseAppNotification {
181
- type: "comment-reaction-milestone-specific";
182
- action: "open-comment";
183
- metadata: {
184
- entityId: string;
185
- entityShortId: string;
186
- entityTitle: string | null | undefined;
187
- entityContent: string | null | undefined;
188
- commentId: string;
189
- commentContent: string | null | undefined;
190
- reactionType: string;
191
- milestoneCount: number;
192
- lastThreeUsers: MilestoneUser[];
193
- };
194
- }
195
- export interface CommentReactionMilestoneTotalNotification extends BaseAppNotification {
196
- type: "comment-reaction-milestone-total";
197
- action: "open-comment";
198
- metadata: {
199
- entityId: string;
200
- entityShortId: string;
201
- entityTitle: string | null | undefined;
202
- entityContent: string | null | undefined;
203
- commentId: string;
204
- commentContent: string | null | undefined;
205
- milestoneCount: number;
206
- reactionCounts: Record<string, number>;
207
- lastThreeUsers: MilestoneUser[];
208
- };
209
- }
210
- export interface SpaceMembershipApprovedNotification extends BaseAppNotification {
211
- type: "space-membership-approved";
212
- action: "open-space";
213
- metadata: {
214
- spaceId: string;
215
- spaceName: string;
216
- spaceShortId: string;
217
- spaceSlug: string | null | undefined;
218
- spaceAvatar: string | null | undefined;
219
- };
220
- }
221
- export interface NewFollowNotification extends BaseAppNotification {
222
- type: "new-follow";
223
- action: "open-profile";
224
- metadata: {
225
- initiatorId: string;
226
- initiatorName: string | null | undefined;
227
- initiatorUsername: string | null | undefined;
228
- initiatorAvatar: string | null | undefined;
229
- };
230
- }
231
- export interface ConnectionRequestNotification extends BaseAppNotification {
232
- type: "connection-request";
233
- action: "open-profile";
234
- metadata: {
235
- connectionId: string;
236
- initiatorId: string;
237
- initiatorName: string | null | undefined;
238
- initiatorUsername: string | null | undefined;
239
- initiatorAvatar: string | null | undefined;
240
- };
241
- }
242
- export interface ConnectionAcceptedNotification extends BaseAppNotification {
243
- type: "connection-accepted";
244
- action: "open-profile";
245
- metadata: {
246
- connectionId: string;
247
- initiatorId: string;
248
- initiatorName: string | null | undefined;
249
- initiatorUsername: string | null | undefined;
250
- initiatorAvatar: string | null | undefined;
251
- };
252
- }
253
- export type UnifiedAppNotification = SystemNotification | EntityCommentNotification | CommentReplyNotification | EntityMentionNotification | CommentMentionNotification | EntityUpvoteNotification | CommentUpvoteNotification | EntityReactionNotification | CommentReactionNotification | EntityReactionMilestoneSpecificNotification | EntityReactionMilestoneTotalNotification | CommentReactionMilestoneSpecificNotification | CommentReactionMilestoneTotalNotification | NewFollowNotification | ConnectionRequestNotification | ConnectionAcceptedNotification | SpaceMembershipApprovedNotification;
254
- export type PotentiallyPopulatedUnifiedAppNotification = UnifiedAppNotification & {
255
- title?: string;
256
- content?: string;
257
- };
258
- export {};
@@ -1,32 +0,0 @@
1
- import { GifData } from "./Comment";
2
- import { File } from "./File";
3
- import { Mention } from "./Mention";
4
- import { User } from "./User";
5
- export interface ChatMessage {
6
- id: string;
7
- projectId: string;
8
- conversationId: string;
9
- userId: string | null;
10
- content: string | null;
11
- gif: GifData | null;
12
- mentions: Mention[];
13
- files?: File[];
14
- metadata: Record<string, any>;
15
- parentMessageId: string | null;
16
- quotedMessageId: string | null;
17
- threadReplyCount: number;
18
- reactionCounts: Record<string, number>;
19
- userReactions: string[];
20
- editedAt: string | null;
21
- userDeletedAt: string | null;
22
- moderationStatus: "approved" | "removed" | null;
23
- moderatedAt: string | null;
24
- moderatedById: string | null;
25
- moderatedByType: "client" | "user" | null;
26
- moderationReason: string | null;
27
- createdAt: string;
28
- updatedAt: string;
29
- user: User | null;
30
- quotedMessage?: ChatMessage | null;
31
- parentMessage?: ChatMessage | null;
32
- }
@@ -1,10 +0,0 @@
1
- export interface Collection {
2
- id: string;
3
- projectId: string;
4
- userId: string;
5
- parentId: string | null;
6
- name: string;
7
- entityCount: number;
8
- createdAt: string;
9
- updatedAt: string;
10
- }
@@ -1,42 +0,0 @@
1
- import { Entity } from "./Entity";
2
- import { Mention } from "./Mention";
3
- import { User } from "./User";
4
- import { ReactionCounts, ReactionType } from "./Reaction";
5
- export interface GifData {
6
- id: string;
7
- url: string;
8
- gifUrl: string;
9
- gifPreviewUrl: string;
10
- altText: string;
11
- aspectRatio: string;
12
- }
13
- export interface Comment {
14
- id: string;
15
- projectId: string;
16
- foreignId: string | null;
17
- entityId: string;
18
- entity?: Entity;
19
- userId: string;
20
- user?: User;
21
- parentId: string | null;
22
- parentComment?: Comment;
23
- content: string | null;
24
- gif: GifData | null;
25
- mentions: Mention[];
26
- upvotes: string[];
27
- downvotes: string[];
28
- reactionCounts: ReactionCounts;
29
- userReaction?: ReactionType | null;
30
- repliesCount: number;
31
- metadata: Record<string, any>;
32
- createdAt: string;
33
- updatedAt: string;
34
- deletedAt: string | null;
35
- parentDeletedAt: string | null;
36
- userDeletedAt: string | null;
37
- moderationStatus: "approved" | "removed" | null;
38
- moderatedAt: string | null;
39
- moderatedById: string | null;
40
- moderatedByType: "client" | "user" | null;
41
- moderationReason: string | null;
42
- }
@@ -1,67 +0,0 @@
1
- import { User } from "./User";
2
- export interface Connection {
3
- id: string;
4
- message?: string;
5
- createdAt: string;
6
- }
7
- /** Returned by `POST /users/:userId/connection` (requestConnection). */
8
- export interface ConnectionRequestResponse {
9
- id: string;
10
- status: string;
11
- createdAt: string;
12
- }
13
- export interface EstablishedConnection {
14
- id: string;
15
- connectedUser: User;
16
- connectedAt: string;
17
- }
18
- export interface PendingConnection extends Connection {
19
- user: User;
20
- type: "received" | "sent";
21
- }
22
- export interface ConnectionRequestParams {
23
- userId: string;
24
- message?: string;
25
- }
26
- export interface ConnectionActionResponse {
27
- id: string;
28
- status: string;
29
- createdAt?: string;
30
- respondedAt?: string;
31
- }
32
- export interface ConnectionWithdrawResponse {
33
- message: string;
34
- }
35
- export interface ConnectionCountResponse {
36
- count: number;
37
- }
38
- export interface RemoveConnectionByUserIdResponse {
39
- id?: string;
40
- status?: string;
41
- respondedAt?: string;
42
- message?: string;
43
- action?: "withdraw" | "disconnect" | "decline";
44
- }
45
- export interface ConnectionStatusNone {
46
- status: "none";
47
- }
48
- export interface ConnectionStatusPending {
49
- status: "pending";
50
- type: "sent" | "received";
51
- connectionId: string;
52
- createdAt: string;
53
- }
54
- export interface ConnectionStatusConnected {
55
- status: "connected";
56
- connectionId: string;
57
- connectedAt: string;
58
- requestedAt: string;
59
- }
60
- export interface ConnectionStatusDeclined {
61
- status: "declined";
62
- type: "sent" | "received";
63
- connectionId: string;
64
- respondedAt: string;
65
- }
66
- export type ConnectionStatusResponse = ConnectionStatusNone | ConnectionStatusPending | ConnectionStatusConnected | ConnectionStatusDeclined;
67
- export type ConnectionStatus = "none" | "pending-sent" | "pending-received" | "connected" | "declined-sent" | "declined-received";
@@ -1,27 +0,0 @@
1
- import { File } from "./File";
2
- import { ChatMessage } from "./ChatMessage";
3
- import { ConversationMember } from "./ConversationMember";
4
- import { User } from "./User";
5
- export interface Conversation {
6
- id: string;
7
- projectId: string;
8
- type: "direct" | "group" | "space";
9
- name: string | null;
10
- description: string | null;
11
- spaceId: string | null;
12
- createdById: string | null;
13
- avatarFileId: string | null;
14
- lastMessageAt: string | null;
15
- postingPermission: "members" | "admins" | null;
16
- metadata: Record<string, any>;
17
- createdAt: string;
18
- updatedAt: string;
19
- memberCount?: number;
20
- currentMember?: ConversationMember;
21
- avatarFile?: File;
22
- }
23
- export interface ConversationPreview extends Conversation {
24
- unreadCount: number;
25
- lastMessage: ChatMessage | null;
26
- otherMembers?: Pick<User, "id" | "name" | "username" | "avatar">[];
27
- }
@@ -1,17 +0,0 @@
1
- import { User } from "./User";
2
- export type ConversationMemberRole = "admin" | "member";
3
- export interface ConversationMember {
4
- id: string;
5
- projectId: string;
6
- conversationId: string;
7
- userId: string;
8
- role: ConversationMemberRole | null;
9
- lastReadAt: string | null;
10
- mutedUntil?: string | null;
11
- mutedForever?: boolean;
12
- isActive: boolean;
13
- leftAt: string | null;
14
- createdAt: string;
15
- updatedAt: string;
16
- user?: User;
17
- }
@@ -1,55 +0,0 @@
1
- import { Mention } from "./Mention";
2
- import { User } from "./User";
3
- import { Space } from "./Space";
4
- import { ReactionCounts, ReactionType } from "./Reaction";
5
- import { File } from "./File";
6
- export interface TopComment {
7
- id: string;
8
- user: User;
9
- upvotesCount: number;
10
- content: string;
11
- createdAt: string;
12
- }
13
- export interface Entity {
14
- id: string;
15
- foreignId: string | null;
16
- shortId: string;
17
- projectId: string;
18
- sourceId: string | null;
19
- spaceId: string | null;
20
- space?: Space | null;
21
- userId: string | null;
22
- user?: User | null;
23
- title: string | null;
24
- content: string | null;
25
- mentions: Mention[];
26
- attachments: Record<string, any>[];
27
- files?: File[];
28
- keywords: string[];
29
- upvotes: string[];
30
- downvotes: string[];
31
- reactionCounts: ReactionCounts;
32
- userReaction?: ReactionType | null;
33
- repliesCount: number;
34
- views: number;
35
- score: number;
36
- scoreUpdatedAt: string;
37
- location: {
38
- type: "Point";
39
- coordinates: [number, number];
40
- } | null;
41
- metadata: Record<string, any>;
42
- nsfw: boolean;
43
- nsfwEffective: boolean;
44
- topComment: TopComment | null;
45
- isSaved?: boolean;
46
- isDraft: boolean | null;
47
- moderationStatus: "approved" | "removed" | null;
48
- moderatedAt: string | null;
49
- moderatedById: string | null;
50
- moderatedByType: "client" | "user" | null;
51
- moderationReason: string | null;
52
- createdAt: string;
53
- updatedAt: string;
54
- deletedAt: string | null;
55
- }
@@ -1,66 +0,0 @@
1
- import { User } from "./User";
2
- import { Space } from "./Space";
3
- import { File } from "./File";
4
- export type EventType = "online" | "physical" | "hybrid";
5
- export type EventVisibility = "public" | "members" | "invite";
6
- export type EventStatus = "active" | "cancelled";
7
- export type RsvpStatus = "going" | "maybe" | "not_going";
8
- export interface RsvpCounts {
9
- going: number;
10
- maybe: number;
11
- not_going: number;
12
- }
13
- export interface Event {
14
- id: string;
15
- shortId: string;
16
- projectId: string;
17
- userId: string | null;
18
- user?: User | null;
19
- title: string;
20
- description: string | null;
21
- startTime: string;
22
- endTime: string | null;
23
- timezone: string | null;
24
- type: EventType;
25
- url: string | null;
26
- venueName: string | null;
27
- address: string | null;
28
- location: {
29
- type: "Point";
30
- coordinates: [number, number];
31
- } | null;
32
- spaceId: string | null;
33
- space?: Space | null;
34
- visibility: EventVisibility;
35
- status: EventStatus;
36
- allowMaybe: boolean;
37
- guestListVisible: boolean;
38
- capacity: number | null;
39
- hostIds: string[];
40
- coverImageId: string | null;
41
- files?: File[];
42
- rsvpCounts: RsvpCounts;
43
- userRsvp?: RsvpStatus | null;
44
- metadata: Record<string, any>;
45
- createdAt: string;
46
- updatedAt: string;
47
- deletedAt: string | null;
48
- }
49
- export interface EventRsvp {
50
- id: string;
51
- eventId: string;
52
- userId: string;
53
- user?: User | null;
54
- status: RsvpStatus;
55
- createdAt: string;
56
- updatedAt: string;
57
- }
58
- export interface EventInvite {
59
- id: string;
60
- eventId: string;
61
- userId: string;
62
- user?: User | null;
63
- invitedAt: string;
64
- createdAt: string;
65
- updatedAt: string;
66
- }
@@ -1,39 +0,0 @@
1
- export interface FileImageVariant {
2
- path: string;
3
- publicPath: string;
4
- width: number;
5
- height: number;
6
- size: number;
7
- format: string;
8
- }
9
- export interface FileImage {
10
- fileId: string;
11
- originalWidth: number;
12
- originalHeight: number;
13
- variants: Record<string, FileImageVariant>;
14
- processingStatus: "completed" | "failed";
15
- processingError: string | null;
16
- format: string;
17
- quality: number;
18
- exifStripped: boolean;
19
- createdAt: string;
20
- updatedAt: string;
21
- }
22
- export interface File {
23
- id: string;
24
- projectId: string;
25
- userId: string | null;
26
- entityId: string | null;
27
- commentId: string | null;
28
- chatMessageId: string | null;
29
- spaceId: string | null;
30
- type: "image" | "video" | "document" | "other";
31
- originalPath: string;
32
- originalSize: number;
33
- originalMimeType: string;
34
- position: number;
35
- metadata: Record<string, any>;
36
- image?: FileImage;
37
- createdAt: string;
38
- updatedAt: string;
39
- }
@@ -1,19 +0,0 @@
1
- import { User } from "./User";
2
- export interface Follow {
3
- id: string;
4
- projectId: string;
5
- followerId: string;
6
- followedId: string;
7
- createdAt: string;
8
- }
9
- /**
10
- * An entry in a follower/following list. The list endpoints
11
- * (`/follows/(followers|following)` and `/users/:userId/(followers|following)`)
12
- * return the follow id, the populated other user, and when the follow happened
13
- * — NOT the raw {@link Follow} row.
14
- */
15
- export interface FollowListItem {
16
- followId: string;
17
- user: User;
18
- followedAt: string;
19
- }
@@ -1,11 +0,0 @@
1
- export interface HostedApp {
2
- id: string;
3
- projectId: string;
4
- name: string;
5
- type: "discord-board";
6
- subdomain: string;
7
- metadata: Record<string, any>;
8
- createdAt: string;
9
- updatedAt: string;
10
- deletedAt: string | null;
11
- }
@@ -1,11 +0,0 @@
1
- export interface PaginationMetadata {
2
- page: number;
3
- pageSize: number;
4
- totalPages: number;
5
- totalItems: number;
6
- hasMore: boolean;
7
- }
8
- export interface PaginatedResponse<T> {
9
- data: T[];
10
- pagination: PaginationMetadata;
11
- }