github.com/livekit/protocol@v1.39.3/protobufs/livekit_cloud_agent.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  import "google/protobuf/timestamp.proto";
    18  
    19  package livekit;
    20  option go_package = "github.com/livekit/protocol/livekit";
    21  option csharp_namespace = "LiveKit.Proto";
    22  option ruby_package = "LiveKit::Proto";
    23  
    24  message AgentSecret {
    25      string name = 1;
    26      bytes value = 2;
    27      google.protobuf.Timestamp created_at = 3;
    28      google.protobuf.Timestamp updated_at = 4;
    29  }
    30  
    31  message CreateAgentRequest {
    32      string agent_name            = 1 [deprecated=true];
    33      repeated AgentSecret secrets = 2;
    34      int32 replicas               = 3 [deprecated=true];
    35      int32 max_replicas           = 4 [deprecated=true];
    36      string cpu_req               = 5 [deprecated=true];
    37      repeated string regions      = 6;
    38  }
    39  
    40  message CreateAgentResponse {
    41      string agent_id = 1;
    42      string agent_name = 2;
    43      string status = 3;
    44      string version = 4;
    45      string presigned_url = 5;
    46  }
    47  
    48  message AgentDeployment {
    49      string region = 1;
    50      string agent_id = 2;
    51      string status = 3;
    52      int32 replicas = 4;
    53      int32 min_replicas = 5;
    54      int32 max_replicas = 6;
    55      string cpu_req = 7;
    56      string cur_cpu = 8;
    57      string cur_mem = 9;
    58      string mem_req = 10;
    59      string mem_limit = 11;
    60      string cpu_limit = 12;
    61  }
    62  
    63  message AgentInfo {
    64      string agent_id = 1;
    65      string agent_name = 2;
    66      string version = 3;
    67      repeated AgentDeployment agent_deployments = 4;
    68      repeated AgentSecret secrets = 5;
    69      google.protobuf.Timestamp deployed_at = 6;
    70  }
    71  
    72  message ListAgentsRequest {
    73      string agent_name = 1;
    74      string agent_id = 2;
    75  }
    76  
    77  message ListAgentsResponse {
    78      repeated AgentInfo agents = 1;
    79  }
    80  
    81  message AgentVersion {
    82      string version = 1;
    83      bool current = 2;
    84      google.protobuf.Timestamp created_at = 3;
    85  }
    86  
    87  message ListAgentVersionsRequest {
    88      string agent_id = 1;
    89      string agent_name = 2;
    90  }
    91  
    92  message ListAgentVersionsResponse {
    93      repeated AgentVersion versions = 1;
    94  }
    95  
    96  message UpdateAgentRequest {
    97      string agent_id              = 1;
    98      string agent_name            = 2 [deprecated=true];
    99      int32 replicas               = 3 [deprecated=true];
   100      int32 max_replicas           = 4 [deprecated=true];
   101      string cpu_req               = 5 [deprecated=true];
   102      repeated string regions      = 6;
   103      repeated AgentSecret secrets = 7;
   104  }
   105  
   106  message UpdateAgentResponse {
   107      bool success = 1;
   108      string message = 2;
   109  }
   110  
   111  message DeployAgentRequest {
   112      string agent_id              = 1;
   113      string agent_name            = 2 [deprecated=true];
   114      repeated AgentSecret secrets = 3;
   115      int32 replicas               = 4 [deprecated=true];
   116      int32 max_replicas           = 5 [deprecated=true];
   117      string cpu_req               = 6 [deprecated=true];
   118  }
   119  
   120  message DeployAgentResponse {
   121      bool success = 1;
   122      string message = 2;
   123      string agent_id = 3;
   124      string presigned_url = 4;
   125  }
   126  
   127  message UpdateAgentSecretsRequest {
   128      string agent_id = 1;
   129      string agent_name = 2;
   130      bool overwrite = 3;
   131      repeated AgentSecret secrets = 4;
   132  }
   133  
   134  message UpdateAgentSecretsResponse {
   135      bool success = 1;
   136      string message = 2;
   137  }
   138  
   139  message RollbackAgentRequest {
   140      string agent_id = 1;
   141      string agent_name = 2;
   142      string version = 3;
   143  }
   144  
   145  message RollbackAgentResponse {
   146      bool success = 1;
   147      string message = 2;
   148  }
   149  
   150  message DeleteAgentRequest {
   151      string agent_id = 1;
   152      string agent_name = 2;
   153  }
   154  
   155  message DeleteAgentResponse {
   156      bool success = 1;
   157      string message = 2;
   158  }
   159  
   160  message ListAgentSecretsRequest {
   161      string agent_id = 1;
   162      string agent_name = 2;
   163  }
   164  
   165  message ListAgentSecretsResponse {
   166      repeated AgentSecret secrets = 1;
   167  }
   168  
   169  message SettingsParam {
   170      string name = 1;
   171      string value = 2;
   172  }
   173  
   174  message ClientSettingsResponse {
   175      repeated SettingsParam params = 1;
   176  }
   177  
   178  message ClientSettingsRequest {
   179  }
   180  
   181  service CloudAgent {
   182      rpc CreateAgent(CreateAgentRequest) returns (CreateAgentResponse) {}
   183      rpc ListAgents(ListAgentsRequest) returns (ListAgentsResponse) {}
   184      rpc ListAgentVersions(ListAgentVersionsRequest) returns (ListAgentVersionsResponse) {}
   185      rpc ListAgentSecrets(ListAgentSecretsRequest) returns (ListAgentSecretsResponse) {}
   186      rpc UpdateAgent(UpdateAgentRequest) returns (UpdateAgentResponse) {}
   187      rpc DeployAgent(DeployAgentRequest) returns (DeployAgentResponse) {}
   188      rpc UpdateAgentSecrets(UpdateAgentSecretsRequest) returns (UpdateAgentSecretsResponse) {}
   189      rpc RollbackAgent(RollbackAgentRequest) returns (RollbackAgentResponse) {}
   190      rpc DeleteAgent(DeleteAgentRequest) returns (DeleteAgentResponse) {}
   191      rpc GetClientSettings(ClientSettingsRequest) returns (ClientSettingsResponse) {}
   192  }