@d-id/client-sdk 1.1.11 → 1.1.12-staging.48
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/index.js +546 -670
- package/dist/index.umd.cjs +1 -1
- package/dist/src/api/agents.d.ts +1 -0
- package/dist/src/api/apiClient.d.ts +4 -3
- package/dist/src/api/knowledge.d.ts +1 -0
- package/dist/src/api/streams/streamApi.d.ts +1 -0
- package/dist/src/api/streams/streamsApiV2.d.ts +5 -0
- package/dist/src/auth/get-auth-header.d.ts +1 -0
- package/dist/src/errors/chat/chat-creation-failed.d.ts +1 -0
- package/dist/src/errors/chat/chat-mode-downgraded.d.ts +1 -0
- package/dist/src/errors/validation-error.d.ts +1 -0
- package/dist/src/errors/ws-error.d.ts +1 -0
- package/dist/src/services/agent-manager/connect-to-manager.d.ts +1 -0
- package/dist/src/services/agent-manager/connect-to-manager.test.d.ts +1 -0
- package/dist/src/services/agent-manager/index.d.ts +1 -0
- package/dist/src/services/agent-manager/index.test.d.ts +1 -0
- package/dist/src/services/analytics/mixpanel.d.ts +1 -0
- package/dist/src/services/chat/index.d.ts +2 -2
- package/dist/src/services/chat/intial-messages.d.ts +1 -0
- package/dist/src/services/interrupt/index.d.ts +1 -0
- package/dist/src/services/socket-manager/index.d.ts +1 -0
- package/dist/src/services/socket-manager/message-queue.d.ts +1 -0
- package/dist/src/services/streaming-manager/advanced.test.d.ts +5 -0
- package/dist/src/services/streaming-manager/business-flows.test.d.ts +5 -0
- package/dist/src/services/streaming-manager/common.d.ts +43 -0
- package/dist/src/services/streaming-manager/disconnect.test.d.ts +5 -0
- package/dist/src/services/streaming-manager/edge-cases.test.d.ts +5 -0
- package/dist/src/services/streaming-manager/factory.d.ts +3 -0
- package/dist/src/services/streaming-manager/factory.test.d.ts +1 -0
- package/dist/src/services/streaming-manager/index.d.ts +3 -27
- package/dist/src/services/streaming-manager/livekit-manager.d.ts +5 -0
- package/dist/src/services/streaming-manager/stats/poll.d.ts +1 -1
- package/dist/src/services/streaming-manager/stats/report.d.ts +1 -0
- package/dist/src/services/streaming-manager/webrtc-core.test.d.ts +5 -0
- package/dist/src/services/streaming-manager/webrtc-manager.d.ts +12 -0
- package/dist/src/services/streaming-manager/webrtc-utils.test.d.ts +5 -0
- package/dist/src/test-utils/factories/agent-manager.factory.d.ts +3 -0
- package/dist/src/test-utils/factories/agent.factory.d.ts +4 -0
- package/dist/src/test-utils/factories/agents-api.factory.d.ts +1 -0
- package/dist/src/test-utils/factories/analytics.factory.d.ts +1 -0
- package/dist/src/test-utils/factories/chat.factory.d.ts +1 -0
- package/dist/src/test-utils/factories/index.d.ts +8 -0
- package/dist/src/test-utils/factories/socket-manager.factory.d.ts +1 -0
- package/dist/src/test-utils/factories/stream-api.factory.d.ts +1 -0
- package/dist/src/test-utils/factories/streaming-manager.factory.d.ts +4 -0
- package/dist/src/types/entities/agents/agent.d.ts +1 -0
- package/dist/src/types/entities/agents/manager.d.ts +7 -1
- package/dist/src/types/entities/agents/presenter.d.ts +6 -2
- package/dist/src/types/entities/knowledge/document.d.ts +1 -0
- package/dist/src/types/entities/knowledge/record.d.ts +1 -0
- package/dist/src/types/entities/video.d.ts +2 -1
- package/dist/src/types/stream/api/clip.d.ts +1 -0
- package/dist/src/types/stream/api/talk.d.ts +1 -0
- package/dist/src/types/stream/index.d.ts +1 -0
- package/dist/src/types/stream/rtc.d.ts +1 -0
- package/dist/src/types/stream/stream.d.ts +1 -0
- package/dist/src/types/stream/streams-v2.d.ts +12 -0
- package/dist/src/types/stream-script.d.ts +1 -0
- package/dist/src/utils/agent.d.ts +2 -1
- package/dist/src/utils/analytics.d.ts +3 -2
- package/dist/src/utils/chat.d.ts +1 -0
- package/package.json +21 -2
|
@@ -3,6 +3,7 @@ import { VideoRTCStatsReport } from '../../services/streaming-manager/stats/repo
|
|
|
3
3
|
import { Auth } from '../auth';
|
|
4
4
|
import { CreateClipStreamRequest, CreateTalkStreamRequest, SendClipStreamPayload, SendTalkStreamPayload } from './api';
|
|
5
5
|
import { ICreateStreamRequestResponse, IceCandidate, SendStreamPayloadResponse, Status } from './rtc';
|
|
6
|
+
|
|
6
7
|
export type CompatibilityMode = 'on' | 'off' | 'auto';
|
|
7
8
|
export declare enum StreamingState {
|
|
8
9
|
Start = "START",
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare enum Transport {
|
|
2
|
+
Livekit = "livekit"
|
|
3
|
+
}
|
|
4
|
+
export interface CreateStreamV2Options {
|
|
5
|
+
transport: Transport.Livekit;
|
|
6
|
+
}
|
|
7
|
+
export interface CreateStreamV2Response {
|
|
8
|
+
agent_id: 'string';
|
|
9
|
+
session_id: 'string';
|
|
10
|
+
session_url: 'string';
|
|
11
|
+
session_token: 'string';
|
|
12
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Agent } from '../types';
|
|
2
|
+
|
|
2
3
|
type AgentType = 'clip_v2' | Agent['presenter']['type'];
|
|
3
|
-
export declare const getAgentType: (presenter: Agent[
|
|
4
|
+
export declare const getAgentType: (presenter: Agent["presenter"]) => AgentType;
|
|
4
5
|
export {};
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { Agent } from '../types/index';
|
|
2
|
+
|
|
2
3
|
export declare function getAnalyticsInfo(agent: Agent): {
|
|
3
4
|
$os: string;
|
|
4
5
|
isMobile: string;
|
|
5
6
|
browser: string;
|
|
6
7
|
origin: string;
|
|
7
|
-
agentType: "talk" | "clip" | "clip_v2";
|
|
8
|
+
agentType: "talk" | "clip" | "expressive" | "clip_v2";
|
|
8
9
|
agentVoice: {
|
|
9
10
|
voiceId: string | undefined;
|
|
10
11
|
provider: import('../types/index').Providers | undefined;
|
|
@@ -12,7 +13,7 @@ export declare function getAnalyticsInfo(agent: Agent): {
|
|
|
12
13
|
};
|
|
13
14
|
export declare function getAgentInfo(agent: Agent): {
|
|
14
15
|
from?: string | undefined;
|
|
15
|
-
agentType: "talk" | "clip" | "clip_v2";
|
|
16
|
+
agentType: "talk" | "clip" | "expressive" | "clip_v2";
|
|
16
17
|
owner_id: string;
|
|
17
18
|
promptVersion: "v1" | "v2" | null | undefined;
|
|
18
19
|
behavior: {
|
package/dist/src/utils/chat.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@d-id/client-sdk",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.12-staging.48",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "d-id client sdk",
|
|
7
7
|
"repository": {
|
|
@@ -29,17 +29,36 @@
|
|
|
29
29
|
"deploy:prod": "node ./infra/deploy.js --version beta",
|
|
30
30
|
"preview": "vite preview",
|
|
31
31
|
"test-build": "node .infra/build.js -m development",
|
|
32
|
-
"build:docs": "typedoc"
|
|
32
|
+
"build:docs": "typedoc",
|
|
33
|
+
"test": "jest",
|
|
34
|
+
"test:watch": "jest --watch",
|
|
35
|
+
"test:ci": "jest --watchAll=false --passWithNoTests --verbose=false",
|
|
36
|
+
"type-check": "tsc --noEmit",
|
|
37
|
+
"lint": "prettier --check \"src/**/*.{ts,tsx,js,jsx}\"",
|
|
38
|
+
"lint:fix": "prettier --write \"src/**/*.{ts,tsx,js,jsx}\"",
|
|
39
|
+
"ci:test": "yarn type-check && yarn test:ci"
|
|
40
|
+
},
|
|
41
|
+
"dependencies": {
|
|
42
|
+
"livekit-client": "^2.0.0"
|
|
33
43
|
},
|
|
34
44
|
"devDependencies": {
|
|
35
45
|
"@preact/preset-vite": "^2.8.1",
|
|
36
46
|
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
|
|
47
|
+
"@types/jest": "^30.0.0",
|
|
37
48
|
"@types/node": "^22.15.0",
|
|
49
|
+
"@types/rosie": "^0.0.45",
|
|
38
50
|
"commander": "^11.1.0",
|
|
39
51
|
"glob": "^10.3.10",
|
|
52
|
+
"jest": "^29.7.0",
|
|
53
|
+
"jest-environment-jsdom": "^29.7.0",
|
|
40
54
|
"preact": "^10.19.6",
|
|
41
55
|
"prettier": "^3.2.5",
|
|
42
56
|
"prettier-plugin-organize-imports": "^3.2.4",
|
|
57
|
+
"rosie": "^2.1.1",
|
|
58
|
+
"string-length": "^4.0.2",
|
|
59
|
+
"string-width": "^4.2.3",
|
|
60
|
+
"strip-ansi": "^6.0.1",
|
|
61
|
+
"ts-jest": "^29.4.1",
|
|
43
62
|
"typedoc": "^0.25.7",
|
|
44
63
|
"typescript": "^5.3.3",
|
|
45
64
|
"vite": "^5.1.4",
|