@sublay/js 7.9.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.
- package/LICENSE +202 -0
- package/NOTICE +9 -0
- package/README.md +23 -14
- package/dist/index.d.mts +38 -7
- package/dist/index.d.ts +4363 -35
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +29 -18
- package/dist/core/client.d.ts +0 -64
- package/dist/core/multipart.d.ts +0 -22
- package/dist/core/spaceReputationParams.d.ts +0 -57
- package/dist/interfaces/AppNotification.d.ts +0 -258
- package/dist/interfaces/ChatMessage.d.ts +0 -40
- package/dist/interfaces/Collection.d.ts +0 -10
- package/dist/interfaces/Comment.d.ts +0 -50
- package/dist/interfaces/Connection.d.ts +0 -67
- package/dist/interfaces/Conversation.d.ts +0 -27
- package/dist/interfaces/ConversationMember.d.ts +0 -17
- package/dist/interfaces/Entity.d.ts +0 -63
- package/dist/interfaces/Event.d.ts +0 -66
- package/dist/interfaces/File.d.ts +0 -39
- package/dist/interfaces/Follow.d.ts +0 -19
- package/dist/interfaces/HostedApp.d.ts +0 -11
- package/dist/interfaces/IPaginatedResponse.d.ts +0 -11
- package/dist/interfaces/ImageProcessing.d.ts +0 -62
- package/dist/interfaces/Mention.d.ts +0 -12
- package/dist/interfaces/OAuthIdentity.d.ts +0 -14
- package/dist/interfaces/Project.d.ts +0 -14
- package/dist/interfaces/Push.d.ts +0 -74
- package/dist/interfaces/Reaction.d.ts +0 -23
- package/dist/interfaces/Report.d.ts +0 -38
- package/dist/interfaces/ReputationGrant.d.ts +0 -85
- package/dist/interfaces/Rule.d.ts +0 -22
- package/dist/interfaces/Space.d.ts +0 -130
- package/dist/interfaces/SpaceMember.d.ts +0 -29
- package/dist/interfaces/SpaceReputation.d.ts +0 -100
- package/dist/interfaces/Table.d.ts +0 -63
- package/dist/interfaces/User.d.ts +0 -46
- package/dist/interfaces/UserSearch.d.ts +0 -13
- package/dist/interfaces/Workspace.d.ts +0 -178
- package/dist/modules/app-notifications/countUnreadNotifications.d.ts +0 -2
- package/dist/modules/app-notifications/fetchNotifications.d.ts +0 -8
- package/dist/modules/app-notifications/index.d.ts +0 -4
- package/dist/modules/app-notifications/markAllNotificationsAsRead.d.ts +0 -5
- package/dist/modules/app-notifications/markNotificationAsRead.d.ts +0 -5
- package/dist/modules/auth/changePassword.d.ts +0 -34
- package/dist/modules/auth/confirmAccountDeletion.d.ts +0 -11
- package/dist/modules/auth/index.d.ts +0 -13
- package/dist/modules/auth/requestAccountDeletion.d.ts +0 -14
- package/dist/modules/auth/requestNewAccessToken.d.ts +0 -16
- package/dist/modules/auth/requestPasswordReset.d.ts +0 -5
- package/dist/modules/auth/resetPassword.d.ts +0 -6
- package/dist/modules/auth/sendVerificationEmail.d.ts +0 -13
- package/dist/modules/auth/setPassword.d.ts +0 -9
- package/dist/modules/auth/signIn.d.ts +0 -12
- package/dist/modules/auth/signOut.d.ts +0 -103
- package/dist/modules/auth/signUp.d.ts +0 -24
- package/dist/modules/auth/verifyEmail.d.ts +0 -5
- package/dist/modules/auth/verifyExternalUser.d.ts +0 -11
- package/dist/modules/chat/addMember.d.ts +0 -8
- package/dist/modules/chat/changeMemberRole.d.ts +0 -9
- package/dist/modules/chat/createDirectConversation.d.ts +0 -7
- package/dist/modules/chat/createGroupConversation.d.ts +0 -10
- package/dist/modules/chat/deleteConversation.d.ts +0 -8
- package/dist/modules/chat/deleteMessage.d.ts +0 -11
- package/dist/modules/chat/editMessage.d.ts +0 -14
- package/dist/modules/chat/getConversation.d.ts +0 -6
- package/dist/modules/chat/getMessage.d.ts +0 -13
- package/dist/modules/chat/getUnreadCount.d.ts +0 -6
- package/dist/modules/chat/index.d.ts +0 -21
- package/dist/modules/chat/leaveConversation.d.ts +0 -7
- package/dist/modules/chat/listConversations.d.ts +0 -17
- package/dist/modules/chat/listMembers.d.ts +0 -11
- package/dist/modules/chat/listMessages.d.ts +0 -44
- package/dist/modules/chat/listReactions.d.ts +0 -24
- package/dist/modules/chat/markAsRead.d.ts +0 -9
- package/dist/modules/chat/muteConversation.d.ts +0 -23
- package/dist/modules/chat/removeMember.d.ts +0 -9
- package/dist/modules/chat/reportMessage.d.ts +0 -12
- package/dist/modules/chat/sendMessage.d.ts +0 -22
- package/dist/modules/chat/toggleReaction.d.ts +0 -16
- package/dist/modules/chat/updateConversation.d.ts +0 -12
- package/dist/modules/collections/addEntityToCollection.d.ts +0 -13
- package/dist/modules/collections/createNewCollection.d.ts +0 -8
- package/dist/modules/collections/deleteCollection.d.ts +0 -5
- package/dist/modules/collections/fetchCollectionEntities.d.ts +0 -13
- package/dist/modules/collections/fetchRootCollection.d.ts +0 -3
- package/dist/modules/collections/fetchSubCollections.d.ts +0 -6
- package/dist/modules/collections/index.d.ts +0 -8
- package/dist/modules/collections/removeEntityFromCollection.d.ts +0 -7
- package/dist/modules/collections/updateCollection.d.ts +0 -7
- package/dist/modules/comments/addReaction.d.ts +0 -8
- package/dist/modules/comments/createComment.d.ts +0 -15
- package/dist/modules/comments/deleteComment.d.ts +0 -5
- package/dist/modules/comments/fetchComment.d.ts +0 -8
- package/dist/modules/comments/fetchCommentByForeignId.d.ts +0 -7
- package/dist/modules/comments/fetchManyComments.d.ts +0 -26
- package/dist/modules/comments/fetchReactions.d.ts +0 -16
- package/dist/modules/comments/getUserReaction.d.ts +0 -9
- package/dist/modules/comments/index.d.ts +0 -10
- package/dist/modules/comments/removeReaction.d.ts +0 -6
- package/dist/modules/comments/updateComment.d.ts +0 -10
- package/dist/modules/connections/acceptConnection.d.ts +0 -6
- package/dist/modules/connections/declineConnection.d.ts +0 -6
- package/dist/modules/connections/fetchConnections.d.ts +0 -9
- package/dist/modules/connections/fetchConnectionsCount.d.ts +0 -3
- package/dist/modules/connections/fetchReceivedPendingConnections.d.ts +0 -8
- package/dist/modules/connections/fetchSentPendingConnections.d.ts +0 -8
- package/dist/modules/connections/index.d.ts +0 -7
- package/dist/modules/connections/removeConnection.d.ts +0 -5
- package/dist/modules/entities/addReaction.d.ts +0 -8
- package/dist/modules/entities/createEntity.d.ts +0 -23
- package/dist/modules/entities/deleteEntity.d.ts +0 -5
- package/dist/modules/entities/fetchDrafts.d.ts +0 -11
- package/dist/modules/entities/fetchEntity.d.ts +0 -8
- package/dist/modules/entities/fetchEntityByForeignId.d.ts +0 -8
- package/dist/modules/entities/fetchEntityByShortId.d.ts +0 -7
- package/dist/modules/entities/fetchManyEntities.d.ts +0 -65
- package/dist/modules/entities/fetchReactions.d.ts +0 -16
- package/dist/modules/entities/fetchTopComment.d.ts +0 -6
- package/dist/modules/entities/getUserReaction.d.ts +0 -9
- package/dist/modules/entities/index.d.ts +0 -15
- package/dist/modules/entities/isEntitySaved.d.ts +0 -12
- package/dist/modules/entities/publishDraft.d.ts +0 -6
- package/dist/modules/entities/removeReaction.d.ts +0 -6
- package/dist/modules/entities/updateEntity.d.ts +0 -18
- package/dist/modules/events/addHost.d.ts +0 -8
- package/dist/modules/events/addInvite.d.ts +0 -8
- package/dist/modules/events/cancelEvent.d.ts +0 -6
- package/dist/modules/events/createEvent.d.ts +0 -49
- package/dist/modules/events/deleteEvent.d.ts +0 -5
- package/dist/modules/events/fetchEvent.d.ts +0 -8
- package/dist/modules/events/fetchEventRsvps.d.ts +0 -19
- package/dist/modules/events/fetchInvitees.d.ts +0 -12
- package/dist/modules/events/fetchManyEvents.d.ts +0 -42
- package/dist/modules/events/index.d.ts +0 -14
- package/dist/modules/events/removeHost.d.ts +0 -8
- package/dist/modules/events/removeInvite.d.ts +0 -8
- package/dist/modules/events/setRsvp.d.ts +0 -7
- package/dist/modules/events/updateEvent.d.ts +0 -43
- package/dist/modules/events/withdrawRsvp.d.ts +0 -6
- package/dist/modules/follows/deleteFollow.d.ts +0 -5
- package/dist/modules/follows/fetchFollowers.d.ts +0 -9
- package/dist/modules/follows/fetchFollowersCount.d.ts +0 -5
- package/dist/modules/follows/fetchFollowing.d.ts +0 -9
- package/dist/modules/follows/fetchFollowingCount.d.ts +0 -5
- package/dist/modules/follows/index.d.ts +0 -5
- package/dist/modules/oauth/authorize.d.ts +0 -25
- package/dist/modules/oauth/index.d.ts +0 -4
- package/dist/modules/oauth/linkIdentity.d.ts +0 -14
- package/dist/modules/oauth/listIdentities.d.ts +0 -4
- package/dist/modules/oauth/unlinkIdentity.d.ts +0 -12
- package/dist/modules/push/getNotificationPreferences.d.ts +0 -11
- package/dist/modules/push/index.d.ts +0 -2
- package/dist/modules/push/updateNotificationPreferences.d.ts +0 -16
- package/dist/modules/reports/createReport.d.ts +0 -9
- package/dist/modules/reports/fetchModeratedReports.d.ts +0 -13
- package/dist/modules/reports/index.d.ts +0 -2
- package/dist/modules/reputation/createGrant.d.ts +0 -45
- package/dist/modules/reputation/index.d.ts +0 -2
- package/dist/modules/reputation/listGrants.d.ts +0 -45
- package/dist/modules/search/askContent.d.ts +0 -58
- package/dist/modules/search/index.d.ts +0 -5
- package/dist/modules/search/matchUsers.d.ts +0 -36
- package/dist/modules/search/searchContent.d.ts +0 -24
- package/dist/modules/search/searchSpaces.d.ts +0 -11
- package/dist/modules/search/searchUsers.d.ts +0 -11
- package/dist/modules/spaces/approveMembership.d.ts +0 -7
- package/dist/modules/spaces/banMember.d.ts +0 -13
- package/dist/modules/spaces/checkMyMembership.d.ts +0 -6
- package/dist/modules/spaces/checkSlugAvailability.d.ts +0 -8
- package/dist/modules/spaces/createRule.d.ts +0 -8
- package/dist/modules/spaces/createSpace.d.ts +0 -29
- package/dist/modules/spaces/declineMembership.d.ts +0 -7
- package/dist/modules/spaces/deleteRule.d.ts +0 -7
- package/dist/modules/spaces/deleteSpace.d.ts +0 -6
- package/dist/modules/spaces/fetchChildSpaces.d.ts +0 -11
- package/dist/modules/spaces/fetchDigestConfig.d.ts +0 -6
- package/dist/modules/spaces/fetchManyRules.d.ts +0 -6
- package/dist/modules/spaces/fetchManySpaces.d.ts +0 -17
- package/dist/modules/spaces/fetchMutualSpaces.d.ts +0 -11
- package/dist/modules/spaces/fetchRule.d.ts +0 -7
- package/dist/modules/spaces/fetchSpace.d.ts +0 -6
- package/dist/modules/spaces/fetchSpaceBreadcrumb.d.ts +0 -6
- package/dist/modules/spaces/fetchSpaceByShortId.d.ts +0 -6
- package/dist/modules/spaces/fetchSpaceBySlug.d.ts +0 -6
- package/dist/modules/spaces/fetchSpaceMembers.d.ts +0 -11
- package/dist/modules/spaces/fetchSpaceTeam.d.ts +0 -7
- package/dist/modules/spaces/fetchUserSpaces.d.ts +0 -17
- package/dist/modules/spaces/getSpaceConversation.d.ts +0 -6
- package/dist/modules/spaces/handleCommentReport.d.ts +0 -14
- package/dist/modules/spaces/handleEntityReport.d.ts +0 -17
- package/dist/modules/spaces/handleSpaceChatReport.d.ts +0 -18
- package/dist/modules/spaces/index.d.ts +0 -36
- package/dist/modules/spaces/joinSpace.d.ts +0 -6
- package/dist/modules/spaces/leaveSpace.d.ts +0 -6
- package/dist/modules/spaces/moderateSpaceChatMessage.d.ts +0 -12
- package/dist/modules/spaces/moderateSpaceComment.d.ts +0 -9
- package/dist/modules/spaces/moderateSpaceEntity.d.ts +0 -12
- package/dist/modules/spaces/reorderRules.d.ts +0 -7
- package/dist/modules/spaces/setSpaceEntityNsfw.d.ts +0 -16
- package/dist/modules/spaces/unbanMember.d.ts +0 -13
- package/dist/modules/spaces/updateDigestConfig.d.ts +0 -11
- package/dist/modules/spaces/updateMemberRole.d.ts +0 -8
- package/dist/modules/spaces/updateRule.d.ts +0 -9
- package/dist/modules/spaces/updateSpace.d.ts +0 -22
- package/dist/modules/storage/deleteFile.d.ts +0 -5
- package/dist/modules/storage/getFile.d.ts +0 -34
- package/dist/modules/storage/index.d.ts +0 -4
- package/dist/modules/storage/uploadFile.d.ts +0 -30
- package/dist/modules/storage/uploadImage.d.ts +0 -42
- package/dist/modules/tables/bulkCreate.d.ts +0 -4
- package/dist/modules/tables/bulkDelete.d.ts +0 -7
- package/dist/modules/tables/create.d.ts +0 -4
- package/dist/modules/tables/createTableAccessor.d.ts +0 -9
- package/dist/modules/tables/deleteRow.d.ts +0 -9
- package/dist/modules/tables/find.d.ts +0 -8
- package/dist/modules/tables/findOne.d.ts +0 -7
- package/dist/modules/tables/index.d.ts +0 -9
- package/dist/modules/tables/restore.d.ts +0 -6
- package/dist/modules/tables/update.d.ts +0 -4
- package/dist/modules/users/checkUsernameAvailability.d.ts +0 -8
- package/dist/modules/users/createBlock.d.ts +0 -19
- package/dist/modules/users/createFollow.d.ts +0 -7
- package/dist/modules/users/deleteBlock.d.ts +0 -13
- package/dist/modules/users/deleteFollow.d.ts +0 -6
- package/dist/modules/users/fetchBlockStatus.d.ts +0 -23
- package/dist/modules/users/fetchBlockedUsers.d.ts +0 -19
- package/dist/modules/users/fetchConnectionStatus.d.ts +0 -10
- package/dist/modules/users/fetchConnectionsByUserId.d.ts +0 -11
- package/dist/modules/users/fetchConnectionsCountByUserId.d.ts +0 -6
- package/dist/modules/users/fetchFollowStatus.d.ts +0 -14
- package/dist/modules/users/fetchFollowersByUserId.d.ts +0 -11
- package/dist/modules/users/fetchFollowersCountByUserId.d.ts +0 -8
- package/dist/modules/users/fetchFollowingByUserId.d.ts +0 -11
- package/dist/modules/users/fetchFollowingCountByUserId.d.ts +0 -8
- package/dist/modules/users/fetchUserByForeignId.d.ts +0 -8
- package/dist/modules/users/fetchUserById.d.ts +0 -8
- package/dist/modules/users/fetchUserByUsername.d.ts +0 -8
- package/dist/modules/users/fetchUserSuggestions.d.ts +0 -7
- package/dist/modules/users/index.d.ts +0 -22
- package/dist/modules/users/removeConnectionByUserId.d.ts +0 -10
- package/dist/modules/users/requestConnection.d.ts +0 -11
- package/dist/modules/users/updateUser.d.ts +0 -32
- package/dist/modules/workspaces/acceptInvite.d.ts +0 -13
- package/dist/modules/workspaces/acceptWorkspaceInvite.d.ts +0 -13
- package/dist/modules/workspaces/createInvite.d.ts +0 -17
- package/dist/modules/workspaces/createWorkspace.d.ts +0 -12
- package/dist/modules/workspaces/createWorkspaceInvite.d.ts +0 -66
- package/dist/modules/workspaces/declineInvite.d.ts +0 -12
- package/dist/modules/workspaces/declineWorkspaceInvite.d.ts +0 -14
- package/dist/modules/workspaces/deleteWorkspace.d.ts +0 -13
- package/dist/modules/workspaces/fetchManyWorkspaces.d.ts +0 -17
- package/dist/modules/workspaces/fetchMembers.d.ts +0 -13
- package/dist/modules/workspaces/fetchMyInvites.d.ts +0 -11
- package/dist/modules/workspaces/fetchMyWorkspaceInvites.d.ts +0 -15
- package/dist/modules/workspaces/fetchWorkspace.d.ts +0 -7
- package/dist/modules/workspaces/fetchWorkspaceAuthority.d.ts +0 -16
- package/dist/modules/workspaces/fetchWorkspaceInvites.d.ts +0 -17
- package/dist/modules/workspaces/fetchWorkspaceMemberStanding.d.ts +0 -15
- package/dist/modules/workspaces/fetchWorkspaceMembers.d.ts +0 -18
- package/dist/modules/workspaces/getAuthority.d.ts +0 -11
- package/dist/modules/workspaces/index.d.ts +0 -21
- package/dist/modules/workspaces/leaveWorkspace.d.ts +0 -12
- package/dist/modules/workspaces/removeWorkspaceMember.d.ts +0 -12
- package/dist/modules/workspaces/removeWorkspaceMemberFromSubtree.d.ts +0 -16
- package/dist/modules/workspaces/resendWorkspaceInvite.d.ts +0 -12
- package/dist/modules/workspaces/revokeWorkspaceInvite.d.ts +0 -13
- package/dist/modules/workspaces/transferWorkspaceOwnership.d.ts +0 -15
- package/dist/modules/workspaces/updateWorkspace.d.ts +0 -12
- package/dist/modules/workspaces/updateWorkspaceInheritFlag.d.ts +0 -13
- package/dist/modules/workspaces/updateWorkspaceMember.d.ts +0 -35
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { WorkspaceMemberStanding } from "../../interfaces/Workspace";
|
|
3
|
-
export interface FetchWorkspaceMemberStandingProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
targetUserId: string;
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Read one user's resolved standing on a workspace (`reasons`, `capabilities`,
|
|
9
|
-
* `permissions`, `rank`, `relativeRank`, `title`, `metadata`).
|
|
10
|
-
*
|
|
11
|
-
* `relativeRank` is the target's `rank` as an offset from YOU (negative =
|
|
12
|
-
* senior to you), and is fenced with `rank`: both are absent, not null, for a
|
|
13
|
-
* caller who may not see the target's authority.
|
|
14
|
-
*/
|
|
15
|
-
export declare function fetchWorkspaceMemberStanding(client: SublayHttpClient, data: FetchWorkspaceMemberStandingProps): Promise<WorkspaceMemberStanding>;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { WorkspaceRosterResponse, WorkspaceRosterCountsResponse } from "../../interfaces/Workspace";
|
|
3
|
-
export interface FetchWorkspaceMembersProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
include?: string;
|
|
6
|
-
countOnly?: boolean;
|
|
7
|
-
}
|
|
8
|
-
/**
|
|
9
|
-
* Unified roster read — one entry per distinct user, each with a `reasons`
|
|
10
|
-
* array. Always returned in full (never paginated). With `countOnly=true` the
|
|
11
|
-
* shape is `WorkspaceRosterCountsResponse` instead. Actor from the token.
|
|
12
|
-
*
|
|
13
|
-
* Same-node `member` reasons carry both rank coordinates: absolute `rank` and
|
|
14
|
-
* `relativeRank`, the offset from you (`1` = one rung below you, `-3` = three
|
|
15
|
-
* above). Both are fenced together and both are absent for a caller who does
|
|
16
|
-
* not operate people here. `descendant-member` reasons carry `rank` only.
|
|
17
|
-
*/
|
|
18
|
-
export declare function fetchWorkspaceMembers(client: SublayHttpClient, data: FetchWorkspaceMembersProps): Promise<WorkspaceRosterResponse | WorkspaceRosterCountsResponse>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { WorkspaceAuthority } from "../../interfaces/Workspace";
|
|
3
|
-
export interface GetAuthorityProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
}
|
|
6
|
-
/**
|
|
7
|
-
* Authority-as-a-service read — the bearer-token user's resolved standing
|
|
8
|
-
* (`{ reasons, capabilities, permissions, rank }`) on the workspace. A
|
|
9
|
-
* permission check is a one-line `.includes()` on the result.
|
|
10
|
-
*/
|
|
11
|
-
export declare function getAuthority(client: SublayHttpClient, data: GetAuthorityProps): Promise<WorkspaceAuthority>;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
export { createWorkspace } from "./createWorkspace";
|
|
2
|
-
export { fetchWorkspace } from "./fetchWorkspace";
|
|
3
|
-
export { fetchManyWorkspaces } from "./fetchManyWorkspaces";
|
|
4
|
-
export { updateWorkspace } from "./updateWorkspace";
|
|
5
|
-
export { updateWorkspaceInheritFlag } from "./updateWorkspaceInheritFlag";
|
|
6
|
-
export { deleteWorkspace } from "./deleteWorkspace";
|
|
7
|
-
export { transferWorkspaceOwnership } from "./transferWorkspaceOwnership";
|
|
8
|
-
export { fetchWorkspaceMembers } from "./fetchWorkspaceMembers";
|
|
9
|
-
export { fetchWorkspaceMemberStanding } from "./fetchWorkspaceMemberStanding";
|
|
10
|
-
export { updateWorkspaceMember } from "./updateWorkspaceMember";
|
|
11
|
-
export { removeWorkspaceMember } from "./removeWorkspaceMember";
|
|
12
|
-
export { leaveWorkspace } from "./leaveWorkspace";
|
|
13
|
-
export { removeWorkspaceMemberFromSubtree } from "./removeWorkspaceMemberFromSubtree";
|
|
14
|
-
export { createWorkspaceInvite } from "./createWorkspaceInvite";
|
|
15
|
-
export { fetchWorkspaceInvites } from "./fetchWorkspaceInvites";
|
|
16
|
-
export { revokeWorkspaceInvite } from "./revokeWorkspaceInvite";
|
|
17
|
-
export { resendWorkspaceInvite } from "./resendWorkspaceInvite";
|
|
18
|
-
export { acceptWorkspaceInvite } from "./acceptWorkspaceInvite";
|
|
19
|
-
export { declineWorkspaceInvite } from "./declineWorkspaceInvite";
|
|
20
|
-
export { fetchMyWorkspaceInvites } from "./fetchMyWorkspaceInvites";
|
|
21
|
-
export { fetchWorkspaceAuthority } from "./fetchWorkspaceAuthority";
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
export interface LeaveWorkspaceProps {
|
|
3
|
-
workspaceId: string;
|
|
4
|
-
}
|
|
5
|
-
/**
|
|
6
|
-
* The bearer-token user leaves this workspace — removes THEIR OWN direct
|
|
7
|
-
* membership on THIS node only (owning a child is unaffected). An owner cannot
|
|
8
|
-
* leave (409 `workspace/sole-owner`) — transfer ownership or remove the
|
|
9
|
-
* workspace first. No actor field is sent; the server derives the leaver from
|
|
10
|
-
* the token.
|
|
11
|
-
*/
|
|
12
|
-
export declare function leaveWorkspace(client: SublayHttpClient, data: LeaveWorkspaceProps): Promise<void>;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
export interface RemoveWorkspaceMemberProps {
|
|
3
|
-
workspaceId: string;
|
|
4
|
-
targetUserId: string;
|
|
5
|
-
}
|
|
6
|
-
/**
|
|
7
|
-
* Remove a member from this workspace. Requires the `remove-member` capability
|
|
8
|
-
* and is rank-bounded. The workspace owner cannot be removed (409
|
|
9
|
-
* `workspace/sole-owner`) — transfer ownership first. No actor field is sent;
|
|
10
|
-
* the actor comes from the token.
|
|
11
|
-
*/
|
|
12
|
-
export declare function removeWorkspaceMember(client: SublayHttpClient, data: RemoveWorkspaceMemberProps): Promise<void>;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { RemoveWorkspaceMemberFromSubtreeResponse } from "../../interfaces/Workspace";
|
|
3
|
-
export interface RemoveWorkspaceMemberFromSubtreeProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
targetUserId: string;
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Removes the target user's direct memberships on this workspace and every
|
|
9
|
-
* descendant. Requires `remove-member` (rank-bounded per node). Blocks (409
|
|
10
|
-
* `workspace/owns-descendants`) with a report if the user OWNS any descendant
|
|
11
|
-
* workspace — transfer or delete those first. The actor comes from the token.
|
|
12
|
-
*
|
|
13
|
-
* A NON-owner's sweep can be PARTIAL: it stops at sealed sub-workspaces. Check
|
|
14
|
-
* `skippedCount` / `skipped` before treating the user as fully offboarded.
|
|
15
|
-
*/
|
|
16
|
-
export declare function removeWorkspaceMemberFromSubtree(client: SublayHttpClient, data: RemoveWorkspaceMemberFromSubtreeProps): Promise<RemoveWorkspaceMemberFromSubtreeResponse>;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { WorkspaceInvitation } from "../../interfaces/Workspace";
|
|
3
|
-
export interface ResendWorkspaceInviteProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
inviteId: string;
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Resend / refresh a pending invitation (valid on any `pending` invite, even one
|
|
9
|
-
* past `expiresAt` — resets a 14-day expiry and resends the email). A terminal
|
|
10
|
-
* invite (accepted/declined/revoked) → 409. Requires `invite` (or owner).
|
|
11
|
-
*/
|
|
12
|
-
export declare function resendWorkspaceInvite(client: SublayHttpClient, data: ResendWorkspaceInviteProps): Promise<WorkspaceInvitation>;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
export interface RevokeWorkspaceInviteProps {
|
|
3
|
-
workspaceId: string;
|
|
4
|
-
inviteId: string;
|
|
5
|
-
}
|
|
6
|
-
export interface RevokeWorkspaceInviteResponse {
|
|
7
|
-
success: boolean;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Revoke a pending invitation. Requires the `invite` capability (or owner).
|
|
11
|
-
* Note the verb-suffixed POST route — this is not a `DELETE`.
|
|
12
|
-
*/
|
|
13
|
-
export declare function revokeWorkspaceInvite(client: SublayHttpClient, data: RevokeWorkspaceInviteProps): Promise<RevokeWorkspaceInviteResponse>;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { Workspace, WorkspaceCapability } from "../../interfaces/Workspace";
|
|
3
|
-
export interface TransferWorkspaceOwnershipProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
newOwnerId: string;
|
|
6
|
-
previousOwnerDisposition?: "demote" | "remove";
|
|
7
|
-
previousOwnerRank?: number;
|
|
8
|
-
previousOwnerCapabilities?: WorkspaceCapability[];
|
|
9
|
-
}
|
|
10
|
-
/**
|
|
11
|
-
* Hand the workspace to a new owner. Owner-only (own owner or an ancestor
|
|
12
|
-
* owner). The actor is the bearer-token user — no actor field is sent;
|
|
13
|
-
* `newOwnerId` addresses the TARGET, not the actor.
|
|
14
|
-
*/
|
|
15
|
-
export declare function transferWorkspaceOwnership(client: SublayHttpClient, data: TransferWorkspaceOwnershipProps): Promise<Workspace>;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { Workspace } from "../../interfaces/Workspace";
|
|
3
|
-
export interface UpdateWorkspaceProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
name?: string;
|
|
6
|
-
metadata?: Record<string, any>;
|
|
7
|
-
}
|
|
8
|
-
/**
|
|
9
|
-
* Edit a workspace's name / metadata. Requires the `edit-workspace` capability
|
|
10
|
-
* (or ownership). The actor is the bearer-token user — no actor field is sent.
|
|
11
|
-
*/
|
|
12
|
-
export declare function updateWorkspace(client: SublayHttpClient, data: UpdateWorkspaceProps): Promise<Workspace>;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { Workspace } from "../../interfaces/Workspace";
|
|
3
|
-
export interface UpdateWorkspaceInheritFlagProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
inheritsFromParent: boolean;
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Flip whether capabilities held on an ancestor "reach" into this workspace.
|
|
9
|
-
* Owner-only in both directions (own owner or an ancestor owner), and blocked
|
|
10
|
-
* (403 `workspace/inherit-enforced`) when the project enforces its default.
|
|
11
|
-
* The actor is the bearer-token user — no actor field is sent.
|
|
12
|
-
*/
|
|
13
|
-
export declare function updateWorkspaceInheritFlag(client: SublayHttpClient, data: UpdateWorkspaceInheritFlagProps): Promise<Workspace>;
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { SublayHttpClient } from "../../core/client";
|
|
2
|
-
import { WorkspaceCapability, WorkspaceMember } from "../../interfaces/Workspace";
|
|
3
|
-
export interface UpdateWorkspaceMemberProps {
|
|
4
|
-
workspaceId: string;
|
|
5
|
-
targetUserId: string;
|
|
6
|
-
capabilities?: WorkspaceCapability[];
|
|
7
|
-
permissions?: string[];
|
|
8
|
-
rank?: number;
|
|
9
|
-
/**
|
|
10
|
-
* `rank`'s relative twin: an offset from the ACTOR (`1` = one rung below me),
|
|
11
|
-
* resolved to an absolute rank at write time and stored absolute. Must be
|
|
12
|
-
* `>= 1`; mutually exclusive with `rank` (sending both is a 400). Both rank fields are also capped at `2147483647` (int4), and the RESOLVED sum is bounded too — an in-range anchor plus an in-range offset can still overflow, which is a 400 rather than a 500.
|
|
13
|
-
*
|
|
14
|
-
* The anchor is the actor's own rank if they hold a member row on this
|
|
15
|
-
* workspace, apex otherwise. A SNAPSHOT — frozen at write time, it does not
|
|
16
|
-
* follow the actor's own rank afterwards.
|
|
17
|
-
*
|
|
18
|
-
* Unlike invite, edit has NO default: omitting BOTH still means "rank
|
|
19
|
-
* unchanged", so editing someone's capabilities never moves them on the
|
|
20
|
-
* ladder.
|
|
21
|
-
*/
|
|
22
|
-
relativeRank?: number;
|
|
23
|
-
title?: string | null;
|
|
24
|
-
metadata?: Record<string, any>;
|
|
25
|
-
}
|
|
26
|
-
/**
|
|
27
|
-
* Edit a member's grant / profile. Powerful fields need `edit-member-access`
|
|
28
|
-
* plus rank + no-escalation rules; cosmetic fields need only
|
|
29
|
-
* `edit-member-profile`. No actor field is sent — the actor comes from the token.
|
|
30
|
-
*
|
|
31
|
-
* Rank moves in either coordinate — `rank` (absolute) or `relativeRank` (an
|
|
32
|
-
* offset from the actor) — never both. Omitting both leaves rank UNCHANGED;
|
|
33
|
-
* unlike invite, edit has no value default.
|
|
34
|
-
*/
|
|
35
|
-
export declare function updateWorkspaceMember(client: SublayHttpClient, data: UpdateWorkspaceMemberProps): Promise<WorkspaceMember>;
|