@fusebase/fusebase-gate-sdk 2.2.21-sdk.1 → 2.2.21-sdk.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/apis/IsolatedStoresApi.d.ts +26 -0
- package/dist/apis/IsolatedStoresApi.js +30 -0
- package/dist/apis/PortalsApi.d.ts +15 -3
- package/dist/apis/PortalsApi.js +17 -2
- package/dist/apis/WorkspacesApi.d.ts +12 -1
- package/dist/apis/WorkspacesApi.js +15 -0
- package/dist/types/app-api/app-api.d.ts +2 -0
- package/dist/types/index.d.ts +2 -2
- package/dist/types/org-user/org-user.d.ts +4 -0
- package/dist/types/portals/portals.d.ts +26 -0
- package/dist/types/shared/enums.d.ts +1 -1
- package/dist/types/shared/enums.js +1 -1
- package/package.json +1 -1
- package/release-notes/2.2.21-sdk.11.md +9 -0
- package/release-notes/latest.md +3 -3
- package/release-notes/2.2.21-sdk.1.md +0 -9
|
@@ -73,6 +73,19 @@ export declare class IsolatedStoresApi {
|
|
|
73
73
|
headers?: Record<string, string>;
|
|
74
74
|
body: IsolatedStoreSqlCountRequestContract;
|
|
75
75
|
}): Promise<IsolatedStoreSqlCountResponseContract>;
|
|
76
|
+
/**
|
|
77
|
+
* Count rows with RLS bypass
|
|
78
|
+
* Counts rows in a postgres table through the explicit audited RLS-bypass read path. Intended for Studio/admin data explorer views only; normal runtime reads must use countIsolatedStoreSqlRows.
|
|
79
|
+
*/
|
|
80
|
+
countIsolatedStoreSqlRowsRlsBypass(params: {
|
|
81
|
+
path: {
|
|
82
|
+
orgId: orgIdInPathRequired;
|
|
83
|
+
storeId: IsolatedStoreIdInPathRequired;
|
|
84
|
+
stage: IsolatedStoreStageInPathRequired;
|
|
85
|
+
};
|
|
86
|
+
headers?: Record<string, string>;
|
|
87
|
+
body: IsolatedStoreSqlCountRequestContract;
|
|
88
|
+
}): Promise<IsolatedStoreSqlCountResponseContract>;
|
|
76
89
|
/**
|
|
77
90
|
* Create isolated store
|
|
78
91
|
* Registers a low-level store and binds it to the organization scope plus an isolated source scope such as app.
|
|
@@ -379,6 +392,19 @@ export declare class IsolatedStoresApi {
|
|
|
379
392
|
headers?: Record<string, string>;
|
|
380
393
|
body: IsolatedStoreSqlSelectRequestContract;
|
|
381
394
|
}): Promise<IsolatedStoreSqlSelectResponseContract>;
|
|
395
|
+
/**
|
|
396
|
+
* Select rows with RLS bypass
|
|
397
|
+
* Reads rows through the explicit audited RLS-bypass read path. Intended for Studio/admin data explorer views only; normal runtime reads must use selectIsolatedStoreSqlRows.
|
|
398
|
+
*/
|
|
399
|
+
selectIsolatedStoreSqlRowsRlsBypass(params: {
|
|
400
|
+
path: {
|
|
401
|
+
orgId: orgIdInPathRequired;
|
|
402
|
+
storeId: IsolatedStoreIdInPathRequired;
|
|
403
|
+
stage: IsolatedStoreStageInPathRequired;
|
|
404
|
+
};
|
|
405
|
+
headers?: Record<string, string>;
|
|
406
|
+
body: IsolatedStoreSqlSelectRequestContract;
|
|
407
|
+
}): Promise<IsolatedStoreSqlSelectResponseContract>;
|
|
382
408
|
/**
|
|
383
409
|
* Update rows
|
|
384
410
|
* Updates rows in a postgres table using structured filters. Filterless updates are blocked unless allowAll=true is explicitly set.
|
|
@@ -86,6 +86,21 @@ class IsolatedStoresApi {
|
|
|
86
86
|
expectedContentType: "application/json",
|
|
87
87
|
});
|
|
88
88
|
}
|
|
89
|
+
/**
|
|
90
|
+
* Count rows with RLS bypass
|
|
91
|
+
* Counts rows in a postgres table through the explicit audited RLS-bypass read path. Intended for Studio/admin data explorer views only; normal runtime reads must use countIsolatedStoreSqlRows.
|
|
92
|
+
*/
|
|
93
|
+
async countIsolatedStoreSqlRowsRlsBypass(params) {
|
|
94
|
+
return this.client.request({
|
|
95
|
+
method: "POST",
|
|
96
|
+
path: "/:orgId/isolated-stores/:storeId/stages/:stage/sql/rows/count/rls-bypass",
|
|
97
|
+
pathParams: params.path,
|
|
98
|
+
headers: params.headers,
|
|
99
|
+
body: params.body,
|
|
100
|
+
opId: "countIsolatedStoreSqlRowsRlsBypass",
|
|
101
|
+
expectedContentType: "application/json",
|
|
102
|
+
});
|
|
103
|
+
}
|
|
89
104
|
/**
|
|
90
105
|
* Create isolated store
|
|
91
106
|
* Registers a low-level store and binds it to the organization scope plus an isolated source scope such as app.
|
|
@@ -438,6 +453,21 @@ class IsolatedStoresApi {
|
|
|
438
453
|
expectedContentType: "application/json",
|
|
439
454
|
});
|
|
440
455
|
}
|
|
456
|
+
/**
|
|
457
|
+
* Select rows with RLS bypass
|
|
458
|
+
* Reads rows through the explicit audited RLS-bypass read path. Intended for Studio/admin data explorer views only; normal runtime reads must use selectIsolatedStoreSqlRows.
|
|
459
|
+
*/
|
|
460
|
+
async selectIsolatedStoreSqlRowsRlsBypass(params) {
|
|
461
|
+
return this.client.request({
|
|
462
|
+
method: "POST",
|
|
463
|
+
path: "/:orgId/isolated-stores/:storeId/stages/:stage/sql/rows/select/rls-bypass",
|
|
464
|
+
pathParams: params.path,
|
|
465
|
+
headers: params.headers,
|
|
466
|
+
body: params.body,
|
|
467
|
+
opId: "selectIsolatedStoreSqlRowsRlsBypass",
|
|
468
|
+
expectedContentType: "application/json",
|
|
469
|
+
});
|
|
470
|
+
}
|
|
441
471
|
/**
|
|
442
472
|
* Update rows
|
|
443
473
|
* Updates rows in a postgres table using structured filters. Filterless updates are blocked unless allowAll=true is explicitly set.
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Domain: portals
|
|
6
6
|
*/
|
|
7
7
|
import type { Client } from "../runtime/transport";
|
|
8
|
-
import type { CreatePortalRequestContract, CreatePortalResponseContract, DuplicatePortalRequestContract, globalIdInPathRequired, orgIdInPathRequired, OrgPortalListResponseContract, PortalDetailContract } from "../types";
|
|
8
|
+
import type { CreatePortalRequestContract, CreatePortalResponseContract, DuplicatePortalRequestContract, globalIdInPathRequired, InviteToPortalRequestContract, InviteToPortalResponseContract, orgIdInPathRequired, OrgPortalListResponseContract, PortalDetailContract } from "../types";
|
|
9
9
|
export declare class PortalsApi {
|
|
10
10
|
private client;
|
|
11
11
|
constructor(client: Client);
|
|
@@ -34,7 +34,7 @@ export declare class PortalsApi {
|
|
|
34
34
|
}): Promise<CreatePortalResponseContract>;
|
|
35
35
|
/**
|
|
36
36
|
* Get portal details
|
|
37
|
-
* Returns detailed information for a single portal by ID. Requires
|
|
37
|
+
* Returns detailed information for a single portal by ID. Requires portals.read access.
|
|
38
38
|
*/
|
|
39
39
|
getPortal(params: {
|
|
40
40
|
path: {
|
|
@@ -43,9 +43,21 @@ export declare class PortalsApi {
|
|
|
43
43
|
};
|
|
44
44
|
headers?: Record<string, string>;
|
|
45
45
|
}): Promise<PortalDetailContract>;
|
|
46
|
+
/**
|
|
47
|
+
* Invite a user to a portal
|
|
48
|
+
* Invites a user (client, member, or manager) to a portal via a magic link. For orgRole='client' (default): isFullAccess controls access to private pages (default true). For orgRole='member' or 'manager': always full access, isFullAccess is ignored. Returns a magic link for direct portal access without email confirmation. Invarian — before calling this operation for a client invite (orgRole='client' or unspecified): ALWAYS ask the user 'Full access (all pages) or Shared only (public pages)?' and wait for their answer before proceeding. Do NOT silently assume a default.
|
|
49
|
+
*/
|
|
50
|
+
inviteToPortal(params: {
|
|
51
|
+
path: {
|
|
52
|
+
orgId: orgIdInPathRequired;
|
|
53
|
+
portalId: globalIdInPathRequired;
|
|
54
|
+
};
|
|
55
|
+
headers?: Record<string, string>;
|
|
56
|
+
body: InviteToPortalRequestContract;
|
|
57
|
+
}): Promise<InviteToPortalResponseContract>;
|
|
46
58
|
/**
|
|
47
59
|
* List organization portals
|
|
48
|
-
* Returns portals visible for the caller in the organization. Requires
|
|
60
|
+
* Returns portals visible for the caller in the organization. Requires portals.read and org access.
|
|
49
61
|
*/
|
|
50
62
|
listPortals(params: {
|
|
51
63
|
path: {
|
package/dist/apis/PortalsApi.js
CHANGED
|
@@ -43,7 +43,7 @@ class PortalsApi {
|
|
|
43
43
|
}
|
|
44
44
|
/**
|
|
45
45
|
* Get portal details
|
|
46
|
-
* Returns detailed information for a single portal by ID. Requires
|
|
46
|
+
* Returns detailed information for a single portal by ID. Requires portals.read access.
|
|
47
47
|
*/
|
|
48
48
|
async getPortal(params) {
|
|
49
49
|
return this.client.request({
|
|
@@ -55,9 +55,24 @@ class PortalsApi {
|
|
|
55
55
|
expectedContentType: "application/json",
|
|
56
56
|
});
|
|
57
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* Invite a user to a portal
|
|
60
|
+
* Invites a user (client, member, or manager) to a portal via a magic link. For orgRole='client' (default): isFullAccess controls access to private pages (default true). For orgRole='member' or 'manager': always full access, isFullAccess is ignored. Returns a magic link for direct portal access without email confirmation. Invarian — before calling this operation for a client invite (orgRole='client' or unspecified): ALWAYS ask the user 'Full access (all pages) or Shared only (public pages)?' and wait for their answer before proceeding. Do NOT silently assume a default.
|
|
61
|
+
*/
|
|
62
|
+
async inviteToPortal(params) {
|
|
63
|
+
return this.client.request({
|
|
64
|
+
method: "POST",
|
|
65
|
+
path: "/:orgId/portals/:portalId/invite",
|
|
66
|
+
pathParams: params.path,
|
|
67
|
+
headers: params.headers,
|
|
68
|
+
body: params.body,
|
|
69
|
+
opId: "inviteToPortal",
|
|
70
|
+
expectedContentType: "application/json",
|
|
71
|
+
});
|
|
72
|
+
}
|
|
58
73
|
/**
|
|
59
74
|
* List organization portals
|
|
60
|
-
* Returns portals visible for the caller in the organization. Requires
|
|
75
|
+
* Returns portals visible for the caller in the organization. Requires portals.read and org access.
|
|
61
76
|
*/
|
|
62
77
|
async listPortals(params) {
|
|
63
78
|
return this.client.request({
|
|
@@ -5,10 +5,21 @@
|
|
|
5
5
|
* Domain: workspaces
|
|
6
6
|
*/
|
|
7
7
|
import type { Client } from "../runtime/transport";
|
|
8
|
-
import type { orgIdInPathRequired, OrgWorkspaceListResponseContract } from "../types";
|
|
8
|
+
import type { CreateWorkspaceRequestContract, orgIdInPathRequired, OrgWorkspaceContract, OrgWorkspaceListResponseContract } from "../types";
|
|
9
9
|
export declare class WorkspacesApi {
|
|
10
10
|
private client;
|
|
11
11
|
constructor(client: Client);
|
|
12
|
+
/**
|
|
13
|
+
* Create a new workspace
|
|
14
|
+
* Creates a new workspace in the organization. Returns the created workspace details. Requires org.write and org access.
|
|
15
|
+
*/
|
|
16
|
+
createWorkspace(params: {
|
|
17
|
+
path: {
|
|
18
|
+
orgId: orgIdInPathRequired;
|
|
19
|
+
};
|
|
20
|
+
headers?: Record<string, string>;
|
|
21
|
+
body: CreateWorkspaceRequestContract;
|
|
22
|
+
}): Promise<OrgWorkspaceContract>;
|
|
12
23
|
/**
|
|
13
24
|
* List organization workspaces
|
|
14
25
|
* Returns workspaces visible for the caller in the organization and marks the default workspace. Requires org.read and org access.
|
|
@@ -11,6 +11,21 @@ class WorkspacesApi {
|
|
|
11
11
|
constructor(client) {
|
|
12
12
|
this.client = client;
|
|
13
13
|
}
|
|
14
|
+
/**
|
|
15
|
+
* Create a new workspace
|
|
16
|
+
* Creates a new workspace in the organization. Returns the created workspace details. Requires org.write and org access.
|
|
17
|
+
*/
|
|
18
|
+
async createWorkspace(params) {
|
|
19
|
+
return this.client.request({
|
|
20
|
+
method: "POST",
|
|
21
|
+
path: "/:orgId/workspaces",
|
|
22
|
+
pathParams: params.path,
|
|
23
|
+
headers: params.headers,
|
|
24
|
+
body: params.body,
|
|
25
|
+
opId: "createWorkspace",
|
|
26
|
+
expectedContentType: "application/json",
|
|
27
|
+
});
|
|
28
|
+
}
|
|
14
29
|
/**
|
|
15
30
|
* List organization workspaces
|
|
16
31
|
* Returns workspaces visible for the caller in the organization and marks the default workspace. Requires org.read and org access.
|
|
@@ -11,6 +11,8 @@ export interface AppApiOperationContract {
|
|
|
11
11
|
description?: string | null;
|
|
12
12
|
visibility?: string | null;
|
|
13
13
|
executionMode?: string | null;
|
|
14
|
+
allowedCallers?: string[];
|
|
15
|
+
requiredPermissions?: string[];
|
|
14
16
|
tags: string[];
|
|
15
17
|
manifestVersion?: string | null;
|
|
16
18
|
publishedAt?: string | null;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -16,8 +16,8 @@ export * from "./mcp-manager/mcp-manager";
|
|
|
16
16
|
export type { MeAuthContract, MeOrgGroupContract, MeResponseContract, MeScopeContract, MeUserContract } from "./me/me";
|
|
17
17
|
export * from "./note/note";
|
|
18
18
|
export * from "./org-group/org-group";
|
|
19
|
-
export type { OrgInviteContract, OrgMagicLinkContract, OrgPortalContract, OrgPortalListResponseContract, OrgUserAddRequestContract, OrgUserAddResponseContract, OrgUserContract, OrgUserListResponseContract, OrgWorkspaceContract, OrgWorkspaceInviteContract, OrgWorkspaceListResponseContract, OrgWorkspaceMemberContract } from "./org-user/org-user";
|
|
20
|
-
export type { CreatePortalRequestContract, CreatePortalResponseContract, DuplicatePortalRequestContract, PortalDetailContract, globalIdInPathRequired } from "./portals/portals";
|
|
19
|
+
export type { CreateWorkspaceRequestContract, OrgInviteContract, OrgMagicLinkContract, OrgPortalContract, OrgPortalListResponseContract, OrgUserAddRequestContract, OrgUserAddResponseContract, OrgUserContract, OrgUserListResponseContract, OrgWorkspaceContract, OrgWorkspaceInviteContract, OrgWorkspaceListResponseContract, OrgWorkspaceMemberContract } from "./org-user/org-user";
|
|
20
|
+
export type { CreatePortalRequestContract, CreatePortalResponseContract, DuplicatePortalRequestContract, InviteToPortalRequestContract, InviteToPortalResponseContract, PortalDetailContract, globalIdInPathRequired } from "./portals/portals";
|
|
21
21
|
export * from "./shared/common";
|
|
22
22
|
export * from "./shared/enums";
|
|
23
23
|
export type { GetHealth200ResponseContract } from "./shared/health";
|
|
@@ -69,6 +69,10 @@ export interface OrgWorkspaceContract {
|
|
|
69
69
|
export interface OrgWorkspaceListResponseContract {
|
|
70
70
|
workspaces: OrgWorkspaceContract[];
|
|
71
71
|
}
|
|
72
|
+
export interface CreateWorkspaceRequestContract {
|
|
73
|
+
/** Display name for the new workspace. Required. */
|
|
74
|
+
title: string;
|
|
75
|
+
}
|
|
72
76
|
export interface OrgPortalContract {
|
|
73
77
|
id: string;
|
|
74
78
|
orgId: string;
|
|
@@ -29,3 +29,29 @@ export interface PortalDetailContract {
|
|
|
29
29
|
cnameValue?: string;
|
|
30
30
|
cnameStatus?: string;
|
|
31
31
|
}
|
|
32
|
+
export interface InviteToPortalRequestContract {
|
|
33
|
+
email: string;
|
|
34
|
+
fullName?: string;
|
|
35
|
+
/**
|
|
36
|
+
* Org role for the invitee (default: "client").
|
|
37
|
+
* Supported: "client", "member", "manager".
|
|
38
|
+
*/
|
|
39
|
+
orgRole?: "client" | "member" | "manager";
|
|
40
|
+
/** Workspace role (default: "editor"). */
|
|
41
|
+
workspaceRole?: "reader" | "editor";
|
|
42
|
+
/**
|
|
43
|
+
* Only relevant when orgRole="client".
|
|
44
|
+
* true = Full access (sees all pages including private) — default.
|
|
45
|
+
* false = Shared only (public/shared pages only).
|
|
46
|
+
* For orgRole "member" and "manager" this is always true and the field is ignored.
|
|
47
|
+
*/
|
|
48
|
+
isFullAccess?: boolean;
|
|
49
|
+
}
|
|
50
|
+
export interface InviteToPortalResponseContract {
|
|
51
|
+
/** Magic link for direct portal access (no email confirmation needed). */
|
|
52
|
+
magicLink: string;
|
|
53
|
+
/** Portal URL. */
|
|
54
|
+
url: string;
|
|
55
|
+
/** User ID in the system. */
|
|
56
|
+
userId: number;
|
|
57
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export type OrgRoleContract = "owner" | "manager" | "member" | "client" | "guest" | "visitor";
|
|
2
2
|
export type PermissionContract = string & {
|
|
3
|
-
__pattern: "^[^.]+\\.(?:[^.]+\\.)?(read|write|delete|execute)$";
|
|
3
|
+
__pattern: "^[^.]+\\.(?:[^.]+\\.)?(read|write|delete|execute|create|manage)$";
|
|
4
4
|
};
|
|
5
5
|
export type RootEntityContract = "custom" | "portal" | "workspace" | "org" | "user" | "client" | "form" | "form-response" | "tracker" | "tracker-result" | "meeting";
|
|
6
6
|
export type ScopeTypeContract = "org" | "workspace" | "portal" | "user" | "client" | "block" | "tracker" | "parent_row" | "parent_table";
|
|
@@ -37,7 +37,7 @@ exports.ScopeTypeContract = {
|
|
|
37
37
|
exports.ScopeTypeOrgContract = {
|
|
38
38
|
Org: "org"
|
|
39
39
|
};
|
|
40
|
-
const PERMISSION_RE = /^[^.]+\.(?:[^.]+\.)?(read|write|delete|execute)$/;
|
|
40
|
+
const PERMISSION_RE = /^[^.]+\.(?:[^.]+\.)?(read|write|delete|execute|create|manage)$/;
|
|
41
41
|
function asPermission(value) {
|
|
42
42
|
if (!PERMISSION_RE.test(value)) {
|
|
43
43
|
throw new Error(`Invalid permission: ${value}`);
|
package/package.json
CHANGED
package/release-notes/latest.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
# Release Notes 2.2.21-sdk.
|
|
1
|
+
# Release Notes 2.2.21-sdk.11
|
|
2
2
|
|
|
3
3
|
- Current ref: `HEAD`
|
|
4
|
-
- Previous tag: `v2.2.21-sdk.
|
|
5
|
-
- Generated at: 2026-
|
|
4
|
+
- Previous tag: `v2.2.21-sdk.11`
|
|
5
|
+
- Generated at: 2026-06-05T03:08:53.595Z
|
|
6
6
|
|
|
7
7
|
## Included Drafts
|
|
8
8
|
|