@seaverse/conversation-sdk 0.2.0
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 +284 -0
- package/dist/aggregated/apps-with-conversations.d.ts +47 -0
- package/dist/aggregated/apps-with-conversations.d.ts.map +1 -0
- package/dist/aggregated/apps-with-conversations.js +90 -0
- package/dist/aggregated/apps-with-conversations.js.map +1 -0
- package/dist/aggregated/index.d.ts +3 -0
- package/dist/aggregated/index.d.ts.map +1 -0
- package/dist/aggregated/index.js +2 -0
- package/dist/aggregated/index.js.map +1 -0
- package/dist/client/ConversationClient.d.ts +24 -0
- package/dist/client/ConversationClient.d.ts.map +1 -0
- package/dist/client/ConversationClient.js +56 -0
- package/dist/client/ConversationClient.js.map +1 -0
- package/dist/client/ConversationsClient.d.ts +31 -0
- package/dist/client/ConversationsClient.d.ts.map +1 -0
- package/dist/client/ConversationsClient.js +50 -0
- package/dist/client/ConversationsClient.js.map +1 -0
- package/dist/client/EnvironmentConfig.d.ts +12 -0
- package/dist/client/EnvironmentConfig.d.ts.map +1 -0
- package/dist/client/EnvironmentConfig.js +21 -0
- package/dist/client/EnvironmentConfig.js.map +1 -0
- package/dist/client/MessagesClient.d.ts +31 -0
- package/dist/client/MessagesClient.d.ts.map +1 -0
- package/dist/client/MessagesClient.js +57 -0
- package/dist/client/MessagesClient.js.map +1 -0
- package/dist/client/index.d.ts +3 -0
- package/dist/client/index.d.ts.map +1 -0
- package/dist/client/index.js +3 -0
- package/dist/client/index.js.map +1 -0
- package/dist/data/DbClient.d.ts +76 -0
- package/dist/data/DbClient.d.ts.map +1 -0
- package/dist/data/DbClient.js +107 -0
- package/dist/data/DbClient.js.map +1 -0
- package/dist/data/index.d.ts +2 -0
- package/dist/data/index.d.ts.map +1 -0
- package/dist/data/index.js +2 -0
- package/dist/data/index.js.map +1 -0
- package/dist/data/postgrest-headers.d.ts +10 -0
- package/dist/data/postgrest-headers.d.ts.map +1 -0
- package/dist/data/postgrest-headers.js +58 -0
- package/dist/data/postgrest-headers.js.map +1 -0
- package/dist/data/query.types.d.ts +62 -0
- package/dist/data/query.types.d.ts.map +1 -0
- package/dist/data/query.types.js +2 -0
- package/dist/data/query.types.js.map +1 -0
- package/dist/errors/AuthError.d.ts +8 -0
- package/dist/errors/AuthError.d.ts.map +1 -0
- package/dist/errors/AuthError.js +10 -0
- package/dist/errors/AuthError.js.map +1 -0
- package/dist/errors/BaseError.d.ts +17 -0
- package/dist/errors/BaseError.d.ts.map +1 -0
- package/dist/errors/BaseError.js +26 -0
- package/dist/errors/BaseError.js.map +1 -0
- package/dist/errors/NetworkError.d.ts +8 -0
- package/dist/errors/NetworkError.d.ts.map +1 -0
- package/dist/errors/NetworkError.js +10 -0
- package/dist/errors/NetworkError.js.map +1 -0
- package/dist/errors/ProtocolError.d.ts +8 -0
- package/dist/errors/ProtocolError.d.ts.map +1 -0
- package/dist/errors/ProtocolError.js +10 -0
- package/dist/errors/ProtocolError.js.map +1 -0
- package/dist/errors/TimeoutError.d.ts +8 -0
- package/dist/errors/TimeoutError.d.ts.map +1 -0
- package/dist/errors/TimeoutError.js +10 -0
- package/dist/errors/TimeoutError.js.map +1 -0
- package/dist/errors/index.d.ts +6 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/index.js +6 -0
- package/dist/errors/index.js.map +1 -0
- package/dist/functional-api.d.ts +24 -0
- package/dist/functional-api.d.ts.map +1 -0
- package/dist/functional-api.js +59 -0
- package/dist/functional-api.js.map +1 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +9 -0
- package/dist/index.js.map +1 -0
- package/dist/resources/AppsResource.d.ts +37 -0
- package/dist/resources/AppsResource.d.ts.map +1 -0
- package/dist/resources/AppsResource.js +51 -0
- package/dist/resources/AppsResource.js.map +1 -0
- package/dist/resources/ConversationsResource.d.ts +81 -0
- package/dist/resources/ConversationsResource.d.ts.map +1 -0
- package/dist/resources/ConversationsResource.js +103 -0
- package/dist/resources/ConversationsResource.js.map +1 -0
- package/dist/resources/MessagesResource.d.ts +56 -0
- package/dist/resources/MessagesResource.d.ts.map +1 -0
- package/dist/resources/MessagesResource.js +115 -0
- package/dist/resources/MessagesResource.js.map +1 -0
- package/dist/session/session-token.d.ts +38 -0
- package/dist/session/session-token.d.ts.map +1 -0
- package/dist/session/session-token.js +74 -0
- package/dist/session/session-token.js.map +1 -0
- package/dist/transforms/app.transform.d.ts +6 -0
- package/dist/transforms/app.transform.d.ts.map +1 -0
- package/dist/transforms/app.transform.js +39 -0
- package/dist/transforms/app.transform.js.map +1 -0
- package/dist/transforms/conversation.transform.d.ts +10 -0
- package/dist/transforms/conversation.transform.d.ts.map +1 -0
- package/dist/transforms/conversation.transform.js +45 -0
- package/dist/transforms/conversation.transform.js.map +1 -0
- package/dist/transforms/message.transform.d.ts +12 -0
- package/dist/transforms/message.transform.d.ts.map +1 -0
- package/dist/transforms/message.transform.js +119 -0
- package/dist/transforms/message.transform.js.map +1 -0
- package/dist/transport/HttpClient.d.ts +34 -0
- package/dist/transport/HttpClient.d.ts.map +1 -0
- package/dist/transport/HttpClient.js +158 -0
- package/dist/transport/HttpClient.js.map +1 -0
- package/dist/transport/config.types.d.ts +40 -0
- package/dist/transport/config.types.d.ts.map +1 -0
- package/dist/transport/config.types.js +2 -0
- package/dist/transport/config.types.js.map +1 -0
- package/dist/transport/index.d.ts +10 -0
- package/dist/transport/index.d.ts.map +1 -0
- package/dist/transport/index.js +11 -0
- package/dist/transport/index.js.map +1 -0
- package/dist/transport/timeout.d.ts +12 -0
- package/dist/transport/timeout.d.ts.map +1 -0
- package/dist/transport/timeout.js +29 -0
- package/dist/transport/timeout.js.map +1 -0
- package/dist/types/common.types.d.ts +24 -0
- package/dist/types/common.types.d.ts.map +1 -0
- package/dist/types/common.types.js +5 -0
- package/dist/types/common.types.js.map +1 -0
- package/dist/types/config.types.d.ts +28 -0
- package/dist/types/config.types.d.ts.map +1 -0
- package/dist/types/config.types.js +2 -0
- package/dist/types/config.types.js.map +1 -0
- package/dist/types/http.types.d.ts +47 -0
- package/dist/types/http.types.d.ts.map +1 -0
- package/dist/types/http.types.js +2 -0
- package/dist/types/http.types.js.map +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/models.types.d.ts +118 -0
- package/dist/types/models.types.d.ts.map +1 -0
- package/dist/types/models.types.js +5 -0
- package/dist/types/models.types.js.map +1 -0
- package/dist/types/pagination.types.d.ts +69 -0
- package/dist/types/pagination.types.d.ts.map +1 -0
- package/dist/types/pagination.types.js +24 -0
- package/dist/types/pagination.types.js.map +1 -0
- package/dist/types/token.types.d.ts +6 -0
- package/dist/types/token.types.d.ts.map +1 -0
- package/dist/types/token.types.js +2 -0
- package/dist/types/token.types.js.map +1 -0
- package/package.json +38 -0
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { HttpClient } from './HttpClient.js';
|
|
2
|
+
import type { HttpClientConfig } from './config.types.js';
|
|
3
|
+
/**
|
|
4
|
+
* Create an HTTP client with the given configuration
|
|
5
|
+
*/
|
|
6
|
+
export declare function createHttpClient(config: HttpClientConfig): HttpClient;
|
|
7
|
+
export { HttpClient } from './HttpClient.js';
|
|
8
|
+
export type { HttpClientConfig } from './config.types.js';
|
|
9
|
+
export { withTimeout, createTimeoutPromise } from './timeout.js';
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/transport/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAE1D;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,gBAAgB,GAAG,UAAU,CAErE;AAGD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,YAAY,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { HttpClient } from './HttpClient.js';
|
|
2
|
+
/**
|
|
3
|
+
* Create an HTTP client with the given configuration
|
|
4
|
+
*/
|
|
5
|
+
export function createHttpClient(config) {
|
|
6
|
+
return new HttpClient(config);
|
|
7
|
+
}
|
|
8
|
+
// Re-exports
|
|
9
|
+
export { HttpClient } from './HttpClient.js';
|
|
10
|
+
export { withTimeout, createTimeoutPromise } from './timeout.js';
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/transport/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAG7C;;GAEG;AACH,MAAM,UAAU,gBAAgB,CAAC,MAAwB;IACvD,OAAO,IAAI,UAAU,CAAC,MAAM,CAAC,CAAC;AAChC,CAAC;AAED,aAAa;AACb,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAE7C,OAAO,EAAE,WAAW,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Create a timeout promise that rejects after specified milliseconds
|
|
3
|
+
*/
|
|
4
|
+
export declare function createTimeoutPromise(timeoutMs: number): {
|
|
5
|
+
promise: Promise<never>;
|
|
6
|
+
cancel: () => void;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Race a promise against a timeout
|
|
10
|
+
*/
|
|
11
|
+
export declare function withTimeout<T>(promise: Promise<T>, timeoutMs: number): Promise<T>;
|
|
12
|
+
//# sourceMappingURL=timeout.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"timeout.d.ts","sourceRoot":"","sources":["../../src/transport/timeout.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,SAAS,EAAE,MAAM,GAAG;IACvD,OAAO,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC;IACxB,MAAM,EAAE,MAAM,IAAI,CAAC;CACpB,CAcA;AAED;;GAEG;AACH,wBAAsB,WAAW,CAAC,CAAC,EACjC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,EACnB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,CAAC,CAAC,CAQZ"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { TimeoutError } from '../errors/TimeoutError.js';
|
|
2
|
+
/**
|
|
3
|
+
* Create a timeout promise that rejects after specified milliseconds
|
|
4
|
+
*/
|
|
5
|
+
export function createTimeoutPromise(timeoutMs) {
|
|
6
|
+
let timeoutId;
|
|
7
|
+
const promise = new Promise((_, reject) => {
|
|
8
|
+
timeoutId = setTimeout(() => {
|
|
9
|
+
reject(new TimeoutError(`Request timeout after ${timeoutMs}ms`, timeoutMs));
|
|
10
|
+
}, timeoutMs);
|
|
11
|
+
});
|
|
12
|
+
const cancel = () => {
|
|
13
|
+
clearTimeout(timeoutId);
|
|
14
|
+
};
|
|
15
|
+
return { promise, cancel };
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Race a promise against a timeout
|
|
19
|
+
*/
|
|
20
|
+
export async function withTimeout(promise, timeoutMs) {
|
|
21
|
+
const { promise: timeoutPromise, cancel } = createTimeoutPromise(timeoutMs);
|
|
22
|
+
try {
|
|
23
|
+
return await Promise.race([promise, timeoutPromise]);
|
|
24
|
+
}
|
|
25
|
+
finally {
|
|
26
|
+
cancel();
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=timeout.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"timeout.js","sourceRoot":"","sources":["../../src/transport/timeout.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEzD;;GAEG;AACH,MAAM,UAAU,oBAAoB,CAAC,SAAiB;IAIpD,IAAI,SAAwC,CAAC;IAE7C,MAAM,OAAO,GAAG,IAAI,OAAO,CAAQ,CAAC,CAAC,EAAE,MAAM,EAAE,EAAE;QAC/C,SAAS,GAAG,UAAU,CAAC,GAAG,EAAE;YAC1B,MAAM,CAAC,IAAI,YAAY,CAAC,yBAAyB,SAAS,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC;QAC9E,CAAC,EAAE,SAAS,CAAC,CAAC;IAChB,CAAC,CAAC,CAAC;IAEH,MAAM,MAAM,GAAG,GAAG,EAAE;QAClB,YAAY,CAAC,SAAS,CAAC,CAAC;IAC1B,CAAC,CAAC;IAEF,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC;AAC7B,CAAC;AAED;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,WAAW,CAC/B,OAAmB,EACnB,SAAiB;IAEjB,MAAM,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,EAAE,GAAG,oBAAoB,CAAC,SAAS,CAAC,CAAC;IAE5E,IAAI,CAAC;QACH,OAAO,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,cAAc,CAAC,CAAC,CAAC;IACvD,CAAC;YAAS,CAAC;QACT,MAAM,EAAE,CAAC;IACX,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Common utility types
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Make specific properties optional
|
|
6
|
+
*/
|
|
7
|
+
export type PartialBy<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
|
|
8
|
+
/**
|
|
9
|
+
* Make specific properties required
|
|
10
|
+
*/
|
|
11
|
+
export type RequiredBy<T, K extends keyof T> = Omit<T, K> & Required<Pick<T, K>>;
|
|
12
|
+
/**
|
|
13
|
+
* Deep partial type
|
|
14
|
+
*/
|
|
15
|
+
export type DeepPartial<T> = {
|
|
16
|
+
[P in keyof T]?: T[P] extends object ? DeepPartial<T[P]> : T[P];
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* Prettify type for better IDE display
|
|
20
|
+
*/
|
|
21
|
+
export type Prettify<T> = {
|
|
22
|
+
[K in keyof T]: T[K];
|
|
23
|
+
} & {};
|
|
24
|
+
//# sourceMappingURL=common.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.types.d.ts","sourceRoot":"","sources":["../../src/types/common.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,MAAM,MAAM,SAAS,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,IAAI,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAE/E;;GAEG;AACH,MAAM,MAAM,UAAU,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,IAAI,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAEjF;;GAEG;AACH,MAAM,MAAM,WAAW,CAAC,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAChE,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,QAAQ,CAAC,CAAC,IAAI;KACvB,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CACrB,GAAG,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.types.js","sourceRoot":"","sources":["../../src/types/common.types.ts"],"names":[],"mappings":"AAAA;;GAEG"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type { TokenProvider } from './token.types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Conversation SDK 客户端配置
|
|
4
|
+
*/
|
|
5
|
+
export interface ConversationClientConfig {
|
|
6
|
+
/**
|
|
7
|
+
* 环境(自动映射到对应的服务 URL)
|
|
8
|
+
*/
|
|
9
|
+
environment: 'dev' | 'prod';
|
|
10
|
+
/**
|
|
11
|
+
* 访问 token(必需)
|
|
12
|
+
*/
|
|
13
|
+
token: string;
|
|
14
|
+
/**
|
|
15
|
+
* Token 提供函数(可选,优先级高于 token)
|
|
16
|
+
*/
|
|
17
|
+
getToken?: TokenProvider;
|
|
18
|
+
/**
|
|
19
|
+
* 自定义 fetch 实现
|
|
20
|
+
*/
|
|
21
|
+
fetch?: typeof fetch;
|
|
22
|
+
/**
|
|
23
|
+
* 请求超时(毫秒)
|
|
24
|
+
* @default 30000
|
|
25
|
+
*/
|
|
26
|
+
timeout?: number;
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=config.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.types.d.ts","sourceRoot":"","sources":["../../src/types/config.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEtD;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC;;OAEG;IACH,WAAW,EAAE,KAAK,GAAG,MAAM,CAAC;IAE5B;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,QAAQ,CAAC,EAAE,aAAa,CAAC;IAEzB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,KAAK,CAAC;IAErB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.types.js","sourceRoot":"","sources":["../../src/types/config.types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* HTTP request configuration
|
|
3
|
+
*/
|
|
4
|
+
export interface HttpRequestConfig {
|
|
5
|
+
method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
|
|
6
|
+
headers?: Record<string, string>;
|
|
7
|
+
body?: unknown;
|
|
8
|
+
signal?: AbortSignal;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* HTTP response type
|
|
12
|
+
*/
|
|
13
|
+
export interface HttpResponse<T = unknown> {
|
|
14
|
+
data: T;
|
|
15
|
+
status: number;
|
|
16
|
+
statusText: string;
|
|
17
|
+
headers: Headers;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* HTTP request hook - called before request is sent
|
|
21
|
+
*/
|
|
22
|
+
export type OnRequestHook = (config: {
|
|
23
|
+
url: string;
|
|
24
|
+
method: string;
|
|
25
|
+
headers: Record<string, string>;
|
|
26
|
+
body?: unknown;
|
|
27
|
+
}) => void | Promise<void>;
|
|
28
|
+
/**
|
|
29
|
+
* HTTP response hook - called after response is received
|
|
30
|
+
*/
|
|
31
|
+
export type OnResponseHook = (response: {
|
|
32
|
+
url: string;
|
|
33
|
+
status: number;
|
|
34
|
+
statusText: string;
|
|
35
|
+
headers: Headers;
|
|
36
|
+
data: unknown;
|
|
37
|
+
}) => void | Promise<void>;
|
|
38
|
+
/**
|
|
39
|
+
* HTTP error hook - called when request fails
|
|
40
|
+
*/
|
|
41
|
+
export type OnErrorHook = (error: {
|
|
42
|
+
url: string;
|
|
43
|
+
message: string;
|
|
44
|
+
statusCode?: number;
|
|
45
|
+
details?: unknown;
|
|
46
|
+
}) => void | Promise<void>;
|
|
47
|
+
//# sourceMappingURL=http.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"http.types.d.ts","sourceRoot":"","sources":["../../src/types/http.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,MAAM,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAC;IACrD,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,MAAM,CAAC,EAAE,WAAW,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,YAAY,CAAC,CAAC,GAAG,OAAO;IACvC,IAAI,EAAE,CAAC,CAAC;IACR,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,MAAM,EAAE;IACnC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AAE3B;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,CAAC,QAAQ,EAAE;IACtC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,OAAO,CAAC;CACf,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AAE3B;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,KAAK,EAAE;IAChC,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"http.types.js","sourceRoot":"","sources":["../../src/types/http.types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export type { ConversationClientConfig } from './config.types.js';
|
|
2
|
+
export type { Conversation, Message, ToolCall, App, AppWithConversations, ListAppsWithConversationsResult, } from './models.types.js';
|
|
3
|
+
export type { PaginationMeta, PaginatedResult, PaginationOptions, } from './pagination.types.js';
|
|
4
|
+
export type { ListConversationsOptions, CreateConversationData, UpdateConversationData, } from '../resources/ConversationsResource.js';
|
|
5
|
+
export type { ListMessagesOptions, CreateMessageData, } from '../resources/MessagesResource.js';
|
|
6
|
+
export type { ListAppsOptions, } from '../resources/AppsResource.js';
|
|
7
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AACA,YAAY,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;AAGlE,YAAY,EACV,YAAY,EACZ,OAAO,EACP,QAAQ,EACR,GAAG,EACH,oBAAoB,EACpB,+BAA+B,GAChC,MAAM,mBAAmB,CAAC;AAG3B,YAAY,EACV,cAAc,EACd,eAAe,EACf,iBAAiB,GAClB,MAAM,uBAAuB,CAAC;AAG/B,YAAY,EACV,wBAAwB,EACxB,sBAAsB,EACtB,sBAAsB,GACvB,MAAM,uCAAuC,CAAC;AAE/C,YAAY,EACV,mBAAmB,EACnB,iBAAiB,GAClB,MAAM,kCAAkC,CAAC;AAE1C,YAAY,EACV,eAAe,GAChB,MAAM,8BAA8B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 前端业务模型(camelCase 格式)
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* 会话模型
|
|
6
|
+
*/
|
|
7
|
+
export interface Conversation {
|
|
8
|
+
id: string;
|
|
9
|
+
title: string;
|
|
10
|
+
appId: string | null;
|
|
11
|
+
userId: string;
|
|
12
|
+
createdAt: number;
|
|
13
|
+
updatedAt: number;
|
|
14
|
+
lastActiveAt: number;
|
|
15
|
+
messageCount?: number;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* 工具调用信息
|
|
19
|
+
*/
|
|
20
|
+
export interface ToolCall {
|
|
21
|
+
id: string;
|
|
22
|
+
toolName: string;
|
|
23
|
+
toolInput: Record<string, unknown>;
|
|
24
|
+
isCompleted: boolean;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* 消息模型(兼容旧 API 格式)
|
|
28
|
+
*/
|
|
29
|
+
export interface Message {
|
|
30
|
+
id: string;
|
|
31
|
+
conversationId?: string;
|
|
32
|
+
role?: 'user' | 'assistant' | 'system';
|
|
33
|
+
content?: string;
|
|
34
|
+
timestamp: number;
|
|
35
|
+
type?: 'text' | 'conversation_tips' | string;
|
|
36
|
+
tips?: string[];
|
|
37
|
+
toolCalls?: ToolCall[];
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* 应用模型(仅包含实际使用的字段)
|
|
41
|
+
*/
|
|
42
|
+
export interface App {
|
|
43
|
+
id: string;
|
|
44
|
+
name: string;
|
|
45
|
+
displayName: string;
|
|
46
|
+
description: string;
|
|
47
|
+
thumbnailUrls: string[];
|
|
48
|
+
userName: string;
|
|
49
|
+
version: string;
|
|
50
|
+
tags: string[] | null;
|
|
51
|
+
status: 'draft' | 'published' | 'archived';
|
|
52
|
+
positiveCount: number;
|
|
53
|
+
forkCount: number;
|
|
54
|
+
commentCount: number;
|
|
55
|
+
createdAt: number;
|
|
56
|
+
updatedAt: number;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* 应用与会话聚合结果
|
|
60
|
+
*/
|
|
61
|
+
export interface AppWithConversations {
|
|
62
|
+
app: App;
|
|
63
|
+
conversations: Conversation[];
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* 列表查询结果
|
|
67
|
+
*/
|
|
68
|
+
export interface ListAppsWithConversationsResult {
|
|
69
|
+
apps: AppWithConversations[];
|
|
70
|
+
hasMore: boolean;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* 数据库原始模型(snake_case 格式,内部使用)
|
|
74
|
+
*/
|
|
75
|
+
export declare namespace DbSchema {
|
|
76
|
+
interface Conversation {
|
|
77
|
+
conversation_id?: string;
|
|
78
|
+
id?: string;
|
|
79
|
+
app_id: string | null;
|
|
80
|
+
user_id: string;
|
|
81
|
+
title: string;
|
|
82
|
+
created_at: number;
|
|
83
|
+
updated_at: number;
|
|
84
|
+
last_message_created_at?: number;
|
|
85
|
+
message_count?: number;
|
|
86
|
+
}
|
|
87
|
+
interface Message {
|
|
88
|
+
message_id?: string;
|
|
89
|
+
id?: string;
|
|
90
|
+
conversation_id: string;
|
|
91
|
+
role: 'user' | 'assistant' | 'system';
|
|
92
|
+
content: string;
|
|
93
|
+
created_at: number;
|
|
94
|
+
metadata?: unknown;
|
|
95
|
+
}
|
|
96
|
+
interface App {
|
|
97
|
+
app_id?: string;
|
|
98
|
+
app_name?: string;
|
|
99
|
+
description?: string;
|
|
100
|
+
template?: string;
|
|
101
|
+
created_at?: string | number;
|
|
102
|
+
updated_at?: string | number;
|
|
103
|
+
metadata?: Record<string, unknown>;
|
|
104
|
+
user_id?: string;
|
|
105
|
+
id?: string;
|
|
106
|
+
name?: string;
|
|
107
|
+
display_name?: string;
|
|
108
|
+
thumbnail_urls?: string[];
|
|
109
|
+
user_name?: string;
|
|
110
|
+
version?: string;
|
|
111
|
+
tags?: string[] | null;
|
|
112
|
+
status?: 'draft' | 'published' | 'archived';
|
|
113
|
+
positive_count?: number;
|
|
114
|
+
fork_count?: number;
|
|
115
|
+
comment_count?: number;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
//# sourceMappingURL=models.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"models.types.d.ts","sourceRoot":"","sources":["../../src/types/models.types.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"models.types.js","sourceRoot":"","sources":["../../src/types/models.types.ts"],"names":[],"mappings":"AAAA;;GAEG"}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 分页元数据
|
|
3
|
+
*/
|
|
4
|
+
export interface PaginationMeta {
|
|
5
|
+
/**
|
|
6
|
+
* 总记录数
|
|
7
|
+
*/
|
|
8
|
+
total: number;
|
|
9
|
+
/**
|
|
10
|
+
* 当前页码(从 1 开始)
|
|
11
|
+
*/
|
|
12
|
+
page: number;
|
|
13
|
+
/**
|
|
14
|
+
* 每页数量
|
|
15
|
+
*/
|
|
16
|
+
pageSize: number;
|
|
17
|
+
/**
|
|
18
|
+
* 总页数
|
|
19
|
+
*/
|
|
20
|
+
totalPages: number;
|
|
21
|
+
/**
|
|
22
|
+
* 是否有下一页
|
|
23
|
+
*/
|
|
24
|
+
hasNextPage: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* 是否有上一页
|
|
27
|
+
*/
|
|
28
|
+
hasPreviousPage: boolean;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* 分页结果
|
|
32
|
+
*/
|
|
33
|
+
export interface PaginatedResult<T> {
|
|
34
|
+
/**
|
|
35
|
+
* 数据列表
|
|
36
|
+
*/
|
|
37
|
+
data: T[];
|
|
38
|
+
/**
|
|
39
|
+
* 分页元数据
|
|
40
|
+
*/
|
|
41
|
+
pagination: PaginationMeta;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* 分页选项(基于 page/pageSize)
|
|
45
|
+
*/
|
|
46
|
+
export interface PaginationOptions {
|
|
47
|
+
/**
|
|
48
|
+
* 页码(从 1 开始)
|
|
49
|
+
* @default 1
|
|
50
|
+
*/
|
|
51
|
+
page?: number;
|
|
52
|
+
/**
|
|
53
|
+
* 每页数量
|
|
54
|
+
* @default 20
|
|
55
|
+
*/
|
|
56
|
+
pageSize?: number;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* 计算分页元数据
|
|
60
|
+
*/
|
|
61
|
+
export declare function calculatePaginationMeta(total: number, page: number, pageSize: number): PaginationMeta;
|
|
62
|
+
/**
|
|
63
|
+
* 将 page/pageSize 转换为 limit/offset
|
|
64
|
+
*/
|
|
65
|
+
export declare function pageToOffset(page: number, pageSize: number): {
|
|
66
|
+
limit: number;
|
|
67
|
+
offset: number;
|
|
68
|
+
};
|
|
69
|
+
//# sourceMappingURL=pagination.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pagination.types.d.ts","sourceRoot":"","sources":["../../src/types/pagination.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,WAAW,EAAE,OAAO,CAAC;IAErB;;OAEG;IACH,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,WAAW,eAAe,CAAC,CAAC;IAChC;;OAEG;IACH,IAAI,EAAE,CAAC,EAAE,CAAC;IAEV;;OAEG;IACH,UAAU,EAAE,cAAc,CAAC;CAC5B;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,MAAM,EACb,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,GACf,cAAc,CAWhB;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAK9F"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 计算分页元数据
|
|
3
|
+
*/
|
|
4
|
+
export function calculatePaginationMeta(total, page, pageSize) {
|
|
5
|
+
const totalPages = Math.ceil(total / pageSize);
|
|
6
|
+
return {
|
|
7
|
+
total,
|
|
8
|
+
page,
|
|
9
|
+
pageSize,
|
|
10
|
+
totalPages,
|
|
11
|
+
hasNextPage: page < totalPages,
|
|
12
|
+
hasPreviousPage: page > 1,
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* 将 page/pageSize 转换为 limit/offset
|
|
17
|
+
*/
|
|
18
|
+
export function pageToOffset(page, pageSize) {
|
|
19
|
+
return {
|
|
20
|
+
limit: pageSize,
|
|
21
|
+
offset: (page - 1) * pageSize,
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
//# sourceMappingURL=pagination.types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pagination.types.js","sourceRoot":"","sources":["../../src/types/pagination.types.ts"],"names":[],"mappings":"AAmEA;;GAEG;AACH,MAAM,UAAU,uBAAuB,CACrC,KAAa,EACb,IAAY,EACZ,QAAgB;IAEhB,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC,CAAC;IAE/C,OAAO;QACL,KAAK;QACL,IAAI;QACJ,QAAQ;QACR,UAAU;QACV,WAAW,EAAE,IAAI,GAAG,UAAU;QAC9B,eAAe,EAAE,IAAI,GAAG,CAAC;KAC1B,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,YAAY,CAAC,IAAY,EAAE,QAAgB;IACzD,OAAO;QACL,KAAK,EAAE,QAAQ;QACf,MAAM,EAAE,CAAC,IAAI,GAAG,CAAC,CAAC,GAAG,QAAQ;KAC9B,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token.types.d.ts","sourceRoot":"","sources":["../../src/types/token.types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,MAAM,aAAa,GAAG,MAAM,MAAM,GAAG,IAAI,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token.types.js","sourceRoot":"","sources":["../../src/types/token.types.ts"],"names":[],"mappings":""}
|
package/package.json
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@seaverse/conversation-sdk",
|
|
3
|
+
"version": "0.2.0",
|
|
4
|
+
"description": "SeaVerse Conversation SDK - SDK for conversations and messages management",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./dist/index.js",
|
|
7
|
+
"module": "./dist/index.js",
|
|
8
|
+
"types": "./dist/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"types": "./dist/index.d.ts",
|
|
12
|
+
"import": "./dist/index.js"
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
"files": [
|
|
16
|
+
"dist",
|
|
17
|
+
"README.md"
|
|
18
|
+
],
|
|
19
|
+
"scripts": {
|
|
20
|
+
"build": "tsc",
|
|
21
|
+
"typecheck": "tsc --noEmit",
|
|
22
|
+
"clean": "rm -rf dist"
|
|
23
|
+
},
|
|
24
|
+
"keywords": [
|
|
25
|
+
"seaverse",
|
|
26
|
+
"conversation",
|
|
27
|
+
"sdk",
|
|
28
|
+
"conversations",
|
|
29
|
+
"messages",
|
|
30
|
+
"apps"
|
|
31
|
+
],
|
|
32
|
+
"author": "SeaVerse",
|
|
33
|
+
"license": "MIT",
|
|
34
|
+
"dependencies": {},
|
|
35
|
+
"devDependencies": {
|
|
36
|
+
"typescript": "^5.3.0"
|
|
37
|
+
}
|
|
38
|
+
}
|