GitHub Action 3 месяцев назад
Родитель
Сommit
da394439a1
2 измененных файлов с 43 добавлено и 0 удалено
  1. 19 0
      packages/sdk/js/src/v2/gen/types.gen.ts
  2. 24 0
      packages/sdk/openapi.json

+ 19 - 0
packages/sdk/js/src/v2/gen/types.gen.ts

@@ -1156,6 +1156,24 @@ export type KeybindsConfig = {
  */
  */
 export type LogLevel = "DEBUG" | "INFO" | "WARN" | "ERROR"
 export type LogLevel = "DEBUG" | "INFO" | "WARN" | "ERROR"
 
 
+/**
+ * Server configuration for opencode serve and web commands
+ */
+export type ServerConfig = {
+  /**
+   * Port to listen on
+   */
+  port?: number
+  /**
+   * Hostname to listen on
+   */
+  hostname?: string
+  /**
+   * Enable mDNS service discovery
+   */
+  mdns?: boolean
+}
+
 export type AgentConfig = {
 export type AgentConfig = {
   model?: string
   model?: string
   temperature?: number
   temperature?: number
@@ -1416,6 +1434,7 @@ export type Config = {
      */
      */
     diff_style?: "auto" | "stacked"
     diff_style?: "auto" | "stacked"
   }
   }
+  server?: ServerConfig
   /**
   /**
    * Command configuration, see https://opencode.ai/docs/commands
    * Command configuration, see https://opencode.ai/docs/commands
    */
    */

+ 24 - 0
packages/sdk/openapi.json

@@ -7692,6 +7692,27 @@
         "type": "string",
         "type": "string",
         "enum": ["DEBUG", "INFO", "WARN", "ERROR"]
         "enum": ["DEBUG", "INFO", "WARN", "ERROR"]
       },
       },
+      "ServerConfig": {
+        "description": "Server configuration for opencode serve and web commands",
+        "type": "object",
+        "properties": {
+          "port": {
+            "description": "Port to listen on",
+            "type": "integer",
+            "exclusiveMinimum": 0,
+            "maximum": 9007199254740991
+          },
+          "hostname": {
+            "description": "Hostname to listen on",
+            "type": "string"
+          },
+          "mdns": {
+            "description": "Enable mDNS service discovery",
+            "type": "boolean"
+          }
+        },
+        "additionalProperties": false
+      },
       "AgentConfig": {
       "AgentConfig": {
         "type": "object",
         "type": "object",
         "properties": {
         "properties": {
@@ -8178,6 +8199,9 @@
               }
               }
             }
             }
           },
           },
+          "server": {
+            "$ref": "#/components/schemas/ServerConfig"
+          },
           "command": {
           "command": {
             "description": "Command configuration, see https://opencode.ai/docs/commands",
             "description": "Command configuration, see https://opencode.ai/docs/commands",
             "type": "object",
             "type": "object",