@volter/twin-livekit 0.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/LICENSE +202 -0
- package/README.md +106 -0
- package/dist/src/cli.d.ts +2 -0
- package/dist/src/cli.js +23 -0
- package/dist/src/egress-service-cli.d.ts +2 -0
- package/dist/src/egress-service-cli.js +101 -0
- package/dist/src/index.d.ts +14 -0
- package/dist/src/index.js +53 -0
- package/dist/src/livekit-budget.d.ts +57 -0
- package/dist/src/livekit-budget.js +131 -0
- package/dist/src/livekit-capabilities.d.ts +3 -0
- package/dist/src/livekit-capabilities.js +728 -0
- package/dist/src/livekit-conformance.d.ts +8 -0
- package/dist/src/livekit-conformance.js +13 -0
- package/dist/src/livekit-connector.d.ts +130 -0
- package/dist/src/livekit-connector.js +382 -0
- package/dist/src/livekit-data.d.ts +86 -0
- package/dist/src/livekit-data.js +246 -0
- package/dist/src/livekit-perform-harness.d.ts +5 -0
- package/dist/src/livekit-perform-harness.js +17 -0
- package/dist/src/livekit-server.d.ts +23 -0
- package/dist/src/livekit-server.js +45 -0
- package/dist/src/livekit-service-cli.d.ts +2 -0
- package/dist/src/livekit-service-cli.js +88 -0
- package/dist/src/livekit-token.d.ts +68 -0
- package/dist/src/livekit-token.js +76 -0
- package/dist/src/livekit-twin.d.ts +4 -0
- package/dist/src/livekit-twin.js +1161 -0
- package/dist/src/livekit-types.d.ts +203 -0
- package/dist/src/livekit-types.js +1 -0
- package/dist/src/livekit-webhook.d.ts +26 -0
- package/dist/src/livekit-webhook.js +79 -0
- package/dist/src/redis-service-cli.d.ts +2 -0
- package/dist/src/redis-service-cli.js +35 -0
- package/dist/test-fixtures/livekit-openapi-operations.SOURCE.md +88 -0
- package/dist/test-fixtures/livekit-openapi-operations.json +442 -0
- package/dist/test-fixtures/protobufs/cloud_replay.proto +82 -0
- package/dist/test-fixtures/protobufs/livekit_agent.proto +185 -0
- package/dist/test-fixtures/protobufs/livekit_agent_dispatch.proto +103 -0
- package/dist/test-fixtures/protobufs/livekit_agent_simulation.proto +422 -0
- package/dist/test-fixtures/protobufs/livekit_agent_worker.proto +29 -0
- package/dist/test-fixtures/protobufs/livekit_agentdb.proto +226 -0
- package/dist/test-fixtures/protobufs/livekit_analytics.proto +312 -0
- package/dist/test-fixtures/protobufs/livekit_cloud_agent.proto +376 -0
- package/dist/test-fixtures/protobufs/livekit_connector.proto +41 -0
- package/dist/test-fixtures/protobufs/livekit_connector_twilio.proto +65 -0
- package/dist/test-fixtures/protobufs/livekit_connector_whatsapp.proto +171 -0
- package/dist/test-fixtures/protobufs/livekit_egress.proto +641 -0
- package/dist/test-fixtures/protobufs/livekit_ingress.proto +222 -0
- package/dist/test-fixtures/protobufs/livekit_internal.proto +228 -0
- package/dist/test-fixtures/protobufs/livekit_metrics.proto +103 -0
- package/dist/test-fixtures/protobufs/livekit_models.proto +992 -0
- package/dist/test-fixtures/protobufs/livekit_phone_number.proto +151 -0
- package/dist/test-fixtures/protobufs/livekit_room.proto +312 -0
- package/dist/test-fixtures/protobufs/livekit_rtc.proto +673 -0
- package/dist/test-fixtures/protobufs/livekit_sip.proto +1000 -0
- package/dist/test-fixtures/protobufs/livekit_token_source.proto +49 -0
- package/dist/test-fixtures/protobufs/livekit_webhook.proto +62 -0
- package/package.json +58 -0
- package/src/cli.ts +22 -0
- package/src/egress-service-cli.ts +111 -0
- package/src/index.ts +103 -0
- package/src/livekit-budget.ts +158 -0
- package/src/livekit-capabilities.ts +789 -0
- package/src/livekit-conformance.ts +15 -0
- package/src/livekit-connector.ts +406 -0
- package/src/livekit-data.ts +278 -0
- package/src/livekit-perform-harness.ts +17 -0
- package/src/livekit-server.ts +67 -0
- package/src/livekit-service-cli.ts +93 -0
- package/src/livekit-token.ts +133 -0
- package/src/livekit-twin.ts +1162 -0
- package/src/livekit-types.ts +211 -0
- package/src/livekit-webhook.ts +91 -0
- package/src/redis-service-cli.ts +39 -0
- package/test-fixtures/livekit-openapi-operations.SOURCE.md +88 -0
- package/test-fixtures/livekit-openapi-operations.json +442 -0
- package/test-fixtures/protobufs/cloud_replay.proto +82 -0
- package/test-fixtures/protobufs/livekit_agent.proto +185 -0
- package/test-fixtures/protobufs/livekit_agent_dispatch.proto +103 -0
- package/test-fixtures/protobufs/livekit_agent_simulation.proto +422 -0
- package/test-fixtures/protobufs/livekit_agent_worker.proto +29 -0
- package/test-fixtures/protobufs/livekit_agentdb.proto +226 -0
- package/test-fixtures/protobufs/livekit_analytics.proto +312 -0
- package/test-fixtures/protobufs/livekit_cloud_agent.proto +376 -0
- package/test-fixtures/protobufs/livekit_connector.proto +41 -0
- package/test-fixtures/protobufs/livekit_connector_twilio.proto +65 -0
- package/test-fixtures/protobufs/livekit_connector_whatsapp.proto +171 -0
- package/test-fixtures/protobufs/livekit_egress.proto +641 -0
- package/test-fixtures/protobufs/livekit_ingress.proto +222 -0
- package/test-fixtures/protobufs/livekit_internal.proto +228 -0
- package/test-fixtures/protobufs/livekit_metrics.proto +103 -0
- package/test-fixtures/protobufs/livekit_models.proto +992 -0
- package/test-fixtures/protobufs/livekit_phone_number.proto +151 -0
- package/test-fixtures/protobufs/livekit_room.proto +312 -0
- package/test-fixtures/protobufs/livekit_rtc.proto +673 -0
- package/test-fixtures/protobufs/livekit_sip.proto +1000 -0
- package/test-fixtures/protobufs/livekit_token_source.proto +49 -0
- package/test-fixtures/protobufs/livekit_webhook.proto +62 -0
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
// Copyright 2026 LiveKit, Inc.
|
|
2
|
+
//
|
|
3
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
// you may not use this file except in compliance with the License.
|
|
5
|
+
// You may obtain a copy of the License at
|
|
6
|
+
//
|
|
7
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
//
|
|
9
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
// See the License for the specific language governing permissions and
|
|
13
|
+
// limitations under the License.
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
syntax = "proto3";
|
|
17
|
+
|
|
18
|
+
package livekit;
|
|
19
|
+
|
|
20
|
+
option go_package = "github.com/livekit/protocol/livekit";
|
|
21
|
+
option csharp_namespace = "LiveKit.Proto";
|
|
22
|
+
option ruby_package = "LiveKit::Proto";
|
|
23
|
+
|
|
24
|
+
// AgentDBService is the lifecycle and export API for SQLite databases; queries
|
|
25
|
+
// run over the data plane below. The project comes from the access token.
|
|
26
|
+
service AgentDBService {
|
|
27
|
+
rpc CreateDatabase(AgentDB.CreateRequest) returns (AgentDB.CreateResponse);
|
|
28
|
+
rpc GetDatabase(AgentDB.GetRequest) returns (AgentDB.AgentDatabase);
|
|
29
|
+
rpc ListDatabases(AgentDB.ListRequest) returns (AgentDB.ListResponse);
|
|
30
|
+
// Deletes the stored data, not just the metadata.
|
|
31
|
+
rpc DeleteDatabase(AgentDB.DeleteRequest) returns (AgentDB.DeleteResponse);
|
|
32
|
+
// Exports a consistent SQLite file as a time-limited download URL.
|
|
33
|
+
rpc DumpDatabase(AgentDB.DumpRequest) returns (AgentDB.DumpResponse);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// Nested so that names like Value and Ping need not be unique across the
|
|
37
|
+
// livekit package. `tip` throughout is the latest durable commit sequence.
|
|
38
|
+
message AgentDB {
|
|
39
|
+
message CreateRequest {
|
|
40
|
+
string region = 1;
|
|
41
|
+
// Unset: never expires, and expires_at is then 0 everywhere.
|
|
42
|
+
// Otherwise clamped to the server cap, and never extended.
|
|
43
|
+
int64 ttl_seconds = 2;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
message CreateResponse {
|
|
47
|
+
string database_id = 1; // "DB_..."
|
|
48
|
+
int64 expires_at = 2;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
message GetRequest {
|
|
52
|
+
string database_id = 1;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
message ListRequest {
|
|
56
|
+
int32 page_size = 1; // server-clamped
|
|
57
|
+
string page_token = 2;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
message ListResponse {
|
|
61
|
+
repeated AgentDatabase databases = 1;
|
|
62
|
+
string next_page_token = 2; // empty when exhausted
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
// One database, as get and list both report it.
|
|
66
|
+
message AgentDatabase {
|
|
67
|
+
string database_id = 1;
|
|
68
|
+
string region = 2;
|
|
69
|
+
int64 created_at = 3;
|
|
70
|
+
int64 expires_at = 4;
|
|
71
|
+
int64 tip = 5;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
message DeleteRequest {
|
|
75
|
+
string database_id = 1;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
message DeleteResponse {}
|
|
79
|
+
|
|
80
|
+
message DumpRequest {
|
|
81
|
+
string database_id = 1;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
message DumpResponse {
|
|
85
|
+
string download_url = 1; // pre-authenticated object-storage URL
|
|
86
|
+
int64 expires_at = 2; // of the URL, not the database
|
|
87
|
+
int64 tip = 3; // what the dump is consistent at
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
// Data plane: one WebSocket per database, one message per frame, correlated
|
|
91
|
+
// by a client-chosen request_id. Result batches are paced by Credit, so the
|
|
92
|
+
// server never sends more un-consumed batches than granted.
|
|
93
|
+
message Wire {
|
|
94
|
+
message ClientMessage {
|
|
95
|
+
uint32 request_id = 1;
|
|
96
|
+
oneof message {
|
|
97
|
+
Hello hello = 2; // must be first on the socket
|
|
98
|
+
Statement exec = 3; // answers ExecResult
|
|
99
|
+
Statement query = 4; // answers Columns + ColumnBatch* + Done
|
|
100
|
+
Batch batch = 5;
|
|
101
|
+
Begin begin = 6;
|
|
102
|
+
Commit commit = 7;
|
|
103
|
+
Rollback rollback = 8;
|
|
104
|
+
Cancel cancel = 9;
|
|
105
|
+
Credit credit = 10;
|
|
106
|
+
Ping ping = 11;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
message ServerMessage {
|
|
111
|
+
uint32 request_id = 1;
|
|
112
|
+
oneof message {
|
|
113
|
+
HelloOk hello_ok = 2;
|
|
114
|
+
Columns columns = 3;
|
|
115
|
+
ColumnBatch column_batch = 4;
|
|
116
|
+
ExecResult exec_result = 5;
|
|
117
|
+
Done done = 6;
|
|
118
|
+
Error error = 7;
|
|
119
|
+
Pong pong = 8;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
enum QueryLang {
|
|
124
|
+
SQL = 0;
|
|
125
|
+
reserved 1;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
// SQLite's five storage classes.
|
|
129
|
+
message Value {
|
|
130
|
+
oneof value {
|
|
131
|
+
bool null_value = 1; // always true when set
|
|
132
|
+
int64 int_value = 2;
|
|
133
|
+
double double_value = 3;
|
|
134
|
+
string text_value = 4;
|
|
135
|
+
bytes blob_value = 5;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
message Statement {
|
|
140
|
+
string sql = 1;
|
|
141
|
+
repeated Value params = 2; // positional
|
|
142
|
+
QueryLang lang = 3;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
message Batch {
|
|
146
|
+
repeated Statement statements = 1; // applied atomically, in order
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
message Begin {}
|
|
150
|
+
message Commit {}
|
|
151
|
+
message Rollback {}
|
|
152
|
+
message Cancel {}
|
|
153
|
+
|
|
154
|
+
message Credit {
|
|
155
|
+
uint32 batches = 1; // additional batches the client can absorb
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
message Ping {
|
|
159
|
+
int64 timestamp_ms = 1;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
message Pong {
|
|
163
|
+
int64 last_ping_timestamp_ms = 1;
|
|
164
|
+
int64 timestamp_ms = 2;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
message Hello {
|
|
168
|
+
string token = 1;
|
|
169
|
+
string database_id = 2;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
message HelloOk {
|
|
173
|
+
int64 tip = 1;
|
|
174
|
+
uint32 ping_interval_ms = 2;
|
|
175
|
+
uint32 ping_timeout_ms = 3;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
message Columns {
|
|
179
|
+
repeated string names = 1;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
enum ValueType {
|
|
183
|
+
NULL = 0;
|
|
184
|
+
INT = 1;
|
|
185
|
+
DOUBLE = 2;
|
|
186
|
+
TEXT = 3;
|
|
187
|
+
BLOB = 4;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
// Values are typed per row, as SQLite types them, so a column may mix
|
|
191
|
+
// classes: walk `types` and take the next entry from the matching array. Text
|
|
192
|
+
// and blobs are concatenated with one exclusive end offset each, so value i
|
|
193
|
+
// is data[ends[i-1]:ends[i]] with 0 implied before the first. A NULL occupies
|
|
194
|
+
// a tag only.
|
|
195
|
+
message Column {
|
|
196
|
+
bytes types = 1; // one ValueType per row
|
|
197
|
+
repeated sint64 ints = 2;
|
|
198
|
+
repeated double doubles = 3;
|
|
199
|
+
bytes text_data = 4;
|
|
200
|
+
repeated uint32 text_ends = 5;
|
|
201
|
+
bytes blob_data = 6;
|
|
202
|
+
repeated uint32 blob_ends = 7;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
message ColumnBatch {
|
|
206
|
+
repeated Column columns = 1; // one per name in Columns
|
|
207
|
+
uint32 rows = 2;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
message ExecResult {
|
|
211
|
+
int64 rows_affected = 1;
|
|
212
|
+
int64 last_insert_id = 2;
|
|
213
|
+
int64 tip = 3;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
message Done {
|
|
217
|
+
int64 tip = 1; // the snapshot the query ran at
|
|
218
|
+
uint64 total_rows = 2;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
message Error {
|
|
222
|
+
string code = 1; // stable, machine-readable
|
|
223
|
+
string message = 2;
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
}
|
|
@@ -0,0 +1,312 @@
|
|
|
1
|
+
// Copyright 2023 LiveKit, Inc.
|
|
2
|
+
//
|
|
3
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
// you may not use this file except in compliance with the License.
|
|
5
|
+
// You may obtain a copy of the License at
|
|
6
|
+
//
|
|
7
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
//
|
|
9
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
// See the License for the specific language governing permissions and
|
|
13
|
+
// limitations under the License.
|
|
14
|
+
|
|
15
|
+
syntax = "proto3";
|
|
16
|
+
|
|
17
|
+
package livekit;
|
|
18
|
+
|
|
19
|
+
import "google/protobuf/timestamp.proto";
|
|
20
|
+
import "livekit_egress.proto";
|
|
21
|
+
import "livekit_ingress.proto";
|
|
22
|
+
import "livekit_models.proto";
|
|
23
|
+
import "livekit_room.proto";
|
|
24
|
+
import "livekit_sip.proto";
|
|
25
|
+
import "logger/options.proto";
|
|
26
|
+
|
|
27
|
+
option csharp_namespace = "LiveKit.Proto";
|
|
28
|
+
option go_package = "github.com/livekit/protocol/livekit";
|
|
29
|
+
option ruby_package = "LiveKit::Proto";
|
|
30
|
+
|
|
31
|
+
enum StreamType {
|
|
32
|
+
UPSTREAM = 0;
|
|
33
|
+
DOWNSTREAM = 1;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
message AnalyticsVideoLayer {
|
|
37
|
+
int32 layer = 1;
|
|
38
|
+
uint32 packets = 2;
|
|
39
|
+
uint64 bytes = 3;
|
|
40
|
+
uint32 frames = 4;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
message AnalyticsStream {
|
|
44
|
+
uint32 ssrc = 1;
|
|
45
|
+
uint32 primary_packets = 2;
|
|
46
|
+
uint64 primary_bytes = 3;
|
|
47
|
+
uint32 retransmit_packets = 4;
|
|
48
|
+
uint64 retransmit_bytes = 5;
|
|
49
|
+
uint32 padding_packets = 6;
|
|
50
|
+
uint64 padding_bytes = 7;
|
|
51
|
+
uint32 packets_lost = 8;
|
|
52
|
+
uint32 frames = 9;
|
|
53
|
+
uint32 rtt = 10;
|
|
54
|
+
uint32 jitter = 11;
|
|
55
|
+
uint32 nacks = 12;
|
|
56
|
+
uint32 plis = 13;
|
|
57
|
+
uint32 firs = 14;
|
|
58
|
+
repeated AnalyticsVideoLayer video_layers = 15;
|
|
59
|
+
google.protobuf.Timestamp start_time = 17;
|
|
60
|
+
google.protobuf.Timestamp end_time = 18;
|
|
61
|
+
uint32 packets_out_of_order = 19;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
message AnalyticsStat {
|
|
65
|
+
// unique id for this stat
|
|
66
|
+
string id = 14;
|
|
67
|
+
string analytics_key = 1;
|
|
68
|
+
StreamType kind = 2;
|
|
69
|
+
google.protobuf.Timestamp time_stamp = 3;
|
|
70
|
+
string node = 4;
|
|
71
|
+
string room_id = 5 [(logger.name) = "roomID"];
|
|
72
|
+
string room_name = 6;
|
|
73
|
+
string participant_id = 7 [(logger.name) = "participantID"];
|
|
74
|
+
string track_id = 8 [(logger.name) = "trackID"];
|
|
75
|
+
float score = 9; // average score
|
|
76
|
+
repeated AnalyticsStream streams = 10;
|
|
77
|
+
string mime = 11;
|
|
78
|
+
float min_score = 12;
|
|
79
|
+
float median_score = 13;
|
|
80
|
+
|
|
81
|
+
// NEXT_ID: 15
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
message AnalyticsStats {
|
|
85
|
+
repeated AnalyticsStat stats = 1;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
enum AnalyticsEventType {
|
|
89
|
+
ROOM_CREATED = 0;
|
|
90
|
+
ROOM_ENDED = 1;
|
|
91
|
+
PARTICIPANT_JOINED = 2;
|
|
92
|
+
PARTICIPANT_LEFT = 3;
|
|
93
|
+
PARTICIPANT_CONNECTION_ABORTED = 45;
|
|
94
|
+
TRACK_PUBLISHED = 4;
|
|
95
|
+
TRACK_PUBLISH_REQUESTED = 20;
|
|
96
|
+
TRACK_UNPUBLISHED = 5;
|
|
97
|
+
TRACK_SUBSCRIBED = 6;
|
|
98
|
+
TRACK_SUBSCRIBE_REQUESTED = 21;
|
|
99
|
+
TRACK_SUBSCRIBE_FAILED = 25;
|
|
100
|
+
TRACK_UNSUBSCRIBED = 7;
|
|
101
|
+
TRACK_PUBLISHED_UPDATE = 10;
|
|
102
|
+
TRACK_MUTED = 23;
|
|
103
|
+
TRACK_UNMUTED = 24;
|
|
104
|
+
TRACK_PUBLISH_STATS = 26;
|
|
105
|
+
TRACK_SUBSCRIBE_STATS = 27;
|
|
106
|
+
PARTICIPANT_ACTIVE = 11;
|
|
107
|
+
PARTICIPANT_RESUMED = 22;
|
|
108
|
+
EGRESS_STARTED = 12;
|
|
109
|
+
EGRESS_ENDED = 13;
|
|
110
|
+
EGRESS_UPDATED = 28;
|
|
111
|
+
TRACK_MAX_SUBSCRIBED_VIDEO_QUALITY = 14;
|
|
112
|
+
RECONNECTED = 15;
|
|
113
|
+
INGRESS_CREATED = 18;
|
|
114
|
+
INGRESS_DELETED = 19;
|
|
115
|
+
INGRESS_STARTED = 16;
|
|
116
|
+
INGRESS_ENDED = 17;
|
|
117
|
+
INGRESS_UPDATED = 29;
|
|
118
|
+
SIP_INBOUND_TRUNK_CREATED = 30;
|
|
119
|
+
SIP_INBOUND_TRUNK_DELETED = 31;
|
|
120
|
+
SIP_OUTBOUND_TRUNK_CREATED = 32;
|
|
121
|
+
SIP_OUTBOUND_TRUNK_DELETED = 33;
|
|
122
|
+
SIP_DISPATCH_RULE_CREATED = 34;
|
|
123
|
+
SIP_DISPATCH_RULE_DELETED = 35;
|
|
124
|
+
SIP_PARTICIPANT_CREATED = 36;
|
|
125
|
+
SIP_CALL_INCOMING = 37;
|
|
126
|
+
SIP_CALL_STARTED = 38;
|
|
127
|
+
SIP_CALL_ENDED = 39;
|
|
128
|
+
SIP_TRANSFER_REQUESTED = 43;
|
|
129
|
+
SIP_TRANSFER_COMPLETE = 44;
|
|
130
|
+
SIP_CALL_UPDATE = 46;
|
|
131
|
+
REPORT = 40;
|
|
132
|
+
API_CALL = 41;
|
|
133
|
+
WEBHOOK = 42;
|
|
134
|
+
|
|
135
|
+
// NEXT_ID: 47
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
message AnalyticsClientMeta {
|
|
139
|
+
string region = 1;
|
|
140
|
+
string node = 2;
|
|
141
|
+
string client_addr = 3;
|
|
142
|
+
uint32 client_connect_time = 4;
|
|
143
|
+
// udp, tcp, turn
|
|
144
|
+
string connection_type = 5;
|
|
145
|
+
ReconnectReason reconnect_reason = 6;
|
|
146
|
+
optional string geo_hash = 7;
|
|
147
|
+
optional string country = 8;
|
|
148
|
+
optional uint32 isp_asn = 9;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
message AnalyticsEvent {
|
|
152
|
+
// unique id for this event
|
|
153
|
+
string id = 25;
|
|
154
|
+
AnalyticsEventType type = 1;
|
|
155
|
+
google.protobuf.Timestamp timestamp = 2;
|
|
156
|
+
string room_id = 3 [(logger.name) = "roomID"];
|
|
157
|
+
Room room = 4;
|
|
158
|
+
string participant_id = 5 [(logger.name) = "participantID"];
|
|
159
|
+
ParticipantInfo participant = 6;
|
|
160
|
+
string track_id = 7 [(logger.name) = "trackID"];
|
|
161
|
+
TrackInfo track = 8;
|
|
162
|
+
string analytics_key = 10;
|
|
163
|
+
ClientInfo client_info = 11;
|
|
164
|
+
AnalyticsClientMeta client_meta = 12;
|
|
165
|
+
string egress_id = 13 [(logger.name) = "egressID"];
|
|
166
|
+
string ingress_id = 19 [(logger.name) = "ingressID"];
|
|
167
|
+
VideoQuality max_subscribed_video_quality = 14;
|
|
168
|
+
ParticipantInfo publisher = 15;
|
|
169
|
+
string mime = 16;
|
|
170
|
+
EgressInfo egress = 17;
|
|
171
|
+
IngressInfo ingress = 18;
|
|
172
|
+
string error = 20;
|
|
173
|
+
RTPStats rtp_stats = 21;
|
|
174
|
+
int32 video_layer = 22;
|
|
175
|
+
string node_id = 24 [(logger.name) = "nodeID"];
|
|
176
|
+
string sip_call_id = 26 [(logger.name) = "sipCallID"];
|
|
177
|
+
SIPCallInfo sip_call = 27;
|
|
178
|
+
string sip_trunk_id = 28 [(logger.name) = "sipTrunkID"];
|
|
179
|
+
SIPInboundTrunkInfo sip_inbound_trunk = 29;
|
|
180
|
+
SIPOutboundTrunkInfo sip_outbound_trunk = 30;
|
|
181
|
+
string sip_dispatch_rule_id = 31 [(logger.name) = "sipDispatchRuleID"];
|
|
182
|
+
SIPDispatchRuleInfo sip_dispatch_rule = 32;
|
|
183
|
+
SIPTransferInfo sip_transfer = 36;
|
|
184
|
+
ReportInfo report = 33;
|
|
185
|
+
APICallInfo api_call = 34;
|
|
186
|
+
WebhookInfo webhook = 35;
|
|
187
|
+
RoomEndReason room_end_reason = 37;
|
|
188
|
+
|
|
189
|
+
// NEXT_ID: 38
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
message AnalyticsEvents {
|
|
193
|
+
repeated AnalyticsEvent events = 1;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
message AnalyticsRoomParticipant {
|
|
197
|
+
string id = 1;
|
|
198
|
+
string identity = 2;
|
|
199
|
+
string name = 3;
|
|
200
|
+
ParticipantInfo.State state = 4;
|
|
201
|
+
google.protobuf.Timestamp joined_at = 5;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
message AnalyticsRoom {
|
|
205
|
+
string id = 1;
|
|
206
|
+
string name = 2;
|
|
207
|
+
string project_id = 5 [(logger.name) = "projectID"];
|
|
208
|
+
google.protobuf.Timestamp created_at = 3;
|
|
209
|
+
repeated AnalyticsRoomParticipant participants = 4;
|
|
210
|
+
|
|
211
|
+
// NEXT_ID: 6
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
message AnalyticsNodeRooms {
|
|
215
|
+
string node_id = 1 [(logger.name) = "nodeID"];
|
|
216
|
+
uint64 sequence_number = 2;
|
|
217
|
+
google.protobuf.Timestamp timestamp = 3;
|
|
218
|
+
repeated AnalyticsRoom rooms = 4;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
message ReportInfo {
|
|
222
|
+
oneof message {
|
|
223
|
+
FeatureUsageInfo feature_usage = 1;
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
message TimeRange {
|
|
228
|
+
google.protobuf.Timestamp started_at = 1;
|
|
229
|
+
google.protobuf.Timestamp ended_at = 2;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
message FeatureUsageInfo {
|
|
233
|
+
enum Feature {
|
|
234
|
+
KRISP_NOISE_CANCELLATION = 0;
|
|
235
|
+
KRISP_BACKGROUND_VOICE_CANCELLATION = 1;
|
|
236
|
+
AIC_AUDIO_ENHANCEMENT = 2;
|
|
237
|
+
KRISP_VIVA = 3;
|
|
238
|
+
}
|
|
239
|
+
Feature feature = 1;
|
|
240
|
+
string project_id = 2 [(logger.name) = "projectID"];
|
|
241
|
+
string room_name = 3;
|
|
242
|
+
string room_id = 4 [(logger.name) = "roomID"];
|
|
243
|
+
string participant_identity = 5;
|
|
244
|
+
string participant_id = 6 [(logger.name) = "participantID"];
|
|
245
|
+
string track_id = 7 [(logger.name) = "trackID"];
|
|
246
|
+
// time ranges during which the feature was enabled.
|
|
247
|
+
// for e. g., noise cancellation may not be applied when a media track is paused/muted,
|
|
248
|
+
// this allows reporting only periods during which a feature is active.
|
|
249
|
+
repeated TimeRange time_ranges = 8;
|
|
250
|
+
|
|
251
|
+
// Feature specific metadata included in the report
|
|
252
|
+
map<string, string> feature_info = 9;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
message APICallRequest {
|
|
256
|
+
oneof message {
|
|
257
|
+
CreateRoomRequest create_room_request = 1;
|
|
258
|
+
ListRoomsRequest list_rooms_request = 2;
|
|
259
|
+
DeleteRoomRequest delete_room_request = 3;
|
|
260
|
+
ListParticipantsRequest list_participants_request = 4;
|
|
261
|
+
RoomParticipantIdentity room_participant_identity = 5;
|
|
262
|
+
MuteRoomTrackRequest mute_room_track_request = 6;
|
|
263
|
+
UpdateParticipantRequest update_participant_request = 7;
|
|
264
|
+
UpdateSubscriptionsRequest update_subscriptions_request = 8;
|
|
265
|
+
SendDataRequest send_data_request = 9;
|
|
266
|
+
UpdateRoomMetadataRequest update_room_metadata_request = 10;
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
message APICallInfo {
|
|
271
|
+
string project_id = 1 [(logger.name) = "projectID"];
|
|
272
|
+
APICallRequest request = 2;
|
|
273
|
+
string service = 3;
|
|
274
|
+
string method = 4;
|
|
275
|
+
string node_id = 5 [(logger.name) = "nodeID"];
|
|
276
|
+
int32 status = 6;
|
|
277
|
+
string twirp_error_code = 7;
|
|
278
|
+
string twirp_error_message = 8;
|
|
279
|
+
string room_name = 9;
|
|
280
|
+
string room_id = 10 [(logger.name) = "roomID"];
|
|
281
|
+
string participant_identity = 11;
|
|
282
|
+
string participant_id = 12 [(logger.name) = "participantID"];
|
|
283
|
+
string track_id = 13 [(logger.name) = "trackID"];
|
|
284
|
+
google.protobuf.Timestamp started_at = 14;
|
|
285
|
+
int64 duration_ns = 15;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
message WebhookInfo {
|
|
289
|
+
string event_id = 1 [(logger.name) = "eventID"];
|
|
290
|
+
string event = 2;
|
|
291
|
+
string project_id = 3 [(logger.name) = "projectID"];
|
|
292
|
+
string room_name = 4;
|
|
293
|
+
string room_id = 5 [(logger.name) = "roomID"];
|
|
294
|
+
string participant_identity = 6;
|
|
295
|
+
string participant_id = 7 [(logger.name) = "participantID"];
|
|
296
|
+
string track_id = 8 [(logger.name) = "trackID"];
|
|
297
|
+
string egress_id = 9 [(logger.name) = "egressID"];
|
|
298
|
+
string ingress_id = 10 [(logger.name) = "ingressID"];
|
|
299
|
+
google.protobuf.Timestamp created_at = 11;
|
|
300
|
+
google.protobuf.Timestamp queued_at = 12;
|
|
301
|
+
int64 queue_duration_ns = 13;
|
|
302
|
+
google.protobuf.Timestamp sent_at = 14;
|
|
303
|
+
int64 send_duration_ns = 15;
|
|
304
|
+
string url = 16;
|
|
305
|
+
int32 num_dropped = 17;
|
|
306
|
+
bool is_dropped = 18;
|
|
307
|
+
string service_status = 19;
|
|
308
|
+
int32 service_error_code = 20;
|
|
309
|
+
string service_error = 21;
|
|
310
|
+
string send_error = 22;
|
|
311
|
+
int32 http_status_code = 23; // HTTP response status code for the delivery attempt (0 if no response).
|
|
312
|
+
}
|