@budibase/frontend-core 3.31.4 → 3.31.6
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/package.json +2 -2
- package/src/api/agents.ts +49 -5
- package/src/constants.ts +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@budibase/frontend-core",
|
|
3
|
-
"version": "3.31.
|
|
3
|
+
"version": "3.31.6",
|
|
4
4
|
"description": "Budibase frontend core libraries used in builder and client",
|
|
5
5
|
"author": "Budibase",
|
|
6
6
|
"license": "MPL-2.0",
|
|
@@ -24,5 +24,5 @@
|
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"vitest": "^3.2.4"
|
|
26
26
|
},
|
|
27
|
-
"gitHead": "
|
|
27
|
+
"gitHead": "431d595ada96873e3b6ff34e80a2f710f5ad5051"
|
|
28
28
|
}
|
package/src/api/agents.ts
CHANGED
|
@@ -5,12 +5,14 @@ import {
|
|
|
5
5
|
DuplicateAgentResponse,
|
|
6
6
|
FetchAgentFilesResponse,
|
|
7
7
|
FetchAgentsResponse,
|
|
8
|
+
ProvisionAgentSlackChannelRequest,
|
|
9
|
+
ProvisionAgentSlackChannelResponse,
|
|
8
10
|
ProvisionAgentMSTeamsChannelRequest,
|
|
9
11
|
ProvisionAgentMSTeamsChannelResponse,
|
|
10
12
|
SyncAgentDiscordCommandsRequest,
|
|
11
13
|
SyncAgentDiscordCommandsResponse,
|
|
12
|
-
|
|
13
|
-
|
|
14
|
+
ToggleAgentDeploymentRequest,
|
|
15
|
+
ToggleAgentDeploymentResponse,
|
|
14
16
|
ToolMetadata,
|
|
15
17
|
UpdateAgentRequest,
|
|
16
18
|
UpdateAgentResponse,
|
|
@@ -42,10 +44,22 @@ export interface AgentEndpoints {
|
|
|
42
44
|
agentId: string,
|
|
43
45
|
body?: ProvisionAgentMSTeamsChannelRequest
|
|
44
46
|
) => Promise<ProvisionAgentMSTeamsChannelResponse>
|
|
47
|
+
provisionAgentSlackChannel: (
|
|
48
|
+
agentId: string,
|
|
49
|
+
body?: ProvisionAgentSlackChannelRequest
|
|
50
|
+
) => Promise<ProvisionAgentSlackChannelResponse>
|
|
45
51
|
toggleAgentDiscordDeployment: (
|
|
46
52
|
agentId: string,
|
|
47
53
|
enabled: boolean
|
|
48
|
-
) => Promise<
|
|
54
|
+
) => Promise<ToggleAgentDeploymentResponse>
|
|
55
|
+
toggleAgentMSTeamsDeployment: (
|
|
56
|
+
agentId: string,
|
|
57
|
+
enabled: boolean
|
|
58
|
+
) => Promise<ToggleAgentDeploymentResponse>
|
|
59
|
+
toggleAgentSlackDeployment: (
|
|
60
|
+
agentId: string,
|
|
61
|
+
enabled: boolean
|
|
62
|
+
) => Promise<ToggleAgentDeploymentResponse>
|
|
49
63
|
}
|
|
50
64
|
|
|
51
65
|
export const buildAgentEndpoints = (API: BaseAPIClient): AgentEndpoints => ({
|
|
@@ -131,13 +145,43 @@ export const buildAgentEndpoints = (API: BaseAPIClient): AgentEndpoints => ({
|
|
|
131
145
|
})
|
|
132
146
|
},
|
|
133
147
|
|
|
148
|
+
provisionAgentSlackChannel: async (agentId: string, body) => {
|
|
149
|
+
return await API.post<
|
|
150
|
+
ProvisionAgentSlackChannelRequest | undefined,
|
|
151
|
+
ProvisionAgentSlackChannelResponse
|
|
152
|
+
>({
|
|
153
|
+
url: `/api/agent/${agentId}/slack/provision`,
|
|
154
|
+
body,
|
|
155
|
+
})
|
|
156
|
+
},
|
|
157
|
+
|
|
134
158
|
toggleAgentDiscordDeployment: async (agentId: string, enabled: boolean) => {
|
|
135
159
|
return await API.post<
|
|
136
|
-
|
|
137
|
-
|
|
160
|
+
ToggleAgentDeploymentRequest,
|
|
161
|
+
ToggleAgentDeploymentResponse
|
|
138
162
|
>({
|
|
139
163
|
url: `/api/agent/${agentId}/discord/toggle`,
|
|
140
164
|
body: { enabled },
|
|
141
165
|
})
|
|
142
166
|
},
|
|
167
|
+
|
|
168
|
+
toggleAgentMSTeamsDeployment: async (agentId: string, enabled: boolean) => {
|
|
169
|
+
return await API.post<
|
|
170
|
+
ToggleAgentDeploymentRequest,
|
|
171
|
+
ToggleAgentDeploymentResponse
|
|
172
|
+
>({
|
|
173
|
+
url: `/api/agent/${agentId}/ms-teams/toggle`,
|
|
174
|
+
body: { enabled },
|
|
175
|
+
})
|
|
176
|
+
},
|
|
177
|
+
|
|
178
|
+
toggleAgentSlackDeployment: async (agentId: string, enabled: boolean) => {
|
|
179
|
+
return await API.post<
|
|
180
|
+
ToggleAgentDeploymentRequest,
|
|
181
|
+
ToggleAgentDeploymentResponse
|
|
182
|
+
>({
|
|
183
|
+
url: `/api/agent/${agentId}/slack/toggle`,
|
|
184
|
+
body: { enabled },
|
|
185
|
+
})
|
|
186
|
+
},
|
|
143
187
|
})
|
package/src/constants.ts
CHANGED
|
@@ -52,9 +52,9 @@ export const BudibaseRoleOptionsOld = [
|
|
|
52
52
|
]
|
|
53
53
|
export const BudibaseRoleOptions = [
|
|
54
54
|
{
|
|
55
|
-
label: "
|
|
55
|
+
label: "Organisation admin",
|
|
56
56
|
value: BudibaseRoles.Admin,
|
|
57
|
-
subtitle: "
|
|
57
|
+
subtitle: "Can change settings and access all workspaces.",
|
|
58
58
|
sortOrder: 1,
|
|
59
59
|
},
|
|
60
60
|
{
|