@composio/client 2.0.0-rc.19 → 2.0.0-rc.20
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/README.md +19 -6
- package/dist/{session-configs-BLy_O6bX.d.mts → api-key-revocation-DUHNHxSZ.d.mts} +177 -1205
- package/dist/effect.d.mts +3 -3
- package/dist/effect.mjs +4 -4
- package/dist/{generated-deprecated-inputs-Dy_lBver.mjs → environments-BGA2C5nZ.mjs} +18 -2
- package/dist/environments-xPjIJ-r7.d.mts +19 -0
- package/dist/{generated-operations-Dv7pAKDT.mjs → generated-operations-DhZryVXy.mjs} +1 -1
- package/dist/index.d.mts +3 -3
- package/dist/index.mjs +46 -71
- package/dist/resources/api-key-revocation.d.mts +2 -2
- package/dist/resources/api-key-revocation.mjs +13 -2
- package/dist/resources/auth/auth.d.mts +2 -2
- package/dist/resources/auth/auth.mjs +7 -2
- package/dist/resources/auth/session.d.mts +2 -2
- package/dist/resources/auth/session.mjs +10 -2
- package/dist/resources/auth-configs.d.mts +2 -2
- package/dist/resources/auth-configs.mjs +45 -2
- package/dist/resources/auth.d.mts +2 -2
- package/dist/resources/auth.mjs +1 -5
- package/dist/resources/cli/cli.d.mts +2 -2
- package/dist/resources/cli/cli.mjs +32 -2
- package/dist/resources/cli/realtime.d.mts +2 -2
- package/dist/resources/cli/realtime.mjs +19 -2
- package/dist/resources/cli.d.mts +2 -2
- package/dist/resources/cli.mjs +1 -5
- package/dist/resources/connected-accounts.d.mts +2 -2
- package/dist/resources/connected-accounts.mjs +70 -2
- package/dist/resources/custom.d.mts +2 -2
- package/dist/resources/custom.mjs +29 -2
- package/dist/resources/files.d.mts +2 -2
- package/dist/resources/files.mjs +22 -2
- package/dist/resources/keyring.d.mts +2 -2
- package/dist/resources/keyring.mjs +10 -2
- package/dist/resources/link.d.mts +2 -2
- package/dist/resources/link.mjs +13 -2
- package/dist/resources/logs/logs.d.mts +2 -2
- package/dist/resources/logs/logs.mjs +23 -2
- package/dist/resources/logs/tools.d.mts +2 -2
- package/dist/resources/logs/tools.mjs +23 -2
- package/dist/resources/logs/triggers.d.mts +2 -2
- package/dist/resources/logs/triggers.mjs +19 -2
- package/dist/resources/logs.d.mts +2 -2
- package/dist/resources/logs.mjs +1 -6
- package/dist/resources/mcp/custom.d.mts +2 -2
- package/dist/resources/mcp/custom.mjs +13 -2
- package/dist/resources/mcp/generate.d.mts +2 -2
- package/dist/resources/mcp/generate.mjs +13 -2
- package/dist/resources/mcp/mcp.d.mts +2 -2
- package/dist/resources/mcp/mcp.mjs +67 -2
- package/dist/resources/mcp.d.mts +2 -2
- package/dist/resources/mcp.mjs +1 -6
- package/dist/resources/org/clanker.d.mts +2 -2
- package/dist/resources/org/clanker.mjs +13 -2
- package/dist/resources/org/consumer/consumer.d.mts +2 -2
- package/dist/resources/org/consumer/consumer.mjs +21 -2
- package/dist/resources/org/consumer/project.d.mts +2 -2
- package/dist/resources/org/consumer/project.mjs +14 -2
- package/dist/resources/org/consumer.d.mts +2 -2
- package/dist/resources/org/consumer.mjs +1 -5
- package/dist/resources/org/org.d.mts +2 -2
- package/dist/resources/org/org.mjs +25 -2
- package/dist/resources/org/owner/owner.d.mts +2 -2
- package/dist/resources/org/owner/owner.mjs +7 -2
- package/dist/resources/org/owner/project.d.mts +2 -2
- package/dist/resources/org/owner/project.mjs +37 -2
- package/dist/resources/org/owner.d.mts +2 -2
- package/dist/resources/org/owner.mjs +1 -5
- package/dist/resources/org/project.d.mts +2 -2
- package/dist/resources/org/project.mjs +13 -2
- package/dist/resources/org/usage.d.mts +2 -2
- package/dist/resources/org/usage.mjs +22 -2
- package/dist/resources/org.d.mts +2 -2
- package/dist/resources/org.mjs +1 -9
- package/dist/resources/project/project.d.mts +2 -2
- package/dist/resources/project/project.mjs +7 -2
- package/dist/resources/project/usage.d.mts +2 -2
- package/dist/resources/project/usage.mjs +22 -2
- package/dist/resources/project.d.mts +2 -3
- package/dist/resources/project.mjs +1 -5
- package/dist/resources/session-configs.d.mts +2 -2
- package/dist/resources/session-configs.mjs +8 -12
- package/dist/resources/tool-router/session/files.d.mts +2 -2
- package/dist/resources/tool-router/session/files.mjs +40 -2
- package/dist/resources/tool-router/session/session.d.mts +2 -2
- package/dist/resources/tool-router/session/session.mjs +95 -2
- package/dist/resources/tool-router/session.d.mts +2 -2
- package/dist/resources/tool-router/session.mjs +1 -5
- package/dist/resources/tool-router/tool-router.d.mts +2 -2
- package/dist/resources/tool-router/tool-router.mjs +7 -2
- package/dist/resources/tool-router.d.mts +2 -2
- package/dist/resources/tool-router.mjs +1 -5
- package/dist/resources/toolkits.d.mts +2 -2
- package/dist/resources/toolkits.mjs +51 -2
- package/dist/resources/tools.d.mts +2 -2
- package/dist/resources/tools.mjs +56 -2
- package/dist/resources/trigger-instances/manage.d.mts +2 -2
- package/dist/resources/trigger-instances/manage.mjs +19 -2
- package/dist/resources/trigger-instances/trigger-instances.d.mts +2 -2
- package/dist/resources/trigger-instances/trigger-instances.mjs +24 -2
- package/dist/resources/trigger-instances.d.mts +2 -2
- package/dist/resources/trigger-instances.mjs +1 -5
- package/dist/resources/triggers-types.d.mts +2 -2
- package/dist/resources/triggers-types.mjs +26 -2
- package/dist/resources/webhook-endpoints.d.mts +2 -2
- package/dist/resources/webhook-endpoints.mjs +40 -2
- package/dist/resources/webhook-subscriptions.d.mts +2 -2
- package/dist/resources/webhook-subscriptions.mjs +45 -2
- package/package.json +2 -31
- package/dist/api-key-revocation-DMCgun-A.mjs +0 -25
- package/dist/auth-D-U9Aq8C.mjs +0 -17
- package/dist/auth-configs-DAG5mMeH.mjs +0 -55
- package/dist/clanker-Yomp86hJ.mjs +0 -24
- package/dist/cli-zihiw3aI.mjs +0 -44
- package/dist/config-BLBbhLe1.mjs +0 -10
- package/dist/config-DnyMhILW.d.mts +0 -9
- package/dist/connected-accounts-Bd4AbWoH.mjs +0 -83
- package/dist/consumer-Bk0cyIii.mjs +0 -33
- package/dist/custom-Ce8G2c11.mjs +0 -34
- package/dist/custom-DWT3cCog.mjs +0 -24
- package/dist/files-DRp_J4zH.mjs +0 -49
- package/dist/files-ZxEVlE_y.mjs +0 -31
- package/dist/generate-Du9XUrlx.mjs +0 -24
- package/dist/keyring-CgOIS5x7.mjs +0 -17
- package/dist/link-CW1ts4pm.mjs +0 -23
- package/dist/logs-DFdH5DoT.mjs +0 -37
- package/dist/manage-CeB03gO8.mjs +0 -28
- package/dist/mcp-DNRMWWum.mjs +0 -91
- package/dist/migration-CBhnoN-Y.mjs +0 -10
- package/dist/migration-CKGKuRO3.d.mts +0 -9
- package/dist/org-HuYaKgVf.mjs +0 -45
- package/dist/owner-I9fXmIO_.mjs +0 -17
- package/dist/project-CxQ2H8UB.mjs +0 -22
- package/dist/project-DcV01umC.mjs +0 -25
- package/dist/project-Dwblmpw8.mjs +0 -47
- package/dist/project-FuP5k9R1.mjs +0 -25
- package/dist/realtime-F_sGuTd8.mjs +0 -28
- package/dist/resources/auth/index.d.mts +0 -2
- package/dist/resources/auth/index.mjs +0 -4
- package/dist/resources/cli/index.d.mts +0 -2
- package/dist/resources/cli/index.mjs +0 -4
- package/dist/resources/index.d.mts +0 -3
- package/dist/resources/index.mjs +0 -16
- package/dist/resources/logs/index.d.mts +0 -2
- package/dist/resources/logs/index.mjs +0 -5
- package/dist/resources/mcp/index.d.mts +0 -2
- package/dist/resources/mcp/index.mjs +0 -5
- package/dist/resources/migration.d.mts +0 -2
- package/dist/resources/migration.mjs +0 -3
- package/dist/resources/org/consumer/index.d.mts +0 -2
- package/dist/resources/org/consumer/index.mjs +0 -4
- package/dist/resources/org/index.d.mts +0 -2
- package/dist/resources/org/index.mjs +0 -8
- package/dist/resources/org/owner/index.d.mts +0 -2
- package/dist/resources/org/owner/index.mjs +0 -4
- package/dist/resources/project/config.d.mts +0 -2
- package/dist/resources/project/config.mjs +0 -3
- package/dist/resources/project/index.d.mts +0 -3
- package/dist/resources/project/index.mjs +0 -4
- package/dist/resources/tool-router/index.d.mts +0 -2
- package/dist/resources/tool-router/index.mjs +0 -4
- package/dist/resources/tool-router/session/index.d.mts +0 -2
- package/dist/resources/tool-router/session/index.mjs +0 -4
- package/dist/resources/trigger-instances/index.d.mts +0 -2
- package/dist/resources/trigger-instances/index.mjs +0 -4
- package/dist/session-B-ifOjVv.mjs +0 -21
- package/dist/session-CpwJh7Hn.mjs +0 -110
- package/dist/tool-router-jNsaldKV.mjs +0 -14
- package/dist/toolkits-DK4My9FW.mjs +0 -62
- package/dist/tools-DNkimllW.mjs +0 -33
- package/dist/tools-Gun_2We6.mjs +0 -69
- package/dist/trigger-instances-vvKswQSW.mjs +0 -35
- package/dist/triggers-CfrGxKIo.mjs +0 -28
- package/dist/triggers-types-DYW2Mr8z.mjs +0 -34
- package/dist/usage-YIBYNpVF.mjs +0 -31
- package/dist/usage-vt9HmnNf.mjs +0 -31
- package/dist/version-DB98yI2B.d.mts +0 -4
- package/dist/webhook-endpoints-HqLteVW6.mjs +0 -50
- package/dist/webhook-subscriptions-CXhNXIOM.mjs +0 -55
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { Project,
|
|
1
|
+
import { at as ProjectCreateParams, ct as ProjectDeleteResponse, dt as ProjectRegenerateAPIKeyResponse, ft as ProjectRetrieveResponse, it as Project, lt as ProjectListParams, ot as ProjectCreateResponse, pt as makeProject, st as ProjectDeleteParams, ut as ProjectListResponse } from "../../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { Project, ProjectCreateParams, ProjectCreateResponse, ProjectDeleteParams, ProjectDeleteResponse, ProjectListParams, ProjectListResponse, ProjectRegenerateAPIKeyResponse, ProjectRetrieveResponse, makeProject };
|
|
@@ -1,3 +1,38 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as path, n as generatedOperation, y as withOperation } from "../../../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/org/owner/project.ts
|
|
4
|
+
const OP_CREATE = generatedOperation("org.owner.project.create");
|
|
5
|
+
const OP_RETRIEVE = generatedOperation("org.owner.project.retrieve");
|
|
6
|
+
const OP_LIST = generatedOperation("org.owner.project.list");
|
|
7
|
+
const OP_DELETE = generatedOperation("org.owner.project.delete");
|
|
8
|
+
const OP_REGENERATE_APIKEY = generatedOperation("org.owner.project.regenerateAPIKey");
|
|
9
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
10
|
+
const makeProject = (client) => ({
|
|
11
|
+
create(body, options) {
|
|
12
|
+
return client.post("/api/v3.1/org/owner/project/new", withOperation(OP_CREATE, {
|
|
13
|
+
body,
|
|
14
|
+
...options
|
|
15
|
+
}));
|
|
16
|
+
},
|
|
17
|
+
retrieve(nanoID, options) {
|
|
18
|
+
return client.get(path`/api/v3.1/org/owner/project/${nanoID}`, withOperation(OP_RETRIEVE, { ...options }));
|
|
19
|
+
},
|
|
20
|
+
list(query = {}, options) {
|
|
21
|
+
return client.get("/api/v3.1/org/owner/project/list", withOperation(OP_LIST, {
|
|
22
|
+
query,
|
|
23
|
+
...options
|
|
24
|
+
}));
|
|
25
|
+
},
|
|
26
|
+
delete(nanoID, query = {}, options) {
|
|
27
|
+
return client.delete(path`/api/v3.1/org/owner/project/${nanoID}`, withOperation(OP_DELETE, {
|
|
28
|
+
query,
|
|
29
|
+
...options
|
|
30
|
+
}));
|
|
31
|
+
},
|
|
32
|
+
regenerateAPIKey(nanoID, options) {
|
|
33
|
+
return client.post(path`/api/v3.1/org/owner/project/${nanoID}/regenerate_api_key`, withOperation(OP_REGENERATE_APIKEY, { ...options }));
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
//#endregion
|
|
38
|
+
export { makeProject };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { Owner, Project,
|
|
1
|
+
import { at as ProjectCreateParams, ct as ProjectDeleteResponse, dt as ProjectRegenerateAPIKeyResponse, ft as ProjectRetrieveResponse, it as Project, lt as ProjectListParams, nt as Owner, ot as ProjectCreateResponse, st as ProjectDeleteParams, ut as ProjectListResponse } from "../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export type { Owner, Project, ProjectCreateParams, ProjectCreateResponse, ProjectDeleteParams, ProjectDeleteResponse, ProjectListParams, ProjectListResponse, ProjectRegenerateAPIKeyResponse, ProjectRetrieveResponse };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { Project,
|
|
1
|
+
import { G as ProjectListParams, K as ProjectListResponse, W as Project, q as makeProject } from "../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { Project, ProjectListParams, ProjectListResponse, makeProject };
|
|
@@ -1,3 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { n as generatedOperation, y as withOperation } from "../../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/org/project.ts
|
|
4
|
+
const OP_LIST = generatedOperation("org.project.list");
|
|
5
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
6
|
+
const makeProject = (client) => ({ list(query = {}, options) {
|
|
7
|
+
return client.get("/api/v3.1/org/project/list", withOperation(OP_LIST, {
|
|
8
|
+
query,
|
|
9
|
+
...options
|
|
10
|
+
}));
|
|
11
|
+
} });
|
|
12
|
+
|
|
13
|
+
//#endregion
|
|
14
|
+
export { makeProject };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { Usage,
|
|
1
|
+
import { B as UsageRetrieveResponse, H as UsageRetrieveSummaryResponse, R as Usage, U as makeUsage, V as UsageRetrieveSummaryParams, z as UsageRetrieveParams } from "../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { Usage, UsageRetrieveParams, UsageRetrieveResponse, UsageRetrieveSummaryParams, UsageRetrieveSummaryResponse, makeUsage };
|
|
@@ -1,3 +1,23 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as path, n as generatedOperation, y as withOperation } from "../../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/org/usage.ts
|
|
4
|
+
const OP_RETRIEVE = generatedOperation("org.usage.retrieve");
|
|
5
|
+
const OP_RETRIEVE_SUMMARY = generatedOperation("org.usage.retrieveSummary");
|
|
6
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
7
|
+
const makeUsage = (client) => ({
|
|
8
|
+
retrieve(entityType, body = {}, options) {
|
|
9
|
+
return client.post(path`/api/v3.1/org/usage/${entityType}`, withOperation(OP_RETRIEVE, {
|
|
10
|
+
body,
|
|
11
|
+
...options
|
|
12
|
+
}));
|
|
13
|
+
},
|
|
14
|
+
retrieveSummary(body = {}, options) {
|
|
15
|
+
return client.post("/api/v3.1/org/usage/summary", withOperation(OP_RETRIEVE_SUMMARY, {
|
|
16
|
+
body,
|
|
17
|
+
...options
|
|
18
|
+
}));
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
//#endregion
|
|
23
|
+
export { makeUsage };
|
package/dist/resources/org.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { A as
|
|
2
|
-
export { Clanker,
|
|
1
|
+
import { A as Org, B as UsageRetrieveResponse, F as ClankerCreateClaimParams, G as ProjectListParams, H as UsageRetrieveSummaryResponse, I as ClankerCreateClaimResponse, J as Consumer, K as ProjectListResponse, M as OrgListResponse, P as Clanker, R as Usage, V as UsageRetrieveSummaryParams, W as Project, X as ConsumerListConnectedToolkitsResponse, Y as ConsumerListConnectedToolkitsParams, j as OrgListParams, nt as Owner, z as UsageRetrieveParams } from "../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export type { Clanker, ClankerCreateClaimParams, ClankerCreateClaimResponse, Consumer, ConsumerListConnectedToolkitsParams, ConsumerListConnectedToolkitsResponse, Org, OrgListParams, OrgListResponse, Owner, Project, ProjectListParams, ProjectListResponse, Usage, UsageRetrieveParams, UsageRetrieveResponse, UsageRetrieveSummaryParams, UsageRetrieveSummaryResponse };
|
package/dist/resources/org.mjs
CHANGED
|
@@ -1,9 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { t as Consumer } from "../consumer-Bk0cyIii.mjs";
|
|
3
|
-
import { t as Owner } from "../owner-I9fXmIO_.mjs";
|
|
4
|
-
import { t as Project } from "../project-FuP5k9R1.mjs";
|
|
5
|
-
import { t as Usage } from "../usage-vt9HmnNf.mjs";
|
|
6
|
-
import { t as Org } from "../org-HuYaKgVf.mjs";
|
|
7
|
-
import "./org/index.mjs";
|
|
8
|
-
|
|
9
|
-
export { Clanker, Consumer, Org, Owner, Project, Usage };
|
|
1
|
+
export { };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { Project };
|
|
1
|
+
import { Lt as Project, Rt as makeProject } from "../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { Project, makeProject };
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { makeUsage } from "./usage.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/project/project.ts
|
|
4
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
5
|
+
const makeProject = (client) => ({ usage: makeUsage(client) });
|
|
6
|
+
|
|
7
|
+
//#endregion
|
|
8
|
+
export { makeProject };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { Usage,
|
|
1
|
+
import { Bt as UsageRetrieveParams, Ht as UsageRetrieveSummaryParams, Ut as UsageRetrieveSummaryResponse, Vt as UsageRetrieveResponse, Wt as makeUsage, zt as Usage } from "../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { Usage, UsageRetrieveParams, UsageRetrieveResponse, UsageRetrieveSummaryParams, UsageRetrieveSummaryResponse, makeUsage };
|
|
@@ -1,3 +1,23 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as path, n as generatedOperation, y as withOperation } from "../../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/project/usage.ts
|
|
4
|
+
const OP_RETRIEVE = generatedOperation("project.usage.retrieve");
|
|
5
|
+
const OP_RETRIEVE_SUMMARY = generatedOperation("project.usage.retrieveSummary");
|
|
6
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
7
|
+
const makeUsage = (client) => ({
|
|
8
|
+
retrieve(entityType, body = {}, options) {
|
|
9
|
+
return client.post(path`/api/v3.1/project/usage/${entityType}`, withOperation(OP_RETRIEVE, {
|
|
10
|
+
body,
|
|
11
|
+
...options
|
|
12
|
+
}));
|
|
13
|
+
},
|
|
14
|
+
retrieveSummary(body = {}, options) {
|
|
15
|
+
return client.post("/api/v3.1/project/usage/summary", withOperation(OP_RETRIEVE_SUMMARY, {
|
|
16
|
+
body,
|
|
17
|
+
...options
|
|
18
|
+
}));
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
//#endregion
|
|
23
|
+
export { makeUsage };
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
export { Config, Project };
|
|
1
|
+
import { Bt as UsageRetrieveParams, Ht as UsageRetrieveSummaryParams, Lt as Project, Ut as UsageRetrieveSummaryResponse, Vt as UsageRetrieveResponse, zt as Usage } from "../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export type { Project, Usage, UsageRetrieveParams, UsageRetrieveResponse, UsageRetrieveSummaryParams, UsageRetrieveSummaryResponse };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { SessionConfigs, SessionConfigsListParams, SessionConfigsListResponse, SessionConfigsRetrieveResponse };
|
|
1
|
+
import { d as SessionConfigsListResponse, f as SessionConfigsRetrieveResponse, l as SessionConfigs, p as makeSessionConfigs, u as SessionConfigsListParams } from "../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { SessionConfigs, SessionConfigsListParams, SessionConfigsListResponse, SessionConfigsRetrieveResponse, makeSessionConfigs };
|
|
@@ -1,24 +1,20 @@
|
|
|
1
|
-
import { d as path, n as generatedOperation, y as withOperation } from "../generated-operations-
|
|
1
|
+
import { d as path, n as generatedOperation, y as withOperation } from "../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/compat/resources/session-configs.ts
|
|
4
4
|
const OP_RETRIEVE = generatedOperation("sessionConfigs.retrieve");
|
|
5
5
|
const OP_LIST = generatedOperation("sessionConfigs.list");
|
|
6
|
-
/**
|
|
7
|
-
|
|
8
|
-
#client;
|
|
9
|
-
constructor(client) {
|
|
10
|
-
this.#client = client;
|
|
11
|
-
}
|
|
6
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
7
|
+
const makeSessionConfigs = (client) => ({
|
|
12
8
|
retrieve(sessionConfigID, options) {
|
|
13
|
-
return
|
|
14
|
-
}
|
|
9
|
+
return client.get(path`/api/v3.1/session_configs/${sessionConfigID}`, withOperation(OP_RETRIEVE, { ...options }));
|
|
10
|
+
},
|
|
15
11
|
list(query = {}, options) {
|
|
16
|
-
return
|
|
12
|
+
return client.get("/api/v3.1/session_configs", withOperation(OP_LIST, {
|
|
17
13
|
query,
|
|
18
14
|
...options
|
|
19
15
|
}));
|
|
20
16
|
}
|
|
21
|
-
};
|
|
17
|
+
});
|
|
22
18
|
|
|
23
19
|
//#endregion
|
|
24
|
-
export {
|
|
20
|
+
export { makeSessionConfigs };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { FileCreateDownloadURLParams, FileCreateDownloadURLResponse, FileCreateUploadURLParams, FileCreateUploadURLResponse, FileDeleteParams, FileDeleteResponse, FileListParams, FileListResponse, Files };
|
|
1
|
+
import { aa as FileDeleteResponse, ca as Files, ea as FileCreateDownloadURLParams, ia as FileDeleteParams, la as makeFiles, na as FileCreateUploadURLParams, oa as FileListParams, ra as FileCreateUploadURLResponse, sa as FileListResponse, ta as FileCreateDownloadURLResponse } from "../../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { FileCreateDownloadURLParams, FileCreateDownloadURLResponse, FileCreateUploadURLParams, FileCreateUploadURLResponse, FileDeleteParams, FileDeleteResponse, FileListParams, FileListResponse, Files, makeFiles };
|
|
@@ -1,3 +1,41 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as path, n as generatedOperation, y as withOperation } from "../../../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/tool-router/session/files.ts
|
|
4
|
+
const OP_LIST = generatedOperation("toolRouter.session.files.list");
|
|
5
|
+
const OP_DELETE = generatedOperation("toolRouter.session.files.delete");
|
|
6
|
+
const OP_CREATE_DOWNLOAD_URL = generatedOperation("toolRouter.session.files.createDownloadURL");
|
|
7
|
+
const OP_CREATE_UPLOAD_URL = generatedOperation("toolRouter.session.files.createUploadURL");
|
|
8
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
9
|
+
const makeFiles = (client) => ({
|
|
10
|
+
list(mountID, params, options) {
|
|
11
|
+
const { session_id, ...query } = params;
|
|
12
|
+
return client.get(path`/api/v3.1/tool_router/session/${session_id}/mounts/${mountID}/items`, withOperation(OP_LIST, {
|
|
13
|
+
query,
|
|
14
|
+
...options
|
|
15
|
+
}));
|
|
16
|
+
},
|
|
17
|
+
delete(mountID, params, options) {
|
|
18
|
+
const { session_id, ...body } = params;
|
|
19
|
+
return client.post(path`/api/v3.1/tool_router/session/${session_id}/mounts/${mountID}/delete`, withOperation(OP_DELETE, {
|
|
20
|
+
body,
|
|
21
|
+
...options
|
|
22
|
+
}));
|
|
23
|
+
},
|
|
24
|
+
createDownloadURL(mountID, params, options) {
|
|
25
|
+
const { session_id, ...body } = params;
|
|
26
|
+
return client.post(path`/api/v3.1/tool_router/session/${session_id}/mounts/${mountID}/download_url`, withOperation(OP_CREATE_DOWNLOAD_URL, {
|
|
27
|
+
body,
|
|
28
|
+
...options
|
|
29
|
+
}));
|
|
30
|
+
},
|
|
31
|
+
createUploadURL(mountID, params, options) {
|
|
32
|
+
const { session_id, ...body } = params;
|
|
33
|
+
return client.post(path`/api/v3.1/tool_router/session/${session_id}/mounts/${mountID}/upload_url`, withOperation(OP_CREATE_UPLOAD_URL, {
|
|
34
|
+
body,
|
|
35
|
+
...options
|
|
36
|
+
}));
|
|
37
|
+
}
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
//#endregion
|
|
41
|
+
export { makeFiles };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { $
|
|
2
|
-
export { Session, SessionAttachParams, SessionAttachResponse, SessionConfigHistoryParams, SessionConfigHistoryResponse, SessionCreateParams, SessionCreateResponse, SessionDeleteResponse, SessionExecuteMetaParams, SessionExecuteMetaResponse, SessionExecuteParams, SessionExecuteResponse, SessionLinkParams, SessionLinkResponse, SessionPatchParams, SessionPatchResponse, SessionProxyExecuteParams, SessionProxyExecuteResponse, SessionRetrieveResponse, SessionSearchParams, SessionSearchResponse, SessionToolkitsParams, SessionToolkitsResponse, SessionToolsParams, SessionToolsResponse };
|
|
1
|
+
import { $i as makeSession, Ai as SessionAttachResponse, Bi as SessionLinkParams, Fi as SessionDeleteResponse, Gi as SessionProxyExecuteResponse, Hi as SessionPatchParams, Ii as SessionExecuteMetaParams, Ji as SessionSearchResponse, Ki as SessionRetrieveResponse, Li as SessionExecuteMetaResponse, Mi as SessionConfigHistoryResponse, Ni as SessionCreateParams, Oi as Session, Pi as SessionCreateResponse, Qi as SessionToolsResponse, Ri as SessionExecuteParams, Ui as SessionPatchResponse, Vi as SessionLinkResponse, Wi as SessionProxyExecuteParams, Xi as SessionToolkitsResponse, Yi as SessionToolkitsParams, Zi as SessionToolsParams, ji as SessionConfigHistoryParams, ki as SessionAttachParams, qi as SessionSearchParams, zi as SessionExecuteResponse } from "../../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { Session, SessionAttachParams, SessionAttachResponse, SessionConfigHistoryParams, SessionConfigHistoryResponse, SessionCreateParams, SessionCreateResponse, SessionDeleteResponse, SessionExecuteMetaParams, SessionExecuteMetaResponse, SessionExecuteParams, SessionExecuteResponse, SessionLinkParams, SessionLinkResponse, SessionPatchParams, SessionPatchResponse, SessionProxyExecuteParams, SessionProxyExecuteResponse, SessionRetrieveResponse, SessionSearchParams, SessionSearchResponse, SessionToolkitsParams, SessionToolkitsResponse, SessionToolsParams, SessionToolsResponse, makeSession };
|
|
@@ -1,3 +1,96 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as path, n as generatedOperation, y as withOperation } from "../../../generated-operations-DhZryVXy.mjs";
|
|
2
|
+
import { makeFiles } from "./files.mjs";
|
|
2
3
|
|
|
3
|
-
|
|
4
|
+
//#region src/compat/resources/tool-router/session/session.ts
|
|
5
|
+
const OP_CREATE = generatedOperation("toolRouter.session.create");
|
|
6
|
+
const OP_RETRIEVE = generatedOperation("toolRouter.session.retrieve");
|
|
7
|
+
const OP_DELETE = generatedOperation("toolRouter.session.delete");
|
|
8
|
+
const OP_ATTACH = generatedOperation("toolRouter.session.attach");
|
|
9
|
+
const OP_CONFIG_HISTORY = generatedOperation("toolRouter.session.configHistory");
|
|
10
|
+
const OP_EXECUTE = generatedOperation("toolRouter.session.execute");
|
|
11
|
+
const OP_EXECUTE_META = generatedOperation("toolRouter.session.executeMeta");
|
|
12
|
+
const OP_LINK = generatedOperation("toolRouter.session.link");
|
|
13
|
+
const OP_PATCH = generatedOperation("toolRouter.session.patch");
|
|
14
|
+
const OP_PROXY_EXECUTE = generatedOperation("toolRouter.session.proxyExecute");
|
|
15
|
+
const OP_SEARCH = generatedOperation("toolRouter.session.search");
|
|
16
|
+
const OP_TOOLKITS = generatedOperation("toolRouter.session.toolkits");
|
|
17
|
+
const OP_TOOLS = generatedOperation("toolRouter.session.tools");
|
|
18
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
19
|
+
const makeSession = (client) => ({
|
|
20
|
+
files: makeFiles(client),
|
|
21
|
+
create(body, options) {
|
|
22
|
+
return client.post("/api/v3.1/tool_router/session", withOperation(OP_CREATE, {
|
|
23
|
+
body,
|
|
24
|
+
...options
|
|
25
|
+
}));
|
|
26
|
+
},
|
|
27
|
+
retrieve(sessionID, options) {
|
|
28
|
+
return client.get(path`/api/v3.1/tool_router/session/${sessionID}`, withOperation(OP_RETRIEVE, { ...options }));
|
|
29
|
+
},
|
|
30
|
+
delete(sessionID, options) {
|
|
31
|
+
return client.delete(path`/api/v3.1/tool_router/session/${sessionID}`, withOperation(OP_DELETE, { ...options }));
|
|
32
|
+
},
|
|
33
|
+
attach(sessionID, body = {}, options) {
|
|
34
|
+
return client.post(path`/api/v3.1/tool_router/session/${sessionID}/attach`, withOperation(OP_ATTACH, {
|
|
35
|
+
body,
|
|
36
|
+
...options
|
|
37
|
+
}));
|
|
38
|
+
},
|
|
39
|
+
configHistory(sessionID, query = {}, options) {
|
|
40
|
+
return client.get(path`/api/v3.1/tool_router/session/${sessionID}/config_history`, withOperation(OP_CONFIG_HISTORY, {
|
|
41
|
+
query,
|
|
42
|
+
...options
|
|
43
|
+
}));
|
|
44
|
+
},
|
|
45
|
+
execute(sessionID, body, options) {
|
|
46
|
+
return client.post(path`/api/v3.1/tool_router/session/${sessionID}/execute`, withOperation(OP_EXECUTE, {
|
|
47
|
+
body,
|
|
48
|
+
...options
|
|
49
|
+
}));
|
|
50
|
+
},
|
|
51
|
+
executeMeta(sessionID, body, options) {
|
|
52
|
+
return client.post(path`/api/v3.1/tool_router/session/${sessionID}/execute_meta`, withOperation(OP_EXECUTE_META, {
|
|
53
|
+
body,
|
|
54
|
+
...options
|
|
55
|
+
}));
|
|
56
|
+
},
|
|
57
|
+
link(sessionID, body, options) {
|
|
58
|
+
return client.post(path`/api/v3.1/tool_router/session/${sessionID}/link`, withOperation(OP_LINK, {
|
|
59
|
+
body,
|
|
60
|
+
...options
|
|
61
|
+
}));
|
|
62
|
+
},
|
|
63
|
+
patch(sessionID, body = {}, options) {
|
|
64
|
+
return client.patch(path`/api/v3.1/tool_router/session/${sessionID}`, withOperation(OP_PATCH, {
|
|
65
|
+
body,
|
|
66
|
+
...options
|
|
67
|
+
}));
|
|
68
|
+
},
|
|
69
|
+
proxyExecute(sessionID, body, options) {
|
|
70
|
+
return client.post(path`/api/v3.1/tool_router/session/${sessionID}/proxy_execute`, withOperation(OP_PROXY_EXECUTE, {
|
|
71
|
+
body,
|
|
72
|
+
...options
|
|
73
|
+
}));
|
|
74
|
+
},
|
|
75
|
+
search(sessionID, body, options) {
|
|
76
|
+
return client.post(path`/api/v3.1/tool_router/session/${sessionID}/search`, withOperation(OP_SEARCH, {
|
|
77
|
+
body,
|
|
78
|
+
...options
|
|
79
|
+
}));
|
|
80
|
+
},
|
|
81
|
+
toolkits(sessionID, query = {}, options) {
|
|
82
|
+
return client.get(path`/api/v3.1/tool_router/session/${sessionID}/toolkits`, withOperation(OP_TOOLKITS, {
|
|
83
|
+
query,
|
|
84
|
+
...options
|
|
85
|
+
}));
|
|
86
|
+
},
|
|
87
|
+
tools(sessionID, query = {}, options) {
|
|
88
|
+
return client.get(path`/api/v3.1/tool_router/session/${sessionID}/tools`, withOperation(OP_TOOLS, {
|
|
89
|
+
query,
|
|
90
|
+
...options
|
|
91
|
+
}));
|
|
92
|
+
}
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
//#endregion
|
|
96
|
+
export { makeSession };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
1
|
+
import { Ai as SessionAttachResponse, Bi as SessionLinkParams, Fi as SessionDeleteResponse, Gi as SessionProxyExecuteResponse, Hi as SessionPatchParams, Ii as SessionExecuteMetaParams, Ji as SessionSearchResponse, Ki as SessionRetrieveResponse, Li as SessionExecuteMetaResponse, Mi as SessionConfigHistoryResponse, Ni as SessionCreateParams, Oi as Session, Pi as SessionCreateResponse, Qi as SessionToolsResponse, Ri as SessionExecuteParams, Ui as SessionPatchResponse, Vi as SessionLinkResponse, Wi as SessionProxyExecuteParams, Xi as SessionToolkitsResponse, Yi as SessionToolkitsParams, Zi as SessionToolsParams, aa as FileDeleteResponse, ca as Files, ea as FileCreateDownloadURLParams, ia as FileDeleteParams, ji as SessionConfigHistoryParams, ki as SessionAttachParams, na as FileCreateUploadURLParams, oa as FileListParams, qi as SessionSearchParams, ra as FileCreateUploadURLResponse, sa as FileListResponse, ta as FileCreateDownloadURLResponse, zi as SessionExecuteResponse } from "../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export type { FileCreateDownloadURLParams, FileCreateDownloadURLResponse, FileCreateUploadURLParams, FileCreateUploadURLResponse, FileDeleteParams, FileDeleteResponse, FileListParams, FileListResponse, Files, Session, SessionAttachParams, SessionAttachResponse, SessionConfigHistoryParams, SessionConfigHistoryResponse, SessionCreateParams, SessionCreateResponse, SessionDeleteResponse, SessionExecuteMetaParams, SessionExecuteMetaResponse, SessionExecuteParams, SessionExecuteResponse, SessionLinkParams, SessionLinkResponse, SessionPatchParams, SessionPatchResponse, SessionProxyExecuteParams, SessionProxyExecuteResponse, SessionRetrieveResponse, SessionSearchParams, SessionSearchResponse, SessionToolkitsParams, SessionToolkitsResponse, SessionToolsParams, SessionToolsResponse };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { ToolRouter };
|
|
1
|
+
import { Di as makeToolRouter, Ei as ToolRouter } from "../../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { ToolRouter, makeToolRouter };
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { makeSession } from "./session/session.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/tool-router/tool-router.ts
|
|
4
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
5
|
+
const makeToolRouter = (client) => ({ session: makeSession(client) });
|
|
6
|
+
|
|
7
|
+
//#endregion
|
|
8
|
+
export { makeToolRouter };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { Session,
|
|
1
|
+
import { Ai as SessionAttachResponse, Bi as SessionLinkParams, Ei as ToolRouter, Fi as SessionDeleteResponse, Gi as SessionProxyExecuteResponse, Hi as SessionPatchParams, Ii as SessionExecuteMetaParams, Ji as SessionSearchResponse, Ki as SessionRetrieveResponse, Li as SessionExecuteMetaResponse, Mi as SessionConfigHistoryResponse, Ni as SessionCreateParams, Oi as Session, Pi as SessionCreateResponse, Qi as SessionToolsResponse, Ri as SessionExecuteParams, Ui as SessionPatchResponse, Vi as SessionLinkResponse, Wi as SessionProxyExecuteParams, Xi as SessionToolkitsResponse, Yi as SessionToolkitsParams, Zi as SessionToolsParams, ji as SessionConfigHistoryParams, ki as SessionAttachParams, qi as SessionSearchParams, zi as SessionExecuteResponse } from "../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export type { Session, SessionAttachParams, SessionAttachResponse, SessionConfigHistoryParams, SessionConfigHistoryResponse, SessionCreateParams, SessionCreateResponse, SessionDeleteResponse, SessionExecuteMetaParams, SessionExecuteMetaResponse, SessionExecuteParams, SessionExecuteResponse, SessionLinkParams, SessionLinkResponse, SessionPatchParams, SessionPatchResponse, SessionProxyExecuteParams, SessionProxyExecuteResponse, SessionRetrieveResponse, SessionSearchParams, SessionSearchResponse, SessionToolkitsParams, SessionToolkitsResponse, SessionToolsParams, SessionToolsResponse, ToolRouter };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
1
|
+
import { Ar as ToolkitRetrieveMultiResponse, Cr as ToolkitListParams, Dr as ToolkitRetrieveCategoriesResponse, Er as ToolkitRecommendScopesResponse, Fr as Toolkits, Ir as makeToolkits, Mr as ToolkitRetrieveResponse, Nr as ToolkitRetrieveScopesGrantContextParams, Or as ToolkitRetrieveChangelogResponse, Pr as ToolkitRetrieveScopesGrantContextResponse, Tr as ToolkitRecommendScopesParams, jr as ToolkitRetrieveParams, kr as ToolkitRetrieveMultiParams, wr as ToolkitListResponse } from "../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { ToolkitListParams, ToolkitListResponse, ToolkitRecommendScopesParams, ToolkitRecommendScopesResponse, ToolkitRetrieveCategoriesResponse, ToolkitRetrieveChangelogResponse, ToolkitRetrieveMultiParams, ToolkitRetrieveMultiResponse, ToolkitRetrieveParams, ToolkitRetrieveResponse, ToolkitRetrieveScopesGrantContextParams, ToolkitRetrieveScopesGrantContextResponse, Toolkits, makeToolkits };
|
|
@@ -1,3 +1,52 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as path, n as generatedOperation, y as withOperation } from "../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/toolkits.ts
|
|
4
|
+
const OP_RETRIEVE = generatedOperation("toolkits.retrieve");
|
|
5
|
+
const OP_LIST = generatedOperation("toolkits.list");
|
|
6
|
+
const OP_RECOMMEND_SCOPES = generatedOperation("toolkits.recommendScopes");
|
|
7
|
+
const OP_RETRIEVE_CATEGORIES = generatedOperation("toolkits.retrieveCategories");
|
|
8
|
+
const OP_RETRIEVE_CHANGELOG = generatedOperation("toolkits.retrieveChangelog");
|
|
9
|
+
const OP_RETRIEVE_MULTI = generatedOperation("toolkits.retrieveMulti");
|
|
10
|
+
const OP_RETRIEVE_SCOPES_GRANT_CONTEXT = generatedOperation("toolkits.retrieveScopesGrantContext");
|
|
11
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
12
|
+
const makeToolkits = (client) => ({
|
|
13
|
+
retrieve(slug, query = {}, options) {
|
|
14
|
+
return client.get(path`/api/v3.1/toolkits/${slug}`, withOperation(OP_RETRIEVE, {
|
|
15
|
+
query,
|
|
16
|
+
...options
|
|
17
|
+
}));
|
|
18
|
+
},
|
|
19
|
+
list(query = {}, options) {
|
|
20
|
+
return client.get("/api/v3.1/toolkits", withOperation(OP_LIST, {
|
|
21
|
+
query,
|
|
22
|
+
...options
|
|
23
|
+
}));
|
|
24
|
+
},
|
|
25
|
+
recommendScopes(toolkitSlug, body, options) {
|
|
26
|
+
return client.post(path`/api/v3.1/toolkits/${toolkitSlug}/scopes/recommended`, withOperation(OP_RECOMMEND_SCOPES, {
|
|
27
|
+
body,
|
|
28
|
+
...options
|
|
29
|
+
}));
|
|
30
|
+
},
|
|
31
|
+
retrieveCategories(options) {
|
|
32
|
+
return client.get("/api/v3.1/toolkits/categories", withOperation(OP_RETRIEVE_CATEGORIES, { ...options }));
|
|
33
|
+
},
|
|
34
|
+
retrieveChangelog(options) {
|
|
35
|
+
return client.get("/api/v3.1/toolkits/changelog", withOperation(OP_RETRIEVE_CHANGELOG, { ...options }));
|
|
36
|
+
},
|
|
37
|
+
retrieveMulti(body = {}, options) {
|
|
38
|
+
return client.post("/api/v3.1/toolkits/multi", withOperation(OP_RETRIEVE_MULTI, {
|
|
39
|
+
body,
|
|
40
|
+
...options
|
|
41
|
+
}));
|
|
42
|
+
},
|
|
43
|
+
retrieveScopesGrantContext(toolkitSlug, query = {}, options) {
|
|
44
|
+
return client.get(path`/api/v3.1/toolkits/${toolkitSlug}/scopes/grant_context`, withOperation(OP_RETRIEVE_SCOPES_GRANT_CONTEXT, {
|
|
45
|
+
query,
|
|
46
|
+
...options
|
|
47
|
+
}));
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
//#endregion
|
|
52
|
+
export { makeToolkits };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
1
|
+
import { Ci as ToolRetrieveResponse, Si as ToolRetrieveRequiredScopesResponse, Ti as makeTools, _i as ToolProxyParams, bi as ToolRetrieveParams, di as ToolExecuteParams, fi as ToolExecuteResponse, gi as ToolListResponse, hi as ToolListParams, mi as ToolGetInputResponse, pi as ToolGetInputParams, vi as ToolProxyResponse, wi as Tools, xi as ToolRetrieveRequiredScopesParams, yi as ToolRetrieveEnumResponse } from "../api-key-revocation-DUHNHxSZ.mjs";
|
|
2
|
+
export { ToolExecuteParams, ToolExecuteResponse, ToolGetInputParams, ToolGetInputResponse, ToolListParams, ToolListResponse, ToolProxyParams, ToolProxyResponse, ToolRetrieveEnumResponse, ToolRetrieveParams, ToolRetrieveRequiredScopesParams, ToolRetrieveRequiredScopesResponse, ToolRetrieveResponse, Tools, makeTools };
|
package/dist/resources/tools.mjs
CHANGED
|
@@ -1,3 +1,57 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { E as mergeHeaders, d as path, n as generatedOperation, y as withOperation } from "../generated-operations-DhZryVXy.mjs";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
//#region src/compat/resources/tools.ts
|
|
4
|
+
const OP_RETRIEVE = generatedOperation("tools.retrieve");
|
|
5
|
+
const OP_LIST = generatedOperation("tools.list");
|
|
6
|
+
const OP_EXECUTE = generatedOperation("tools.execute");
|
|
7
|
+
const OP_GET_INPUT = generatedOperation("tools.getInput");
|
|
8
|
+
const OP_PROXY = generatedOperation("tools.proxy");
|
|
9
|
+
const OP_RETRIEVE_ENUM = generatedOperation("tools.retrieveEnum");
|
|
10
|
+
const OP_RETRIEVE_REQUIRED_SCOPES = generatedOperation("tools.retrieveRequiredScopes");
|
|
11
|
+
/** @internal Builds the resource over a client; `new Composio(...)` calls it. */
|
|
12
|
+
const makeTools = (client) => ({
|
|
13
|
+
retrieve(toolSlug, query = {}, options) {
|
|
14
|
+
return client.get(path`/api/v3.1/tools/${toolSlug}`, withOperation(OP_RETRIEVE, {
|
|
15
|
+
query,
|
|
16
|
+
...options
|
|
17
|
+
}));
|
|
18
|
+
},
|
|
19
|
+
list(query = {}, options) {
|
|
20
|
+
return client.get("/api/v3.1/tools", withOperation(OP_LIST, {
|
|
21
|
+
query,
|
|
22
|
+
...options
|
|
23
|
+
}));
|
|
24
|
+
},
|
|
25
|
+
execute(toolSlug, params = {}, options) {
|
|
26
|
+
const { "x-llm-gateway-headers": xLlmGatewayHeaders, ...body } = params ?? {};
|
|
27
|
+
return client.post(path`/api/v3.1/tools/execute/${toolSlug}`, withOperation(OP_EXECUTE, {
|
|
28
|
+
body,
|
|
29
|
+
...options,
|
|
30
|
+
headers: mergeHeaders([{ ...xLlmGatewayHeaders != null ? { "x-llm-gateway-headers": xLlmGatewayHeaders } : void 0 }, options?.headers])
|
|
31
|
+
}));
|
|
32
|
+
},
|
|
33
|
+
getInput(toolSlug, body, options) {
|
|
34
|
+
return client.post(path`/api/v3.1/tools/execute/${toolSlug}/input`, withOperation(OP_GET_INPUT, {
|
|
35
|
+
body,
|
|
36
|
+
...options
|
|
37
|
+
}));
|
|
38
|
+
},
|
|
39
|
+
proxy(body, options) {
|
|
40
|
+
return client.post("/api/v3.1/tools/execute/proxy", withOperation(OP_PROXY, {
|
|
41
|
+
body,
|
|
42
|
+
...options
|
|
43
|
+
}));
|
|
44
|
+
},
|
|
45
|
+
retrieveEnum(options) {
|
|
46
|
+
return client.get("/api/v3.1/tools/enum", withOperation(OP_RETRIEVE_ENUM, { ...options }));
|
|
47
|
+
},
|
|
48
|
+
retrieveRequiredScopes(body, options) {
|
|
49
|
+
return client.post("/api/v3.1/tools/scopes/required", withOperation(OP_RETRIEVE_REQUIRED_SCOPES, {
|
|
50
|
+
body,
|
|
51
|
+
...options
|
|
52
|
+
}));
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
|
|
56
|
+
//#endregion
|
|
57
|
+
export { makeTools };
|