@botpress/api 0.6.0 → 0.7.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/dist/gen/state.d.ts +170 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +211 -7
- package/package.json +2 -2
- package/src/gen/metadata.json +1 -1
- package/src/gen/openapi.json +1 -1
- package/src/gen/state.ts +190 -2
package/dist/gen/state.d.ts
CHANGED
|
@@ -1197,6 +1197,130 @@ export declare const state: {
|
|
|
1197
1197
|
};
|
|
1198
1198
|
parameters: {};
|
|
1199
1199
|
};
|
|
1200
|
+
listPersonalAccessTokens: {
|
|
1201
|
+
name: string;
|
|
1202
|
+
description: string;
|
|
1203
|
+
method: "get";
|
|
1204
|
+
path: string;
|
|
1205
|
+
section: "account";
|
|
1206
|
+
disableDefaultParameters: {
|
|
1207
|
+
"x-workspace-id": boolean;
|
|
1208
|
+
};
|
|
1209
|
+
response: {
|
|
1210
|
+
description: string;
|
|
1211
|
+
schema: {
|
|
1212
|
+
type: "object";
|
|
1213
|
+
properties: {
|
|
1214
|
+
pats: {
|
|
1215
|
+
type: "array";
|
|
1216
|
+
items: {
|
|
1217
|
+
type: "object";
|
|
1218
|
+
properties: {
|
|
1219
|
+
id: {
|
|
1220
|
+
type: "string";
|
|
1221
|
+
};
|
|
1222
|
+
createdAt: {
|
|
1223
|
+
type: "string";
|
|
1224
|
+
format: string;
|
|
1225
|
+
};
|
|
1226
|
+
note: {
|
|
1227
|
+
type: "string";
|
|
1228
|
+
};
|
|
1229
|
+
};
|
|
1230
|
+
required: string[];
|
|
1231
|
+
};
|
|
1232
|
+
};
|
|
1233
|
+
};
|
|
1234
|
+
required: string[];
|
|
1235
|
+
title: string;
|
|
1236
|
+
additionalProperties: false;
|
|
1237
|
+
};
|
|
1238
|
+
};
|
|
1239
|
+
parameters: {};
|
|
1240
|
+
};
|
|
1241
|
+
createPersonalAccessToken: {
|
|
1242
|
+
name: string;
|
|
1243
|
+
description: string;
|
|
1244
|
+
method: "post";
|
|
1245
|
+
path: string;
|
|
1246
|
+
section: "account";
|
|
1247
|
+
disableDefaultParameters: {
|
|
1248
|
+
"x-workspace-id": boolean;
|
|
1249
|
+
};
|
|
1250
|
+
requestBody: {
|
|
1251
|
+
description: string;
|
|
1252
|
+
schema: {
|
|
1253
|
+
type: "object";
|
|
1254
|
+
properties: {
|
|
1255
|
+
note: {
|
|
1256
|
+
type: "string";
|
|
1257
|
+
description: string;
|
|
1258
|
+
};
|
|
1259
|
+
};
|
|
1260
|
+
required: string[];
|
|
1261
|
+
title: string;
|
|
1262
|
+
additionalProperties: false;
|
|
1263
|
+
};
|
|
1264
|
+
};
|
|
1265
|
+
response: {
|
|
1266
|
+
description: string;
|
|
1267
|
+
schema: {
|
|
1268
|
+
type: "object";
|
|
1269
|
+
properties: {
|
|
1270
|
+
pat: {
|
|
1271
|
+
type: "object";
|
|
1272
|
+
properties: {
|
|
1273
|
+
id: {
|
|
1274
|
+
type: "string";
|
|
1275
|
+
};
|
|
1276
|
+
createdAt: {
|
|
1277
|
+
type: "string";
|
|
1278
|
+
format: string;
|
|
1279
|
+
};
|
|
1280
|
+
note: {
|
|
1281
|
+
type: "string";
|
|
1282
|
+
};
|
|
1283
|
+
value: {
|
|
1284
|
+
type: "string";
|
|
1285
|
+
description: string;
|
|
1286
|
+
};
|
|
1287
|
+
};
|
|
1288
|
+
required: string[];
|
|
1289
|
+
additionalProperties: false;
|
|
1290
|
+
};
|
|
1291
|
+
};
|
|
1292
|
+
required: string[];
|
|
1293
|
+
title: string;
|
|
1294
|
+
additionalProperties: false;
|
|
1295
|
+
};
|
|
1296
|
+
};
|
|
1297
|
+
parameters: {};
|
|
1298
|
+
};
|
|
1299
|
+
deletePersonalAccessToken: {
|
|
1300
|
+
name: string;
|
|
1301
|
+
description: string;
|
|
1302
|
+
method: "delete";
|
|
1303
|
+
path: string;
|
|
1304
|
+
section: "account";
|
|
1305
|
+
disableDefaultParameters: {
|
|
1306
|
+
"x-workspace-id": boolean;
|
|
1307
|
+
};
|
|
1308
|
+
parameters: {
|
|
1309
|
+
id: {
|
|
1310
|
+
type: "string";
|
|
1311
|
+
description: string;
|
|
1312
|
+
in: "path";
|
|
1313
|
+
};
|
|
1314
|
+
};
|
|
1315
|
+
response: {
|
|
1316
|
+
description: string;
|
|
1317
|
+
schema: {
|
|
1318
|
+
type: "object";
|
|
1319
|
+
title: string;
|
|
1320
|
+
additionalProperties: false;
|
|
1321
|
+
};
|
|
1322
|
+
};
|
|
1323
|
+
};
|
|
1200
1324
|
listPublicIntegrations: {
|
|
1201
1325
|
name: string;
|
|
1202
1326
|
description: string;
|
|
@@ -2032,6 +2156,24 @@ export declare const state: {
|
|
|
2032
2156
|
description: string;
|
|
2033
2157
|
in: "path";
|
|
2034
2158
|
};
|
|
2159
|
+
timeStart: {
|
|
2160
|
+
in: "query";
|
|
2161
|
+
description: string;
|
|
2162
|
+
type: "string";
|
|
2163
|
+
required: true;
|
|
2164
|
+
};
|
|
2165
|
+
timeEnd: {
|
|
2166
|
+
in: "query";
|
|
2167
|
+
description: string;
|
|
2168
|
+
type: "string";
|
|
2169
|
+
required: true;
|
|
2170
|
+
};
|
|
2171
|
+
nextToken: {
|
|
2172
|
+
in: "query";
|
|
2173
|
+
description: string;
|
|
2174
|
+
type: "string";
|
|
2175
|
+
required: false;
|
|
2176
|
+
};
|
|
2035
2177
|
};
|
|
2036
2178
|
response: {
|
|
2037
2179
|
description: string;
|
|
@@ -2056,6 +2198,9 @@ export declare const state: {
|
|
|
2056
2198
|
required: string[];
|
|
2057
2199
|
};
|
|
2058
2200
|
};
|
|
2201
|
+
nextToken: {
|
|
2202
|
+
type: "string";
|
|
2203
|
+
};
|
|
2059
2204
|
};
|
|
2060
2205
|
required: string[];
|
|
2061
2206
|
title: string;
|
|
@@ -3580,6 +3725,24 @@ export declare const state: {
|
|
|
3580
3725
|
description: string;
|
|
3581
3726
|
in: "path";
|
|
3582
3727
|
};
|
|
3728
|
+
timeStart: {
|
|
3729
|
+
in: "query";
|
|
3730
|
+
description: string;
|
|
3731
|
+
type: "string";
|
|
3732
|
+
required: true;
|
|
3733
|
+
};
|
|
3734
|
+
timeEnd: {
|
|
3735
|
+
in: "query";
|
|
3736
|
+
description: string;
|
|
3737
|
+
type: "string";
|
|
3738
|
+
required: true;
|
|
3739
|
+
};
|
|
3740
|
+
nextToken: {
|
|
3741
|
+
in: "query";
|
|
3742
|
+
description: string;
|
|
3743
|
+
type: "string";
|
|
3744
|
+
required: false;
|
|
3745
|
+
};
|
|
3583
3746
|
};
|
|
3584
3747
|
response: {
|
|
3585
3748
|
description: string;
|
|
@@ -3604,6 +3767,9 @@ export declare const state: {
|
|
|
3604
3767
|
required: string[];
|
|
3605
3768
|
};
|
|
3606
3769
|
};
|
|
3770
|
+
nextToken: {
|
|
3771
|
+
type: "string";
|
|
3772
|
+
};
|
|
3607
3773
|
};
|
|
3608
3774
|
required: string[];
|
|
3609
3775
|
title: string;
|
|
@@ -3949,6 +4115,7 @@ export declare const state: {
|
|
|
3949
4115
|
patchStateBody: true;
|
|
3950
4116
|
callActionBody: true;
|
|
3951
4117
|
configureIntegrationBody: true;
|
|
4118
|
+
createPersonalAccessTokenBody: true;
|
|
3952
4119
|
createBotBody: true;
|
|
3953
4120
|
updateBotBody: true;
|
|
3954
4121
|
transferBotBody: true;
|
|
@@ -3990,6 +4157,9 @@ export declare const state: {
|
|
|
3990
4157
|
callActionResponse: true;
|
|
3991
4158
|
configureIntegrationResponse: true;
|
|
3992
4159
|
getAccountResponse: true;
|
|
4160
|
+
listPersonalAccessTokensResponse: true;
|
|
4161
|
+
createPersonalAccessTokenResponse: true;
|
|
4162
|
+
deletePersonalAccessTokenResponse: true;
|
|
3993
4163
|
listPublicIntegrationsResponse: true;
|
|
3994
4164
|
getPublicIntegrationByIdResponse: true;
|
|
3995
4165
|
getPublicIntegrationResponse: true;
|
package/dist/index.d.ts
CHANGED
|
@@ -6,4 +6,5 @@ export declare const api: {
|
|
|
6
6
|
exportServer: (dir: string | undefined, useExpressTypes: boolean) => Promise<void>;
|
|
7
7
|
exportOpenapi: (dir?: string | undefined) => void;
|
|
8
8
|
exportState: (dir?: string | undefined) => void;
|
|
9
|
+
exportErrors: (dir?: string | undefined) => void;
|
|
9
10
|
};
|
package/dist/index.js
CHANGED
|
@@ -258872,7 +258872,7 @@ __export(src_exports, {
|
|
|
258872
258872
|
});
|
|
258873
258873
|
module.exports = __toCommonJS(src_exports);
|
|
258874
258874
|
|
|
258875
|
-
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.
|
|
258875
|
+
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.4_openapi-types@12.1.0/node_modules/@bpinternal/opapi/dist/index.mjs
|
|
258876
258876
|
var import_zod_openapi = __toESM(require_src(), 1);
|
|
258877
258877
|
var import_zod_openapi2 = __toESM(require_src(), 1);
|
|
258878
258878
|
var import_chalk = __toESM(require_source(), 1);
|
|
@@ -258916,7 +258916,7 @@ var title = (str2) => {
|
|
|
258916
258916
|
return str2.split(/(?=[A-Z])|[\.\-\s_]/).map((s) => s.trim()).filter((s) => !!s).map((s) => capitalize(s.toLowerCase())).join(" ");
|
|
258917
258917
|
};
|
|
258918
258918
|
|
|
258919
|
-
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.
|
|
258919
|
+
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.4_openapi-types@12.1.0/node_modules/@bpinternal/opapi/dist/index.mjs
|
|
258920
258920
|
var import_decompress = __toESM(require_decompress(), 1);
|
|
258921
258921
|
var import_fs2 = __toESM(require("fs"), 1);
|
|
258922
258922
|
var import_promises = __toESM(require("fs/promises"), 1);
|
|
@@ -265905,7 +265905,7 @@ async function openapiTS(schema3, options = {}) {
|
|
|
265905
265905
|
}
|
|
265906
265906
|
var dist_default = openapiTS;
|
|
265907
265907
|
|
|
265908
|
-
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.
|
|
265908
|
+
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.4_openapi-types@12.1.0/node_modules/@bpinternal/opapi/dist/index.mjs
|
|
265909
265909
|
var import_zod_openapi3 = __toESM(require_src(), 1);
|
|
265910
265910
|
var import_openapi3_ts = __toESM(require_dist3(), 1);
|
|
265911
265911
|
var import_verror2 = __toESM(require_verror(), 1);
|
|
@@ -269500,7 +269500,7 @@ var z = /* @__PURE__ */ Object.freeze({
|
|
|
269500
269500
|
ZodError
|
|
269501
269501
|
});
|
|
269502
269502
|
|
|
269503
|
-
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.
|
|
269503
|
+
// ../../node_modules/.pnpm/@bpinternal+opapi@0.3.4_openapi-types@12.1.0/node_modules/@bpinternal/opapi/dist/index.mjs
|
|
269504
269504
|
var import_openapi_parser = __toESM(require_lib11(), 1);
|
|
269505
269505
|
var import_json_schema_to_typescript = __toESM(require_src3(), 1);
|
|
269506
269506
|
var import_zod_openapi4 = __toESM(require_src(), 1);
|
|
@@ -425650,6 +425650,24 @@ var generateClient = async (state2, dir = ".", openApiGeneratorEndpoint, postPro
|
|
|
425650
425650
|
removeLineFromFiles(dir, invalidLine);
|
|
425651
425651
|
log_default.info("");
|
|
425652
425652
|
};
|
|
425653
|
+
function generateErrorsFile(errors, dir = ".") {
|
|
425654
|
+
initDirectory(dir);
|
|
425655
|
+
log_default.info("Generating error types");
|
|
425656
|
+
if (!errors || errors.length === 0) {
|
|
425657
|
+
throw new import_verror.VError("No errors defined");
|
|
425658
|
+
}
|
|
425659
|
+
const errorCode = generateErrors(errors);
|
|
425660
|
+
log_default.info("");
|
|
425661
|
+
log_default.info("Saving generated files");
|
|
425662
|
+
saveFile(dir, "errors.ts", errorCode);
|
|
425663
|
+
log_default.info("");
|
|
425664
|
+
log_default.info(`Appending header to typescript files in ${import_chalk.default.blue(dir)}`);
|
|
425665
|
+
appendHeaders(dir, tsFileHeader);
|
|
425666
|
+
log_default.info("");
|
|
425667
|
+
log_default.info("Removing invalid line from typescript files");
|
|
425668
|
+
removeLineFromFiles(dir, invalidLine);
|
|
425669
|
+
log_default.info("");
|
|
425670
|
+
}
|
|
425653
425671
|
function generateOpenapi(state2, dir = ".") {
|
|
425654
425672
|
initDirectory(dir);
|
|
425655
425673
|
log_default.info("Generating openapi content");
|
|
@@ -425824,7 +425842,8 @@ var createOpapiFromState = (state2) => {
|
|
|
425824
425842
|
exportTypesBySection: (dir = ".") => generateTypesBySection(state2, dir),
|
|
425825
425843
|
exportServer: (dir = ".", useExpressTypes) => generateServer(state2, dir, useExpressTypes),
|
|
425826
425844
|
exportOpenapi: (dir = ".") => generateOpenapi(state2, dir),
|
|
425827
|
-
exportState: (dir = ".") => exportStateAsTypescript(state2, dir)
|
|
425845
|
+
exportState: (dir = ".") => exportStateAsTypescript(state2, dir),
|
|
425846
|
+
exportErrors: (dir = ".") => generateErrorsFile(state2.errors ?? [], dir)
|
|
425828
425847
|
};
|
|
425829
425848
|
};
|
|
425830
425849
|
function OpenApi(props) {
|
|
@@ -427035,6 +427054,130 @@ var state = {
|
|
|
427035
427054
|
},
|
|
427036
427055
|
parameters: {}
|
|
427037
427056
|
},
|
|
427057
|
+
listPersonalAccessTokens: {
|
|
427058
|
+
name: "listPersonalAccessTokens",
|
|
427059
|
+
description: "List PATs (Personal Access Tokens) of account.",
|
|
427060
|
+
method: "get",
|
|
427061
|
+
path: "/v1/admin/account/pats",
|
|
427062
|
+
section: "account",
|
|
427063
|
+
disableDefaultParameters: {
|
|
427064
|
+
"x-workspace-id": true
|
|
427065
|
+
},
|
|
427066
|
+
response: {
|
|
427067
|
+
description: "Success",
|
|
427068
|
+
schema: {
|
|
427069
|
+
type: "object",
|
|
427070
|
+
properties: {
|
|
427071
|
+
pats: {
|
|
427072
|
+
type: "array",
|
|
427073
|
+
items: {
|
|
427074
|
+
type: "object",
|
|
427075
|
+
properties: {
|
|
427076
|
+
id: {
|
|
427077
|
+
type: "string"
|
|
427078
|
+
},
|
|
427079
|
+
createdAt: {
|
|
427080
|
+
type: "string",
|
|
427081
|
+
format: "date-time"
|
|
427082
|
+
},
|
|
427083
|
+
note: {
|
|
427084
|
+
type: "string"
|
|
427085
|
+
}
|
|
427086
|
+
},
|
|
427087
|
+
required: ["id", "createdAt", "note"]
|
|
427088
|
+
}
|
|
427089
|
+
}
|
|
427090
|
+
},
|
|
427091
|
+
required: ["pats"],
|
|
427092
|
+
title: "listPersonalAccessTokensResponse",
|
|
427093
|
+
additionalProperties: false
|
|
427094
|
+
}
|
|
427095
|
+
},
|
|
427096
|
+
parameters: {}
|
|
427097
|
+
},
|
|
427098
|
+
createPersonalAccessToken: {
|
|
427099
|
+
name: "createPersonalAccessToken",
|
|
427100
|
+
description: "Create a PAT",
|
|
427101
|
+
method: "post",
|
|
427102
|
+
path: "/v1/admin/account/pats",
|
|
427103
|
+
section: "account",
|
|
427104
|
+
disableDefaultParameters: {
|
|
427105
|
+
"x-workspace-id": true
|
|
427106
|
+
},
|
|
427107
|
+
requestBody: {
|
|
427108
|
+
description: "",
|
|
427109
|
+
schema: {
|
|
427110
|
+
type: "object",
|
|
427111
|
+
properties: {
|
|
427112
|
+
note: {
|
|
427113
|
+
type: "string",
|
|
427114
|
+
description: "Note to identify the PAT"
|
|
427115
|
+
}
|
|
427116
|
+
},
|
|
427117
|
+
required: ["note"],
|
|
427118
|
+
title: "createPersonalAccessTokenBody",
|
|
427119
|
+
additionalProperties: false
|
|
427120
|
+
}
|
|
427121
|
+
},
|
|
427122
|
+
response: {
|
|
427123
|
+
description: "Success",
|
|
427124
|
+
schema: {
|
|
427125
|
+
type: "object",
|
|
427126
|
+
properties: {
|
|
427127
|
+
pat: {
|
|
427128
|
+
type: "object",
|
|
427129
|
+
properties: {
|
|
427130
|
+
id: {
|
|
427131
|
+
type: "string"
|
|
427132
|
+
},
|
|
427133
|
+
createdAt: {
|
|
427134
|
+
type: "string",
|
|
427135
|
+
format: "date-time"
|
|
427136
|
+
},
|
|
427137
|
+
note: {
|
|
427138
|
+
type: "string"
|
|
427139
|
+
},
|
|
427140
|
+
value: {
|
|
427141
|
+
type: "string",
|
|
427142
|
+
description: "The PAT value. This will only be returned here when created and cannot be retrieved later."
|
|
427143
|
+
}
|
|
427144
|
+
},
|
|
427145
|
+
required: ["id", "createdAt", "note", "value"],
|
|
427146
|
+
additionalProperties: false
|
|
427147
|
+
}
|
|
427148
|
+
},
|
|
427149
|
+
required: ["pat"],
|
|
427150
|
+
title: "createPersonalAccessTokenResponse",
|
|
427151
|
+
additionalProperties: false
|
|
427152
|
+
}
|
|
427153
|
+
},
|
|
427154
|
+
parameters: {}
|
|
427155
|
+
},
|
|
427156
|
+
deletePersonalAccessToken: {
|
|
427157
|
+
name: "deletePersonalAccessToken",
|
|
427158
|
+
description: "Delete a PAT",
|
|
427159
|
+
method: "delete",
|
|
427160
|
+
path: "/v1/admin/account/pats/{id}",
|
|
427161
|
+
section: "account",
|
|
427162
|
+
disableDefaultParameters: {
|
|
427163
|
+
"x-workspace-id": true
|
|
427164
|
+
},
|
|
427165
|
+
parameters: {
|
|
427166
|
+
id: {
|
|
427167
|
+
type: "string",
|
|
427168
|
+
description: "ID of Personal Access Token",
|
|
427169
|
+
in: "path"
|
|
427170
|
+
}
|
|
427171
|
+
},
|
|
427172
|
+
response: {
|
|
427173
|
+
description: "Success",
|
|
427174
|
+
schema: {
|
|
427175
|
+
type: "object",
|
|
427176
|
+
title: "deletePersonalAccessTokenResponse",
|
|
427177
|
+
additionalProperties: false
|
|
427178
|
+
}
|
|
427179
|
+
}
|
|
427180
|
+
},
|
|
427038
427181
|
listPublicIntegrations: {
|
|
427039
427182
|
name: "listPublicIntegrations",
|
|
427040
427183
|
description: "List public integration",
|
|
@@ -427878,6 +428021,24 @@ var state = {
|
|
|
427878
428021
|
type: "string",
|
|
427879
428022
|
description: "Bot ID",
|
|
427880
428023
|
in: "path"
|
|
428024
|
+
},
|
|
428025
|
+
timeStart: {
|
|
428026
|
+
in: "query",
|
|
428027
|
+
description: "Beginning of the time range to get logs from",
|
|
428028
|
+
type: "string",
|
|
428029
|
+
required: true
|
|
428030
|
+
},
|
|
428031
|
+
timeEnd: {
|
|
428032
|
+
in: "query",
|
|
428033
|
+
description: "End of the time range to get logs from",
|
|
428034
|
+
type: "string",
|
|
428035
|
+
required: true
|
|
428036
|
+
},
|
|
428037
|
+
nextToken: {
|
|
428038
|
+
in: "query",
|
|
428039
|
+
description: "Token to get the next page of logs",
|
|
428040
|
+
type: "string",
|
|
428041
|
+
required: false
|
|
427881
428042
|
}
|
|
427882
428043
|
},
|
|
427883
428044
|
response: {
|
|
@@ -427902,6 +428063,9 @@ var state = {
|
|
|
427902
428063
|
},
|
|
427903
428064
|
required: ["timestamp", "level", "message"]
|
|
427904
428065
|
}
|
|
428066
|
+
},
|
|
428067
|
+
nextToken: {
|
|
428068
|
+
type: "string"
|
|
427905
428069
|
}
|
|
427906
428070
|
},
|
|
427907
428071
|
required: ["logs"],
|
|
@@ -429553,6 +429717,24 @@ var state = {
|
|
|
429553
429717
|
type: "string",
|
|
429554
429718
|
description: "Integration Id",
|
|
429555
429719
|
in: "path"
|
|
429720
|
+
},
|
|
429721
|
+
timeStart: {
|
|
429722
|
+
in: "query",
|
|
429723
|
+
description: "Beginning of the time range to get logs from",
|
|
429724
|
+
type: "string",
|
|
429725
|
+
required: true
|
|
429726
|
+
},
|
|
429727
|
+
timeEnd: {
|
|
429728
|
+
in: "query",
|
|
429729
|
+
description: "End of the time range to get logs from",
|
|
429730
|
+
type: "string",
|
|
429731
|
+
required: true
|
|
429732
|
+
},
|
|
429733
|
+
nextToken: {
|
|
429734
|
+
in: "query",
|
|
429735
|
+
description: "Token to get the next page of logs",
|
|
429736
|
+
type: "string",
|
|
429737
|
+
required: false
|
|
429556
429738
|
}
|
|
429557
429739
|
},
|
|
429558
429740
|
response: {
|
|
@@ -429577,6 +429759,9 @@ var state = {
|
|
|
429577
429759
|
},
|
|
429578
429760
|
required: ["timestamp", "level", "message"]
|
|
429579
429761
|
}
|
|
429762
|
+
},
|
|
429763
|
+
nextToken: {
|
|
429764
|
+
type: "string"
|
|
429580
429765
|
}
|
|
429581
429766
|
},
|
|
429582
429767
|
required: ["logs"],
|
|
@@ -429858,7 +430043,7 @@ var state = {
|
|
|
429858
430043
|
title: "Botpress API",
|
|
429859
430044
|
description: "API for Botpress Cloud",
|
|
429860
430045
|
server: "https://api.botpress.cloud",
|
|
429861
|
-
version: "0.
|
|
430046
|
+
version: "0.7.1",
|
|
429862
430047
|
prefix: "v1"
|
|
429863
430048
|
},
|
|
429864
430049
|
errors: [
|
|
@@ -429956,6 +430141,16 @@ var state = {
|
|
|
429956
430141
|
status: 402,
|
|
429957
430142
|
type: "PaymentRequired",
|
|
429958
430143
|
description: "A payment is required to perform this request."
|
|
430144
|
+
},
|
|
430145
|
+
{
|
|
430146
|
+
status: 429,
|
|
430147
|
+
type: "QuotaExceeded",
|
|
430148
|
+
description: "The request exceeds the allowed quota. Quotas are a soft limit that can be increased."
|
|
430149
|
+
},
|
|
430150
|
+
{
|
|
430151
|
+
status: 413,
|
|
430152
|
+
type: "LimitExceeded",
|
|
430153
|
+
description: "The request exceeds the allowed limit. Limits are a hard limit that cannot be increased."
|
|
429959
430154
|
}
|
|
429960
430155
|
],
|
|
429961
430156
|
refs: {
|
|
@@ -429975,6 +430170,7 @@ var state = {
|
|
|
429975
430170
|
patchStateBody: true,
|
|
429976
430171
|
callActionBody: true,
|
|
429977
430172
|
configureIntegrationBody: true,
|
|
430173
|
+
createPersonalAccessTokenBody: true,
|
|
429978
430174
|
createBotBody: true,
|
|
429979
430175
|
updateBotBody: true,
|
|
429980
430176
|
transferBotBody: true,
|
|
@@ -430016,6 +430212,9 @@ var state = {
|
|
|
430016
430212
|
callActionResponse: true,
|
|
430017
430213
|
configureIntegrationResponse: true,
|
|
430018
430214
|
getAccountResponse: true,
|
|
430215
|
+
listPersonalAccessTokensResponse: true,
|
|
430216
|
+
createPersonalAccessTokenResponse: true,
|
|
430217
|
+
deletePersonalAccessTokenResponse: true,
|
|
430019
430218
|
listPublicIntegrationsResponse: true,
|
|
430020
430219
|
getPublicIntegrationByIdResponse: true,
|
|
430021
430220
|
getPublicIntegrationResponse: true,
|
|
@@ -431264,7 +431463,12 @@ var state = {
|
|
|
431264
431463
|
description: "",
|
|
431265
431464
|
title: "Account",
|
|
431266
431465
|
name: "account",
|
|
431267
|
-
operations: [
|
|
431466
|
+
operations: [
|
|
431467
|
+
"getAccount",
|
|
431468
|
+
"listPersonalAccessTokens",
|
|
431469
|
+
"createPersonalAccessToken",
|
|
431470
|
+
"deletePersonalAccessToken"
|
|
431471
|
+
],
|
|
431268
431472
|
schema: "Account"
|
|
431269
431473
|
}
|
|
431270
431474
|
]
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@botpress/api",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.1",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"scripts": {
|
|
@@ -22,6 +22,6 @@
|
|
|
22
22
|
"zod": "^3.20.6"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@bpinternal/opapi": "0.3.
|
|
25
|
+
"@bpinternal/opapi": "0.3.4"
|
|
26
26
|
}
|
|
27
27
|
}
|
package/src/gen/metadata.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"sections":[{"description":"","title":"User","name":"user","operations":["createUser","getUser","listUsers","getOrCreateUser","updateUser","deleteUser"],"schema":"User"},{"description":"","title":"Conversation","name":"conversation","operations":["createConversation","getConversation","listConversations","getOrCreateConversation","updateConversation","deleteConversation"],"schema":"Conversation"},{"description":"","title":"Event","name":"event","operations":["createEvent","getEvent","listEvents"],"schema":"Event"},{"description":"","title":"Message","name":"message","operations":["createMessage","getOrCreateMessage","getMessage","updateMessage","listMessages","deleteMessage"],"schema":"Message"},{"description":"","title":"File","name":"file","operations":["createFile","getFile","downloadFile","deleteFile","listFiles"],"schema":"File"},{"description":"","title":"State","name":"state","operations":["getState","setState","patchState"],"schema":"State"},{"description":"","title":"Hub","name":"hub","operations":["listPublicIntegrations","getPublicIntegrationById","getPublicIntegration"]},{"description":"","title":"Action","name":"action","operations":["callAction"]},{"description":"","title":"Bot","name":"bot","operations":["createBot","updateBot","transferBot","listBots","getBot","deleteBot","getBotLogs","getBotWebchat","getBotAnalytics"],"schema":"Bot"},{"description":"","title":"Integration","name":"integration","operations":["createIntegration","updateIntegration","listIntegrations","getIntegration","getIntegrationLogs","getIntegrationByName","deleteIntegration"],"schema":"Integration"},{"description":"","title":"Workspace","name":"workspace","operations":["createWorkspace","getWorkspace","updateWorkspace","listWorkspaces","changeWorkspacePlan","deleteWorkspace","getAuditRecords"],"schema":"Workspace"},{"description":"","title":"Workspace Member","name":"workspaceMember","operations":["listWorkspaceMembers","deleteWorkspaceMember","createWorkspaceMember","updateWorkspaceMember"],"schema":"WorkspaceMember"},{"description":"","title":"Account","name":"account","operations":["getAccount"],"schema":"Account"}],"errors":[{"status":500,"type":"Unknown","description":"An unknown error occurred"},{"status":500,"type":"Internal","description":"An internal error occurred"},{"status":401,"type":"Unauthorized","description":"The request requires to be authenticated."},{"status":403,"type":"Forbidden","description":"The requested action can't be peform by this resource."},{"status":413,"type":"PayloadTooLarge","description":"The request payload is too large."},{"status":400,"type":"InvalidPayload","description":"The request payload is invalid."},{"status":415,"type":"UnsupportedMediaType","description":"The request is invalid because the content-type is not supported."},{"status":405,"type":"MethodNotFound","description":"The requested method does not exist."},{"status":404,"type":"ResourceNotFound","description":"The requested resource does not exist."},{"status":400,"type":"InvalidJsonSchema","description":"The provided JSON schema is invalid."},{"status":400,"type":"InvalidDataFormat","description":"The provided data doesn't respect the provided JSON schema."},{"status":400,"type":"InvalidIdentifier","description":"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters."},{"status":409,"type":"RelationConflict","description":"The resource is not related with another resource. This is usually caused when providing two resources that aren't linked together."},{"status":400,"type":"ReferenceNotFound","description":"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request."},{"status":400,"type":"InvalidQuery","description":"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource."},{"status":400,"type":"Runtime","description":"An error happened during the execution of a runtime (bot or integration)."},{"status":409,"type":"AlreadyExists","description":"The record attempted to be created already exists."},{"status":429,"type":"RateLimited","description":"The request has been rate limited."},{"status":402,"type":"PaymentRequired","description":"A payment is required to perform this request."}]}
|
|
1
|
+
{"sections":[{"description":"","title":"User","name":"user","operations":["createUser","getUser","listUsers","getOrCreateUser","updateUser","deleteUser"],"schema":"User"},{"description":"","title":"Conversation","name":"conversation","operations":["createConversation","getConversation","listConversations","getOrCreateConversation","updateConversation","deleteConversation"],"schema":"Conversation"},{"description":"","title":"Event","name":"event","operations":["createEvent","getEvent","listEvents"],"schema":"Event"},{"description":"","title":"Message","name":"message","operations":["createMessage","getOrCreateMessage","getMessage","updateMessage","listMessages","deleteMessage"],"schema":"Message"},{"description":"","title":"File","name":"file","operations":["createFile","getFile","downloadFile","deleteFile","listFiles"],"schema":"File"},{"description":"","title":"State","name":"state","operations":["getState","setState","patchState"],"schema":"State"},{"description":"","title":"Hub","name":"hub","operations":["listPublicIntegrations","getPublicIntegrationById","getPublicIntegration"]},{"description":"","title":"Action","name":"action","operations":["callAction"]},{"description":"","title":"Bot","name":"bot","operations":["createBot","updateBot","transferBot","listBots","getBot","deleteBot","getBotLogs","getBotWebchat","getBotAnalytics"],"schema":"Bot"},{"description":"","title":"Integration","name":"integration","operations":["createIntegration","updateIntegration","listIntegrations","getIntegration","getIntegrationLogs","getIntegrationByName","deleteIntegration"],"schema":"Integration"},{"description":"","title":"Workspace","name":"workspace","operations":["createWorkspace","getWorkspace","updateWorkspace","listWorkspaces","changeWorkspacePlan","deleteWorkspace","getAuditRecords"],"schema":"Workspace"},{"description":"","title":"Workspace Member","name":"workspaceMember","operations":["listWorkspaceMembers","deleteWorkspaceMember","createWorkspaceMember","updateWorkspaceMember"],"schema":"WorkspaceMember"},{"description":"","title":"Account","name":"account","operations":["getAccount","listPersonalAccessTokens","createPersonalAccessToken","deletePersonalAccessToken"],"schema":"Account"}],"errors":[{"status":500,"type":"Unknown","description":"An unknown error occurred"},{"status":500,"type":"Internal","description":"An internal error occurred"},{"status":401,"type":"Unauthorized","description":"The request requires to be authenticated."},{"status":403,"type":"Forbidden","description":"The requested action can't be peform by this resource."},{"status":413,"type":"PayloadTooLarge","description":"The request payload is too large."},{"status":400,"type":"InvalidPayload","description":"The request payload is invalid."},{"status":415,"type":"UnsupportedMediaType","description":"The request is invalid because the content-type is not supported."},{"status":405,"type":"MethodNotFound","description":"The requested method does not exist."},{"status":404,"type":"ResourceNotFound","description":"The requested resource does not exist."},{"status":400,"type":"InvalidJsonSchema","description":"The provided JSON schema is invalid."},{"status":400,"type":"InvalidDataFormat","description":"The provided data doesn't respect the provided JSON schema."},{"status":400,"type":"InvalidIdentifier","description":"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters."},{"status":409,"type":"RelationConflict","description":"The resource is not related with another resource. This is usually caused when providing two resources that aren't linked together."},{"status":400,"type":"ReferenceNotFound","description":"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request."},{"status":400,"type":"InvalidQuery","description":"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource."},{"status":400,"type":"Runtime","description":"An error happened during the execution of a runtime (bot or integration)."},{"status":409,"type":"AlreadyExists","description":"The record attempted to be created already exists."},{"status":429,"type":"RateLimited","description":"The request has been rate limited."},{"status":402,"type":"PaymentRequired","description":"A payment is required to perform this request."},{"status":429,"type":"QuotaExceeded","description":"The request exceeds the allowed quota. Quotas are a soft limit that can be increased."},{"status":413,"type":"LimitExceeded","description":"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased."}]}
|