@daocloud-proto/agentclaw 0.3.3-rc1-7-g4c8fa6b → 0.3.3
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
CHANGED
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
|
|
7
7
|
import * as fm from "../../fetch.pb"
|
|
8
8
|
import * as GoogleProtobufEmpty from "../../google/api/empty.pb"
|
|
9
|
-
import * as AgentclawV1alpha1OverviewOverview from "../overview/overview.pb"
|
|
10
9
|
import * as AgentclawV1alpha1TypesTypes from "../types/types.pb"
|
|
11
10
|
|
|
12
11
|
export enum AgentImagePortName {
|
|
@@ -54,7 +53,6 @@ export type AgentInstanceSpec = {
|
|
|
54
53
|
feishu?: AgentclawV1alpha1TypesTypes.FeishuConfig
|
|
55
54
|
modelConfig?: AgentclawV1alpha1TypesTypes.ModelConfig
|
|
56
55
|
resources?: AgentclawV1alpha1TypesTypes.ResourceConfig
|
|
57
|
-
fallbackModels?: AgentclawV1alpha1TypesTypes.ModelConfig[]
|
|
58
56
|
}
|
|
59
57
|
|
|
60
58
|
export type NetworkConfig = {
|
|
@@ -154,111 +152,6 @@ export type FeishuOnboardEvent = {
|
|
|
154
152
|
clientSecret?: string
|
|
155
153
|
}
|
|
156
154
|
|
|
157
|
-
export type GetAgentInstanceRequest = {
|
|
158
|
-
workspace?: number
|
|
159
|
-
cluster?: string
|
|
160
|
-
namespace?: string
|
|
161
|
-
name?: string
|
|
162
|
-
rangeQuery?: AgentclawV1alpha1OverviewOverview.RangeQuery
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
export type TokenUsageOverview = {
|
|
166
|
-
today?: AgentclawV1alpha1OverviewOverview.TokenUsage
|
|
167
|
-
thisMonth?: AgentclawV1alpha1OverviewOverview.TokenUsage
|
|
168
|
-
currentTotal?: AgentclawV1alpha1OverviewOverview.TokenUsage
|
|
169
|
-
tokenUsageTrend?: AgentclawV1alpha1OverviewOverview.TrendPoint[]
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
export type UsagePerformance = {
|
|
173
|
-
calls?: number
|
|
174
|
-
callsChanges?: number
|
|
175
|
-
successRate?: number
|
|
176
|
-
successRateChanges?: number
|
|
177
|
-
avgResponseTime?: number
|
|
178
|
-
avgResponseTimeChanges?: number
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
export type GetAgentInstanceTokenTrendResponse = {
|
|
182
|
-
tokenUsageToday?: AgentclawV1alpha1OverviewOverview.TokenUsage
|
|
183
|
-
tokenUsageMonth?: AgentclawV1alpha1OverviewOverview.TokenUsage
|
|
184
|
-
tokenUsageTotal?: AgentclawV1alpha1OverviewOverview.TokenUsage
|
|
185
|
-
tokenUsageTrend?: AgentclawV1alpha1OverviewOverview.TrendPoint[]
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
export type GetAgentInstanceBehaviorAnalysisResponse = {
|
|
189
|
-
totalCalls?: number
|
|
190
|
-
totalCallsChanges?: number
|
|
191
|
-
successRate?: number
|
|
192
|
-
successRateChanges?: number
|
|
193
|
-
avgResponseTime?: number
|
|
194
|
-
avgResponseTimeChanges?: number
|
|
195
|
-
skillCallDistribution?: AgentclawV1alpha1OverviewOverview.DistributionItem[]
|
|
196
|
-
modelUsageDistribution?: AgentclawV1alpha1OverviewOverview.DistributionItem[]
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
export type GetAgentInstanceRootSpansRequest = {
|
|
200
|
-
workspace?: number
|
|
201
|
-
cluster?: string
|
|
202
|
-
namespace?: string
|
|
203
|
-
name?: string
|
|
204
|
-
status?: string
|
|
205
|
-
input?: string
|
|
206
|
-
rangeQuery?: AgentclawV1alpha1OverviewOverview.RangeQuery
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
export type GetOpenClawSpansResponse = {
|
|
210
|
-
items?: OpenClawSpan[]
|
|
211
|
-
pagination?: AgentclawV1alpha1TypesTypes.Pagination
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
export type OpenClawSpan = {
|
|
215
|
-
traceId?: string
|
|
216
|
-
spanId?: string
|
|
217
|
-
operationName?: string
|
|
218
|
-
startTime?: string
|
|
219
|
-
durationMs?: number
|
|
220
|
-
agent?: OpenClawAgent
|
|
221
|
-
session?: OpenClawSession
|
|
222
|
-
entryPoint?: string
|
|
223
|
-
model?: OpenClawModel
|
|
224
|
-
tokens?: OpenClawTokens
|
|
225
|
-
toolCount?: string
|
|
226
|
-
costUsd?: number
|
|
227
|
-
status?: string
|
|
228
|
-
previews?: OpenClawPreviews
|
|
229
|
-
lane?: string
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
export type OpenClawAgent = {
|
|
233
|
-
id?: string
|
|
234
|
-
name?: string
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
export type OpenClawSession = {
|
|
238
|
-
id?: string
|
|
239
|
-
key?: string
|
|
240
|
-
chatType?: string
|
|
241
|
-
cwd?: string
|
|
242
|
-
updatedAt?: string
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
export type OpenClawModel = {
|
|
246
|
-
provider?: string
|
|
247
|
-
name?: string
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
export type OpenClawTokens = {
|
|
251
|
-
input?: string
|
|
252
|
-
output?: string
|
|
253
|
-
total?: string
|
|
254
|
-
}
|
|
255
|
-
|
|
256
|
-
export type OpenClawPreviews = {
|
|
257
|
-
input?: string
|
|
258
|
-
output?: string
|
|
259
|
-
reasoning?: string
|
|
260
|
-
}
|
|
261
|
-
|
|
262
155
|
export class AgentService {
|
|
263
156
|
static ListWorkspaceAgentInstances(req: ListWorkspaceAgentInstancesRequest, initReq?: fm.InitReq): Promise<ListWorkspaceAgentInstancesResponse> {
|
|
264
157
|
return fm.fetchReq<ListWorkspaceAgentInstancesRequest, ListWorkspaceAgentInstancesResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspaceId"]}/agent-instances?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
@@ -290,13 +183,4 @@ export class AgentService {
|
|
|
290
183
|
static WatchFeishuOnboard(req: WatchFeishuOnboardRequest, entityNotifier?: fm.NotifyStreamEntityArrival<FeishuOnboardEvent>, initReq?: fm.InitReq): Promise<void> {
|
|
291
184
|
return fm.fetchStreamingRequest<WatchFeishuOnboardRequest, FeishuOnboardEvent>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspaceId"]}/agent-instances/channels/feishu-onboard`, entityNotifier, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
|
|
292
185
|
}
|
|
293
|
-
static GetAgentInstanceTokenTrend(req: GetAgentInstanceRequest, initReq?: fm.InitReq): Promise<GetAgentInstanceTokenTrendResponse> {
|
|
294
|
-
return fm.fetchReq<GetAgentInstanceRequest, GetAgentInstanceTokenTrendResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/agent-instances/${req["name"]}/token-trend?${fm.renderURLSearchParams(req, ["workspace", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
295
|
-
}
|
|
296
|
-
static GetAgentInstanceBehaviorAnalysis(req: GetAgentInstanceRequest, initReq?: fm.InitReq): Promise<GetAgentInstanceBehaviorAnalysisResponse> {
|
|
297
|
-
return fm.fetchReq<GetAgentInstanceRequest, GetAgentInstanceBehaviorAnalysisResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/agent-instances/${req["name"]}/behavior-analysis?${fm.renderURLSearchParams(req, ["workspace", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
298
|
-
}
|
|
299
|
-
static QueryOpenClawRootSpans(req: GetAgentInstanceRootSpansRequest, initReq?: fm.InitReq): Promise<GetOpenClawSpansResponse> {
|
|
300
|
-
return fm.fetchReq<GetAgentInstanceRootSpansRequest, GetOpenClawSpansResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/agent-instances/${req["name"]}/spans`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
|
|
301
|
-
}
|
|
302
186
|
}
|
|
@@ -1,149 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
/*
|
|
4
|
-
* This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
import * as fm from "../../fetch.pb"
|
|
8
|
-
import * as AgentclawV1alpha1TypesTypes from "../types/types.pb"
|
|
9
|
-
|
|
10
|
-
type Absent<T, K extends keyof T> = { [k in Exclude<keyof T, K>]?: undefined };
|
|
11
|
-
type OneOf<T> =
|
|
12
|
-
| { [k in keyof T]?: undefined }
|
|
13
|
-
| (
|
|
14
|
-
keyof T extends infer K ?
|
|
15
|
-
(K extends string & keyof T ? { [k in K]: T[K] } & Absent<T, K>
|
|
16
|
-
: never)
|
|
17
|
-
: never);
|
|
18
|
-
|
|
19
|
-
export enum TokenQuotaPeriod {
|
|
20
|
-
TOKEN_QUOTA_PERIOD_UNSPECIFIED = "TOKEN_QUOTA_PERIOD_UNSPECIFIED",
|
|
21
|
-
TOKEN_QUOTA_PERIOD_DAY = "TOKEN_QUOTA_PERIOD_DAY",
|
|
22
|
-
TOKEN_QUOTA_PERIOD_WEEK = "TOKEN_QUOTA_PERIOD_WEEK",
|
|
23
|
-
TOKEN_QUOTA_PERIOD_MONTH = "TOKEN_QUOTA_PERIOD_MONTH",
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
export enum GetTopStateRequestRankType {
|
|
27
|
-
USER = "USER",
|
|
28
|
-
INSTANCE = "INSTANCE",
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export type GetSummaryRequest = {
|
|
32
|
-
workspace?: number
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
export type GetSummaryResponse = {
|
|
36
|
-
activeUsers?: number
|
|
37
|
-
totalUsers?: number
|
|
38
|
-
activeUserChanges?: number
|
|
39
|
-
tokenQuota?: number
|
|
40
|
-
usedTokens?: number
|
|
41
|
-
tokenUsageRate?: number
|
|
42
|
-
tokenQuotaPeriod?: TokenQuotaPeriod
|
|
43
|
-
totalInstances?: number
|
|
44
|
-
runningInstances?: number
|
|
45
|
-
abnormalInstances?: number
|
|
46
|
-
apiKeyCount?: number
|
|
47
|
-
apiKeyChanges?: number
|
|
48
|
-
tokenUsageToday?: number
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
export type RangeQuery = {
|
|
52
|
-
start?: string
|
|
53
|
-
end?: string
|
|
54
|
-
step?: number
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
export type GetStateRequest = {
|
|
58
|
-
workspace?: number
|
|
59
|
-
rangeQuery?: RangeQuery
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
export type TokenUsage = {
|
|
63
|
-
total?: number
|
|
64
|
-
input?: number
|
|
65
|
-
output?: number
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
export type GetRunningStateResponseTokenUsageTrend = {
|
|
69
|
-
input?: TrendPoint[]
|
|
70
|
-
output?: TrendPoint[]
|
|
71
|
-
total?: TrendPoint[]
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
export type GetRunningStateResponse = {
|
|
75
|
-
tokenUsageCurrent?: TokenUsage
|
|
76
|
-
totalTokenUsageChanges?: TokenUsage
|
|
77
|
-
callTotal?: number
|
|
78
|
-
callTrendChanges?: number
|
|
79
|
-
callErrorsRate?: number
|
|
80
|
-
callErrorsRateTarget?: number
|
|
81
|
-
tokenUsageTrend?: GetRunningStateResponseTokenUsageTrend
|
|
82
|
-
callTrend?: TrendPoint[]
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
export type TrendPoint = {
|
|
86
|
-
time?: string
|
|
87
|
-
value?: number
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
export type GetTopStateRequest = {
|
|
91
|
-
workspace?: number
|
|
92
|
-
rankType?: GetTopStateRequestRankType
|
|
93
|
-
rangeQuery?: RangeQuery
|
|
94
|
-
page?: number
|
|
95
|
-
pageSize?: number
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
type BaseGetTopStateResponse = {
|
|
100
|
-
pagination?: AgentclawV1alpha1TypesTypes.Pagination
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
export type GetTopStateResponse = BaseGetTopStateResponse
|
|
104
|
-
& OneOf<{ users: UserTopList; instances: InstanceTopList }>
|
|
105
|
-
|
|
106
|
-
export type GetTokenDistributionResponse = {
|
|
107
|
-
tokenDistribution?: DistributionItem[]
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
export type UserTopList = {
|
|
111
|
-
items?: TopUserItem[]
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
export type InstanceTopList = {
|
|
115
|
-
items?: TopInstanceItem[]
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
export type TopInstanceItem = {
|
|
119
|
-
instanceName?: string
|
|
120
|
-
userName?: string
|
|
121
|
-
tokenUsage?: number
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
export type TopUserItem = {
|
|
125
|
-
userName?: string
|
|
126
|
-
tokenUsage?: number
|
|
127
|
-
instances?: string[]
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
export type DistributionItem = {
|
|
131
|
-
name?: string
|
|
132
|
-
value?: number
|
|
133
|
-
percentage?: number
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
export class OverviewService {
|
|
137
|
-
static GetOverviewSummary(req: GetSummaryRequest, initReq?: fm.InitReq): Promise<GetSummaryResponse> {
|
|
138
|
-
return fm.fetchReq<GetSummaryRequest, GetSummaryResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/overview/summary?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
|
|
139
|
-
}
|
|
140
|
-
static GetOverviewRunningState(req: GetStateRequest, initReq?: fm.InitReq): Promise<GetRunningStateResponse> {
|
|
141
|
-
return fm.fetchReq<GetStateRequest, GetRunningStateResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/overview/running-state?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
|
|
142
|
-
}
|
|
143
|
-
static ListTopUsersOrInstances(req: GetTopStateRequest, initReq?: fm.InitReq): Promise<GetTopStateResponse> {
|
|
144
|
-
return fm.fetchReq<GetTopStateRequest, GetTopStateResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/overview/top-user-instances?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
|
|
145
|
-
}
|
|
146
|
-
static GetTokenDistribution(req: GetStateRequest, initReq?: fm.InitReq): Promise<GetTokenDistributionResponse> {
|
|
147
|
-
return fm.fetchReq<GetStateRequest, GetTokenDistributionResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/overview/token-distribution?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
|
|
148
|
-
}
|
|
149
|
-
}
|
|
@@ -1,160 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
/*
|
|
4
|
-
* This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
import * as fm from "../../fetch.pb"
|
|
8
|
-
import * as GoogleProtobufEmpty from "../../google/api/empty.pb"
|
|
9
|
-
import * as GoogleApiHttpbody from "../../google/api/httpbody.pb"
|
|
10
|
-
import * as AgentclawV1alpha1TypesTypes from "../types/types.pb"
|
|
11
|
-
import * as AgentclawV1alpha1SkillSkill_types from "./skill_types.pb"
|
|
12
|
-
export type ListSkillsRequest = {
|
|
13
|
-
namespace?: string
|
|
14
|
-
fuzzyName?: string
|
|
15
|
-
workspace?: number
|
|
16
|
-
sort?: AgentclawV1alpha1SkillSkill_types.SkillListSortType
|
|
17
|
-
page?: number
|
|
18
|
-
pageSize?: number
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export type ListSkillsResponse = {
|
|
22
|
-
items?: AgentclawV1alpha1SkillSkill_types.SkillSummary[]
|
|
23
|
-
pagination?: AgentclawV1alpha1TypesTypes.Pagination
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
export type ListAdminManagedSkillsRequest = {
|
|
27
|
-
namespace?: string
|
|
28
|
-
fuzzyName?: string
|
|
29
|
-
sort?: AgentclawV1alpha1SkillSkill_types.SkillListSortType
|
|
30
|
-
page?: number
|
|
31
|
-
pageSize?: number
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
export type ListAdminManagedSkillsResponse = {
|
|
35
|
-
items?: AgentclawV1alpha1SkillSkill_types.SkillSummary[]
|
|
36
|
-
pagination?: AgentclawV1alpha1TypesTypes.Pagination
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export type GetSkillRequest = {
|
|
40
|
-
namespace?: string
|
|
41
|
-
slug?: string
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
export type GetSkillResponse = {
|
|
45
|
-
item?: AgentclawV1alpha1SkillSkill_types.SkillDetail
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
export type ListSkillVersionsRequest = {
|
|
49
|
-
namespace?: string
|
|
50
|
-
slug?: string
|
|
51
|
-
page?: number
|
|
52
|
-
pageSize?: number
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
export type ListSkillVersionsResponse = {
|
|
56
|
-
items?: AgentclawV1alpha1SkillSkill_types.SkillVersionItem[]
|
|
57
|
-
pagination?: AgentclawV1alpha1TypesTypes.Pagination
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
export type ListSkillFilesRequest = {
|
|
61
|
-
namespace?: string
|
|
62
|
-
slug?: string
|
|
63
|
-
version?: string
|
|
64
|
-
path?: string
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export type ListSkillFilesResponse = {
|
|
68
|
-
items?: AgentclawV1alpha1SkillSkill_types.SkillFile[]
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
export type GetSkillFileRequest = {
|
|
72
|
-
namespace?: string
|
|
73
|
-
slug?: string
|
|
74
|
-
version?: string
|
|
75
|
-
path?: string
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
export type GetSkillFileResponse = {
|
|
79
|
-
contentType?: string
|
|
80
|
-
text?: string
|
|
81
|
-
size?: string
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
export type DownloadSkillFileRequest = {
|
|
85
|
-
namespace?: string
|
|
86
|
-
slug?: string
|
|
87
|
-
version?: string
|
|
88
|
-
path?: string
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
export type GetSkillSecurityAuditRequest = {
|
|
92
|
-
namespace?: string
|
|
93
|
-
slugId?: string
|
|
94
|
-
versionId?: string
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
export type GetSkillSecurityAuditResponse = {
|
|
98
|
-
items?: AgentclawV1alpha1SkillSkill_types.SkillSecurityAudit[]
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
export type GetSkillRegistryRequest = {
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
export type GetSkillRegistryResponse = {
|
|
105
|
-
registryUrl?: string
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
export type SetSkillListingRequest = {
|
|
109
|
-
namespace?: string
|
|
110
|
-
slug?: string
|
|
111
|
-
listed?: boolean
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
export type SetSkillListingResponse = {
|
|
115
|
-
version?: AgentclawV1alpha1SkillSkill_types.SkillLifecycleVersion
|
|
116
|
-
action?: string
|
|
117
|
-
status?: AgentclawV1alpha1SkillSkill_types.SkillStatus
|
|
118
|
-
listed?: boolean
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
export type DeleteSkillRequest = {
|
|
122
|
-
namespace?: string
|
|
123
|
-
slug?: string
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
export class SkillService {
|
|
127
|
-
static ListSkills(req: ListSkillsRequest, initReq?: fm.InitReq): Promise<ListSkillsResponse> {
|
|
128
|
-
return fm.fetchReq<ListSkillsRequest, ListSkillsResponse>(`/apis/agentclaw.io/v1alpha1/workspaces/${req["workspace"]}/skills?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
|
|
129
|
-
}
|
|
130
|
-
static ListAdminManagedSkills(req: ListAdminManagedSkillsRequest, initReq?: fm.InitReq): Promise<ListAdminManagedSkillsResponse> {
|
|
131
|
-
return fm.fetchReq<ListAdminManagedSkillsRequest, ListAdminManagedSkillsResponse>(`/apis/agentclaw.io/v1alpha1/skills/managed?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
132
|
-
}
|
|
133
|
-
static GetSkill(req: GetSkillRequest, initReq?: fm.InitReq): Promise<GetSkillResponse> {
|
|
134
|
-
return fm.fetchReq<GetSkillRequest, GetSkillResponse>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slug"]}?${fm.renderURLSearchParams(req, ["namespace", "slug"])}`, {...initReq, method: "GET"})
|
|
135
|
-
}
|
|
136
|
-
static ListSkillVersions(req: ListSkillVersionsRequest, initReq?: fm.InitReq): Promise<ListSkillVersionsResponse> {
|
|
137
|
-
return fm.fetchReq<ListSkillVersionsRequest, ListSkillVersionsResponse>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slug"]}/versions?${fm.renderURLSearchParams(req, ["namespace", "slug"])}`, {...initReq, method: "GET"})
|
|
138
|
-
}
|
|
139
|
-
static ListSkillFiles(req: ListSkillFilesRequest, initReq?: fm.InitReq): Promise<ListSkillFilesResponse> {
|
|
140
|
-
return fm.fetchReq<ListSkillFilesRequest, ListSkillFilesResponse>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slug"]}/versions/${req["version"]}/files?${fm.renderURLSearchParams(req, ["namespace", "slug", "version"])}`, {...initReq, method: "GET"})
|
|
141
|
-
}
|
|
142
|
-
static GetSkillFile(req: GetSkillFileRequest, initReq?: fm.InitReq): Promise<GetSkillFileResponse> {
|
|
143
|
-
return fm.fetchReq<GetSkillFileRequest, GetSkillFileResponse>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slug"]}/versions/${req["version"]}/file?${fm.renderURLSearchParams(req, ["namespace", "slug", "version"])}`, {...initReq, method: "GET"})
|
|
144
|
-
}
|
|
145
|
-
static DownloadSkillFile(req: DownloadSkillFileRequest, initReq?: fm.InitReq): Promise<GoogleApiHttpbody.HttpBody> {
|
|
146
|
-
return fm.fetchReq<DownloadSkillFileRequest, GoogleApiHttpbody.HttpBody>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slug"]}/versions/${req["version"]}/file/download?${fm.renderURLSearchParams(req, ["namespace", "slug", "version"])}`, {...initReq, method: "GET"})
|
|
147
|
-
}
|
|
148
|
-
static GetSkillSecurityAudit(req: GetSkillSecurityAuditRequest, initReq?: fm.InitReq): Promise<GetSkillSecurityAuditResponse> {
|
|
149
|
-
return fm.fetchReq<GetSkillSecurityAuditRequest, GetSkillSecurityAuditResponse>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slugId"]}/versions/${req["versionId"]}/security-audit?${fm.renderURLSearchParams(req, ["namespace", "slugId", "versionId"])}`, {...initReq, method: "GET"})
|
|
150
|
-
}
|
|
151
|
-
static GetSkillRegistry(req: GetSkillRegistryRequest, initReq?: fm.InitReq): Promise<GetSkillRegistryResponse> {
|
|
152
|
-
return fm.fetchReq<GetSkillRegistryRequest, GetSkillRegistryResponse>(`/apis/agentclaw.io/v1alpha1/skills/registry?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
153
|
-
}
|
|
154
|
-
static SetSkillListing(req: SetSkillListingRequest, initReq?: fm.InitReq): Promise<SetSkillListingResponse> {
|
|
155
|
-
return fm.fetchReq<SetSkillListingRequest, SetSkillListingResponse>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slug"]}/listing`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
|
|
156
|
-
}
|
|
157
|
-
static DeleteSkill(req: DeleteSkillRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
158
|
-
return fm.fetchReq<DeleteSkillRequest, GoogleProtobufEmpty.Empty>(`/apis/agentclaw.io/v1alpha1/skills/${req["namespace"]}/${req["slug"]}`, {...initReq, method: "DELETE"})
|
|
159
|
-
}
|
|
160
|
-
}
|
|
@@ -1,143 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
/*
|
|
4
|
-
* This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
export enum SkillVisibility {
|
|
8
|
-
SKILL_VISIBILITY_UNSPECIFIED = "SKILL_VISIBILITY_UNSPECIFIED",
|
|
9
|
-
SKILL_VISIBILITY_PUBLIC = "SKILL_VISIBILITY_PUBLIC",
|
|
10
|
-
SKILL_VISIBILITY_PRIVATE = "SKILL_VISIBILITY_PRIVATE",
|
|
11
|
-
SKILL_VISIBILITY_NAMESPACE_ONLY = "SKILL_VISIBILITY_NAMESPACE_ONLY",
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
export enum SkillStatus {
|
|
15
|
-
SKILL_STATUS_UNSPECIFIED = "SKILL_STATUS_UNSPECIFIED",
|
|
16
|
-
SKILL_STATUS_ACTIVE = "SKILL_STATUS_ACTIVE",
|
|
17
|
-
SKILL_STATUS_ARCHIVED = "SKILL_STATUS_ARCHIVED",
|
|
18
|
-
SKILL_STATUS_HIDDEN = "SKILL_STATUS_HIDDEN",
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export enum SkillListSortType {
|
|
22
|
-
NEWEST = "NEWEST",
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export enum SkillVersionStatus {
|
|
26
|
-
SKILL_VERSION_STATUS_UNSPECIFIED = "SKILL_VERSION_STATUS_UNSPECIFIED",
|
|
27
|
-
SKILL_VERSION_STATUS_DRAFT = "SKILL_VERSION_STATUS_DRAFT",
|
|
28
|
-
SKILL_VERSION_STATUS_REVIEW = "SKILL_VERSION_STATUS_REVIEW",
|
|
29
|
-
SKILL_VERSION_STATUS_PUBLISHED = "SKILL_VERSION_STATUS_PUBLISHED",
|
|
30
|
-
SKILL_VERSION_STATUS_YANKED = "SKILL_VERSION_STATUS_YANKED",
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export enum SkillSecurityVerdict {
|
|
34
|
-
SKILL_SECURITY_VERDICT_UNSPECIFIED = "SKILL_SECURITY_VERDICT_UNSPECIFIED",
|
|
35
|
-
SKILL_SECURITY_VERDICT_SAFE = "SKILL_SECURITY_VERDICT_SAFE",
|
|
36
|
-
SKILL_SECURITY_VERDICT_SUSPICIOUS = "SKILL_SECURITY_VERDICT_SUSPICIOUS",
|
|
37
|
-
SKILL_SECURITY_VERDICT_DANGEROUS = "SKILL_SECURITY_VERDICT_DANGEROUS",
|
|
38
|
-
SKILL_SECURITY_VERDICT_BLOCKED = "SKILL_SECURITY_VERDICT_BLOCKED",
|
|
39
|
-
SKILL_SECURITY_VERDICT_SCAN_FAILED = "SKILL_SECURITY_VERDICT_SCAN_FAILED",
|
|
40
|
-
SKILL_SECURITY_VERDICT_SCANNING = "SKILL_SECURITY_VERDICT_SCANNING",
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export enum SkillSecuritySeverity {
|
|
44
|
-
SKILL_SECURITY_SEVERITY_UNSPECIFIED = "SKILL_SECURITY_SEVERITY_UNSPECIFIED",
|
|
45
|
-
SKILL_SECURITY_SEVERITY_INFO = "SKILL_SECURITY_SEVERITY_INFO",
|
|
46
|
-
SKILL_SECURITY_SEVERITY_LOW = "SKILL_SECURITY_SEVERITY_LOW",
|
|
47
|
-
SKILL_SECURITY_SEVERITY_MEDIUM = "SKILL_SECURITY_SEVERITY_MEDIUM",
|
|
48
|
-
SKILL_SECURITY_SEVERITY_HIGH = "SKILL_SECURITY_SEVERITY_HIGH",
|
|
49
|
-
SKILL_SECURITY_SEVERITY_CRITICAL = "SKILL_SECURITY_SEVERITY_CRITICAL",
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
export type SkillLifecycleVersion = {
|
|
53
|
-
id?: string
|
|
54
|
-
version?: string
|
|
55
|
-
status?: SkillVersionStatus
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
export type SkillSummary = {
|
|
59
|
-
id?: string
|
|
60
|
-
slug?: string
|
|
61
|
-
displayName?: string
|
|
62
|
-
summary?: string
|
|
63
|
-
status?: SkillStatus
|
|
64
|
-
downloadCount?: string
|
|
65
|
-
starCount?: number
|
|
66
|
-
ratingAvg?: string
|
|
67
|
-
ratingCount?: number
|
|
68
|
-
namespace?: string
|
|
69
|
-
versionCount?: number
|
|
70
|
-
creator?: string
|
|
71
|
-
updatedAt?: string
|
|
72
|
-
headlineVersion?: SkillLifecycleVersion
|
|
73
|
-
publishedVersion?: SkillLifecycleVersion
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
export type SkillDetail = {
|
|
77
|
-
id?: string
|
|
78
|
-
slug?: string
|
|
79
|
-
displayName?: string
|
|
80
|
-
ownerId?: string
|
|
81
|
-
ownerDisplayName?: string
|
|
82
|
-
summary?: string
|
|
83
|
-
visibility?: SkillVisibility
|
|
84
|
-
status?: SkillStatus
|
|
85
|
-
downloadCount?: string
|
|
86
|
-
starCount?: number
|
|
87
|
-
ratingAvg?: string
|
|
88
|
-
ratingCount?: number
|
|
89
|
-
hidden?: boolean
|
|
90
|
-
namespace?: string
|
|
91
|
-
headlineVersion?: SkillLifecycleVersion
|
|
92
|
-
publishedVersion?: SkillLifecycleVersion
|
|
93
|
-
updatedAt?: string
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
export type SkillVersionItem = {
|
|
97
|
-
id?: string
|
|
98
|
-
version?: string
|
|
99
|
-
status?: SkillVersionStatus
|
|
100
|
-
changelog?: string
|
|
101
|
-
fileCount?: number
|
|
102
|
-
totalSize?: string
|
|
103
|
-
publishedAt?: string
|
|
104
|
-
downloadAvailable?: boolean
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
export type SkillFile = {
|
|
108
|
-
id?: string
|
|
109
|
-
filePath?: string
|
|
110
|
-
fileSize?: string
|
|
111
|
-
contentType?: string
|
|
112
|
-
sha256?: string
|
|
113
|
-
isDir?: boolean
|
|
114
|
-
name?: string
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
export type SkillSecurityFinding = {
|
|
118
|
-
ruleId?: string
|
|
119
|
-
severity?: SkillSecuritySeverity
|
|
120
|
-
category?: string
|
|
121
|
-
title?: string
|
|
122
|
-
message?: string
|
|
123
|
-
filePath?: string
|
|
124
|
-
lineNumber?: number
|
|
125
|
-
codeSnippet?: string
|
|
126
|
-
remediation?: string
|
|
127
|
-
analyzer?: string
|
|
128
|
-
metadata?: {[key: string]: string}
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
export type SkillSecurityAudit = {
|
|
132
|
-
id?: string
|
|
133
|
-
scanId?: string
|
|
134
|
-
scannerType?: string
|
|
135
|
-
verdict?: SkillSecurityVerdict
|
|
136
|
-
isSafe?: boolean
|
|
137
|
-
maxSeverity?: SkillSecuritySeverity
|
|
138
|
-
findingsCount?: number
|
|
139
|
-
findings?: SkillSecurityFinding[]
|
|
140
|
-
scanDurationSeconds?: number
|
|
141
|
-
scannedAt?: string
|
|
142
|
-
createdAt?: string
|
|
143
|
-
}
|