@4players/odin-common 1.7.1 → 2.1.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/lib/cjs/schema/media.js +2 -0
- package/lib/esm/schema/media.js +2 -0
- package/lib/plugin/api.d.ts +18 -1
- package/lib/rpc/commands.d.ts +14 -0
- package/lib/rpc/notifications.d.ts +236 -0
- package/lib/schema/media.d.ts +26 -0
- package/lib/schema/peer.d.ts +44 -0
- package/lib/schema/room.d.ts +182 -0
- package/package.json +1 -1
package/lib/schema/media.d.ts
CHANGED
|
@@ -4,49 +4,61 @@ export type MediaId = z.infer<typeof MediaIdSchema>;
|
|
|
4
4
|
export declare const MediaAudioPropertiesSchema: z.ZodObject<{
|
|
5
5
|
kind: z.ZodOptional<z.ZodLiteral<"audio">>;
|
|
6
6
|
uid: z.ZodOptional<z.ZodString>;
|
|
7
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
7
8
|
}, "strip", z.ZodTypeAny, {
|
|
8
9
|
kind?: "audio" | undefined;
|
|
9
10
|
uid?: string | undefined;
|
|
11
|
+
customType?: string | undefined;
|
|
10
12
|
}, {
|
|
11
13
|
kind?: "audio" | undefined;
|
|
12
14
|
uid?: string | undefined;
|
|
15
|
+
customType?: string | undefined;
|
|
13
16
|
}>;
|
|
14
17
|
export type MediaAudioProperties = z.infer<typeof MediaAudioPropertiesSchema>;
|
|
15
18
|
export declare const MediaVideoPropertiesSchema: z.ZodObject<{
|
|
16
19
|
kind: z.ZodOptional<z.ZodLiteral<"video">>;
|
|
17
20
|
codec: z.ZodOptional<z.ZodString>;
|
|
18
21
|
uid: z.ZodOptional<z.ZodString>;
|
|
22
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
19
23
|
}, "strip", z.ZodTypeAny, {
|
|
20
24
|
kind?: "video" | undefined;
|
|
21
25
|
codec?: string | undefined;
|
|
22
26
|
uid?: string | undefined;
|
|
27
|
+
customType?: string | undefined;
|
|
23
28
|
}, {
|
|
24
29
|
kind?: "video" | undefined;
|
|
25
30
|
codec?: string | undefined;
|
|
26
31
|
uid?: string | undefined;
|
|
32
|
+
customType?: string | undefined;
|
|
27
33
|
}>;
|
|
28
34
|
export type MediaVideoProperties = z.infer<typeof MediaVideoPropertiesSchema>;
|
|
29
35
|
export declare const MediaPropertiesSchema: z.ZodUnion<[z.ZodObject<{
|
|
30
36
|
kind: z.ZodOptional<z.ZodLiteral<"audio">>;
|
|
31
37
|
uid: z.ZodOptional<z.ZodString>;
|
|
38
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
32
39
|
}, "strip", z.ZodTypeAny, {
|
|
33
40
|
kind?: "audio" | undefined;
|
|
34
41
|
uid?: string | undefined;
|
|
42
|
+
customType?: string | undefined;
|
|
35
43
|
}, {
|
|
36
44
|
kind?: "audio" | undefined;
|
|
37
45
|
uid?: string | undefined;
|
|
46
|
+
customType?: string | undefined;
|
|
38
47
|
}>, z.ZodObject<{
|
|
39
48
|
kind: z.ZodOptional<z.ZodLiteral<"video">>;
|
|
40
49
|
codec: z.ZodOptional<z.ZodString>;
|
|
41
50
|
uid: z.ZodOptional<z.ZodString>;
|
|
51
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
42
52
|
}, "strip", z.ZodTypeAny, {
|
|
43
53
|
kind?: "video" | undefined;
|
|
44
54
|
codec?: string | undefined;
|
|
45
55
|
uid?: string | undefined;
|
|
56
|
+
customType?: string | undefined;
|
|
46
57
|
}, {
|
|
47
58
|
kind?: "video" | undefined;
|
|
48
59
|
codec?: string | undefined;
|
|
49
60
|
uid?: string | undefined;
|
|
61
|
+
customType?: string | undefined;
|
|
50
62
|
}>]>;
|
|
51
63
|
export type MediaProperties = z.infer<typeof MediaPropertiesSchema>;
|
|
52
64
|
export declare const MediaSchema: z.ZodObject<{
|
|
@@ -54,24 +66,30 @@ export declare const MediaSchema: z.ZodObject<{
|
|
|
54
66
|
properties: z.ZodUnion<[z.ZodObject<{
|
|
55
67
|
kind: z.ZodOptional<z.ZodLiteral<"audio">>;
|
|
56
68
|
uid: z.ZodOptional<z.ZodString>;
|
|
69
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
57
70
|
}, "strip", z.ZodTypeAny, {
|
|
58
71
|
kind?: "audio" | undefined;
|
|
59
72
|
uid?: string | undefined;
|
|
73
|
+
customType?: string | undefined;
|
|
60
74
|
}, {
|
|
61
75
|
kind?: "audio" | undefined;
|
|
62
76
|
uid?: string | undefined;
|
|
77
|
+
customType?: string | undefined;
|
|
63
78
|
}>, z.ZodObject<{
|
|
64
79
|
kind: z.ZodOptional<z.ZodLiteral<"video">>;
|
|
65
80
|
codec: z.ZodOptional<z.ZodString>;
|
|
66
81
|
uid: z.ZodOptional<z.ZodString>;
|
|
82
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
67
83
|
}, "strip", z.ZodTypeAny, {
|
|
68
84
|
kind?: "video" | undefined;
|
|
69
85
|
codec?: string | undefined;
|
|
70
86
|
uid?: string | undefined;
|
|
87
|
+
customType?: string | undefined;
|
|
71
88
|
}, {
|
|
72
89
|
kind?: "video" | undefined;
|
|
73
90
|
codec?: string | undefined;
|
|
74
91
|
uid?: string | undefined;
|
|
92
|
+
customType?: string | undefined;
|
|
75
93
|
}>]>;
|
|
76
94
|
paused: z.ZodBoolean;
|
|
77
95
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -79,17 +97,21 @@ export declare const MediaSchema: z.ZodObject<{
|
|
|
79
97
|
properties: ({
|
|
80
98
|
kind?: "audio" | undefined;
|
|
81
99
|
uid?: string | undefined;
|
|
100
|
+
customType?: string | undefined;
|
|
82
101
|
} | {
|
|
83
102
|
kind?: "video" | undefined;
|
|
84
103
|
codec?: string | undefined;
|
|
85
104
|
uid?: string | undefined;
|
|
105
|
+
customType?: string | undefined;
|
|
86
106
|
}) & ({
|
|
87
107
|
kind?: "audio" | undefined;
|
|
88
108
|
uid?: string | undefined;
|
|
109
|
+
customType?: string | undefined;
|
|
89
110
|
} | {
|
|
90
111
|
kind?: "video" | undefined;
|
|
91
112
|
codec?: string | undefined;
|
|
92
113
|
uid?: string | undefined;
|
|
114
|
+
customType?: string | undefined;
|
|
93
115
|
} | undefined);
|
|
94
116
|
paused: boolean;
|
|
95
117
|
}, {
|
|
@@ -97,17 +119,21 @@ export declare const MediaSchema: z.ZodObject<{
|
|
|
97
119
|
properties: ({
|
|
98
120
|
kind?: "audio" | undefined;
|
|
99
121
|
uid?: string | undefined;
|
|
122
|
+
customType?: string | undefined;
|
|
100
123
|
} | {
|
|
101
124
|
kind?: "video" | undefined;
|
|
102
125
|
codec?: string | undefined;
|
|
103
126
|
uid?: string | undefined;
|
|
127
|
+
customType?: string | undefined;
|
|
104
128
|
}) & ({
|
|
105
129
|
kind?: "audio" | undefined;
|
|
106
130
|
uid?: string | undefined;
|
|
131
|
+
customType?: string | undefined;
|
|
107
132
|
} | {
|
|
108
133
|
kind?: "video" | undefined;
|
|
109
134
|
codec?: string | undefined;
|
|
110
135
|
uid?: string | undefined;
|
|
136
|
+
customType?: string | undefined;
|
|
111
137
|
} | undefined);
|
|
112
138
|
paused: boolean;
|
|
113
139
|
}>;
|
package/lib/schema/peer.d.ts
CHANGED
|
@@ -12,24 +12,30 @@ export declare const PeerSchema: z.ZodObject<{
|
|
|
12
12
|
properties: z.ZodUnion<[z.ZodObject<{
|
|
13
13
|
kind: z.ZodOptional<z.ZodLiteral<"audio">>;
|
|
14
14
|
uid: z.ZodOptional<z.ZodString>;
|
|
15
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
15
16
|
}, "strip", z.ZodTypeAny, {
|
|
16
17
|
kind?: "audio" | undefined;
|
|
17
18
|
uid?: string | undefined;
|
|
19
|
+
customType?: string | undefined;
|
|
18
20
|
}, {
|
|
19
21
|
kind?: "audio" | undefined;
|
|
20
22
|
uid?: string | undefined;
|
|
23
|
+
customType?: string | undefined;
|
|
21
24
|
}>, z.ZodObject<{
|
|
22
25
|
kind: z.ZodOptional<z.ZodLiteral<"video">>;
|
|
23
26
|
codec: z.ZodOptional<z.ZodString>;
|
|
24
27
|
uid: z.ZodOptional<z.ZodString>;
|
|
28
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
25
29
|
}, "strip", z.ZodTypeAny, {
|
|
26
30
|
kind?: "video" | undefined;
|
|
27
31
|
codec?: string | undefined;
|
|
28
32
|
uid?: string | undefined;
|
|
33
|
+
customType?: string | undefined;
|
|
29
34
|
}, {
|
|
30
35
|
kind?: "video" | undefined;
|
|
31
36
|
codec?: string | undefined;
|
|
32
37
|
uid?: string | undefined;
|
|
38
|
+
customType?: string | undefined;
|
|
33
39
|
}>]>;
|
|
34
40
|
paused: z.ZodBoolean;
|
|
35
41
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -37,17 +43,21 @@ export declare const PeerSchema: z.ZodObject<{
|
|
|
37
43
|
properties: ({
|
|
38
44
|
kind?: "audio" | undefined;
|
|
39
45
|
uid?: string | undefined;
|
|
46
|
+
customType?: string | undefined;
|
|
40
47
|
} | {
|
|
41
48
|
kind?: "video" | undefined;
|
|
42
49
|
codec?: string | undefined;
|
|
43
50
|
uid?: string | undefined;
|
|
51
|
+
customType?: string | undefined;
|
|
44
52
|
}) & ({
|
|
45
53
|
kind?: "audio" | undefined;
|
|
46
54
|
uid?: string | undefined;
|
|
55
|
+
customType?: string | undefined;
|
|
47
56
|
} | {
|
|
48
57
|
kind?: "video" | undefined;
|
|
49
58
|
codec?: string | undefined;
|
|
50
59
|
uid?: string | undefined;
|
|
60
|
+
customType?: string | undefined;
|
|
51
61
|
} | undefined);
|
|
52
62
|
paused: boolean;
|
|
53
63
|
}, {
|
|
@@ -55,17 +65,21 @@ export declare const PeerSchema: z.ZodObject<{
|
|
|
55
65
|
properties: ({
|
|
56
66
|
kind?: "audio" | undefined;
|
|
57
67
|
uid?: string | undefined;
|
|
68
|
+
customType?: string | undefined;
|
|
58
69
|
} | {
|
|
59
70
|
kind?: "video" | undefined;
|
|
60
71
|
codec?: string | undefined;
|
|
61
72
|
uid?: string | undefined;
|
|
73
|
+
customType?: string | undefined;
|
|
62
74
|
}) & ({
|
|
63
75
|
kind?: "audio" | undefined;
|
|
64
76
|
uid?: string | undefined;
|
|
77
|
+
customType?: string | undefined;
|
|
65
78
|
} | {
|
|
66
79
|
kind?: "video" | undefined;
|
|
67
80
|
codec?: string | undefined;
|
|
68
81
|
uid?: string | undefined;
|
|
82
|
+
customType?: string | undefined;
|
|
69
83
|
} | undefined);
|
|
70
84
|
paused: boolean;
|
|
71
85
|
}>, "many">;
|
|
@@ -78,17 +92,21 @@ export declare const PeerSchema: z.ZodObject<{
|
|
|
78
92
|
properties: ({
|
|
79
93
|
kind?: "audio" | undefined;
|
|
80
94
|
uid?: string | undefined;
|
|
95
|
+
customType?: string | undefined;
|
|
81
96
|
} | {
|
|
82
97
|
kind?: "video" | undefined;
|
|
83
98
|
codec?: string | undefined;
|
|
84
99
|
uid?: string | undefined;
|
|
100
|
+
customType?: string | undefined;
|
|
85
101
|
}) & ({
|
|
86
102
|
kind?: "audio" | undefined;
|
|
87
103
|
uid?: string | undefined;
|
|
104
|
+
customType?: string | undefined;
|
|
88
105
|
} | {
|
|
89
106
|
kind?: "video" | undefined;
|
|
90
107
|
codec?: string | undefined;
|
|
91
108
|
uid?: string | undefined;
|
|
109
|
+
customType?: string | undefined;
|
|
92
110
|
} | undefined);
|
|
93
111
|
paused: boolean;
|
|
94
112
|
}[];
|
|
@@ -101,17 +119,21 @@ export declare const PeerSchema: z.ZodObject<{
|
|
|
101
119
|
properties: ({
|
|
102
120
|
kind?: "audio" | undefined;
|
|
103
121
|
uid?: string | undefined;
|
|
122
|
+
customType?: string | undefined;
|
|
104
123
|
} | {
|
|
105
124
|
kind?: "video" | undefined;
|
|
106
125
|
codec?: string | undefined;
|
|
107
126
|
uid?: string | undefined;
|
|
127
|
+
customType?: string | undefined;
|
|
108
128
|
}) & ({
|
|
109
129
|
kind?: "audio" | undefined;
|
|
110
130
|
uid?: string | undefined;
|
|
131
|
+
customType?: string | undefined;
|
|
111
132
|
} | {
|
|
112
133
|
kind?: "video" | undefined;
|
|
113
134
|
codec?: string | undefined;
|
|
114
135
|
uid?: string | undefined;
|
|
136
|
+
customType?: string | undefined;
|
|
115
137
|
} | undefined);
|
|
116
138
|
paused: boolean;
|
|
117
139
|
}[];
|
|
@@ -137,24 +159,30 @@ export declare const PeerUpdateSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodObj
|
|
|
137
159
|
properties: z.ZodUnion<[z.ZodObject<{
|
|
138
160
|
kind: z.ZodOptional<z.ZodLiteral<"audio">>;
|
|
139
161
|
uid: z.ZodOptional<z.ZodString>;
|
|
162
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
140
163
|
}, "strip", z.ZodTypeAny, {
|
|
141
164
|
kind?: "audio" | undefined;
|
|
142
165
|
uid?: string | undefined;
|
|
166
|
+
customType?: string | undefined;
|
|
143
167
|
}, {
|
|
144
168
|
kind?: "audio" | undefined;
|
|
145
169
|
uid?: string | undefined;
|
|
170
|
+
customType?: string | undefined;
|
|
146
171
|
}>, z.ZodObject<{
|
|
147
172
|
kind: z.ZodOptional<z.ZodLiteral<"video">>;
|
|
148
173
|
codec: z.ZodOptional<z.ZodString>;
|
|
149
174
|
uid: z.ZodOptional<z.ZodString>;
|
|
175
|
+
customType: z.ZodOptional<z.ZodString>;
|
|
150
176
|
}, "strip", z.ZodTypeAny, {
|
|
151
177
|
kind?: "video" | undefined;
|
|
152
178
|
codec?: string | undefined;
|
|
153
179
|
uid?: string | undefined;
|
|
180
|
+
customType?: string | undefined;
|
|
154
181
|
}, {
|
|
155
182
|
kind?: "video" | undefined;
|
|
156
183
|
codec?: string | undefined;
|
|
157
184
|
uid?: string | undefined;
|
|
185
|
+
customType?: string | undefined;
|
|
158
186
|
}>]>;
|
|
159
187
|
paused: z.ZodBoolean;
|
|
160
188
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -162,17 +190,21 @@ export declare const PeerUpdateSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodObj
|
|
|
162
190
|
properties: ({
|
|
163
191
|
kind?: "audio" | undefined;
|
|
164
192
|
uid?: string | undefined;
|
|
193
|
+
customType?: string | undefined;
|
|
165
194
|
} | {
|
|
166
195
|
kind?: "video" | undefined;
|
|
167
196
|
codec?: string | undefined;
|
|
168
197
|
uid?: string | undefined;
|
|
198
|
+
customType?: string | undefined;
|
|
169
199
|
}) & ({
|
|
170
200
|
kind?: "audio" | undefined;
|
|
171
201
|
uid?: string | undefined;
|
|
202
|
+
customType?: string | undefined;
|
|
172
203
|
} | {
|
|
173
204
|
kind?: "video" | undefined;
|
|
174
205
|
codec?: string | undefined;
|
|
175
206
|
uid?: string | undefined;
|
|
207
|
+
customType?: string | undefined;
|
|
176
208
|
} | undefined);
|
|
177
209
|
paused: boolean;
|
|
178
210
|
}, {
|
|
@@ -180,17 +212,21 @@ export declare const PeerUpdateSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodObj
|
|
|
180
212
|
properties: ({
|
|
181
213
|
kind?: "audio" | undefined;
|
|
182
214
|
uid?: string | undefined;
|
|
215
|
+
customType?: string | undefined;
|
|
183
216
|
} | {
|
|
184
217
|
kind?: "video" | undefined;
|
|
185
218
|
codec?: string | undefined;
|
|
186
219
|
uid?: string | undefined;
|
|
220
|
+
customType?: string | undefined;
|
|
187
221
|
}) & ({
|
|
188
222
|
kind?: "audio" | undefined;
|
|
189
223
|
uid?: string | undefined;
|
|
224
|
+
customType?: string | undefined;
|
|
190
225
|
} | {
|
|
191
226
|
kind?: "video" | undefined;
|
|
192
227
|
codec?: string | undefined;
|
|
193
228
|
uid?: string | undefined;
|
|
229
|
+
customType?: string | undefined;
|
|
194
230
|
} | undefined);
|
|
195
231
|
paused: boolean;
|
|
196
232
|
}>;
|
|
@@ -202,17 +238,21 @@ export declare const PeerUpdateSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodObj
|
|
|
202
238
|
properties: ({
|
|
203
239
|
kind?: "audio" | undefined;
|
|
204
240
|
uid?: string | undefined;
|
|
241
|
+
customType?: string | undefined;
|
|
205
242
|
} | {
|
|
206
243
|
kind?: "video" | undefined;
|
|
207
244
|
codec?: string | undefined;
|
|
208
245
|
uid?: string | undefined;
|
|
246
|
+
customType?: string | undefined;
|
|
209
247
|
}) & ({
|
|
210
248
|
kind?: "audio" | undefined;
|
|
211
249
|
uid?: string | undefined;
|
|
250
|
+
customType?: string | undefined;
|
|
212
251
|
} | {
|
|
213
252
|
kind?: "video" | undefined;
|
|
214
253
|
codec?: string | undefined;
|
|
215
254
|
uid?: string | undefined;
|
|
255
|
+
customType?: string | undefined;
|
|
216
256
|
} | undefined);
|
|
217
257
|
paused: boolean;
|
|
218
258
|
};
|
|
@@ -224,17 +264,21 @@ export declare const PeerUpdateSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodObj
|
|
|
224
264
|
properties: ({
|
|
225
265
|
kind?: "audio" | undefined;
|
|
226
266
|
uid?: string | undefined;
|
|
267
|
+
customType?: string | undefined;
|
|
227
268
|
} | {
|
|
228
269
|
kind?: "video" | undefined;
|
|
229
270
|
codec?: string | undefined;
|
|
230
271
|
uid?: string | undefined;
|
|
272
|
+
customType?: string | undefined;
|
|
231
273
|
}) & ({
|
|
232
274
|
kind?: "audio" | undefined;
|
|
233
275
|
uid?: string | undefined;
|
|
276
|
+
customType?: string | undefined;
|
|
234
277
|
} | {
|
|
235
278
|
kind?: "video" | undefined;
|
|
236
279
|
codec?: string | undefined;
|
|
237
280
|
uid?: string | undefined;
|
|
281
|
+
customType?: string | undefined;
|
|
238
282
|
} | undefined);
|
|
239
283
|
paused: boolean;
|
|
240
284
|
};
|