@neocode-ai/sdk 1.1.1 → 1.2.10
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/client.js +1 -1
- package/dist/gen/client/client.gen.d.ts +1 -1
- package/dist/gen/client/utils.gen.d.ts +4 -4
- package/dist/gen/core/bodySerializer.gen.d.ts +2 -2
- package/dist/gen/core/params.gen.d.ts +1 -1
- package/dist/gen/core/pathSerializer.gen.d.ts +5 -5
- package/dist/gen/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/gen/core/queryKeySerializer.gen.js +93 -0
- package/dist/gen/core/serverSentEvents.gen.d.ts +1 -1
- package/dist/gen/core/utils.gen.d.ts +3 -3
- package/dist/v2/gen/client/client.gen.d.ts +1 -1
- package/dist/v2/gen/client/utils.gen.d.ts +4 -4
- package/dist/v2/gen/core/bodySerializer.gen.d.ts +2 -2
- package/dist/v2/gen/core/params.gen.d.ts +1 -1
- package/dist/v2/gen/core/pathSerializer.gen.d.ts +5 -5
- package/dist/v2/gen/core/serverSentEvents.gen.d.ts +1 -1
- package/dist/v2/gen/core/utils.gen.d.ts +3 -3
- package/dist/v2/gen/sdk.gen.d.ts +23 -3
- package/dist/v2/gen/sdk.gen.js +35 -2
- package/dist/v2/gen/types.gen.d.ts +144 -13
- package/package.json +15 -5
package/dist/client.js
CHANGED
|
@@ -17,7 +17,7 @@ export function createNeocodeClient(config) {
|
|
|
17
17
|
if (config?.directory) {
|
|
18
18
|
config.headers = {
|
|
19
19
|
...config.headers,
|
|
20
|
-
"x-neocode-directory": config.directory,
|
|
20
|
+
"x-neocode-directory": encodeURIComponent(config.directory),
|
|
21
21
|
};
|
|
22
22
|
}
|
|
23
23
|
const client = createClient(config);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { Client, Config } from "./types.gen.js";
|
|
2
|
-
export declare const createClient: (config?: Config) => Client;
|
|
2
|
+
export declare const createClient: (config?: Config<import("./types.gen.js").ClientOptions>) => Client;
|
|
@@ -4,13 +4,13 @@ export declare const createQuerySerializer: <T = unknown>({ allowReserved, array
|
|
|
4
4
|
/**
|
|
5
5
|
* Infers parseAs value from provided Content-Type header.
|
|
6
6
|
*/
|
|
7
|
-
export declare const getParseAs: (contentType: string | null) =>
|
|
8
|
-
export declare const setAuthParams: ({ security, ...options }: Pick<Required<RequestOptions
|
|
7
|
+
export declare const getParseAs: (contentType: string | null) => "arrayBuffer" | "blob" | "formData" | "json" | "stream" | "text" | undefined;
|
|
8
|
+
export declare const setAuthParams: ({ security, ...options }: Pick<Required<RequestOptions<unknown, "fields", boolean, string>>, "security"> & Pick<RequestOptions<unknown, "fields", boolean, string>, "auth" | "query"> & {
|
|
9
9
|
headers: Headers;
|
|
10
10
|
}) => Promise<void>;
|
|
11
11
|
export declare const buildUrl: Client["buildUrl"];
|
|
12
|
-
export declare const mergeConfigs: (a: Config
|
|
13
|
-
export declare const mergeHeaders: (...headers:
|
|
12
|
+
export declare const mergeConfigs: (a: Config<ClientOptions>, b: Config<ClientOptions>) => Config<ClientOptions>;
|
|
13
|
+
export declare const mergeHeaders: (...headers: (Record<string, unknown> | HeadersInit | undefined)[]) => Headers;
|
|
14
14
|
type ErrInterceptor<Err, Res, Req, Options> = (error: Err, response: Res, request: Req, options: Options) => Err | Promise<Err>;
|
|
15
15
|
type ReqInterceptor<Req, Options> = (request: Req, options: Options) => Req | Promise<Req>;
|
|
16
16
|
type ResInterceptor<Res, Req, Options> = (response: Res, request: Req, options: Options) => Res | Promise<Res>;
|
|
@@ -7,11 +7,11 @@ export interface QuerySerializerOptions {
|
|
|
7
7
|
object?: SerializerOptions<ObjectStyle>;
|
|
8
8
|
}
|
|
9
9
|
export declare const formDataBodySerializer: {
|
|
10
|
-
bodySerializer: <T extends Record<string, any> |
|
|
10
|
+
bodySerializer: <T extends Record<string, any>[] | Record<string, any>>(body: T) => FormData;
|
|
11
11
|
};
|
|
12
12
|
export declare const jsonBodySerializer: {
|
|
13
13
|
bodySerializer: <T>(body: T) => string;
|
|
14
14
|
};
|
|
15
15
|
export declare const urlSearchParamsBodySerializer: {
|
|
16
|
-
bodySerializer: <T extends Record<string, any> |
|
|
16
|
+
bodySerializer: <T extends Record<string, any>[] | Record<string, any>>(body: T) => string;
|
|
17
17
|
};
|
|
@@ -29,5 +29,5 @@ interface Params {
|
|
|
29
29
|
path: Record<string, unknown>;
|
|
30
30
|
query: Record<string, unknown>;
|
|
31
31
|
}
|
|
32
|
-
export declare const buildClientParams: (args:
|
|
32
|
+
export declare const buildClientParams: (args: readonly unknown[], fields: FieldsConfig) => Params;
|
|
33
33
|
export {};
|
|
@@ -19,15 +19,15 @@ type ObjectSeparatorStyle = ObjectStyle | MatrixStyle;
|
|
|
19
19
|
interface SerializePrimitiveParam extends SerializePrimitiveOptions {
|
|
20
20
|
value: string;
|
|
21
21
|
}
|
|
22
|
-
export declare const separatorArrayExplode: (style: ArraySeparatorStyle) => "
|
|
23
|
-
export declare const separatorArrayNoExplode: (style: ArraySeparatorStyle) => "
|
|
24
|
-
export declare const separatorObjectExplode: (style: ObjectSeparatorStyle) => "
|
|
22
|
+
export declare const separatorArrayExplode: (style: ArraySeparatorStyle) => "&" | "," | "." | ";";
|
|
23
|
+
export declare const separatorArrayNoExplode: (style: ArraySeparatorStyle) => "%20" | "," | "|";
|
|
24
|
+
export declare const separatorObjectExplode: (style: ObjectSeparatorStyle) => "&" | "," | "." | ";";
|
|
25
25
|
export declare const serializeArrayParam: ({ allowReserved, explode, name, style, value, }: SerializeOptions<ArraySeparatorStyle> & {
|
|
26
26
|
value: unknown[];
|
|
27
27
|
}) => string;
|
|
28
28
|
export declare const serializePrimitiveParam: ({ allowReserved, name, value }: SerializePrimitiveParam) => string;
|
|
29
29
|
export declare const serializeObjectParam: ({ allowReserved, explode, name, style, value, valueOnly, }: SerializeOptions<ObjectSeparatorStyle> & {
|
|
30
|
-
value: Record<string, unknown
|
|
31
|
-
valueOnly?: boolean;
|
|
30
|
+
value: Date | Record<string, unknown>;
|
|
31
|
+
valueOnly?: boolean | undefined;
|
|
32
32
|
}) => string;
|
|
33
33
|
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* JSON-friendly union that mirrors what Pinia Colada can hash.
|
|
3
|
+
*/
|
|
4
|
+
export type JsonValue = null | string | number | boolean | JsonValue[] | {
|
|
5
|
+
[key: string]: JsonValue;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* Replacer that converts non-JSON values (bigint, Date, etc.) to safe substitutes.
|
|
9
|
+
*/
|
|
10
|
+
export declare const queryKeyJsonReplacer: (_key: string, value: unknown) => {} | null | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* Safely stringifies a value and parses it back into a JsonValue.
|
|
13
|
+
*/
|
|
14
|
+
export declare const stringifyToJsonValue: (input: unknown) => JsonValue | undefined;
|
|
15
|
+
/**
|
|
16
|
+
* Normalizes any accepted value into a JSON-friendly shape for query keys.
|
|
17
|
+
*/
|
|
18
|
+
export declare const serializeQueryKeyValue: (value: unknown) => JsonValue | undefined;
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
|
+
/**
|
|
3
|
+
* Replacer that converts non-JSON values (bigint, Date, etc.) to safe substitutes.
|
|
4
|
+
*/
|
|
5
|
+
export const queryKeyJsonReplacer = (_key, value) => {
|
|
6
|
+
if (value === undefined || typeof value === "function" || typeof value === "symbol") {
|
|
7
|
+
return undefined;
|
|
8
|
+
}
|
|
9
|
+
if (typeof value === "bigint") {
|
|
10
|
+
return value.toString();
|
|
11
|
+
}
|
|
12
|
+
if (value instanceof Date) {
|
|
13
|
+
return value.toISOString();
|
|
14
|
+
}
|
|
15
|
+
return value;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Safely stringifies a value and parses it back into a JsonValue.
|
|
19
|
+
*/
|
|
20
|
+
export const stringifyToJsonValue = (input) => {
|
|
21
|
+
try {
|
|
22
|
+
const json = JSON.stringify(input, queryKeyJsonReplacer);
|
|
23
|
+
if (json === undefined) {
|
|
24
|
+
return undefined;
|
|
25
|
+
}
|
|
26
|
+
return JSON.parse(json);
|
|
27
|
+
}
|
|
28
|
+
catch {
|
|
29
|
+
return undefined;
|
|
30
|
+
}
|
|
31
|
+
};
|
|
32
|
+
/**
|
|
33
|
+
* Detects plain objects (including objects with a null prototype).
|
|
34
|
+
*/
|
|
35
|
+
const isPlainObject = (value) => {
|
|
36
|
+
if (value === null || typeof value !== "object") {
|
|
37
|
+
return false;
|
|
38
|
+
}
|
|
39
|
+
const prototype = Object.getPrototypeOf(value);
|
|
40
|
+
return prototype === Object.prototype || prototype === null;
|
|
41
|
+
};
|
|
42
|
+
/**
|
|
43
|
+
* Turns URLSearchParams into a sorted JSON object for deterministic keys.
|
|
44
|
+
*/
|
|
45
|
+
const serializeSearchParams = (params) => {
|
|
46
|
+
const entries = Array.from(params.entries()).sort(([a], [b]) => a.localeCompare(b));
|
|
47
|
+
const result = {};
|
|
48
|
+
for (const [key, value] of entries) {
|
|
49
|
+
const existing = result[key];
|
|
50
|
+
if (existing === undefined) {
|
|
51
|
+
result[key] = value;
|
|
52
|
+
continue;
|
|
53
|
+
}
|
|
54
|
+
if (Array.isArray(existing)) {
|
|
55
|
+
;
|
|
56
|
+
existing.push(value);
|
|
57
|
+
}
|
|
58
|
+
else {
|
|
59
|
+
result[key] = [existing, value];
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
return result;
|
|
63
|
+
};
|
|
64
|
+
/**
|
|
65
|
+
* Normalizes any accepted value into a JSON-friendly shape for query keys.
|
|
66
|
+
*/
|
|
67
|
+
export const serializeQueryKeyValue = (value) => {
|
|
68
|
+
if (value === null) {
|
|
69
|
+
return null;
|
|
70
|
+
}
|
|
71
|
+
if (typeof value === "string" || typeof value === "number" || typeof value === "boolean") {
|
|
72
|
+
return value;
|
|
73
|
+
}
|
|
74
|
+
if (value === undefined || typeof value === "function" || typeof value === "symbol") {
|
|
75
|
+
return undefined;
|
|
76
|
+
}
|
|
77
|
+
if (typeof value === "bigint") {
|
|
78
|
+
return value.toString();
|
|
79
|
+
}
|
|
80
|
+
if (value instanceof Date) {
|
|
81
|
+
return value.toISOString();
|
|
82
|
+
}
|
|
83
|
+
if (Array.isArray(value)) {
|
|
84
|
+
return stringifyToJsonValue(value);
|
|
85
|
+
}
|
|
86
|
+
if (typeof URLSearchParams !== "undefined" && value instanceof URLSearchParams) {
|
|
87
|
+
return serializeSearchParams(value);
|
|
88
|
+
}
|
|
89
|
+
if (isPlainObject(value)) {
|
|
90
|
+
return stringifyToJsonValue(value);
|
|
91
|
+
}
|
|
92
|
+
return undefined;
|
|
93
|
+
};
|
|
@@ -56,4 +56,4 @@ export interface StreamEvent<TData = unknown> {
|
|
|
56
56
|
export type ServerSentEventsResult<TData = unknown, TReturn = void, TNext = unknown> = {
|
|
57
57
|
stream: AsyncGenerator<TData extends Record<string, unknown> ? TData[keyof TData] : TData, TReturn, TNext>;
|
|
58
58
|
};
|
|
59
|
-
export declare const createSseClient: <TData = unknown>({ onSseError, onSseEvent, responseTransformer, responseValidator, sseDefaultRetryDelay, sseMaxRetryAttempts, sseMaxRetryDelay, sseSleepFn, url, ...options }: ServerSentEventsOptions) => ServerSentEventsResult<TData>;
|
|
59
|
+
export declare const createSseClient: <TData = unknown>({ onSseError, onSseEvent, responseTransformer, responseValidator, sseDefaultRetryDelay, sseMaxRetryAttempts, sseMaxRetryDelay, sseSleepFn, url, ...options }: ServerSentEventsOptions<unknown>) => ServerSentEventsResult<TData, void, unknown>;
|
|
@@ -6,9 +6,9 @@ export interface PathSerializer {
|
|
|
6
6
|
export declare const PATH_PARAM_RE: RegExp;
|
|
7
7
|
export declare const defaultPathSerializer: ({ path, url: _url }: PathSerializer) => string;
|
|
8
8
|
export declare const getUrl: ({ baseUrl, path, query, querySerializer, url: _url, }: {
|
|
9
|
-
baseUrl?: string;
|
|
10
|
-
path?: Record<string, unknown
|
|
11
|
-
query?: Record<string, unknown
|
|
9
|
+
baseUrl?: string | undefined;
|
|
10
|
+
path?: Record<string, unknown> | undefined;
|
|
11
|
+
query?: Record<string, unknown> | undefined;
|
|
12
12
|
querySerializer: QuerySerializer;
|
|
13
13
|
url: string;
|
|
14
14
|
}) => string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { Client, Config } from "./types.gen.js";
|
|
2
|
-
export declare const createClient: (config?: Config) => Client;
|
|
2
|
+
export declare const createClient: (config?: Config<import("./types.gen.js").ClientOptions>) => Client;
|
|
@@ -4,13 +4,13 @@ export declare const createQuerySerializer: <T = unknown>({ parameters, ...args
|
|
|
4
4
|
/**
|
|
5
5
|
* Infers parseAs value from provided Content-Type header.
|
|
6
6
|
*/
|
|
7
|
-
export declare const getParseAs: (contentType: string | null) =>
|
|
8
|
-
export declare const setAuthParams: ({ security, ...options }: Pick<Required<RequestOptions
|
|
7
|
+
export declare const getParseAs: (contentType: string | null) => "arrayBuffer" | "blob" | "formData" | "json" | "stream" | "text" | undefined;
|
|
8
|
+
export declare const setAuthParams: ({ security, ...options }: Pick<Required<RequestOptions<unknown, "fields", boolean, string>>, "security"> & Pick<RequestOptions<unknown, "fields", boolean, string>, "auth" | "query"> & {
|
|
9
9
|
headers: Headers;
|
|
10
10
|
}) => Promise<void>;
|
|
11
11
|
export declare const buildUrl: Client["buildUrl"];
|
|
12
|
-
export declare const mergeConfigs: (a: Config
|
|
13
|
-
export declare const mergeHeaders: (...headers:
|
|
12
|
+
export declare const mergeConfigs: (a: Config<ClientOptions>, b: Config<ClientOptions>) => Config<ClientOptions>;
|
|
13
|
+
export declare const mergeHeaders: (...headers: (Record<string, unknown> | HeadersInit | undefined)[]) => Headers;
|
|
14
14
|
type ErrInterceptor<Err, Res, Req, Options> = (error: Err, response: Res, request: Req, options: Options) => Err | Promise<Err>;
|
|
15
15
|
type ReqInterceptor<Req, Options> = (request: Req, options: Options) => Req | Promise<Req>;
|
|
16
16
|
type ResInterceptor<Res, Req, Options> = (response: Res, request: Req, options: Options) => Res | Promise<Res>;
|
|
@@ -14,12 +14,12 @@ export type QuerySerializerOptions = QuerySerializerOptionsObject & {
|
|
|
14
14
|
parameters?: Record<string, QuerySerializerOptionsObject>;
|
|
15
15
|
};
|
|
16
16
|
export declare const formDataBodySerializer: {
|
|
17
|
-
bodySerializer: <T extends Record<string, any> |
|
|
17
|
+
bodySerializer: <T extends Record<string, any>[] | Record<string, any>>(body: T) => FormData;
|
|
18
18
|
};
|
|
19
19
|
export declare const jsonBodySerializer: {
|
|
20
20
|
bodySerializer: <T>(body: T) => string;
|
|
21
21
|
};
|
|
22
22
|
export declare const urlSearchParamsBodySerializer: {
|
|
23
|
-
bodySerializer: <T extends Record<string, any> |
|
|
23
|
+
bodySerializer: <T extends Record<string, any>[] | Record<string, any>>(body: T) => string;
|
|
24
24
|
};
|
|
25
25
|
export {};
|
|
@@ -39,5 +39,5 @@ interface Params {
|
|
|
39
39
|
path: Record<string, unknown>;
|
|
40
40
|
query: Record<string, unknown>;
|
|
41
41
|
}
|
|
42
|
-
export declare const buildClientParams: (args:
|
|
42
|
+
export declare const buildClientParams: (args: readonly unknown[], fields: FieldsConfig) => Params;
|
|
43
43
|
export {};
|
|
@@ -19,15 +19,15 @@ type ObjectSeparatorStyle = ObjectStyle | MatrixStyle;
|
|
|
19
19
|
interface SerializePrimitiveParam extends SerializePrimitiveOptions {
|
|
20
20
|
value: string;
|
|
21
21
|
}
|
|
22
|
-
export declare const separatorArrayExplode: (style: ArraySeparatorStyle) => "
|
|
23
|
-
export declare const separatorArrayNoExplode: (style: ArraySeparatorStyle) => "
|
|
24
|
-
export declare const separatorObjectExplode: (style: ObjectSeparatorStyle) => "
|
|
22
|
+
export declare const separatorArrayExplode: (style: ArraySeparatorStyle) => "&" | "," | "." | ";";
|
|
23
|
+
export declare const separatorArrayNoExplode: (style: ArraySeparatorStyle) => "%20" | "," | "|";
|
|
24
|
+
export declare const separatorObjectExplode: (style: ObjectSeparatorStyle) => "&" | "," | "." | ";";
|
|
25
25
|
export declare const serializeArrayParam: ({ allowReserved, explode, name, style, value, }: SerializeOptions<ArraySeparatorStyle> & {
|
|
26
26
|
value: unknown[];
|
|
27
27
|
}) => string;
|
|
28
28
|
export declare const serializePrimitiveParam: ({ allowReserved, name, value }: SerializePrimitiveParam) => string;
|
|
29
29
|
export declare const serializeObjectParam: ({ allowReserved, explode, name, style, value, valueOnly, }: SerializeOptions<ObjectSeparatorStyle> & {
|
|
30
|
-
value: Record<string, unknown
|
|
31
|
-
valueOnly?: boolean;
|
|
30
|
+
value: Date | Record<string, unknown>;
|
|
31
|
+
valueOnly?: boolean | undefined;
|
|
32
32
|
}) => string;
|
|
33
33
|
export {};
|
|
@@ -68,4 +68,4 @@ export interface StreamEvent<TData = unknown> {
|
|
|
68
68
|
export type ServerSentEventsResult<TData = unknown, TReturn = void, TNext = unknown> = {
|
|
69
69
|
stream: AsyncGenerator<TData extends Record<string, unknown> ? TData[keyof TData] : TData, TReturn, TNext>;
|
|
70
70
|
};
|
|
71
|
-
export declare const createSseClient: <TData = unknown>({ onRequest, onSseError, onSseEvent, responseTransformer, responseValidator, sseDefaultRetryDelay, sseMaxRetryAttempts, sseMaxRetryDelay, sseSleepFn, url, ...options }: ServerSentEventsOptions) => ServerSentEventsResult<TData>;
|
|
71
|
+
export declare const createSseClient: <TData = unknown>({ onRequest, onSseError, onSseEvent, responseTransformer, responseValidator, sseDefaultRetryDelay, sseMaxRetryAttempts, sseMaxRetryDelay, sseSleepFn, url, ...options }: ServerSentEventsOptions<unknown>) => ServerSentEventsResult<TData, void, unknown>;
|
|
@@ -6,9 +6,9 @@ export interface PathSerializer {
|
|
|
6
6
|
export declare const PATH_PARAM_RE: RegExp;
|
|
7
7
|
export declare const defaultPathSerializer: ({ path, url: _url }: PathSerializer) => string;
|
|
8
8
|
export declare const getUrl: ({ baseUrl, path, query, querySerializer, url: _url, }: {
|
|
9
|
-
baseUrl?: string;
|
|
10
|
-
path?: Record<string, unknown
|
|
11
|
-
query?: Record<string, unknown
|
|
9
|
+
baseUrl?: string | undefined;
|
|
10
|
+
path?: Record<string, unknown> | undefined;
|
|
11
|
+
query?: Record<string, unknown> | undefined;
|
|
12
12
|
querySerializer: QuerySerializer;
|
|
13
13
|
url: string;
|
|
14
14
|
}) => string;
|
package/dist/v2/gen/sdk.gen.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Client, type Options as Options2, type TDataShape } from "./client/index.js";
|
|
2
|
-
import type { AgentPartInput, AppAgentsResponses, AppLogErrors, AppLogResponses, AppSkillsResponses, Auth as Auth3, AuthRemoveErrors, AuthRemoveResponses, AuthSetErrors, AuthSetResponses, CommandListResponses, Config as Config3, ConfigGetResponses, ConfigProvidersResponses, ConfigUpdateErrors, ConfigUpdateResponses, EventSubscribeResponses, EventTuiCommandExecute, EventTuiPromptAppend, EventTuiSessionSelect, EventTuiToastShow, ExperimentalResourceListResponses, FileListResponses, FilePartInput, FilePartSource, FileReadResponses, FileStatusResponses, FindFilesResponses, FindSymbolsResponses, FindTextResponses, FormatterStatusResponses, GlobalConfigGetResponses, GlobalConfigUpdateErrors, GlobalConfigUpdateResponses, GlobalDisposeResponses, GlobalEventResponses, GlobalHealthResponses, InstanceDisposeResponses, LspStatusResponses, McpAddErrors, McpAddResponses, McpAuthAuthenticateErrors, McpAuthAuthenticateResponses, McpAuthCallbackErrors, McpAuthCallbackResponses, McpAuthRemoveErrors, McpAuthRemoveResponses, McpAuthStartErrors, McpAuthStartResponses, McpConnectResponses, McpDisconnectResponses, McpLocalConfig, McpRemoteConfig, McpStatusResponses, Part as Part2, PartDeleteErrors, PartDeleteResponses, PartUpdateErrors, PartUpdateResponses, PathGetResponses, PermissionListResponses, PermissionReplyErrors, PermissionReplyResponses, PermissionRespondErrors, PermissionRespondResponses, PermissionRuleset, ProjectCurrentResponses, ProjectListResponses, ProjectUpdateErrors, ProjectUpdateResponses, ProviderAuthResponses, ProviderListResponses, ProviderOauthAuthorizeErrors, ProviderOauthAuthorizeResponses, ProviderOauthCallbackErrors, ProviderOauthCallbackResponses, PtyConnectErrors, PtyConnectResponses, PtyCreateErrors, PtyCreateResponses, PtyGetErrors, PtyGetResponses, PtyListResponses, PtyRemoveErrors, PtyRemoveResponses, PtyUpdateErrors, PtyUpdateResponses, QuestionAnswer, QuestionListResponses, QuestionRejectErrors, QuestionRejectResponses, QuestionReplyErrors, QuestionReplyResponses, SessionAbortErrors, SessionAbortResponses, SessionChildrenErrors, SessionChildrenResponses, SessionCommandErrors, SessionCommandResponses, SessionCreateErrors, SessionCreateResponses, SessionDeleteErrors, SessionDeleteResponses, SessionDiffResponses, SessionForkResponses, SessionGetErrors, SessionGetResponses, SessionInitErrors, SessionInitResponses, SessionListResponses, SessionMessageErrors, SessionMessageResponses, SessionMessagesErrors, SessionMessagesResponses, SessionPromptAsyncErrors, SessionPromptAsyncResponses, SessionPromptErrors, SessionPromptResponses, SessionRevertErrors, SessionRevertResponses, SessionShareErrors, SessionShareResponses, SessionShellErrors, SessionShellResponses, SessionStatusErrors, SessionStatusResponses, SessionSummarizeErrors, SessionSummarizeResponses, SessionTodoErrors, SessionTodoResponses, SessionUnrevertErrors, SessionUnrevertResponses, SessionUnshareErrors, SessionUnshareResponses, SessionUpdateErrors, SessionUpdateResponses, SubtaskPartInput, TextPartInput, ToolIdsErrors, ToolIdsResponses, ToolListErrors, ToolListResponses, TuiAppendPromptErrors, TuiAppendPromptResponses, TuiClearPromptResponses, TuiControlNextResponses, TuiControlResponseResponses, TuiExecuteCommandErrors, TuiExecuteCommandResponses, TuiOpenHelpResponses, TuiOpenModelsResponses, TuiOpenSessionsResponses, TuiOpenThemesResponses, TuiPublishErrors, TuiPublishResponses, TuiSelectSessionErrors, TuiSelectSessionResponses, TuiShowToastResponses, TuiSubmitPromptResponses, VcsGetResponses, WorktreeCreateErrors, WorktreeCreateInput, WorktreeCreateResponses, WorktreeListResponses, WorktreeRemoveErrors, WorktreeRemoveInput, WorktreeRemoveResponses, WorktreeResetErrors, WorktreeResetInput, WorktreeResetResponses } from "./types.gen.js";
|
|
2
|
+
import type { AgentPartInput, AppAgentsResponses, AppLogErrors, AppLogResponses, AppSkillsResponses, Auth as Auth3, AuthRemoveErrors, AuthRemoveResponses, AuthSetErrors, AuthSetResponses, CommandListResponses, Config as Config3, ConfigGetResponses, ConfigProvidersResponses, ConfigUpdateErrors, ConfigUpdateResponses, EventSubscribeResponses, EventTuiCommandExecute, EventTuiPromptAppend, EventTuiSessionSelect, EventTuiToastShow, ExperimentalResourceListResponses, ExperimentalSessionListResponses, FileListResponses, FilePartInput, FilePartSource, FileReadResponses, FileStatusResponses, FindFilesResponses, FindSymbolsResponses, FindTextResponses, FormatterStatusResponses, GlobalConfigGetResponses, GlobalConfigUpdateErrors, GlobalConfigUpdateResponses, GlobalDisposeResponses, GlobalEventResponses, GlobalHealthResponses, InstanceDisposeResponses, LspStatusResponses, McpAddErrors, McpAddResponses, McpAuthAuthenticateErrors, McpAuthAuthenticateResponses, McpAuthCallbackErrors, McpAuthCallbackResponses, McpAuthRemoveErrors, McpAuthRemoveResponses, McpAuthStartErrors, McpAuthStartResponses, McpConnectResponses, McpDisconnectResponses, McpLocalConfig, McpRemoteConfig, McpStatusResponses, OutputFormat, Part as Part2, PartDeleteErrors, PartDeleteResponses, PartUpdateErrors, PartUpdateResponses, PathGetResponses, PermissionListResponses, PermissionReplyErrors, PermissionReplyResponses, PermissionRespondErrors, PermissionRespondResponses, PermissionRuleset, ProjectCurrentResponses, ProjectListResponses, ProjectUpdateErrors, ProjectUpdateResponses, ProviderAuthResponses, ProviderListResponses, ProviderOauthAuthorizeErrors, ProviderOauthAuthorizeResponses, ProviderOauthCallbackErrors, ProviderOauthCallbackResponses, PtyConnectErrors, PtyConnectResponses, PtyCreateErrors, PtyCreateResponses, PtyGetErrors, PtyGetResponses, PtyListResponses, PtyRemoveErrors, PtyRemoveResponses, PtyUpdateErrors, PtyUpdateResponses, QuestionAnswer, QuestionListResponses, QuestionRejectErrors, QuestionRejectResponses, QuestionReplyErrors, QuestionReplyResponses, SessionAbortErrors, SessionAbortResponses, SessionChildrenErrors, SessionChildrenResponses, SessionCommandErrors, SessionCommandResponses, SessionCreateErrors, SessionCreateResponses, SessionDeleteErrors, SessionDeleteResponses, SessionDiffResponses, SessionForkResponses, SessionGetErrors, SessionGetResponses, SessionInitErrors, SessionInitResponses, SessionListResponses, SessionMessageErrors, SessionMessageResponses, SessionMessagesErrors, SessionMessagesResponses, SessionPromptAsyncErrors, SessionPromptAsyncResponses, SessionPromptErrors, SessionPromptResponses, SessionRevertErrors, SessionRevertResponses, SessionShareErrors, SessionShareResponses, SessionShellErrors, SessionShellResponses, SessionStatusErrors, SessionStatusResponses, SessionSummarizeErrors, SessionSummarizeResponses, SessionTodoErrors, SessionTodoResponses, SessionUnrevertErrors, SessionUnrevertResponses, SessionUnshareErrors, SessionUnshareResponses, SessionUpdateErrors, SessionUpdateResponses, SubtaskPartInput, TextPartInput, ToolIdsErrors, ToolIdsResponses, ToolListErrors, ToolListResponses, TuiAppendPromptErrors, TuiAppendPromptResponses, TuiClearPromptResponses, TuiControlNextResponses, TuiControlResponseResponses, TuiExecuteCommandErrors, TuiExecuteCommandResponses, TuiOpenHelpResponses, TuiOpenModelsResponses, TuiOpenSessionsResponses, TuiOpenThemesResponses, TuiPublishErrors, TuiPublishResponses, TuiSelectSessionErrors, TuiSelectSessionResponses, TuiShowToastResponses, TuiSubmitPromptResponses, VcsGetResponses, WorktreeCreateErrors, WorktreeCreateInput, WorktreeCreateResponses, WorktreeListResponses, WorktreeRemoveErrors, WorktreeRemoveInput, WorktreeRemoveResponses, WorktreeResetErrors, WorktreeResetInput, WorktreeResetResponses } from "./types.gen.js";
|
|
3
3
|
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean> = Options2<TData, ThrowOnError> & {
|
|
4
4
|
/**
|
|
5
5
|
* You can provide a client instance returned by `createClient()` instead of
|
|
@@ -271,6 +271,22 @@ export declare class Worktree extends HeyApiClient {
|
|
|
271
271
|
worktreeResetInput?: WorktreeResetInput;
|
|
272
272
|
}, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<WorktreeResetResponses, WorktreeResetErrors, ThrowOnError, "fields">;
|
|
273
273
|
}
|
|
274
|
+
export declare class Session extends HeyApiClient {
|
|
275
|
+
/**
|
|
276
|
+
* List sessions
|
|
277
|
+
*
|
|
278
|
+
* Get a list of all NeoCode sessions across projects, sorted by most recently updated. Archived sessions are excluded by default.
|
|
279
|
+
*/
|
|
280
|
+
list<ThrowOnError extends boolean = false>(parameters?: {
|
|
281
|
+
directory?: string;
|
|
282
|
+
roots?: boolean;
|
|
283
|
+
start?: number;
|
|
284
|
+
cursor?: number;
|
|
285
|
+
search?: string;
|
|
286
|
+
limit?: number;
|
|
287
|
+
archived?: boolean;
|
|
288
|
+
}, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalSessionListResponses, unknown, ThrowOnError, "fields">;
|
|
289
|
+
}
|
|
274
290
|
export declare class Resource extends HeyApiClient {
|
|
275
291
|
/**
|
|
276
292
|
* Get MCP resources
|
|
@@ -282,10 +298,12 @@ export declare class Resource extends HeyApiClient {
|
|
|
282
298
|
}, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<ExperimentalResourceListResponses, unknown, ThrowOnError, "fields">;
|
|
283
299
|
}
|
|
284
300
|
export declare class Experimental extends HeyApiClient {
|
|
301
|
+
private _session?;
|
|
302
|
+
get session(): Session;
|
|
285
303
|
private _resource?;
|
|
286
304
|
get resource(): Resource;
|
|
287
305
|
}
|
|
288
|
-
export declare class
|
|
306
|
+
export declare class Session2 extends HeyApiClient {
|
|
289
307
|
/**
|
|
290
308
|
* List sessions
|
|
291
309
|
*
|
|
@@ -465,6 +483,7 @@ export declare class Session extends HeyApiClient {
|
|
|
465
483
|
tools?: {
|
|
466
484
|
[key: string]: boolean;
|
|
467
485
|
};
|
|
486
|
+
format?: OutputFormat;
|
|
468
487
|
system?: string;
|
|
469
488
|
variant?: string;
|
|
470
489
|
parts?: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
|
|
@@ -497,6 +516,7 @@ export declare class Session extends HeyApiClient {
|
|
|
497
516
|
tools?: {
|
|
498
517
|
[key: string]: boolean;
|
|
499
518
|
};
|
|
519
|
+
format?: OutputFormat;
|
|
500
520
|
system?: string;
|
|
501
521
|
variant?: string;
|
|
502
522
|
parts?: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
|
|
@@ -1066,7 +1086,7 @@ export declare class NeocodeClient extends HeyApiClient {
|
|
|
1066
1086
|
private _experimental?;
|
|
1067
1087
|
get experimental(): Experimental;
|
|
1068
1088
|
private _session?;
|
|
1069
|
-
get session():
|
|
1089
|
+
get session(): Session2;
|
|
1070
1090
|
private _part?;
|
|
1071
1091
|
get part(): Part;
|
|
1072
1092
|
private _permission?;
|
package/dist/v2/gen/sdk.gen.js
CHANGED
|
@@ -497,6 +497,33 @@ export class Worktree extends HeyApiClient {
|
|
|
497
497
|
});
|
|
498
498
|
}
|
|
499
499
|
}
|
|
500
|
+
export class Session extends HeyApiClient {
|
|
501
|
+
/**
|
|
502
|
+
* List sessions
|
|
503
|
+
*
|
|
504
|
+
* Get a list of all NeoCode sessions across projects, sorted by most recently updated. Archived sessions are excluded by default.
|
|
505
|
+
*/
|
|
506
|
+
list(parameters, options) {
|
|
507
|
+
const params = buildClientParams([parameters], [
|
|
508
|
+
{
|
|
509
|
+
args: [
|
|
510
|
+
{ in: "query", key: "directory" },
|
|
511
|
+
{ in: "query", key: "roots" },
|
|
512
|
+
{ in: "query", key: "start" },
|
|
513
|
+
{ in: "query", key: "cursor" },
|
|
514
|
+
{ in: "query", key: "search" },
|
|
515
|
+
{ in: "query", key: "limit" },
|
|
516
|
+
{ in: "query", key: "archived" },
|
|
517
|
+
],
|
|
518
|
+
},
|
|
519
|
+
]);
|
|
520
|
+
return (options?.client ?? this.client).get({
|
|
521
|
+
url: "/experimental/session",
|
|
522
|
+
...options,
|
|
523
|
+
...params,
|
|
524
|
+
});
|
|
525
|
+
}
|
|
526
|
+
}
|
|
500
527
|
export class Resource extends HeyApiClient {
|
|
501
528
|
/**
|
|
502
529
|
* Get MCP resources
|
|
@@ -513,12 +540,16 @@ export class Resource extends HeyApiClient {
|
|
|
513
540
|
}
|
|
514
541
|
}
|
|
515
542
|
export class Experimental extends HeyApiClient {
|
|
543
|
+
_session;
|
|
544
|
+
get session() {
|
|
545
|
+
return (this._session ??= new Session({ client: this.client }));
|
|
546
|
+
}
|
|
516
547
|
_resource;
|
|
517
548
|
get resource() {
|
|
518
549
|
return (this._resource ??= new Resource({ client: this.client }));
|
|
519
550
|
}
|
|
520
551
|
}
|
|
521
|
-
export class
|
|
552
|
+
export class Session2 extends HeyApiClient {
|
|
522
553
|
/**
|
|
523
554
|
* List sessions
|
|
524
555
|
*
|
|
@@ -889,6 +920,7 @@ export class Session extends HeyApiClient {
|
|
|
889
920
|
{ in: "body", key: "agent" },
|
|
890
921
|
{ in: "body", key: "noReply" },
|
|
891
922
|
{ in: "body", key: "tools" },
|
|
923
|
+
{ in: "body", key: "format" },
|
|
892
924
|
{ in: "body", key: "system" },
|
|
893
925
|
{ in: "body", key: "variant" },
|
|
894
926
|
{ in: "body", key: "parts" },
|
|
@@ -943,6 +975,7 @@ export class Session extends HeyApiClient {
|
|
|
943
975
|
{ in: "body", key: "agent" },
|
|
944
976
|
{ in: "body", key: "noReply" },
|
|
945
977
|
{ in: "body", key: "tools" },
|
|
978
|
+
{ in: "body", key: "format" },
|
|
946
979
|
{ in: "body", key: "system" },
|
|
947
980
|
{ in: "body", key: "variant" },
|
|
948
981
|
{ in: "body", key: "parts" },
|
|
@@ -2077,7 +2110,7 @@ export class NeocodeClient extends HeyApiClient {
|
|
|
2077
2110
|
}
|
|
2078
2111
|
_session;
|
|
2079
2112
|
get session() {
|
|
2080
|
-
return (this._session ??= new
|
|
2113
|
+
return (this._session ??= new Session2({ client: this.client }));
|
|
2081
2114
|
}
|
|
2082
2115
|
_part;
|
|
2083
2116
|
get part() {
|
|
@@ -77,6 +77,18 @@ export type EventFileEdited = {
|
|
|
77
77
|
file: string;
|
|
78
78
|
};
|
|
79
79
|
};
|
|
80
|
+
export type OutputFormatText = {
|
|
81
|
+
type: "text";
|
|
82
|
+
};
|
|
83
|
+
export type JsonSchema = {
|
|
84
|
+
[key: string]: unknown;
|
|
85
|
+
};
|
|
86
|
+
export type OutputFormatJsonSchema = {
|
|
87
|
+
type: "json_schema";
|
|
88
|
+
schema: JsonSchema;
|
|
89
|
+
retryCount?: number;
|
|
90
|
+
};
|
|
91
|
+
export type OutputFormat = OutputFormatText | OutputFormatJsonSchema;
|
|
80
92
|
export type FileDiff = {
|
|
81
93
|
file: string;
|
|
82
94
|
before: string;
|
|
@@ -92,6 +104,7 @@ export type UserMessage = {
|
|
|
92
104
|
time: {
|
|
93
105
|
created: number;
|
|
94
106
|
};
|
|
107
|
+
format?: OutputFormat;
|
|
95
108
|
summary?: {
|
|
96
109
|
title?: string;
|
|
97
110
|
body?: string;
|
|
@@ -133,6 +146,20 @@ export type MessageAbortedError = {
|
|
|
133
146
|
message: string;
|
|
134
147
|
};
|
|
135
148
|
};
|
|
149
|
+
export type StructuredOutputError = {
|
|
150
|
+
name: "StructuredOutputError";
|
|
151
|
+
data: {
|
|
152
|
+
message: string;
|
|
153
|
+
retries: number;
|
|
154
|
+
};
|
|
155
|
+
};
|
|
156
|
+
export type ContextOverflowError = {
|
|
157
|
+
name: "ContextOverflowError";
|
|
158
|
+
data: {
|
|
159
|
+
message: string;
|
|
160
|
+
responseBody?: string;
|
|
161
|
+
};
|
|
162
|
+
};
|
|
136
163
|
export type ApiError = {
|
|
137
164
|
name: "APIError";
|
|
138
165
|
data: {
|
|
@@ -156,7 +183,7 @@ export type AssistantMessage = {
|
|
|
156
183
|
created: number;
|
|
157
184
|
completed?: number;
|
|
158
185
|
};
|
|
159
|
-
error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | ApiError;
|
|
186
|
+
error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | StructuredOutputError | ContextOverflowError | ApiError;
|
|
160
187
|
parentID: string;
|
|
161
188
|
modelID: string;
|
|
162
189
|
providerID: string;
|
|
@@ -169,6 +196,7 @@ export type AssistantMessage = {
|
|
|
169
196
|
summary?: boolean;
|
|
170
197
|
cost: number;
|
|
171
198
|
tokens: {
|
|
199
|
+
total?: number;
|
|
172
200
|
input: number;
|
|
173
201
|
output: number;
|
|
174
202
|
reasoning: number;
|
|
@@ -177,6 +205,8 @@ export type AssistantMessage = {
|
|
|
177
205
|
write: number;
|
|
178
206
|
};
|
|
179
207
|
};
|
|
208
|
+
structured?: unknown;
|
|
209
|
+
variant?: string;
|
|
180
210
|
finish?: string;
|
|
181
211
|
};
|
|
182
212
|
export type Message = UserMessage | AssistantMessage;
|
|
@@ -362,6 +392,7 @@ export type StepFinishPart = {
|
|
|
362
392
|
snapshot?: string;
|
|
363
393
|
cost: number;
|
|
364
394
|
tokens: {
|
|
395
|
+
total?: number;
|
|
365
396
|
input: number;
|
|
366
397
|
output: number;
|
|
367
398
|
reasoning: number;
|
|
@@ -421,7 +452,16 @@ export type EventMessagePartUpdated = {
|
|
|
421
452
|
type: "message.part.updated";
|
|
422
453
|
properties: {
|
|
423
454
|
part: Part;
|
|
424
|
-
|
|
455
|
+
};
|
|
456
|
+
};
|
|
457
|
+
export type EventMessagePartDelta = {
|
|
458
|
+
type: "message.part.delta";
|
|
459
|
+
properties: {
|
|
460
|
+
sessionID: string;
|
|
461
|
+
messageID: string;
|
|
462
|
+
partID: string;
|
|
463
|
+
field: string;
|
|
464
|
+
delta: string;
|
|
425
465
|
};
|
|
426
466
|
};
|
|
427
467
|
export type EventMessagePartRemoved = {
|
|
@@ -571,10 +611,6 @@ export type Todo = {
|
|
|
571
611
|
* Priority level of the task: high, medium, low
|
|
572
612
|
*/
|
|
573
613
|
priority: string;
|
|
574
|
-
/**
|
|
575
|
-
* Unique identifier for the todo item
|
|
576
|
-
*/
|
|
577
|
-
id: string;
|
|
578
614
|
};
|
|
579
615
|
export type EventTodoUpdated = {
|
|
580
616
|
type: "todo.updated";
|
|
@@ -705,7 +741,7 @@ export type EventSessionError = {
|
|
|
705
741
|
type: "session.error";
|
|
706
742
|
properties: {
|
|
707
743
|
sessionID?: string;
|
|
708
|
-
error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | ApiError;
|
|
744
|
+
error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | StructuredOutputError | ContextOverflowError | ApiError;
|
|
709
745
|
};
|
|
710
746
|
};
|
|
711
747
|
export type EventVcsBranchUpdated = {
|
|
@@ -761,7 +797,7 @@ export type EventWorktreeFailed = {
|
|
|
761
797
|
message: string;
|
|
762
798
|
};
|
|
763
799
|
};
|
|
764
|
-
export type Event = EventInstallationUpdated | EventInstallationUpdateAvailable | EventProjectUpdated | EventServerInstanceDisposed | EventServerConnected | EventGlobalDisposed | EventLspClientDiagnostics | EventLspUpdated | EventFileEdited | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartRemoved | EventPermissionAsked | EventPermissionReplied | EventSessionStatus | EventSessionIdle | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventSessionCompacted | EventFileWatcherUpdated | EventTodoUpdated | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventCommandExecuted | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventSessionDiff | EventSessionError | EventVcsBranchUpdated | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventWorktreeReady | EventWorktreeFailed;
|
|
800
|
+
export type Event = EventInstallationUpdated | EventInstallationUpdateAvailable | EventProjectUpdated | EventServerInstanceDisposed | EventServerConnected | EventGlobalDisposed | EventLspClientDiagnostics | EventLspUpdated | EventFileEdited | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartDelta | EventMessagePartRemoved | EventPermissionAsked | EventPermissionReplied | EventSessionStatus | EventSessionIdle | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventSessionCompacted | EventFileWatcherUpdated | EventTodoUpdated | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventCommandExecuted | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventSessionDiff | EventSessionError | EventVcsBranchUpdated | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventWorktreeReady | EventWorktreeFailed;
|
|
765
801
|
export type GlobalEvent = {
|
|
766
802
|
directory: string;
|
|
767
803
|
payload: Event;
|
|
@@ -1142,6 +1178,10 @@ export type KeybindsConfig = {
|
|
|
1142
1178
|
* Toggle tips on home screen
|
|
1143
1179
|
*/
|
|
1144
1180
|
tips_toggle?: string;
|
|
1181
|
+
/**
|
|
1182
|
+
* Toggle thinking blocks visibility
|
|
1183
|
+
*/
|
|
1184
|
+
display_thinking?: string;
|
|
1145
1185
|
};
|
|
1146
1186
|
/**
|
|
1147
1187
|
* Log level
|
|
@@ -1227,9 +1267,9 @@ export type AgentConfig = {
|
|
|
1227
1267
|
[key: string]: unknown;
|
|
1228
1268
|
};
|
|
1229
1269
|
/**
|
|
1230
|
-
* Hex color code
|
|
1270
|
+
* Hex color code (e.g., #FF5733) or theme color (e.g., primary)
|
|
1231
1271
|
*/
|
|
1232
|
-
color?: string;
|
|
1272
|
+
color?: string | "primary" | "secondary" | "accent" | "success" | "warning" | "error" | "info";
|
|
1233
1273
|
/**
|
|
1234
1274
|
* Maximum number of agentic iterations before forcing text-only response
|
|
1235
1275
|
*/
|
|
@@ -1243,7 +1283,7 @@ export type AgentConfig = {
|
|
|
1243
1283
|
[key: string]: boolean;
|
|
1244
1284
|
} | boolean | "subagent" | "primary" | "all" | {
|
|
1245
1285
|
[key: string]: unknown;
|
|
1246
|
-
} | string | number | PermissionConfig | undefined;
|
|
1286
|
+
} | string | "primary" | "secondary" | "accent" | "success" | "warning" | "error" | "info" | number | PermissionConfig | undefined;
|
|
1247
1287
|
};
|
|
1248
1288
|
export type ProviderConfig = {
|
|
1249
1289
|
api?: string;
|
|
@@ -1294,7 +1334,8 @@ export type ProviderConfig = {
|
|
|
1294
1334
|
[key: string]: string;
|
|
1295
1335
|
};
|
|
1296
1336
|
provider?: {
|
|
1297
|
-
npm
|
|
1337
|
+
npm?: string;
|
|
1338
|
+
api?: string;
|
|
1298
1339
|
};
|
|
1299
1340
|
/**
|
|
1300
1341
|
* Variant-specific configuration
|
|
@@ -1454,6 +1495,10 @@ export type Config = {
|
|
|
1454
1495
|
* Additional paths to skill folders
|
|
1455
1496
|
*/
|
|
1456
1497
|
paths?: Array<string>;
|
|
1498
|
+
/**
|
|
1499
|
+
* URLs to fetch skills from (e.g., https://example.com/.well-known/skills/)
|
|
1500
|
+
*/
|
|
1501
|
+
urls?: Array<string>;
|
|
1457
1502
|
};
|
|
1458
1503
|
watcher?: {
|
|
1459
1504
|
ignore?: Array<string>;
|
|
@@ -1580,6 +1625,10 @@ export type Config = {
|
|
|
1580
1625
|
* Enable pruning of old tool outputs (default: true)
|
|
1581
1626
|
*/
|
|
1582
1627
|
prune?: boolean;
|
|
1628
|
+
/**
|
|
1629
|
+
* Token buffer for compaction. Leaves enough window to avoid overflow during compaction.
|
|
1630
|
+
*/
|
|
1631
|
+
reserved?: number;
|
|
1583
1632
|
};
|
|
1584
1633
|
experimental?: {
|
|
1585
1634
|
disable_paste_summary?: boolean;
|
|
@@ -1742,6 +1791,43 @@ export type WorktreeRemoveInput = {
|
|
|
1742
1791
|
export type WorktreeResetInput = {
|
|
1743
1792
|
directory: string;
|
|
1744
1793
|
};
|
|
1794
|
+
export type ProjectSummary = {
|
|
1795
|
+
id: string;
|
|
1796
|
+
name?: string;
|
|
1797
|
+
worktree: string;
|
|
1798
|
+
};
|
|
1799
|
+
export type GlobalSession = {
|
|
1800
|
+
id: string;
|
|
1801
|
+
slug: string;
|
|
1802
|
+
projectID: string;
|
|
1803
|
+
directory: string;
|
|
1804
|
+
parentID?: string;
|
|
1805
|
+
summary?: {
|
|
1806
|
+
additions: number;
|
|
1807
|
+
deletions: number;
|
|
1808
|
+
files: number;
|
|
1809
|
+
diffs?: Array<FileDiff>;
|
|
1810
|
+
};
|
|
1811
|
+
share?: {
|
|
1812
|
+
url: string;
|
|
1813
|
+
};
|
|
1814
|
+
title: string;
|
|
1815
|
+
version: string;
|
|
1816
|
+
time: {
|
|
1817
|
+
created: number;
|
|
1818
|
+
updated: number;
|
|
1819
|
+
compacting?: number;
|
|
1820
|
+
archived?: number;
|
|
1821
|
+
};
|
|
1822
|
+
permission?: PermissionRuleset;
|
|
1823
|
+
revert?: {
|
|
1824
|
+
messageID: string;
|
|
1825
|
+
partID?: string;
|
|
1826
|
+
snapshot?: string;
|
|
1827
|
+
diff?: string;
|
|
1828
|
+
};
|
|
1829
|
+
project: ProjectSummary | null;
|
|
1830
|
+
};
|
|
1745
1831
|
export type McpResource = {
|
|
1746
1832
|
name: string;
|
|
1747
1833
|
uri: string;
|
|
@@ -2435,6 +2521,48 @@ export type WorktreeResetResponses = {
|
|
|
2435
2521
|
200: boolean;
|
|
2436
2522
|
};
|
|
2437
2523
|
export type WorktreeResetResponse = WorktreeResetResponses[keyof WorktreeResetResponses];
|
|
2524
|
+
export type ExperimentalSessionListData = {
|
|
2525
|
+
body?: never;
|
|
2526
|
+
path?: never;
|
|
2527
|
+
query?: {
|
|
2528
|
+
/**
|
|
2529
|
+
* Filter sessions by project directory
|
|
2530
|
+
*/
|
|
2531
|
+
directory?: string;
|
|
2532
|
+
/**
|
|
2533
|
+
* Only return root sessions (no parentID)
|
|
2534
|
+
*/
|
|
2535
|
+
roots?: boolean;
|
|
2536
|
+
/**
|
|
2537
|
+
* Filter sessions updated on or after this timestamp (milliseconds since epoch)
|
|
2538
|
+
*/
|
|
2539
|
+
start?: number;
|
|
2540
|
+
/**
|
|
2541
|
+
* Return sessions updated before this timestamp (milliseconds since epoch)
|
|
2542
|
+
*/
|
|
2543
|
+
cursor?: number;
|
|
2544
|
+
/**
|
|
2545
|
+
* Filter sessions by title (case-insensitive)
|
|
2546
|
+
*/
|
|
2547
|
+
search?: string;
|
|
2548
|
+
/**
|
|
2549
|
+
* Maximum number of sessions to return
|
|
2550
|
+
*/
|
|
2551
|
+
limit?: number;
|
|
2552
|
+
/**
|
|
2553
|
+
* Include archived sessions (default false)
|
|
2554
|
+
*/
|
|
2555
|
+
archived?: boolean;
|
|
2556
|
+
};
|
|
2557
|
+
url: "/experimental/session";
|
|
2558
|
+
};
|
|
2559
|
+
export type ExperimentalSessionListResponses = {
|
|
2560
|
+
/**
|
|
2561
|
+
* List of sessions
|
|
2562
|
+
*/
|
|
2563
|
+
200: Array<GlobalSession>;
|
|
2564
|
+
};
|
|
2565
|
+
export type ExperimentalSessionListResponse = ExperimentalSessionListResponses[keyof ExperimentalSessionListResponses];
|
|
2438
2566
|
export type ExperimentalResourceListData = {
|
|
2439
2567
|
body?: never;
|
|
2440
2568
|
path?: never;
|
|
@@ -2925,6 +3053,7 @@ export type SessionPromptData = {
|
|
|
2925
3053
|
tools?: {
|
|
2926
3054
|
[key: string]: boolean;
|
|
2927
3055
|
};
|
|
3056
|
+
format?: OutputFormat;
|
|
2928
3057
|
system?: string;
|
|
2929
3058
|
variant?: string;
|
|
2930
3059
|
parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
|
|
@@ -3092,6 +3221,7 @@ export type SessionPromptAsyncData = {
|
|
|
3092
3221
|
tools?: {
|
|
3093
3222
|
[key: string]: boolean;
|
|
3094
3223
|
};
|
|
3224
|
+
format?: OutputFormat;
|
|
3095
3225
|
system?: string;
|
|
3096
3226
|
variant?: string;
|
|
3097
3227
|
parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
|
|
@@ -3486,7 +3616,8 @@ export type ProviderListResponses = {
|
|
|
3486
3616
|
[key: string]: string;
|
|
3487
3617
|
};
|
|
3488
3618
|
provider?: {
|
|
3489
|
-
npm
|
|
3619
|
+
npm?: string;
|
|
3620
|
+
api?: string;
|
|
3490
3621
|
};
|
|
3491
3622
|
variants?: {
|
|
3492
3623
|
[key: string]: {
|
package/package.json
CHANGED
|
@@ -1,19 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
3
|
"name": "@neocode-ai/sdk",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.2.10",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"scripts": {
|
|
8
|
-
"typecheck": "
|
|
8
|
+
"typecheck": "tsgo --noEmit",
|
|
9
9
|
"build": "./script/build.ts"
|
|
10
10
|
},
|
|
11
11
|
"exports": {
|
|
12
12
|
".": "./src/index.ts",
|
|
13
13
|
"./client": "./src/client.ts",
|
|
14
14
|
"./server": "./src/server.ts",
|
|
15
|
-
"./v2":
|
|
16
|
-
|
|
15
|
+
"./v2": {
|
|
16
|
+
"types": "./dist/v2/index.d.ts",
|
|
17
|
+
"default": "./src/v2/index.ts"
|
|
18
|
+
},
|
|
19
|
+
"./v2/client": {
|
|
20
|
+
"types": "./dist/v2/client.d.ts",
|
|
21
|
+
"default": "./src/v2/client.ts"
|
|
22
|
+
},
|
|
23
|
+
"./v2/gen/client": {
|
|
24
|
+
"types": "./dist/v2/gen/client/index.d.ts",
|
|
25
|
+
"default": "./src/v2/gen/client/index.ts"
|
|
26
|
+
},
|
|
17
27
|
"./v2/server": "./src/v2/server.ts"
|
|
18
28
|
},
|
|
19
29
|
"files": [
|
|
@@ -30,4 +40,4 @@
|
|
|
30
40
|
"publishConfig": {
|
|
31
41
|
"directory": "dist"
|
|
32
42
|
}
|
|
33
|
-
}
|
|
43
|
+
}
|