github.com/livekit/protocol@v1.39.3/protobufs/livekit_agent_dispatch.proto (about) 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 option go_package = "github.com/livekit/protocol/livekit"; 19 option csharp_namespace = "LiveKit.Proto"; 20 option ruby_package = "LiveKit::Proto"; 21 22 import "livekit_agent.proto"; 23 24 service AgentDispatchService { 25 rpc CreateDispatch(CreateAgentDispatchRequest) returns (AgentDispatch); 26 rpc DeleteDispatch(DeleteAgentDispatchRequest) returns (AgentDispatch); 27 rpc ListDispatch(ListAgentDispatchRequest) returns (ListAgentDispatchResponse); 28 } 29 30 message CreateAgentDispatchRequest { 31 string agent_name = 1; 32 string room = 2; 33 string metadata = 3; 34 } 35 36 message RoomAgentDispatch { 37 string agent_name = 1; 38 string metadata = 2; 39 } 40 41 message DeleteAgentDispatchRequest { 42 string dispatch_id = 1; 43 string room = 2; 44 } 45 46 message ListAgentDispatchRequest { 47 string dispatch_id = 1; // if set, only the dispatch whose id is given will be returned 48 string room = 2; // name of the room to list agents for. Must be set. 49 } 50 51 message ListAgentDispatchResponse { 52 repeated AgentDispatch agent_dispatches = 1; 53 } 54 55 message AgentDispatch { 56 string id = 1; 57 string agent_name = 2; 58 string room = 3; 59 string metadata = 4; 60 AgentDispatchState state = 5; 61 } 62 63 message AgentDispatchState { 64 // For dispatches of tyoe JT_ROOM, there will be at most 1 job. 65 // For dispatches of type JT_PUBLISHER, there will be 1 per publisher. 66 repeated Job jobs = 1; 67 int64 created_at = 2; 68 int64 deleted_at = 3; 69 } 70