@inconvoai/node 0.7.1 → 0.7.7
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/CHANGELOG.md +58 -0
- package/client.d.mts +1 -1
- package/client.d.mts.map +1 -1
- package/client.d.ts +1 -1
- package/client.d.ts.map +1 -1
- package/client.js +8 -7
- package/client.js.map +1 -1
- package/client.mjs +8 -7
- package/client.mjs.map +1 -1
- package/internal/tslib.js +17 -17
- package/internal/utils/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.ts +1 -0
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/package.json +12 -1
- package/resources/agents/conversations/conversations.d.mts +3 -0
- package/resources/agents/conversations/conversations.d.mts.map +1 -1
- package/resources/agents/conversations/conversations.d.ts +3 -0
- package/resources/agents/conversations/conversations.d.ts.map +1 -1
- package/resources/agents/conversations/conversations.js +3 -0
- package/resources/agents/conversations/conversations.js.map +1 -1
- package/resources/agents/conversations/conversations.mjs +3 -0
- package/resources/agents/conversations/conversations.mjs.map +1 -1
- package/resources/agents/conversations/response/feedback.d.mts +3 -0
- package/resources/agents/conversations/response/feedback.d.mts.map +1 -1
- package/resources/agents/conversations/response/feedback.d.ts +3 -0
- package/resources/agents/conversations/response/feedback.d.ts.map +1 -1
- package/resources/agents/conversations/response/feedback.js +3 -0
- package/resources/agents/conversations/response/feedback.js.map +1 -1
- package/resources/agents/conversations/response/feedback.mjs +3 -0
- package/resources/agents/conversations/response/feedback.mjs.map +1 -1
- package/resources/agents/conversations/response/response.d.mts +3 -0
- package/resources/agents/conversations/response/response.d.mts.map +1 -1
- package/resources/agents/conversations/response/response.d.ts +3 -0
- package/resources/agents/conversations/response/response.d.ts.map +1 -1
- package/resources/agents/conversations/response/response.js +3 -0
- package/resources/agents/conversations/response/response.js.map +1 -1
- package/resources/agents/conversations/response/response.mjs +3 -0
- package/resources/agents/conversations/response/response.mjs.map +1 -1
- package/resources/agents/data-summary.d.mts +3 -0
- package/resources/agents/data-summary.d.mts.map +1 -1
- package/resources/agents/data-summary.d.ts +3 -0
- package/resources/agents/data-summary.d.ts.map +1 -1
- package/resources/agents/data-summary.js +3 -0
- package/resources/agents/data-summary.js.map +1 -1
- package/resources/agents/data-summary.mjs +3 -0
- package/resources/agents/data-summary.mjs.map +1 -1
- package/resources/agents/datasets/context.d.mts +11 -0
- package/resources/agents/datasets/context.d.mts.map +1 -1
- package/resources/agents/datasets/context.d.ts +11 -0
- package/resources/agents/datasets/context.d.ts.map +1 -1
- package/resources/agents/datasets/context.js +11 -0
- package/resources/agents/datasets/context.js.map +1 -1
- package/resources/agents/datasets/context.mjs +11 -0
- package/resources/agents/datasets/context.mjs.map +1 -1
- package/resources/agents/datasets/user.d.mts +11 -0
- package/resources/agents/datasets/user.d.mts.map +1 -1
- package/resources/agents/datasets/user.d.ts +11 -0
- package/resources/agents/datasets/user.d.ts.map +1 -1
- package/resources/agents/datasets/user.js +11 -0
- package/resources/agents/datasets/user.js.map +1 -1
- package/resources/agents/datasets/user.mjs +11 -0
- package/resources/agents/datasets/user.mjs.map +1 -1
- package/resources/agents/mcp-servers/tenants.d.mts +3 -0
- package/resources/agents/mcp-servers/tenants.d.mts.map +1 -1
- package/resources/agents/mcp-servers/tenants.d.ts +3 -0
- package/resources/agents/mcp-servers/tenants.d.ts.map +1 -1
- package/resources/agents/mcp-servers/tenants.js +3 -0
- package/resources/agents/mcp-servers/tenants.js.map +1 -1
- package/resources/agents/mcp-servers/tenants.mjs +3 -0
- package/resources/agents/mcp-servers/tenants.mjs.map +1 -1
- package/src/client.ts +11 -10
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils.ts +1 -0
- package/src/resources/agents/conversations/conversations.ts +3 -0
- package/src/resources/agents/conversations/response/feedback.ts +3 -0
- package/src/resources/agents/conversations/response/response.ts +3 -0
- package/src/resources/agents/data-summary.ts +3 -0
- package/src/resources/agents/datasets/context.ts +11 -0
- package/src/resources/agents/datasets/user.ts +11 -0
- package/src/resources/agents/mcp-servers/tenants.ts +3 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tenants.mjs","sourceRoot":"","sources":["../../../src/resources/agents/mcp-servers/tenants.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,OAAQ,SAAQ,WAAW;IACtC;;;;;;;;;;;;;;;;OAgBG;IACH,MAAM,CACJ,WAAmB,EACnB,MAA0B,EAC1B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC;QACnC,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,WAAW,OAAO,eAAe,WAAW,UAAU,EAAE;YACnF,IAAI,EAAE,MAAM;YACZ,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;OAWG;IACH,MAAM,CACJ,WAAmB,EACnB,MAA0B,EAC1B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,GAAG,MAAM,CAAC;QACvC,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CACxB,IAAI,CAAA,WAAW,OAAO,eAAe,WAAW,YAAY,UAAU,EAAE,EACxE,OAAO,CACR,CAAC;IACJ,CAAC;CACF"}
|
|
1
|
+
{"version":3,"file":"tenants.mjs","sourceRoot":"","sources":["../../../src/resources/agents/mcp-servers/tenants.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf;;GAEG;AACH,MAAM,OAAO,OAAQ,SAAQ,WAAW;IACtC;;;;;;;;;;;;;;;;OAgBG;IACH,MAAM,CACJ,WAAmB,EACnB,MAA0B,EAC1B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC;QACnC,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,WAAW,OAAO,eAAe,WAAW,UAAU,EAAE;YACnF,IAAI,EAAE,MAAM;YACZ,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;OAWG;IACH,MAAM,CACJ,WAAmB,EACnB,MAA0B,EAC1B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,GAAG,MAAM,CAAC;QACvC,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CACxB,IAAI,CAAA,WAAW,OAAO,eAAe,WAAW,YAAY,UAAU,EAAE,EACxE,OAAO,CACR,CAAC;IACJ,CAAC;CACF"}
|
package/src/client.ts
CHANGED
|
@@ -11,7 +11,7 @@ import type { APIResponseProps } from './internal/parse';
|
|
|
11
11
|
import { getPlatformHeaders } from './internal/detect-platform';
|
|
12
12
|
import * as Shims from './internal/shims';
|
|
13
13
|
import * as Opts from './internal/request-options';
|
|
14
|
-
import
|
|
14
|
+
import { stringifyQuery } from './internal/utils/query';
|
|
15
15
|
import { VERSION } from './version';
|
|
16
16
|
import * as Errors from './core/error';
|
|
17
17
|
import * as Pagination from './core/pagination';
|
|
@@ -213,8 +213,8 @@ export class Inconvo {
|
|
|
213
213
|
return buildHeaders([{ Authorization: `Bearer ${this.apiKey}` }]);
|
|
214
214
|
}
|
|
215
215
|
|
|
216
|
-
protected stringifyQuery(query: Record<string, unknown>): string {
|
|
217
|
-
return
|
|
216
|
+
protected stringifyQuery(query: object | Record<string, unknown>): string {
|
|
217
|
+
return stringifyQuery(query);
|
|
218
218
|
}
|
|
219
219
|
|
|
220
220
|
private getUserAgent(): string {
|
|
@@ -246,12 +246,13 @@ export class Inconvo {
|
|
|
246
246
|
: new URL(baseURL + (baseURL.endsWith('/') && path.startsWith('/') ? path.slice(1) : path));
|
|
247
247
|
|
|
248
248
|
const defaultQuery = this.defaultQuery();
|
|
249
|
-
|
|
250
|
-
|
|
249
|
+
const pathQuery = Object.fromEntries(url.searchParams);
|
|
250
|
+
if (!isEmptyObj(defaultQuery) || !isEmptyObj(pathQuery)) {
|
|
251
|
+
query = { ...pathQuery, ...defaultQuery, ...query };
|
|
251
252
|
}
|
|
252
253
|
|
|
253
254
|
if (typeof query === 'object' && query && !Array.isArray(query)) {
|
|
254
|
-
url.search = this.stringifyQuery(query
|
|
255
|
+
url.search = this.stringifyQuery(query);
|
|
255
256
|
}
|
|
256
257
|
|
|
257
258
|
return url.toString();
|
|
@@ -580,9 +581,9 @@ export class Inconvo {
|
|
|
580
581
|
}
|
|
581
582
|
}
|
|
582
583
|
|
|
583
|
-
// If the API asks us to wait a certain amount of time
|
|
584
|
-
//
|
|
585
|
-
if (
|
|
584
|
+
// If the API asks us to wait a certain amount of time, just do what it
|
|
585
|
+
// says, but otherwise calculate a default
|
|
586
|
+
if (timeoutMillis === undefined) {
|
|
586
587
|
const maxRetries = options.maxRetries ?? this.maxRetries;
|
|
587
588
|
timeoutMillis = this.calculateDefaultRetryTimeoutMillis(retriesRemaining, maxRetries);
|
|
588
589
|
}
|
|
@@ -714,7 +715,7 @@ export class Inconvo {
|
|
|
714
715
|
) {
|
|
715
716
|
return {
|
|
716
717
|
bodyHeaders: { 'content-type': 'application/x-www-form-urlencoded' },
|
|
717
|
-
body: this.stringifyQuery(body
|
|
718
|
+
body: this.stringifyQuery(body),
|
|
718
719
|
};
|
|
719
720
|
} else {
|
|
720
721
|
return this.#encoder({ body, headers });
|
package/src/internal/utils.ts
CHANGED
|
@@ -16,6 +16,9 @@ import { ConversationsCursor, type ConversationsCursorParams, PagePromise } from
|
|
|
16
16
|
import { RequestOptions } from '../../../internal/request-options';
|
|
17
17
|
import { path } from '../../../internal/utils/path';
|
|
18
18
|
|
|
19
|
+
/**
|
|
20
|
+
* Create, list and retrieve conversation threads
|
|
21
|
+
*/
|
|
19
22
|
export class Conversations extends APIResource {
|
|
20
23
|
response: ResponseAPI.Response = new ResponseAPI.Response(this._client);
|
|
21
24
|
|
|
@@ -5,6 +5,9 @@ import { APIPromise } from '../../../../core/api-promise';
|
|
|
5
5
|
import { RequestOptions } from '../../../../internal/request-options';
|
|
6
6
|
import { path } from '../../../../internal/utils/path';
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* Attach or edit quality feedback on individual responses
|
|
10
|
+
*/
|
|
8
11
|
export class FeedbackResource extends APIResource {
|
|
9
12
|
/**
|
|
10
13
|
* Create feedback
|
|
@@ -9,6 +9,9 @@ import { RequestOptions } from '../../../../internal/request-options';
|
|
|
9
9
|
import { path } from '../../../../internal/utils/path';
|
|
10
10
|
import { SSEStream, createSSEStream } from '../../../../core/sse-stream';
|
|
11
11
|
|
|
12
|
+
/**
|
|
13
|
+
* Send a user message and receive Inconvo's structured reply (synchronous or SSE stream)
|
|
14
|
+
*/
|
|
12
15
|
export class Response extends APIResource {
|
|
13
16
|
feedback: FeedbackAPI.FeedbackResource = new FeedbackAPI.FeedbackResource(this._client);
|
|
14
17
|
|
|
@@ -5,6 +5,9 @@ import { APIPromise } from '../../core/api-promise';
|
|
|
5
5
|
import { RequestOptions } from '../../internal/request-options';
|
|
6
6
|
import { path } from '../../internal/utils/path';
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* Retrieve information about agents and their data access
|
|
10
|
+
*/
|
|
8
11
|
export class DataSummary extends APIResource {
|
|
9
12
|
/**
|
|
10
13
|
* Retrieve a summary of data available to the agent
|
|
@@ -7,6 +7,17 @@ import { RequestOptions } from '../../../internal/request-options';
|
|
|
7
7
|
import { multipartFormRequestOptions } from '../../../internal/uploads';
|
|
8
8
|
import { path } from '../../../internal/utils/path';
|
|
9
9
|
|
|
10
|
+
/**
|
|
11
|
+
* Manage dataset files with scoped access.
|
|
12
|
+
*
|
|
13
|
+
* Datasets can be scoped in two ways:
|
|
14
|
+
* - **User-scoped** (`/datasets/user/{userIdentifier}`): Files accessible only to a specific user
|
|
15
|
+
* - **Context-scoped** (`/datasets/context/{contextKey}/{contextValue}`): Files shared with all users matching a context value
|
|
16
|
+
*
|
|
17
|
+
* File storage paths:
|
|
18
|
+
* - User-scoped: `/{orgId}/{agentId}/userIdentifier/{userIdentifier}/filename.csv`
|
|
19
|
+
* - Context-scoped: `/{orgId}/{agentId}/userContext/{contextKey}:{contextValue}/filename.csv`
|
|
20
|
+
*/
|
|
10
21
|
export class Context extends APIResource {
|
|
11
22
|
/**
|
|
12
23
|
* List all dataset files scoped to a context value. These files are shared with
|
|
@@ -7,6 +7,17 @@ import { RequestOptions } from '../../../internal/request-options';
|
|
|
7
7
|
import { multipartFormRequestOptions } from '../../../internal/uploads';
|
|
8
8
|
import { path } from '../../../internal/utils/path';
|
|
9
9
|
|
|
10
|
+
/**
|
|
11
|
+
* Manage dataset files with scoped access.
|
|
12
|
+
*
|
|
13
|
+
* Datasets can be scoped in two ways:
|
|
14
|
+
* - **User-scoped** (`/datasets/user/{userIdentifier}`): Files accessible only to a specific user
|
|
15
|
+
* - **Context-scoped** (`/datasets/context/{contextKey}/{contextValue}`): Files shared with all users matching a context value
|
|
16
|
+
*
|
|
17
|
+
* File storage paths:
|
|
18
|
+
* - User-scoped: `/{orgId}/{agentId}/userIdentifier/{userIdentifier}/filename.csv`
|
|
19
|
+
* - Context-scoped: `/{orgId}/{agentId}/userContext/{contextKey}:{contextValue}/filename.csv`
|
|
20
|
+
*/
|
|
10
21
|
export class User extends APIResource {
|
|
11
22
|
/**
|
|
12
23
|
* List all dataset files scoped to a specific user.
|
|
@@ -5,6 +5,9 @@ import { APIPromise } from '../../../core/api-promise';
|
|
|
5
5
|
import { RequestOptions } from '../../../internal/request-options';
|
|
6
6
|
import { path } from '../../../internal/utils/path';
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* Manage MCP servers and their tenant mappings
|
|
10
|
+
*/
|
|
8
11
|
export class Tenants extends APIResource {
|
|
9
12
|
/**
|
|
10
13
|
* Create a tenant for an MCP Server
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.7.
|
|
1
|
+
export const VERSION = '0.7.7'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.7.
|
|
1
|
+
export declare const VERSION = "0.7.7";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.7.
|
|
1
|
+
export declare const VERSION = "0.7.7";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.7.
|
|
1
|
+
export const VERSION = '0.7.7'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|